Replies: 1 comment
-
Hi @benolmbrt, thanks for your reporting. I hope this helps and let me know if you have any other questions! |
Beta Was this translation helpful? Give feedback.
-
Hi @benolmbrt, thanks for your reporting. I hope this helps and let me know if you have any other questions! |
Beta Was this translation helpful? Give feedback.
-
Describe the bug
It is expected that the DiceMetric returns NaN values for classes that are not present in the ground truth, if the option ignore_empty is set to True. However, the metric returns instead a value of 0.
To Reproduce
Here is a minimal example to reproduce the bug. I'm creating two random segmentations with 8 classes,
and then manually remove classes 2 and 5 from the ground truth.
Output :
--> The Dice scores for class 2 and 5 are set to 0, not NaN.
Expected behavior
It is expected that the Dice values for class 2 and 5 are NaN, but it is 0.
Environment
I am using Monai 1.3.0 with Python 3.11.5
Beta Was this translation helpful? Give feedback.
All reactions