-
Notifications
You must be signed in to change notification settings - Fork 68
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
481 rotation of output images in prostate mri anatomy #482
Merged
wyli
merged 5 commits into
Project-MONAI:dev
from
FaresAlMohamad:481-Rotation-of-output-images-in-prostate_mri_anatomy
Aug 29, 2023
Merged
481 rotation of output images in prostate mri anatomy #482
wyli
merged 5 commits into
Project-MONAI:dev
from
FaresAlMohamad:481-Rotation-of-output-images-in-prostate_mri_anatomy
Aug 29, 2023
Conversation
This file contains 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
481-Rotation of output images in prostate_mri_anatomy - The transformations applied to the test data during preprocessing are not reversed during postprocessing. Thus, the resulting predictions have a different rotation compared to the original images and labels. I added an 'invertd()' function that reverses all the traceable transformations in the preprocessing. - Running the inference on a PC without a GPU leads to an error because the handlers function 'CheckpointLoader' attempts to load the model onto the GPU. I set the map_location argument to torch.device(device) so that it automatically loads the model onto the CPU when a GPU is not available. - Additionally, I changed some of the config directories as they were referring to the validation dataset rather than the test dataset. Signed-off-by: FaresAlMohamad <[email protected]>
updated version and changelog after adding an invertd transformation to postprocessing, setting the map_location argument of the checkpointloader in handlers to torch.devide(device) for CPU compatibility and changing some directories. The changes are documented in the history of the inference.json file of prostate_mri_anatomy. Signed-off-by: FaresAlMohamad <[email protected]>
for more information, see https://pre-commit.ci
wyli
reviewed
Aug 28, 2023
Signed-off-by: Yiheng Wang <[email protected]>
/build |
wyli
approved these changes
Aug 29, 2023
yiheng-wang-nv
pushed a commit
to yiheng-wang-nv/model-zoo
that referenced
this pull request
Jul 29, 2024
) ### Description 481-Rotation of output images in prostate_mri_anatomy - The transformations applied to the test data during preprocessing are not reversed during postprocessing. Thus, the resulting predictions have a different rotation compared to the original images and labels. I added an 'invertd()' function that reverses all the traceable transformations in the preprocessing. - Running the inference on a PC without a GPU leads to an error because the handlers function 'CheckpointLoader' attempts to load the model onto the GPU. I set the map_location argument to torch.device(device) so that it automatically loads the model onto the CPU when a GPU is not available. - Additionally, I changed some of the config directories as they were referring to the validation dataset rather than the test dataset. ### Status Ready ### Please ensure all the checkboxes: <!--- Put an `x` in all the boxes that apply, and remove the not applicable items --> - [x] Codeformat tests passed locally by running `./runtests.sh --codeformat`. - [x] Update `version` and `changelog` in `metadata.json` if changing an existing bundle. - [x] Please ensure the naming rules in config files meet our requirements (please refer to: `CONTRIBUTING.md`). - [x] Ensure versions of packages such as `monai`, `pytorch` and `numpy` are correct in `metadata.json`. - [x] Descriptions should be consistent with the content, such as `eval_metrics` of the provided weights and TorchScript modules. - [x] Files larger than 25MB are excluded and replaced by providing download links in `large_file.yml`. - [x] Avoid using path that contains personal information within config files (such as use `/home/your_name/` for `"bundle_root"`). --------- Signed-off-by: FaresAlMohamad <[email protected]>
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.
Description
481-Rotation of output images in prostate_mri_anatomy
Status
Ready
Please ensure all the checkboxes:
./runtests.sh --codeformat
.version
andchangelog
inmetadata.json
if changing an existing bundle.CONTRIBUTING.md
).monai
,pytorch
andnumpy
are correct inmetadata.json
.eval_metrics
of the provided weights and TorchScript modules.large_file.yml
./home/your_name/
for"bundle_root"
).