June 13, 2021

163 words 1 min read

tg-bomze/BabyGAN

tg-bomze/BabyGAN

StyleGAN-based predictor of children's faces from photos of theoretical parents.

repo name tg-bomze/BabyGAN
repo link https://github.com/tg-bomze/BabyGAN
homepage
language Jupyter Notebook
size (curr.) 21410 kB
stars (curr.) 216
created 2020-08-23
license

BabyGAN

logo

Check how it works online:

  • Russian Language Colab
  • English Language Colab

Based on: StyleGAN

Encoder: StyleGAN-Encoder

example1 example2 example3

Pre-train Models and dictionaries

Follow the LINK and add shortcut to Drive:

shortcut

The folder structure should be:

.
├── data                    
│   └── finetuned_resnet.h5 
├── karras2019stylegan-ffhq-1024x1024.pkl
├── shape_predictor_68_face_landmarks.dat.bz2
├── vgg16_weights_tf_dim_ordering_tf_kernels_notop.h5
├── vgg16_zhang_perceptual.pkl
└── ...

Prerequisites

  • 64-bit Python 3.6 installation.
  • TensorFlow 1.10.0 with GPU support.
  • One or more high-end NVIDIA GPUs with at least 11GB of DRAM.
  • NVIDIA driver 391.35 or newer, CUDA toolkit 9.0 or newer, cuDNN 7.3.1 or newer.

Generating latent representation of your images

You can generate latent representations of your own images using two scripts:

  1. Create folders for photos

mkdir raw_images aligned_images

  1. Extract and align faces from images

python align_images.py raw_images/ aligned_images/

  1. Find latent representation of aligned images

python encode_images.py aligned_images/ generated_images/ latent_representations/

Usage BabyGAN

  • SOON
comments powered by Disqus