I am implementing a variational autoencoder. The input has both positive and negative numbers and it is NOT between 0 and 1. I did a log2 transform before training the model. I was wondering if binary_cross_entropy is a good choice in this case? because after the first iteration it gives me the following error:
RuntimeError: Assertion `x >= 0. && x <= 1.' failed. input value should be between 0~1, but got nan at /Users/distiller/project/conda/conda-bld/pytorch_1556653492823/work/aten/src/THNN/generic/BCECriterion.c:60