GithubHelp home page GithubHelp logo

neural-art's Introduction

Neural-Art

##Overview

This project creates art using structures learned by the vgg19 neural network. The algorithm starts with a random uniform distribution of noise which is then updated to become the resulting image. This is done by giving the vgg19 network three separate inputs: random uniform noise, an image to copy style from, and an image to copy content from. The activations of the vgg19 network are then compared for each of the given inputs. The loss becomes the sum of these differences. To minimize the loss, we take the derivative of the loss with respect to the model input. Then, the model input (noise) is updated to reflect its contribution to the loss. This process is iterated about 1,500 times for optimal results.

###To use:

  1. Download the weights for the trained vgg19 network here. Then put it in the root of the project.
  2. To run using default settings :
  • python3 transfer.py
  • If you wish to sepcify the content and style images:
  • python3 transfer.py -style_image_path [path to image] -content_image_path [path to image]
  • To find out all command line arguments:
  • python3 transfer.py -h
  • To duplicate my results exactly:
  • Make sure the shell script is executable chmod +x batchRun.sh
  • Run the script ./batchRun.sh

###Dependencies: 1. Python3 2. Tensorflow 3. Pillow 4. Scipy 5. Numpy 6. (optional) GPU

###Comparison

Content:

Style Result

Content:

Style Result

###Credits

#####References

#####VGG network

https://github.com/machrisaa/tensorflow-vgg

neural-art's People

Contributors

msokoloff1 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.