Unsupervised Loss functions

How can I use BCEWithLogitsLoss in the unsupervised learning? or there is any similar loss function to be used?

You can’t use this loss function without targets. Unless your “unsupervised learning” approach creates target tensors somehow, you won’t be able to use it.

1 Like

Thank you for your response, and this Loss how can be used for a supervised GAN?

The DCGAN tutorial explains the usage of BCELoss and how the model is trained, so it could be a good starter.