Pytorch-UNet
Pytorch-UNet copied to clipboard
The generated mask graph is in the shape of [h, W, 3]. Now, the following data that only supports three-dimensional data appears using celoss. Does it need to convert the three-channel graph into one channel? Finally, do a dimensionality reduction to get the shape of [n, h, w] ?
1only batches of spatial targets supported (3D tensors) but got targets of size: : [1, 254, 500, 3]
U can do some changes,including transform your masks to one-channel.
ok,thank U.its good.
@SkevyHoo i got predicted mask has shape : torch.Size([1, 2, 497, 640]) and ground true mask has shape: GT torch.Size([1, 497, 640]). I wander what the 2nd dimension in predicted mask shape stand for? Thanks
@BaoanhTrinh n_classes
ok,thank U.its good.
I also encountered this problem, did you solve it? how to solve
你好,我也出现了这个问题,请问你这个问题解决了吗
你需要将你的true_masks转换为单通道格式 @xyx