ProGamerGov / neural-style-pt

PyTorch implementation of neural style transfer algorithm
MIT License
838 stars 175 forks source link

Can you share your training parameters? I can't get as good a performance as you. #94

Open yunlm opened 2 years ago

ProGamerGov commented 2 years ago

@yunlm Try using the following parameters with multiscale generation:

-init image -tv_weight 0 -learning_rate 2 -init image -content_weight 100 -style_weight 6000
strohrbaugh commented 2 years ago

maroon

Starry_Night

Using the above two images and the following parameters `python neural_style.py -style_image ~/Documents/NST/style/Starry-Night.jpg -content_image ~/Documents/NST/maroon.JPG -output_image maroonxstarry.jpg -model_file models/vgg19-d01eb7cb.pth -gpu 0 -num_iterations 2000 -content_weight 10 -style_weight 50000 -image_size 1024 -optimizer lbfgs -init image -tv_weight 0 -learning_rate 2 -init image -style_scale 1.5 -original_colors 1', I produced this:

MaroonXStarry

I'm finding the style_scale parameter to be very useful. Here's the same pair redone using a style scale of 0.5 MaroonXStarry_scale0 5 :

ProGamerGov commented 2 years ago

@strohrbaugh You should start off at a lower image size and then scale it up with multiple steps of increasing image size (multiscale rendering).

strohrbaugh commented 1 year ago

You're so right. I'm glad I finally made the time to try that out.