An implementation of Neural Style Transfer with PyTorch. It allows users to use command line arguments to stylize their own images easily and optionally set hyperparameters different from the default values.
| Content Image | Style Image |
![]() |
![]() |
- Clone (or download) this repository:
git clone https://github.com/Germinari1/StylizeIt.git- Install the requirements for this project with:
pip install -r requirements.txtThere are some other important components for this project, which also need to be installed:
- Python 3
- Pip
- CUDA is recommended for GPU acceleration Now you`re ready to go!
Command-line arguments are used to control the program and stylize your images. Here's the simplest way to generate a stylized image:
python exec.py <path to content image> <path to style image> <path for output>For example:
python exec.py "images/content_imgs/figures.jpg" "images/style_imgs/wave_crop.jpg" "images/stylized_imgs/output1.jpg"Besides creating images, it is possible to change the hyperparameters of the model by using the corresponding flags. For instance:
python exec.py "images/content_imgs/figures.jpg" "images/style_imgs/wave_crop.jpg" "images/stylized_imgs/output1.jpg" --num_iterations 1000 --learning_rate 0.01Here's the complete list of parameters you can manipulate from the command line:
content_weightstyle_weighttotal_variation_weightlearning_ratenum_iterationscontent_layer_weightsstyle_layer_weightsuse_random_initmax_image_sizecheckpoint_interval


