Making Art with GANs : Week 3 Assignment

I tried the Style transfer notebook with different images but I didn't like the results. I updated the iterations but I don't find the end product as interesting. Also, most the images are affected by style (colors) which I find a little limiting. I was able to troubleshoot every issue I had and took notes on this blog that I can reuse in case I were to need to run this notebook again. My goal is to work with video.

Style Transfer Notebook: https://colab.research.google.com/github/dvschultz/artificial-images/blob/master/neural_style_tf.ipynb


content image 1

Photo by me
Style 1
                                                    
Grainstacks at the End of Summer, Morning Effect Painting by Claude Monet
!python neural_style.py \
--content_img /content/test1.jpeg\
--style_imgs /content/mon.jpg \
--max_iterations 300 \
--style_scale 0.8

Result 1



--------------------------------------------------------
Content image 2 

photo: me
Style image 2

Credit: kind-and-curious-ZDUXvlyU_iI-unsplash

RESULT 3

!python neural_style.py \
--content_img /content/sunset.png\
--style_imgs /content/kind.jpg \
--max_iterations 200 \
--style_scale 0.145



RESULT 3B
!python neural_style.py \
--content_img /content/sunset.png\
--style_imgs /content/kind.jpg \
--max_iterations 350 \
--style_scale 0.8



Content Image. 4 Style 4





-------------------------------

Content Image + Style image

Sol Lewitt would cry.


Result





--------------------------------------------
  • First attempt: Running the notebook without changes. Both images are the same size.

Content Image 

Credit: ganapathy-kumar-unsplash

Style image


Output


I'm not pleased with the image, but I am happy the code run.

  • Second attempt : Derrick suggested to make changes on the iterations (between 350-500)
and to adjust the scale of the transfer image. Initially I got an error because of a typo
!python neural_style.py \
--content_img /content/cont.jpg \
--style_imgs /content/style.png \
--max_iterations 500 \
--style_scale 0.5



The image below I updated it with 300 itirerations scale 0.125


 Comparison video between Neural-Style-TF and Neural-Style-PT 









    STEPS

First I picked two images one for content and one for the style . Then resizing the images to make sure the notebook will run smoothly. Currently I'm using the free Google Collab version, so using an ultra high res image  does not make sense. Like Derrick did in class I resize mine to make them 800 px on the largest side.

This notebook uses tensorflow 1 so the output should be 1.15.12

Adding a new line of code to check the GPU that will run the notebook

CODE :
!nvidia-smi -L

RESULT : GPU 0: Tesla K80 (UUID: GPU-ad28731c-79cf-6a4c-20e7-8a37c80a5d10
Location of folders




Popular posts from this blog

Socially Engaged Art and Digital Practice week 9 - Project 2

Socially Engaged Art and Digital Practice : week 5 Materials Presentation

Socially Engaged Art and Digital Practice : week 3