Skip to content

Conversation

@mzouink
Copy link
Member

@mzouink mzouink commented Jan 23, 2025

No description provided.

raise ValueError("Currently only supporting nrs/cellmap and /groups/cellmap/cellmap")
# TODO should be done better
ds = get_ds(dataset_path, filetype)
add_layer(s, ds, "raw")
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@davidackerman i want to support multiscale. do you know a better way to open LocalVolume ?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what type of multiscale? also it seems like in the newest neuroglancer you don't need to specify n5:// or zarr://, itll just know it from the https://path

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

e.g. /nrs/cellmap/data/jrc_mus-pancreas-5/jrc_mus-pancreas-5.zarr/recon-1/em/fibsem-uint8
currently i am only supporting one res

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i haven't used funlib.show. but you can just add a multiscale layer to neuroglancer just like this:

 with viewer.txn() as s:
                s.layers["raw"] = neuroglancer.ImageLayer(
                    source=f"zarr://s3://janelia-cosem-datasets/{current_collection}/{current_collection}.zarr/recon-1/em/fibsem-uint8",
                    shaderControls={
                        "normalized": {"range": [contrast_min, contrast_max]}
                    },
                )

is that what you mean?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

but i can't do that for local data. i can't feed a path

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

there seems to be an unsanswered question about this here: google/neuroglancer#515

but maybe something like this would work if zarr allows reading in multiscale. then you would just open the zarr dataset and pass that to local volume:
https://github.com/google/neuroglancer/blob/5a54a489ed3fd679a5beae9906338c602371a9fa/python/examples/interactive_inference.py#L47-L52

@mzouink mzouink merged commit 340d1b0 into main Jan 28, 2025
@mzouink mzouink deleted the data_server branch January 29, 2025 21:03
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.

3 participants