I have a difficulty understanding the error I got while training. The error goes like this:
 UserWarning: Using a target size (torch.Size([10, 1, 224, 224])) that is different to the input size (torch.Size([10, 60, 224, 224])). This will likely lead to incorrect results due to broadcasting. Please ensure they have the same size.
  return F.mse_loss(input, target, reduction=self.reduction)

My target is the mask for every image and its shape is [batch size, channel, dimension] and my input is the OUTPUT OF MY NETWORK and its shape is [batch size, number of classes, dimension]. Can anyone help me to understand this?