bauerdavid/napari-nD-annotator

Bounding Box does not cover whole object in z

Closed this issue · 5 comments

Hi @bauerdavid,

When using the bounding boxes sometimes not the whole object is in the bounding box in z for me (see screenshot):
bounding_box_bug
Dataset from Ozpolat, B. et al licensed CC BY 4.0 of the marine annelid Platynereis dumerilii, nuclei channel, rescaled.

I assume that the problem is that this object is bigger than the other objects in my image, but in my opinion it would be better to create a bounding box with too many z-slices than one with not enough :)

Best,
Mara

It seems I skipped this issue... 🙁
Actually I determine the bounding box size along z by calculating the average size along x and y. If your object is elongated along z, then it won't fit into the bounding box.
The problem is that it isn't always good to have too many z-slices (for example when working with spheroids). But I see that different use cases need different size options to handle size suggestions along the invisible dimensions. That is why I plan to allow the user to change how it will be determined (some multiple of the average of x-y, fixed etc.). But this will only be solved later... Currently I'm the only one working on this project, so there's a huge To-Do list 😄. But this features is there for sure!

Actually this is already raised in #41, so I'm closing this one for now.

Hey @marabuuu,
I have some good news! As it turns out, I started to work on these functionalities some time ago. With a small tinkering I was able to make it work! I will try to create a release in the upcoming weeks, so stay tuned 😉.

Hey @bauerdavid ,

Awesome, thanks for letting me know!

Best,
Mara

The new version of napari-nD-annotator is out. The bounding box functionality was moved to a separate plugin (napari-bbox), and is included as a dependency. Feel free to check it!

David