Project-MONAI / MONAI

AI Toolkit for Healthcare Imaging
https://monai.io/
Apache License 2.0
5.93k stars 1.09k forks source link

Docstring improvement for ConvertToMultiChannelBasedOnBratsClasses #8225

Open mingxin-zheng opened 1 week ago

mingxin-zheng commented 1 week ago

Describe the bug

The docstring below was confusing to read for people who haven't worked on BRATS 18 before (e.g. me)

https://github.com/Project-MONAI/MONAI/blob/13b96aedc48ad2da16149490b06a1a6bd8361335/monai/transforms/utility/array.py#L1054

I would suggest to elaborate it as below:

Convert labels to multi channels based on brats18 classes, which include TC (Tumor core), WT (Whole tumor) and ET (Enhancing tumor) in order.
According to the [official page](https://www.med.upenn.edu/sbia/brats2018/data.html)
    label 1 is the necrotic and non-enhancing tumor core, which should be counted under TC and WT subregion
    label 2 is the peritumoral edema, which is counted only under WT subresion
    label 4 is the GD-enhancing tumor, which should be counted under ET, TC, WT subregions

Expected behavior A clear and concise description of the function behavior and expected outputs

Additional context Related issue: https://github.com/Project-MONAI/tutorials/issues/1355 Related comment: https://github.com/Project-MONAI/VLM/pull/55#discussion_r1846833112