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

save meshes in sharded neuroglancer precomputed #584

Open
fb0l opened this issue May 16, 2023 · 2 comments
Open

save meshes in sharded neuroglancer precomputed #584

fb0l opened this issue May 16, 2023 · 2 comments
Labels
question What is going on??? :thinking emoji:

Comments

@fb0l
Copy link

fb0l commented May 16, 2023

Hi everyone,
I have a local dataset in neuroglancer precomputed format (sharded) which also contains meshes.
Following the tutorial, I'm loading the meshes and I'm applying some transformations to them.
After the transformations have been applied, I'd like to save the updated meshes back as sharded neuroglancer precomputed format, ideally into a new output folder.

Is this possible with cloud-volume?
Do you have experience with this use-case and know how to continue?

Thanks!

@william-silversmith
Copy link
Contributor

Hi fb0l,

Producing a shard is kind of convoluted, but if you do the updates in batches, you could try following the code here and replacing the original shard filename:

https://github.com/seung-lab/igneous/blob/master/igneous/tasks/mesh/multires.py#L356-L358

You can also generate an unsharded volume and convert it to sharded using igneous mesh xfer and then delete the original.

Let me know if you need additional help!

@william-silversmith william-silversmith added the question What is going on??? :thinking emoji: label May 16, 2023
@william-silversmith
Copy link
Contributor

I forgot to mention, you might find it beneficial to use disassemble_shard

def disassemble_shard(self, shard):

You'll need to use logic in this file in order to read the multi-lod format:

def extract_lod_meshes(manifest, lod, lod_binary, vertex_quantization_bits, transform):

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question What is going on??? :thinking emoji:
Projects
None yet
Development

No branches or pull requests

2 participants