Skip to content

Implementation of A Neural Algorithm of Artistic Style(Gatys et. al.) but with MobileNetV2 backend instead of VGG.

License

Notifications You must be signed in to change notification settings

aadhithya/mobilenet-styletransfer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Neural Style Transfer with MobileNetV2

1. Usage

  • install requirements: pip install -r requirements.py
  • run style transfer: python nst.py
  • for more options: python nst.py --help

2. Losses

  • Content Loss: MSE Loss between feature maps at layer L of content image and output image.
  • Style Loss: MSE Loss between gram matrix of feature maps at different layers of style image and output image.

Loss Layers

Output feature maps of the following layers are used to compute the following losses:

  • Content Loss: InvertedResidualBlock #4.
  • Style Loss: InvertedResidualBlock #1, #2, #4, #7 and #14.

3. Outputs

All images are resized to (imsize, imsize) before processing. Here, imsize=256 and optimized for 50 Iterations.

Content Image Style Image Output Image(50 Itrs)

About

Implementation of A Neural Algorithm of Artistic Style(Gatys et. al.) but with MobileNetV2 backend instead of VGG.

Topics

Resources

License

Stars

Watchers

Forks

Languages