Hi Karthik!



 cskarthik7:

your labels are floating point values whereas the labels should be some fixed values


I don’t think this is correct.
It appears that Sunakutra is not building a classifier (where the labels
would be fixed, integer class labels), but, rather, is performing a
“regression,” where both the predictions and target (not really labels)
are continuous variables that are supposed to be close to one another.
He is using MSELoss, which is appropriate for training continuous
predictions against continuous targets (rather than something like
CrossEntropyLoss which would be appropriate for building a classifier
that has fixed categorical labels for the target).
Best.
K. Frank