MedSegDiff
MedSegDiff copied to clipboard
For multi-class seg, num_class=3 for example
Hi Junde Wu,
I have some questions for you.
The hyper-parameter in_ch=2 is fixed no matter of binary or multi-class task, where the two dimension includes the image and the mask. For multi-calss task, what we are supposed to change is only the calibration output, i.e. sigmoid to softmax, then we can get a [1 3 H W] calibration and a [1 2 H W] model_output. Is that correct?
If we change the in_ch = 3 + 1(one-hot with the image condition), we can have the [1 3 H W] calibration, however, i do not know what is the model_output? is it something like [1 3 2 H W]? or it is also the [1 2 H W], if so, using mask rather then one-hot as the input of diffusion model seems to be meaningful?
I grouped a 5-class task into binary case to check the results. Here are one visualization, is it correct? From top to bottom, img, recovery from diffusion model, calibration, linear combination of the recovery and calibration.
Thanks! Ping
嗨,吴俊德,
我有一些问题要问你。
无论二进制或多类任务,超参数 in_ch=2 都是固定的,其中二维包括图像和掩码。对于多 calss 任务,我们应该更改的只是校准输出,即 sigmoid 到 softmax,然后我们可以得到 [1 3 H W] 校准和 [1 2 H W] model_output。这是对的吗?
如果我们改变in_ch = 3 + 1(在图像条件下的单热),我们可以进行[1 3 H W]校准,但是,我不知道model_output是什么?是像[1 3 2 H W]之类的东西吗?或者它也是 [1 2 H W],如果是这样,使用掩模而不是 one-hot 作为扩散模型的输入似乎有意义?
我将一个 5 类任务分组为二进制大小写以检查结果。这里有一个可视化,正确吗?从上到下,img,从扩散模型中恢复,校准,恢复和校准的线性组合。
谢谢! 乒
你好!我也打算用这个来分多分类的分割,不过我是要运用到航拍的彩色图像上。请问你是怎么改写的数据加载文件?可以交流一下吗?
@WangPing521 Hi. Do you know how and where to add code to find metrics[ hd95,jaccard,dice]? Also is there any validation code? how to find these scores?
你好,请问unet的初始化参数out_channels设置为2是不是针对二值分割任务?这样设置似乎有一个问题, def _predict_xstart_from_eps(self, x_t, t, eps): assert x_t.shape == eps.shape
在以上函数中eps是unet输出,如果out_channel设置为2,那么eps的shape与x_t的通道数不同?请问out_channels是否需要修改
Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑🤝🧑👫🧑🏿🤝🧑🏻👩🏾🤝👨🏿👬🏿
Hello, may I ask if the initialization parameter out_channels of unet is set to 2 for the binary segmentation task? There seems to be a problem with this setup, def _predict_xstart_from_eps(self, x_t, t, eps): assert x_t.shape == eps.shape
In the above function, eps is unet output. If out_channel is set to 2, then the shape of eps is different from the number of channels of x_t? Does out_channels need to be modified?