File tree Expand file tree Collapse file tree 2 files changed +16
-0
lines changed
Expand file tree Collapse file tree 2 files changed +16
-0
lines changed Original file line number Diff line number Diff line change 11# ' This script demonstrates how to build a variational autoencoder with Keras.
22# ' Reference: "Auto-Encoding Variational Bayes" https://arxiv.org/abs/1312.6114
33
4+ # Note: This code reflects pre-TF2 idioms.
5+ # For an example of a TF2-style modularized VAE, see e.g.: https://github.com/rstudio/keras/blob/master/vignettes/examples/eager_cvae.R
6+ # Also cf. the tfprobability-style of coding VAEs: https://rstudio.github.io/tfprobability/
7+
8+ # With TF-2, you can still run this code due to the following line:
9+ if (tensorflow :: tf $ executing_eagerly())
10+ tensorflow :: tf $ compat $ v1 $ disable_eager_execution()
11+
412library(keras )
513K <- keras :: backend()
614
Original file line number Diff line number Diff line change 22# ' and deconvolution layers.
33# ' Reference: "Auto-Encoding Variational Bayes" https://arxiv.org/abs/1312.6114
44
5+ # Note: This code reflects pre-TF2 idioms.
6+ # For an example of a TF2-style modularized VAE, see e.g.: https://github.com/rstudio/keras/blob/master/vignettes/examples/eager_cvae.R
7+ # Also cf. the tfprobability-style of coding VAEs: https://rstudio.github.io/tfprobability/
8+
9+ # With TF-2, you can still run this code due to the following line:
10+ if (tensorflow :: tf $ executing_eagerly())
11+ tensorflow :: tf $ compat $ v1 $ disable_eager_execution()
12+
513library(keras )
614K <- keras :: backend()
715
You can’t perform that action at this time.
0 commit comments