disentanglement_lib icon indicating copy to clipboard operation
disentanglement_lib copied to clipboard

Feature request: Please replace tf.layers with tf.keras.layers

Open sibyjackgrove opened this issue 6 years ago • 2 comments

In the official TensorFlow blog posts, it was said that tf.layers would be depreciated and tf.keras.layers would be the preferred method. However in architectures.py tf.layers has been used everywhere to create the encoder and decoder models. It would be great if these could be modifed to use tf.keras.layers since others would be able to reuse the code without worry.

#feature request

sibyjackgrove avatar Feb 14 '19 23:02 sibyjackgrove

Our initial focus has been on open-sourcing the exact architectures/implementations that can be used to reproduce the experiments in the study "Challenging Common Assumptions in the Unsupervised Learning of Disentangled Representations" (https://arxiv.org/abs/1811.12359). However, we are looking into ways to make sure disentanglement_lib is compatible with the upcoming changes to TensorFlow. In the meantime, it is very easy to define your own encoder/decoder architectures and to use them via gin with disentanglement_lib.

obachem avatar Feb 15 '19 10:02 obachem

Ok, thanks. Good to hear that you have compatibility with tf 2.0 on the radar. I will try writing my own architecture in mean time.

sibyjackgrove avatar Feb 15 '19 16:02 sibyjackgrove