Unofficial pytorch-lightning implementation of a paper, "Arbitrary Style Transfer in Real-time with Adaptive Instance Normalization"
- torch==1.10.1
- torchvision==0.11.2
- pytorch-lightning==1.5.7
- tqdm==4.62.3
- wandb==0.12.10
- opencv-python-headless==4.5.5.62
- easydict==1.9
- onnxruntime==1.10.0
pip install -r requirements.txt
docker-compose up -d
- Encoder(VGG) weights download by "pytorch-AdaIN" repo
- Decoder weights download by link
- Net Torchscript model download by link
- Net onnx model download by link
- content : COCO DATASET
- style : WikiArt
- download dataset (content, style)
- download Encoder weights and mv to weights dir
- check dataset path
- run script
python main.py \
--content_root_dir="{YOUR CONTENT DATASET PATH}" \
--style_root_dir="{YOUR STYLE DATASET PATH}" \
--num_workers=8 \
--batch_size=8 \
--log_every_n_steps=5 \
--gpus=1 \
--max_steps=16000
Streamlit app source code referenced "Neural-Style-Transfer-Streamlit "
Menual
cd app
pip install -r requirements.txt
- torch==1.10.1
- torchvision==0.11.2
- pytorch-lightning==1.5.7
- streamlit==1.7.0
- opencv-python-headless==4.5.5.62
- MODEL_PATH : torchscript file path
cd app
docker-compose up -d