Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BNN: Bernoulli variational posterior approximation #897

Open
BelhalK opened this issue May 29, 2018 · 0 comments
Open

BNN: Bernoulli variational posterior approximation #897

BelhalK opened this issue May 29, 2018 · 0 comments

Comments

@BelhalK
Copy link

BelhalK commented May 29, 2018

I am trying to implement a Bayesian Neural network with Bernoulli posterior approximations but can not find a way to define the shape of my Bernoulli variable to be a matrix of size D=784 (input layer) and P=50 (first hidden layer).
The Gaussian Posterior approximations code would be

qw0 = Normal(loc=tf.Variable(tf.random_normal([D,P])),scale=tf.nn.softplus(tf.Variable(tf.random_normal([D, P]))))

Any idea on how to adapt this for Bernoulli distribution?

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant