If your loss increases, could you check you’ve zeroed out the gradients via optimizer.zero_grad() or model.zero_grad()?
If you didn’t forget it, could you post some information regarding your training, e.g. which criterion are you using?
Note that nn.MSELoss was automatically broadcasting the target or output without a warning in older PyTorch versions. You should get a warning (since 1.1.0?) now.
If neither is the case, you might need to tune the hyperparameters further.