Giter Site home page Giter Site logo

crypto-code / biggan-pretrained Goto Github PK

View Code? Open in Web Editor NEW
2.0 3.0 0.0 205 KB

Uses a Pretrained Network (using Google's Deepmind) to generate images.

License: MIT License

Python 100.00%
biggan pretrained-weights pretrained-network gan-models google-deepmind gan image-generation image-generator

biggan-pretrained's Introduction

BigGAN-Pretrained

Uses a Pretrained Network (Trained using Google's Deepmind) to generate images.

BigGAN

The BigGAN is an implementation of the GAN architecture designed to leverage the best from what has been reported to work more generally. Specifically, the BigGAN is designed for class-conditional image generation. That is, the generation of images using both a point from latent space and image class information as input. Example datasets used to train class-conditional GANs include the CIFAR or ImageNet image classification datasets that have tens, hundreds, or thousands of image classes.

As its name suggests, the BigGAN is focused on scaling up the GAN models.

This includes GAN models with:

  • More model parameters (e.g. more feature maps).
  • Larger Batch Sizes
  • Architectural changes

For more info refer to paper

Download Pretrained Weights

The Pretrained weights can be downloaded from here

Installation

This requires anaconda or miniconda.

To create the environement run

conda env create -f environement.yml

The following dependencies will be installed:

  • python=3.6
  • cudatoolkit=10.0
  • pytorch
  • torchvision
  • scipy

Usage

To run the code, download the pretrained weights first.

python generate.py -w <PRETRAINED_WEIGHT_PATH> [-s IMAGE_SIZE] [-c CLASS_LABEL] [-t TRUNCATION] [-o OUTPUT_FILE] 

For example:

python generate.py -w ./biggan512-release.pt -s 512 -t 0.3 -c 156 
python generate.py -w ./biggan256-release.pt -s 256 -t 0.02 -c 11 -o output

The Valid parameters are:

  • Valid image size: 128, 256, 512
  • Valid class label: 0~999
  • Valid truncation: 0.02~1.0

Examples

Class 156

Class 292

Class 972

Class 992

G00D LUCK

For doubts email me at: [email protected]

biggan-pretrained's People

Contributors

crypto-code avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  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.