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

Is it recommended to run the jupyter notebook on the entire set of images, or can it be processed in smaller batches? #152

Closed
kernco opened this issue Nov 24, 2020 · 1 comment

Comments

@kernco
Copy link

kernco commented Nov 24, 2020

Hi, sorry if posting this question here is abusing the purpose of Github's issues feature, but I didn't see any information in the documentation about where to go or who to contact if we have questions about cellpose.

I'm using the jupyter notebook that's provided for running cellpose, and I'm noticing that it loads all the images into memory and then runs model.eval, io.masks_flow_to_seg, etc. on these lists. Do these functions take lists of images as a convenience to do batch processing, or do they actually aggregate information across multiple images for doing the segmentation? I'm wondering if there would be a downside to running these functions on each image one at a time, or at least on smaller batches, as the number of images in our experiments are too large to fit all of them in memory at the same time.

@carsen-stringer
Copy link
Member

No this is a good question, we are not running batches which contain multiple different images, so there is no change in performance whether or not you use lists or single images as inputs. I've modified the example notebook accordingly to show both running in a loop and running images as a list.

the only time you would need to provide a single list is if you wanted cellpose to stitch together 2D images into a 3D volume with the stitch_threshold parameter activated.

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

2 participants