Coder Social home page Coder Social logo

zackchase / sdgan Goto Github PK

View Code? Open in Web Editor NEW

This project forked from chrisdonahue/sdgan

0.0 3.0 1.0 8.97 MB

Implementation of "Semantically Decomposing the Latent Spaces of Generative Adversarial Networks"

License: MIT License

Python 45.78% Jupyter Notebook 5.15% Shell 0.60% CSS 1.47% HTML 9.30% JavaScript 37.70%

sdgan's Introduction

SD-GAN Tensorflow

Implementation of Semantically Decomposing the Latent Spaces of Generative Adversarial Networks (arXiv, demo).

Semantically decomposed GANs (SD-GANs) learn a decomposed latent space separating identity from the other contingent aspects of observations. In our paper, we demonstrate that SD-GANs can disentangle factors of variation corresponding to identity from photographs of celebrity faces and shoes. SD-GANs are especially applicable for datasets with many labels but few observations of each. Example results from an SD-GAN model; each row shares an identity and each column shares contingent factors:

Currently, only the SD-DCGAN model is implemented here; SD-BEGAN forthcoming.

Instructions

Download one or both of the compressed datasets to sdgan/data:

Run training:

  1. Navigate to: sdgan/data
  2. Extract a dataset: tar xvfz msceleb12k.tar.gz
  3. Navigate to: sdgan
  4. Run training: ./train.sh
  5. Navigate to: sdgan/train
  6. (Optional) Run grid visualization: ./prev.sh
  7. Run tensorboard: tensorboard --logdir=.

Requirements

  • tensorflow (>= 1.0)
  • numpy

Adding new datasets

To add new datasets, follow the naming convention in the prepackaged ones above. Dataset folder must have subdirectory called train. train must contain 64x64 png files formatted as <ID_NAME>_<OBS_NUMBER>_<?>.png. In our datasets, <?> is the original aspect ratio for the source image of the 64x64 thumbnail, though the attribute is unused in our code.

Attribution

If you use this dataset in your research, cite via the following BibTeX:

@article{donahue2017sdgan,
  title={Semantically Decomposing the Latent Spaces of Generative Adversarial Networks},
  author={Donahue, Chris and Balsubramani, Akshay and McAuley, Julian and Lipton, Zachary C},
  journal={arXiv:1705.07904},
  year={2017}
}

Reference code/datasets

Author

Chris Donahue (website, gscholar, twitter)

sdgan's People

Contributors

chrisdonahue avatar

Watchers

James Cloos avatar Zack Chase Lipton avatar  avatar

Forkers

fagan2888

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.