Closed LReion closed 2 months ago
Hi there,
You don't need to convert the masks into one-hot encodings or create separate binary masks for each label. When you mentioned foreground values, I assume you were referring to line 130 in the script. The purpose is to identify slices that contain the organs/lesions of interest by checking if any labeled pixel values are greater than zero in ground truth, and we are only retaining slices that contain the organs/lesions of interest that are relevant for training.
Hello, I saw that all the slices that were judged to be foreground pixel values were selected. That means I don't need to convert the mask to a one-hot or binary mask separately. In other words, can the labels of multi-organ masks also be processed and directly trained?
In addition, one label 12 is removed. If I need to perform segmentation training for each label, should I set this to an empty list, line 75 in pre_CT_MR.
Hello, I saw that all the slices that were judged to be foreground pixel values were selected. That means I don't need to convert the mask to a one-hot or binary mask separately. In other words, can the labels of multi-organ masks also be processed and directly trained?
That's correct. The preprocessing script can handle the multi-label masks.
In addition, one label 12 is removed. If I need to perform segmentation training for each label, should I set this to an empty list, line 75 in pre_CT_MR.
Yes, you will need to empty that list so that no label values are excluded from your dataset.
Thank you for your answer. Best wishes.
我的训练集的图像和标签都是3d的,但是标签是多标签在同一个通道中,用不同的像素值标记的结构。但是我看了一下pre_CT_MR.py文件中的预处理,只判断了一个像素值大于0也就是前景,那么我有一个问题,如果是我这样的多标签的应该如何处理。或者说需要单独将每个标签单独做成图像和其对应的二值掩码。