threeracha / Chuibbo-Flask-Server

๐Ÿ“ธ GAN ๊ธฐ๋ฐ˜ ์ทจ์—… ์‚ฌ์ง„ ์ƒ์„ฑ ์–ดํ”Œ - AI ๐Ÿ“ธ

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

API

Chuibbo-Flask Swagger UI

์‹คํ–‰

gunicorn main:app --bind=[ip์ฃผ์†Œ]:[ํฌํŠธ๋ฒˆํ˜ธ] -w [worker process ์ˆ˜] -k sync

worker process ์ˆ˜๋Š” ์‹คํ–‰ํ•˜๋Š” ๋จธ์‹ ์˜ ๋ฌผ๋ฆฌ์  ์ฝ”์–ด์ˆ˜์— ๋งž๊ฒŒ ์„ค์ •ํ•˜๋Š”๊ฒŒ ์ข‹๋‹ค.

Download requirements.txt

pip install -r requirements.txt

Download 100000_nets.ema.ckpt & wing.ckpt

And insert assets/representative/resume/ref

conda activate stargan
python main.py

StarGAN v2 - Official PyTorch Implementation

StarGAN v2: Diverse Image Synthesis for Multiple Domains
Yunjey Choi*, Youngjung Uh*, Jaejun Yoo*, Jung-Woo Ha
In CVPR 2020. (* indicates equal contribution)

Paper: https://arxiv.org/abs/1912.01865
Video: https://youtu.be/0EVh5Ki4dIY

Abstract: A good image-to-image translation model should learn a mapping between different visual domains while satisfying the following properties: 1) diversity of generated images and 2) scalability over multiple domains. Existing methods address either of the issues, having limited diversity or multiple models for all domains. We propose StarGAN v2, a single framework that tackles both and shows significantly improved results over the baselines. Experiments on CelebA-HQ and a new animal faces dataset (AFHQ) validate our superiority in terms of visual quality, diversity, and scalability. To better assess image-to-image translation models, we release AFHQ, high-quality animal faces with large inter- and intra-domain variations. The code, pre-trained models, and dataset are available at clovaai/stargan-v2.

TensorFlow implementation

The TensorFlow implementation of StarGAN v2 by our team member junho can be found at clovaai/stargan-v2-tensorflow.

Install the dependencies:

conda create -n stargan-v2 python=3.6.7
conda activate stargan-v2
conda install -y pytorch=1.4.0 torchvision=0.5.0 cudatoolkit=10.0 -c pytorch
conda install x264=='1!152.20180717' ffmpeg=4.0.2 -c conda-forge
pip install opencv-python==4.1.2.30 ffmpeg-python==0.2.0 scikit-image==0.16.2
pip install pillow==7.0.0 scipy==1.2.1 tqdm==4.43.0 munch==2.5.0

Datasets and pre-trained networks

We provide a script to download datasets used in StarGAN v2 and the corresponding pre-trained networks. The datasets and network checkpoints will be downloaded and stored in the data and expr/checkpoints directories, respectively.

CelebA-HQ. To download the CelebA-HQ dataset and the pre-trained network, run the following commands:

bash download.sh wing

Training networks

To train StarGAN v2 from scratch, run the following commands. Generated images and network checkpoints will be stored in the expr/samples and expr/checkpoints directories, respectively. Training takes about three days on a single Tesla V100 GPU. Please see here for training arguments and a description of them.

About

๐Ÿ“ธ GAN ๊ธฐ๋ฐ˜ ์ทจ์—… ์‚ฌ์ง„ ์ƒ์„ฑ ์–ดํ”Œ - AI ๐Ÿ“ธ

License:Other


Languages

Language:Python 99.8%Language:HTML 0.2%