-
Notifications
You must be signed in to change notification settings - Fork 48
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
extract the bounding box of a segment #519
Comments
Hi! This is possible if your dataset was created with a spatial index. Currently, no spatial index exists for images, but by default, igneous generates them for meshes and skeletons. If the index exists, you can access the index as:
get_bbox is a less used feature, so it could be buggy. Let me know if you have problems with it. The spatial index consists of a set of JSON files that spans the whole dataset. If your dataset does not have a spatial index, you can create one with igneous using the command That's a lot of info. The spatial index has been primarily used by myself so there might be some rough edges for other people. Let me know how you like it! Spatial index code: https://github.com/seung-lab/cloud-volume/blob/master/cloudvolume/datasource/precomputed/spatial_index.py |
Thanks! I was actually trying to download the data from one public dataset, and sadly they don't have that spatial_index information. |
I think then that the only way to do it (other than exploiting skeleton and mesh information) is to download the volume in chunks and extract the bounding box information that way (i.e. generate your own spatial_index). I recently improved the means to test whether an ID is in a given region using |
I recently discovered that Neuroglancer has its own version of the spatial index that is not currently supported by CloudVolume. You might have some fruitful exploration with this specification: https://github.com/google/neuroglancer/blob/master/src/neuroglancer/datasource/precomputed/annotations.md |
Thank you so much! This link cleared many confusions of mine. |
I know the mesh and the skeleton can be downloaded using the label ID, but how to obtain all the volume (EM & segment region) belonging to a certain segment. The bounding box around a segment ID should work, but how to obtain the information of that bounding box? Is there a way to obtain this bounding box using cloud-volume or from neuroglancer?
The text was updated successfully, but these errors were encountered: