Repository navigation
Conversation
Signed-off-by: Don Yin <Don_Yin@outlook.com>
|
No actionable comments were generated in the recent review.
|
| Layer / File(s) | Summary |
|---|---|
Derive resize dimensions from the tensor generation/maisi/scripts/diff_model_create_training_data.py |
The loop loads the image through plain_transforms and rounds its tensor spatial dimensions to create new_dim. |
Priority:
Estimated code review effort: 1 (Trivial) | ~5 minutes
Change: Bug fix
Suggested reviewers: dongyang0122
Merge Risk: 
Minimal · up to d1941
-
No actionable merge-blocking risk was identified in the reviewed change.
Pre-merge checks: 
5
-
Full details: Linked Issues check
-
Explanation
Issue
#2012requires MAISI preparation to use dimensions after RAS reorientation. The change loads the transformed image once and derivesnew_dimfromimage.shape[1:]. This replaces the original NIfTI metadata dimensions. The code then rounds each spatial dimension before creating the resize transform.
Full details: Out of Scope Changes check
-
Explanation
The whole-PR diff changes only the resize-dimension calculation in
generation/maisi/scripts/diff_model_create_training_data.py. The change directly supports issue#2012and shows no unrelated behavior or files.
Full details: Docstring Coverage
-
Explanation
Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 1 functions across 1 files.
-
Finishing Touches
-
🧪 Generate unit tests (beta)
-
- Create a new PR
-
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Comment @coderabbitai help to get the list of available commands.
The resize target was read from the original NIfTI header, so for non-RAS images it came out in the wrong axis order after reorientation. Using the shape of the reoriented image fixes it.
Fixes #2012.
Summary by CodeRabbit