SegAN icon indicating copy to clipboard operation
SegAN copied to clipboard

there is an error in line 125

Open Qiaohao501 opened this issue 2 years ago • 1 comments

Traceback (most recent call last): File "train.py", line 125, in output_masked[:,d,:,:] = (input_mask[:,d,:,:].unsqueeze(1)) * output RuntimeError: expand(torch.cuda.FloatTensor{[36, 1, 128, 128]}, size=[36, 128, 128]): the number of sizes provided (3) must be greater or equal to the number of dimensions in the tensor (4)

Qiaohao501 avatar Oct 13 '22 18:10 Qiaohao501

origin: output_masked[:,d,:,:] = input_mask[:,d,:,:].unsqueeze(1) * output fix: output_masked[:,d,:,:] = torch.squeeze(input_mask[:,d,:,:].unsqueeze(1) * output)

Aut0matas avatar Mar 28 '23 16:03 Aut0matas