Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question #1088

Open
Jiadalee opened this issue Jan 14, 2025 · 0 comments
Open

Question #1088

Jiadalee opened this issue Jan 14, 2025 · 0 comments

Comments

@Jiadalee
Copy link

Hello, I have a question about the run_cellpose_2.ipynb. For the section of Train new model, the initial model was trained and saved to model_path = train_dir + 'models/'. And then, for the following codes from the section of Evaluation on test data below,

masks = model.eval(test_data, channels=[chan, chan2], diameter=diam_labels)[0]

When you run the model on test images, why don'tyou load the trained model "CP_tissuenet" from the path and then pass the trained model for evaluation? why do you still directly call the model.eval()? It seems themodel.eval()` still calls the initial cyto default model, not the trained model' for evaluation. I would think of replacing this code block by below:

trained_model_path = "content/human_in_the_loop/train/models/CP_tissuenet"
model = models.CellposeModel(gpu=True, pretrained_model= trained_model_path )
masks = model.eval(test_data,
channels=[chan, chan2],
diameter=diam_labels)[0]

Could you pls check?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant