mattlin1124
mattlin1124
What does this PR do? Adds ensure_channel_first utility in monai/metrics/utils.py and integrates it into DiceHelper.__call__ in monai/metrics/meandice.py to normalize input tensors to channel-first layout before Dice computation. This prevents metric...
What Move ensure_channel_first to monai/utils/tensor_utils.py and re-export from inferers/utils.py for backward compatibility. Update MeanDice channel normalization logic: Use num_classes as authoritative hint when provided. Without num_classes: apply heuristic first, then...
### Description This PR addresses issue #8366 by implementing strict shape validation in `sliding_window_inference`. Per the feedback from maintainers (@ericspod), implicit guessing (heuristics) for channel-last data has been avoided. Instead,...