Hide ViT patch tiles on iterative-only scans; tighten detector subtitle#6
Open
Garrett Bischof (gwbischof) wants to merge 2 commits into
Open
Hide ViT patch tiles on iterative-only scans; tighten detector subtitle#6Garrett Bischof (gwbischof) wants to merge 2 commits into
Garrett Bischof (gwbischof) wants to merge 2 commits into
Conversation
- Detect <run>/diffraction/inference (the per-frame ViT patch output) via a
new SourceInfo.hasInference flag, discovered like hasVitAmp. Iterative-only
runs have diffraction/dp but no inference, so the 'ViT patch (amp)' and
'ViT patch (phase)' tiles must not render for them.
- Gate both ViT patch tiles on hasInference and collapse the detector-frame
grid to a single column when they are hidden.
- Simplify the detector-frame subtitle so it no longer wraps: drop the
redundant 'frame' word (the tile title already says 'Detector frame') and
shorten the stride note ('· 1 of every N frames' -> '· every N').
The tile header is a flex row (title left, subtitle right); a long subtitle wrapped to a second line, making that tile's header taller and pushing its image down out of alignment with the others. Keep the title from shrinking and truncate the subtitle with an ellipsis (full text on hover) so the header is always exactly one line. Also drop the redundant 'frame' word from the ViT patch subtitles for consistency with the detector-frame tile.
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.
Summary
Two detail-view fixes in
components/detail/holoptycho-viewer.tsx:Don't show ViT patch tiles on iterative-only scans. "ViT patch (amp)" and "ViT patch (phase)" read from
<run>/diffraction/inference, which only exists when the ViT branch ran. Iterative-only runs havediffraction/dpbut noinference, so those tiles were rendering empty/broken. Added aSourceInfo.hasInferenceflag (discovered by listingdiffractionchildren, mirroring howhasVitAmpis detected undervit) and gate both tiles on it. The detector-frame grid collapses to a single column when the ViT patches are hidden.Tighten the detector-frame subtitle so it stops wrapping. Dropped the redundant
frameword (the tile title is already "Detector frame") and shortened the stride note:frame 16 (latest) · 1 of every 4 frames→16 (latest) · every 4.Verification
npx tsc --noEmitpasses.Date.now()purity error elsewhere in the file is unrelated).Notes
A
--mode bothrun still shows the ViT patches (it hasdiffraction/inference); only iterative-only runs hide them.