GithubHelp home page GithubHelp logo

octoberchang / mmd-gan Goto Github PK

View Code? Open in Web Editor NEW
198.0 4.0 54.0 14 KB

MMD-GAN: Towards Deeper Understanding of Moment Matching Network

License: BSD 3-Clause "New" or "Revised" License

Python 97.01% Shell 2.99%
maximum-mean-discrepancy generative-adversarial-network pytorch mmd-gan

mmd-gan's Introduction

MMD-GAN

Code accompanying the paper MMD-GAN: Towards Deeper Understanding of Moment Matching Network.

Prerequisites

- Python, NumPy, Scipy
- PyTorch (v0.1.12)
- A recent Nvidia GPU

Usage

./mmd_gan [OPTIONS]
OPTIONS:
    --dataset DATASET: type of dataset (mnist/cifar10/celeba/lsun)
    --dataroot DATAROOT: path to dataset
    --workers WORKERS: number of threads to load data
    --batch_size BATCH_SIZE: batch size for training
    --image_size IMAGE_SIZE: image size of dataset
    --nc NC: number of channels in images
    --nz NZ: hidden dimension in z and codespace
    --max_iter MAX_ITER: max iteration for training
    --lr LR: learning rate (default 5e-5)
    --gpu_device GPU_DEVICE: gpu id (default 0)
    --netG NETG: path to generator model
    --netD NETD: path to discriminator model
    --Diters DITERS: number of updates for discriminator per one generator update
    --experiment EXPERIMENT: output directory of sampled images

For a quick start, please set the DATA_PATH variable in run_exp.sh to

    ./data

and run

	$ ./run_exp.sh [mnist/cifar10/celeba/lsun]

Dataset

For mnist and cifar10, the dataset will be automatically download if not exist in the designated DATAROOT directory.

For CelebA and LSUN dataset, please run the download script in ./data directory.

More Info

This repository is by Chun-Liang Li, Wei-Cheng Chang, Yu Cheng, Yiming Yang, Barnabás Póczos, and contains the source code to reproduce the experiments in our paper MMD GAN: Towards Deeper Understanding of Moment Matching Network. If you find this repository helpful in your publications, please consider citing our paper.

@article{li2017mmd,
    title={MMD GAN: Towards Deeper Understanding of Moment Matching Network},
    author={Li, Chun-Liang and Chang, Wei-Cheng and Cheng, Yu and Yang, Yiming and P{\'o}czos, Barnab{\'a}s},
    journal={arXiv preprint arXiv:1705.08584},
    year={2017}
}

For any questions and comments, please send your email to [email protected]

mmd-gan's People

Contributors

octoberchang avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

mmd-gan's Issues

weight clipping

Thanks for posting the code.
I have one question relating to one sentence in the paper.
' the gradient DELTA_θ (maxφ fφ ◦ gθ) has to be bounded, which can be done by clipping φ.'
Shouldn't it be DELTA_x? if not, what will make the gradient explode? Thanks

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.