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

polygon cell geometry of Baysor segmentation vs Xenium #142

Open
alipirani88 opened this issue Oct 15, 2024 · 2 comments
Open

polygon cell geometry of Baysor segmentation vs Xenium #142

alipirani88 opened this issue Oct 15, 2024 · 2 comments
Labels
question Further information is requested

Comments

@alipirani88
Copy link

Hi @VPetukhov

I ran baysor with the following parameters:
-m 50 -p --prior-segmentation-confidence 0.2 --scale-std 0.8 --scale 5 --save-polygons GeoJSON

I see the cell boundaries are drawn like a polygon compare to xenium cell boundaries which seems to be more uniform. Is this expected from Baysor or did something went wrong during the segmentation?

I also see Baysor finding cells of unusual shapes and size in areas which Xenium segmentation is missing? I am not sure what to make ofit?

I would appreciate your thoughts on it.

Screenshot 2024-10-14 at 12 50 52 PM

@alipirani88
Copy link
Author

Also, the xenium sample is a multi tissue array - can baysor handle multi-tissue arrays ?

@VPetukhov
Copy link
Collaborator

VPetukhov commented Oct 16, 2024

Hi @alipirani88 ,

I see the cell boundaries are drawn like a polygon compare to xenium cell boundaries which seems to be more uniform. Is this expected from Baysor or did something went wrong during the segmentation?

Yes, that's how Baysor usually outputs polygons. It's a variation of a concave hull algorithm.

I also see Baysor finding cells of unusual shapes and size in areas which Xenium segmentation is missing? I am not sure what to make ofit?

Regions without prior segmentation are segmented de-novo. If you think that their size is too large, you can either manually provide scale parameter and set it to a smaller value, or you can filter the final segmentation results by cell area.

Also, the xenium sample is a multi tissue array - can baysor handle multi-tissue arrays ?

Baysor assumes uniform cell sizes, which can be violated in multi-tissue arrays. It can also be violated within the same tissue, but if that's the case see #140. That can be a reason why you see cells of unusual size. Also, in multi-tissue arrays NCV coloring would capture tissue differences instead of cell types. So, it would be better to split the data by tissue before Baysor.

@VPetukhov VPetukhov added the question Further information is requested label Oct 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants