Coder Social home page Coder Social logo

gumbel_softmax_vae's Introduction

Gumbel Softmax VAE

PyTorch implementation of a Variational Autoencoder with Gumbel-Softmax Distribution.

Table of Contents

Installation

The program requires the following dependencies (easy to install using pip or Ananconda):

  • python 3.6
  • pytorch (version 0.4.0)
  • numpy

Training

python gumbel_softmax_vae.py --log-interval 100 --epochs 100

Results

Better training accuracy and sample image quality were obtained.

Training output

Train Epoch: 1 [0/60000 (0%)]	Loss: 542.627869
Train Epoch: 1 [10000/60000 (17%)]	Loss: 210.317276
Train Epoch: 1 [20000/60000 (33%)]	Loss: 186.174133
Train Epoch: 1 [30000/60000 (50%)]	Loss: 194.145218
Train Epoch: 1 [40000/60000 (67%)]	Loss: 187.440338
Train Epoch: 1 [50000/60000 (83%)]	Loss: 186.376678
====> Epoch: 1 Average loss: 197.6736
====> Test set loss: 171.0257
Train Epoch: 2 [0/60000 (0%)]	Loss: 170.385742
Train Epoch: 2 [10000/60000 (17%)]	Loss: 162.513947
Train Epoch: 2 [20000/60000 (33%)]	Loss: 160.054916
Train Epoch: 2 [30000/60000 (50%)]	Loss: 158.194092
Train Epoch: 2 [40000/60000 (67%)]	Loss: 149.647385
Train Epoch: 2 [50000/60000 (83%)]	Loss: 144.748962
====> Epoch: 2 Average loss: 153.3126
====> Test set loss: 142.1215
Train Epoch: 3 [0/60000 (0%)]	Loss: 149.698944
Train Epoch: 3 [10000/60000 (17%)]	Loss: 140.085403
Train Epoch: 3 [20000/60000 (33%)]	Loss: 138.817505
Train Epoch: 3 [30000/60000 (50%)]	Loss: 136.967743
Train Epoch: 3 [40000/60000 (67%)]	Loss: 137.792786
Train Epoch: 3 [50000/60000 (83%)]	Loss: 134.401184
====> Epoch: 3 Average loss: 138.2995
====> Test set loss: 133.9106

MNIST

Training Step Ground Truth/Reconstructions Generated Samples
1
10
20
30

gumbel_softmax_vae's People

Contributors

yongfeiyan avatar

Watchers

James Cloos avatar paper2code - bot avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.