As titled, When I trained my multiclass tasks, i found Dice Score were too high, which is abnormal. then I found calculation of Dice were wrong.
in evaluate.py, line 37:
dice_score += multiclass_dice_coeff(mask_pred[:, 1:], mask_true[:, 1:], reduce_batch_first=False)
which should be:
dice_score += multiclass_dice_coeff(mask_pred[:, 1:], mask_true[:, 1:], reduce_batch_first=True)