Repository navigation
SmartSPIM: read Z<z>_Ch<k>.tif slices and a single channel folder without _Ch<n> - #150
Merged
Merged
Conversation
…hout _Ch<n> Some SmartSPIM software versions write a single-channel acquisition with: - a channel folder named Ex_<laser>_Em_<filter>, without _Ch<n>; - stitched All_Channels slices named Z<z*10>_Ch<k>.tif. Neither was recognized, so the folder was "not a SmartSPIM acquisition". - readAllChannelsInfo accepts Z<z*10>_Ch<k>.tif(f) slice names. - listChannels / isSmartSPIM accept a channel folder without _Ch<n> (filterChannel NaN; numTiles counted by laser and filter). Working folders such as _MIP, _stitched and _MIDDLE are still not channels. - A lone unnumbered channel takes whichever single _ch<k> its slices carry. - Several channel folders when any lacks _Ch<n> are refused (ndr:format:smartspim:listChannels:UnnumberedChannels) rather than guessed at: nothing would say which _ch<k> slices are whose. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01E59gJ2kMfx16TfRmzo2SnL
Contributor
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #150 +/- ##
==========================================
+ Coverage 54.96% 55.09% +0.12%
==========================================
Files 164 164
Lines 9617 9647 +30
==========================================
+ Hits 5286 5315 +29
- Misses 4331 4332 +1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
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.
Some SmartSPIM software versions write a single-channel acquisition in a layout NDR did not recognize, so the Lightsheet Manager refused it as "not a SmartSPIM acquisition". Two lab acquisitions look like this (
Nielsen_PSS_Retrobeads/Full_Adult_Hemi_processed,Site_processed):Ex_561_Em_561F, with no_Ch<n>(beside it areEx_561_Em_561F_MIP,_MIP_stitched,_stitched,_MIDDLE);All_ChannelsareZ000000_Ch0.tif,Z000010_Ch0.tif, ….Changes
readAllChannelsInfoaccepts slice namesZ<z*10>_Ch<k>.tif(f), alongside<y>_<x>_<z*10>_ch<k>and<z*10>_ch<k>. Matching ignores case.listChannelsandisSmartSPIMaccept a channel folder namedEx_<laser>_Em_<filter>. Its filter name must have no underscores, so working folders such as_MIP,_stitchedand_MIDDLEstill aren't taken for channels. For that folder,filterChannelis NaN andnumTilesis counted frommetadata.json's tiles with its laser and filter._ch<k>its slices carry._Ch<n>are refused withndr:format:smartspim:listChannels:UnnumberedChannels. Nothing would then say which_ch<k>slices belong to which channel, and a guess could swap two channels without anyone noticing. A multi-channel acquisition in this layout will need to be looked at before it's supported.Tests
In
TestSmartSPIMAllChannels:testSingleChannelWithoutChNumberrewrites the fixture into this layout (one channel folder without_Ch<n>, working folders beside it,Z…_Ch0.tifslices) and reads it, values and z order included.testSeveralChannelsWithoutChNumberAreRefusedcovers two unnumbered folders, and one numbered plus one unnumbered.Per AGENTS.md these MATLAB tests weren't run here. The same change and tests are in NDR-python (VH-Lab/NDR-python, same branch name) and pass there.
Generated by Claude Code