Created
November 9, 2016 05:32
-
-
Save ericjang/79f2ad7f01d94858712d561baf0be908 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# loss and train ops | |
kl_tmp = tf.reshape(q_y*(log_q_y-tf.log(1.0/K)),[-1,N,K]) | |
KL = tf.reduce_sum(kl_tmp,[1,2]) | |
elbo=tf.reduce_sum(p_x.log_prob(x),1) - KL |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment