Code Monkey home page Code Monkey logo

dcgan-tfslim's Introduction

dcgan-tfslim

Deep Convolutional Generative Adversarial Networks (DCGAN) implemented in TensorFlow-Slim

This is a TensorFlow implementation of the following paper: https://arxiv.org/pdf/1511.06434v2.pdf. Some parameters and settings may not be exactly the same from the paper! Nonetheless, the code is able to generate images.

Dependencies

TensorFlow and tensorflow.contrib.slim are required, along with their dependencies (e.g. numpy). The only other additional dependency is PIL. This can be installed with pip:

pip install Pillow

Setup: celebA

Download the celebA dataset and put the images in data/celebA/ (create the directory structure if needed).

Setup: your own dataset

Put your images in data/your_dataset/. Create the directory structure and name your_dataset with whatever you want. Images should be *.jpg.

Optionally, create a file data/your_dataset.txt with each line containing an image file name in data/your_dataset/*. (One way to generate this file is to run the following command in the data/ directory: ls your_dataset/ > your_dataset.txt.) This file specifies the order of training. If this file is not found, then a random order will be used.

Train

Train on celebA:

python main.py --experiment_name celebA_demo --dataset celebA --train True

Train on your dataset:

python main.py --experiment_name your_dataset_demo --dataset your_dataset --train True

The --dataset flag accepts whatever dataset folder you want to use in the data/ directory.

TensorBoard

Use TensorBoard to visualize losses and generated images.

dcgan-tfslim's People

Contributors

mqtlam avatar

Watchers

John D. Pope avatar  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.