Cocofeat / TBraTS

【MICCAI 2022】"TBraTS: Trusted Brain Tumor Segmentation"
46 stars 4 forks source link

about loss #3

Closed liu-tianxiang closed 2 years ago

liu-tianxiang commented 2 years ago

in train(line292) code Snipaste_2022-09-23_22-48-50 if args.rlt > 0: loss = criterion_fl(output, target) + args.rlt * criterion_dl(output, target) else: loss = criterion_dl(output, target) Only criterion_fl (FocalLoss), criterion_dl (DiceLoss) are used here, I opened FocalLoss, DiceLoss contains the uncertainty content (klLoss) mentioned in the paper, but the paper shows 3 losses, does it mean that these two losses already contain the three losses shown in the figure in the paper , That is, L = Lice + λpLKL + λsLDice represents the two losses of FocalLoss and DiceLoss (klLoss is included in FocalLoss, DiceLoss). However, (L_ace + L_dice + L_KL) used in dce_eviloss (trainTBraTs line85) Snipaste_2022-09-23_22-58-38 Snipaste_2022-09-23_23-04-18

in trainTBraTs is consistent with the paper, so which loss should be the loss mentioned in this article

Snipaste_2022-09-23_22-49-51 Snipaste_2022-09-23_22-50-01

Cocofeat commented 2 years ago

Thanks for your attention! We use the dice_loss as the L_dice, not the focal_loss. You can choose the loss depended on your tasks. In evidential deep learning, the L_KL and L_ice are used for loss function. In our task, we add the L_dice.

liu-tianxiang commented 2 years ago

in trainTBraTS.py(line 127) Snipaste_2022-09-25_19-27-32 This model has three accepted values, but TMSU only returned two accepted values(trustedseg line 87) Snipaste_2022-09-25_19-26-47 Is there some problem here, is there a workaround?

Cocofeat commented 2 years ago

We have modified it, thanks for your attention! evidences, loss = model(x,target,epoch,args.mode)
in trainTBraTS.py(line 127)

liu-tianxiang commented 2 years ago

in trainTBraTS.py(line 157) seems to have the same problem

Cocofeat commented 2 years ago

Yeah, modified it.

Xiuxiu21 commented 2 years ago

in trainTBraTS.py(line 157) seems to have the same problem 请问您跑通了吗,方便的话我我想问您一些问题,这是我的邮箱3190221518@qq.com

liu-tianxiang commented 2 years ago

Not yet. The code doesn't seem to see the Dirichlet function part.

Xiuxiu21 commented 2 years ago

还没有。代码似乎看不到狄利克雷函数部分。

===========>Validation begining!=========== Traceback (most recent call last): File "G:/ TBraTS-main/TBraTS-main/trainTBraTS.py", line 278, in val_loss, best_dice = val(args, epoch, best_dice) File "G:/ TBraTS-main/TBraTS-main/trainTBraTS.py", line 162, in val args.mode) # two modality or four modality File "C:\ProgramData\Anaconda3\envs\torch\lib\site-packages\torch\nn\modules\module.py", line 1102, in _call_impl return forward_call(*input, **kwargs) File "G:\ TBraTS-main\TBraTS-main\models\trustedseg.py", line 55, in forward backbone_output = tailor_and_concat(X, self.backbone) File "G:\ TBraTS-main\TBraTS-main\predict.py", line 93, in tailor_and_concat temp.append(x[..., :128, :128, :128]) TypeError: unhashable type: 'slice' 请问您遇到这个问题了吗,我不知道该怎么解决