Wrapper improvements for ROIs - #459
Conversation
|
It is a nice improvement for I noticed that And To be consistent with other |
…lity of getShapes)
|
Could you also add support for loading Shapes on the fly in |
762b3ba to
ff1936b
Compare
|
Hey Will, sorry I'm taking this work back after a long pause. Working back on the tags & ROIs, I would need this to handle tags on ROIs.
I reimplemented These should now work: roi_o = conn.getObject("Roi", 123)
shapes = list(roi_o.listChildren())
annotations = list(roi_o.listAnnotations())
print(shapes)
>> [<_ShapeWrapper id=1714>, <_ShapeWrapper id=1715>]
print(annotations)
>> [<TagAnnotationWrapper id=29>, <TagAnnotationWrapper id=28>] |
| return "PlateAcquisitionAnnotationLink" | ||
| if objecttype == "well": | ||
| return "WellAnnotationLink" | ||
| if objecttype == "roi": |
There was a problem hiding this comment.
Was this change needed to fix something? I don't see that getAnnotationLinkTableName() is used anywhere now.
I've tried to make obj.listAnnotations() work for all object types over at #489, but I'd actually missed that getAnnotationLinkTableName() existed.
There was a problem hiding this comment.
Thank you, I removed the changes. It works without it indeed.
|
Thanks for getting back to this. I wonder if you could open a test PR to add a test like Don't worry about testing roi annotations - I've got that covered in ome/openmicroscopy#6458 for #489 Thanks |
|
I reverted my changes in getAnnotationLinkTableName. This was supposed to enable listing of Annotation from Roi, but is not needed anymore as #489 fixes it. I also want to point out another change I have, to list Rois from an Annotation, in |
Changes in this PR are to increase the support of functionalities around ROIs:
getShapesfor an ROI now retrieves wrapped shapes instead ofShapeI