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

Baysor segmentaion stain #216

Open
lkmartin90 opened this issue Feb 20, 2025 · 4 comments
Open

Baysor segmentaion stain #216

lkmartin90 opened this issue Feb 20, 2025 · 4 comments

Comments

@lkmartin90
Copy link

Thanks for the great tool.
I have a question I can't find the answer to in the documentation. How do we know which stain Baysor is using to segment, and can we change this in the config file?
Sorry if I've missed this somewhere.

@quentinblampey
Copy link
Collaborator

Hello @lkmartin90, Baysor is not using any image for segmentation, it only uses the transcripts. Yet, Baysor can use a prior, e.g. we can run Cellpose on DAPI (or any other stain), and provide it to Baysor as a prior.

Does this help? Which technology do you use?
Let me know if you have additional questions

@lkmartin90
Copy link
Author

lkmartin90 commented Feb 20, 2025

Ah - sorry, my misunderstanding; I read that Baysor also used the stain for segmentation and didn't realise it was in the prior! I'm using CosMx, and despite a fairly good prior segmentation, I am struggling to get the Baysor output to look nice, mainly due to overlapping cells, even when I force it to work in 2D. However, this may just be our data.
Thanks for the help!

@quentinblampey
Copy link
Collaborator

Which prior_segmentation_confidence do you use? This Baysor parameter can be very important, and if you like your prior segmentation I recommend setting a high value, e.g. prior_segmentation_confidence=0.9.

Regarding the cells overlap, this happens mostly when using Baysor. I will soon improve this (once shapely==2.1.0 is released). You can either wait for this new feature, or you can also try other segmentation tools inside Sopa such as ComSeg.

@lkmartin90
Copy link
Author

I'm using a prior confidence of 0.9. Thanks for the help, I'll also try ComSeg!

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