Skip to content

3_BASICS: Installing and using neural style through a virtual machine

jamahun edited this page Jul 28, 2020 · 5 revisions

The following tutorial will be referencing jcjohnson's neural-style. Follow the link for a more detailed information.

Get neural-style

Use git clone to download the neural-style folder onto your virtual machine

cd ~
git clone https://github.com/jcjohnson/neural-style

Install the models

cd neural-style
sh models/download_models.sh

Basic Usage

Navigate to the neural-style root directory cd ~/neural-style and execute the following command:

th neural_style.lua -style_image <examples/inputs/image.jpg> -content_image <examples/inputs/image.jpg>

Download Style & Content Images

Search for images to use for both style and content and upload them to the /examples/inputs folder. You can use the command wget for this, to do so:

cd examples/inputs
wget -O style_name http://your_url.com
wget -O content_name http://your_url.com

Options

For the full list of options go to https://github.com/jcjohnson/neural-style

High Res Neural Style

  1. Use jcjohnson's jcjohnson's bash script by following this address and copying the raw code.