bjr96571:

I’m mainly concerned if I am implementing the losses correctly. For example, I read that it’s okay to sum separate losses and call .backward() , but I’m not 100% certain that I should do that rather than 3 separate losses and backwards.


Summing the losses should work as long as each loss contains as valid .grad_fn as an attribute.
The code looks generally alright. I haven’t checked the architecture (e.g. if the slicing of the vgg model is correct), but the workflow looks good.