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.
Integrating an existing implementation publicly available on GitHub by Patryk Rygiel into the MONAI framework.
Fixes #6993.
Fixes #3481
Fixes #1039
Description
Hausdorff distance is widely used in evaluating medical image segmentation methods. Adding an objective/loss function directly to optimize this distance can be instrumental in optimizing this score [1].
An existing implementation is publicly available on GitHub by Patryk Rygiel, although it might take some engineering work to integrate within the MONAI framework.
I was able to train a 3D segmentation model successfully using MONAI's SwinUNETR with this implementation and I would like to contribute the code for this loss so that it's more widely available and easier to integrate with MONAI-based repositories.
References:
[1] Karimi, D., & Salcudean, S. E. (2019). Reducing the Hausdorff distance in medical image segmentation with convolutional neural networks. IEEE Transactions on medical imaging, 39(2), 499-513.
Types of changes
./runtests.sh -f -u --net --coverage
../runtests.sh --quick --unittests --disttests
.make html
command in thedocs/
folder.