When using newer torch versions, the existing code throws the following error:
ValueError: Using a target size (torch.Size([1000])) that is different to the input size (torch.Size([1000, 1])) is deprecated. Please ensure they have the same size.
By adding an additional dimension to the target tensor this issue is resolved.
When using newer torch versions, the existing code throws the following error:
ValueError: Using a target size (torch.Size([1000])) that is different to the input size (torch.Size([1000, 1])) is deprecated. Please ensure they have the same size.
By adding an additional dimension to the target tensor this issue is resolved.
@akshat998