Pchandrasekaren,
I have checked the inputs and there are no NaN’s in the input.
I have re-run the model removing the sigmoid and using binary cross entropy with logits loss function it seems to be running, at the moment.
The model consists of 2 CVAE’s, and both run and work well with the input data and with the BCE = F.binary_cross_entropy(out,real_data_I,size_average=False) + Sigmoid and the BCE_withLogits and no sigmoid…
Update, the model as crashed with  **RuntimeError: after reduction step 2: cudaErrorAssert: device-side assert triggered** after 5 epochs, this is using F.binary_cross_entropy_with_logits
chaslie