Closed Sarvagya2009 closed 2 years ago
q_logstd
is used for computing the Gaussian log likelihood loss (see here).
q_logstd = tf.maximum(q_logstd, -16)
is to avoid numerical errors by preventing the standard deviation to be smaller than exp(-16). Because when computing the Gaussian log likelihood loss, the std is used as a denominator. The loss will explode when std is too small.
What is the logic behind using q_logstd? Specifically in line 175, why is q_logstd = tf.maximum(q_logstd, -16) done?