Giter Site home page Giter Site logo

curegit / precure-stylegan Goto Github PK

View Code? Open in Web Editor NEW
1.0 3.0 0.0 93.77 MB

Yet another StyleGAN 1.0 implementation with Chainer to synthesize specific Precure (Cure Beauty) images

License: Other

Python 100.00%
deep-learning generative-adversarial-network stylegan chainer precure anime image-synthesis

precure-stylegan's Introduction

Precure StyleGAN

Yet another StyleGAN 1.0 implementation with Chainer

We tried out to generate facial images of a specific Precure (Japanese Anime) character.

This project is finished and will be continued here for better quality with StyleGAN 2.0 ADA.

Overview

Overall Result

StyleGAN is a generative adversarial network introduced by NVIDIA researchers. Like PGGAN, its output image resolutions grow progressively during training. This implementation supports generation ranging from 4x4 px (stage 1) to 1024x1024 px (stage 9) images.

Most of the implementation follows the original paper, but we have added some enhancements. For example, we implemented an alternative least-squares objective introduced in LSGAN. We trained the models with facial images of Cure Beauty (Smile Pretty Cure!, 2012) and other common datasets.

Requirements

  • Python >= 3.6
  • Chainer >= 7.0
  • Pillow >= 9.1
  • Numpy < 1.24
  • H5py
  • Matplotlib

Optional

  • Cupy
  • OpenCV-Python
  • Pydot (Graphviz)

Script Synopses

  • train.py trains StyleGAN models. Use the -h option for more details.
  • generate.py generates images from a trained model. Use the -h option for more details.
  • mix.py mixes styles from latent files. Use the -h option for more details.
  • animate.py makes an animation of the analogy from a trained model. Use the -h option for more details.
  • visualize.py draws an example of a computation graph for debugging (Pydot and Graphviz are required). It takes no command-line arguments.
  • check.py analyzes the Chainer environment. It takes no command-line arguments.

Results

Cure Beauty (Curated, FID = 80.43)

Cure Beauty

MNIST (Uncurated, FID = 1.14)

Try yourself: python3 generate.py -g models/mnist.hdf5 -x 4 -c 256 16 -z 256 -n 100 -d mnist-images

MNIST

CIFAR-10 (Uncurated, ψ = 0.7, FID = 18.61)

Try yourself: python3 generate.py -g models/cifar10.hdf5 -x 4 -c 512 64 -t 0.7 -n 100 -d cifar10-images

CIFAR-10

Anime Face (Uncurated, ψ = 0.8, FID = 13.11)

Try yourself: python3 generate.py -g models/anime.hdf5 -x 5 -c 512 64 -t 0.8 -n 100 -d anime-images

Anime Face

Bibliography

Papers

Implementation used as reference

Datasets for testing

License

CC BY-NC 4.0

precure-stylegan's People

Contributors

curegit avatar

Stargazers

 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.