Repository navigation
Conversation
When the default join_method changed from 'concat' to 'stack', the MultipartRelatedConsolidator stopped deriving files_per_datum from chunk_shape and fell back to frame_per_point (default 1). Multi-frame image sequences (e.g. ophyd-async areaDetector TIFF with NumImages > 1) therefore registered a single file per datum, so the declared stacked shape (N, frames, H, W) could not be filled and reading raised a reshape error. Compute files_per_datum = datum_shape[0] // chunk_shape[0] in the general case, with a single exception: under 'stack', when chunk_shape describes only the stacked/row axis (e.g. (1,) or (1, *datum_shape)) and no multiplier/frame_per_point indicates file-per-frame storage, the whole datum is a single file. This keeps concat, rank-aligned stack, and the legacy file-per-frame multiplier cases correct. TST: add a parametrized regression test covering the modern per-file chunk_shape and legacy multiplier cases, and fix a vacuous assertion in test_tiff_and_jpeg_chunks that never checked the stack file count.
Contributor
Author
|
Closed in favor of #67. |
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.
When the default join_method changed from 'concat' to 'stack' in #52, the MultipartRelatedConsolidator stopped deriving
files_per_datumfromchunk_shapeand fell back to frame_per_point (default 1). Multi-frame image sequences (e.g. ophyd-async areaDetector TIFF with NumImages > 1) therefore registered a single file per datum, so the declared stacked shape (N, frames, H, W) could not be filled and reading raised a reshape error.Compute
files_per_datum = datum_shape[0] // chunk_shape[0]in the general case, with a single exception: under 'stack', whenchunk_shapedescribes only the stacked/row axis (e.g. (1,) or (1, *datum_shape)) and no multiplier/frame_per_point indicates file-per-frame storage, the whole datum is a single file. This keeps (1) concat, (2) rank-aligned stack, and (3) the legacy file-per-frame multiplier cases correct.TST: add a parametrized regression test covering the modern per-file chunk_shape and legacy multiplier cases, and fix a vacuous assertion in test_tiff_and_jpeg_chunks that never checked the stack file count.