Skip to content

Add PathCellObjects class and add_cell method #112

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

Merged
merged 5 commits into from
Jun 2, 2024

Conversation

rtubelleza
Copy link
Contributor

Hello, my first PR here.

Was using paquo to directly import results of image processing and cellpose segmentation in python. Realised I needed PathCellObjects like #110

  • Added QuPathPathCellObject similar to how QuPath{Detection/Tile}Object were implemented. Followed class hierarchy defined in original qupath javadocs.
  • Added add_cell method to QuPathPathObjectHierarchy

Currently, I have added the parameter defining a secondary roi for the nuclear region as a keyword argument, named nucleus_roi, to not ruin from_shapely for the other pathobject constructors. The first roi, should therefore be the outer bounds of the cell (or cytoplasmic polygon).

Not sure if we need some sort of checker like roi.contains(nucleus_roi) or nucleus_roi.within(roi) to ensure the nuclear polygon given is within the cell.

Happy to further improve code.

@ap--
Copy link
Collaborator

ap-- commented Jun 2, 2024

Thank you so much for the PR @rtubelleza ❤️

And sorry that it took a long time to get this merged.
I made a few changes and will release a new version asap.

@ap-- ap-- merged commit afa48fa into Bayer-Group:main Jun 2, 2024
9 checks passed
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

Successfully merging this pull request may close these issues.

2 participants