Commit 75c44e0
authored
fix: handle metadata loading and shape calculation in transforms (#1990)
Fixes # .
handle metadata loading and shape calculation in transforms
### Description
- Add image_only=False and ensure_channel_first=True to LoadImaged
transform to properly load metadata
- Fix shape mismatch in PreprocessAnisotropic.calculate_new_shape by
handling 4D input shapes
- Addresses KeyError: 'image_meta_dict' and ValueError: operands could
not be broadcast together
Note: The metadata loading issue might be related to MONAI version
differences.
Current version: 1.4.0
### Checks
- [x] Avoid including large-size files in the PR.
- [x] Clean up long text outputs from code cells in the notebook.
- [x] For security purposes, please check the contents and remove any
sensitive info such as user names and private key.
---------
Signed-off-by: Tristan Kirscher <85068746+Kirscher@users.noreply.github.com>1 parent 211cfd8 commit 75c44e0
1 file changed
+4
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
43 | | - | |
| 43 | + | |
44 | 44 | | |
45 | | - | |
| 45 | + | |
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
| |||
284 | 284 | | |
285 | 285 | | |
286 | 286 | | |
| 287 | + | |
| 288 | + | |
287 | 289 | | |
288 | 290 | | |
289 | 291 | | |
| |||
0 commit comments