Repository navigation
fix(views): match standalone Neuroglancer layer types in Views - #494
Open
allison-truhlar wants to merge 5 commits into
Open
allison-truhlar wants to merge 5 commits into
allison-truhlar wants to merge 5 commits into
Conversation
Match the standalone Neuroglancer button in Views. It has no thumbnail to run the edge heuristic on a plain array, so it always opens one as an image.
Match the standalone Neuroglancer button in Views by using the same thumbnail-edge heuristic, so the metadata panel and the View agree on image vs. segmentation.
Every dataset now renders a thumbnail. Building them one at a time made checkout time grow with cart size.
Rendering the thumbnails can take longer than the click's user activation lasts, and then the browser blocks the popup.
allison-truhlar
force-pushed
the
fix/views-inferred-layer-type
branch
from
October 30, 2026 19:01
42ad2a3 to
b41ab70
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changed
Views now pick layer types the same way the standalone Neuroglancer
button does:
single-dataset preview to choose between
imageandsegmentation.The
disableHeuristicalLayerTypeDetectionpreference turns it off,as it does for the standalone button.
image. The standalone buttonhas no thumbnail to run the heuristic on, so it does the same. This
removes the name-and-dtype guess in
guessPlainLayerType.Two follow-on changes keep checkout fast and reliable now that it
renders thumbnails:
buildViewStatestarts every dataset at once instead of awaitingthem one at a time, so checkout time no longer grows with cart size.
useCreateViewFlowopens the draft tab right away on click, thensends the tab to the draft once the state is built. Rendering the
thumbnails can take longer than the click's user activation lasts,
and then the browser blocks the popup. If building the state fails,
the tab closes.
Why
The metadata panel and the standalone Neuroglancer button could call a
dataset a segmentation while the View opened it as an image, or the
other way around.
Addresses Clickup ids 17tkuw61tnm and 17tkuw629cv
Testing
viewCheckout.test.tscover inference on, inferenceoff, and the parameter it passes through.
useCreateViewFlow.test.tsxchecks that the pre-opened tab gets thedraft URL and closes on failure.
pixi run test-frontendpasses forviewCheckout,useAddToView,useCartCheckout, anduseCreateViewFlow.opens it as a
segmentationlayer.@krokicki