pytorch-glow
PyTorch implementation of "Glow: Generative Flow with Invertible 1x1 Convolutions"
Usage
First you need to install all requirements by
pip3 install -r requirements.txt
Training
- Prepare dataset and corresponding profile file (like
profile/celeba.json
) - Start training:
python3 train.py [profile]
Inference
Usage: python3 infer.py [OPTIONS] COMMAND [ARGS]...
Options:
--profile PATH
--snapshot PATH
--help Show this message and exit.
Commands:
compute_deltaz
interpolate
reconstruct
sample
Result
Reconstruction
The upper is reconstructed image, the lower is original one.
Interpolation
From left to right, the attribute offset is from -1.0
to 1.0
by step 0.25
.
- Attractive
- Black hair
- Blurry
- Mouth slightly open
Acknowledgement
This project refers to:
- openai/glow (Official implementation)
- chaiyujin/glow-pytorch