Skip to content

An implementation of《Face Aging with Identity-Preserved Conditional Generative Adversarial Networks》

Notifications You must be signed in to change notification settings

androidcodehub/IPCGANs-Pytorch

 
 

Repository files navigation

IPCGANs-pytorch

Author: Yuchao Gu

E-mail: gyc.nankai@gmail.com

Date: 2019-06-24

Description: The code is an pytorch implementation of 《Face Aging with Identity-Preserved Conditional Generative Adversarial Networks》


Usage

Data Preparation

  1. Download the cacd-2000 datasets and unzip.
  2. Use preprocess/preprocess_cacd.py to crop and align face region.
  3. Use preprocess/gentraingroup.py to generate training list, please refer to data/cacd2000-lists as an example.

Training

  1. Pretrain Age Classify model
python pretrain_alexnet.py
  1. Train IPCGANs
python IPCGANS_train.py
  1. Pretrained IPCGANs and AgeAlexnet model can be downloaded here, password:Lr6a

Visualize

Server

This project acted as an server for Android demo. You can start flask server.

python app.py 

Dependencies

This code depends on the following libraries:

  • Python 3.6
  • Pytorch 0.4.1
  • PIL
  • TensorboardX
  • Flask

Structure

IPCGANs
│
├── checkpoint  # path to store logging and parameters
│ 
├── data # path to specify training data groups and testing data groups
│ 
├── data_generator # pytorch dataloader for training
│ 
├── model # path to define model
│ 
├── utils
│
├── preprocess
│  
├── app.py # server scripts
│
├── demo.py # api for server 
│  
├── pretrain_alexnet.py
│
├── IPCGANS_train.py 
│
└── README.md # introduce to this project

About

An implementation of《Face Aging with Identity-Preserved Conditional Generative Adversarial Networks》

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%