dnuffer / large_neural_style Goto Github PK
View Code? Open in Web Editor NEWNeural Style applied to large images
License: Apache License 2.0
Neural Style applied to large images
License: Apache License 2.0
gateway@gateway-media:~/work/large_neural_style$ python3 large_neural_style.py --style /home/gateway/work/styles/star.jpg --content /home/gateway/work/images/home.jpg --content-weight 90.6e11 --output /home/gateway/work/large_neural_style/
Traceback (most recent call last):
File "large_neural_style.py", line 6, in
import stylize
File "/home/gateway/work/large_neural_style/stylize.py", line 10, in
import tiling
File "/home/gateway/work/large_neural_style/tiling.py", line 333
print "Failed:", result
^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print("Failed:", result)?
any thoughts? I didnt really seed any example command lines in the docs.. thank you!
All of the dependencies seemed to install correctly with pip. Any idea what might fix this?
C:\Users\aaols\Documents\large_neural_style>python large_neural_style.py --content eagle.jpg --style lock.jpg --output leagle.jpg
WARNING (theano.tensor.blas): Using NumPy C-API based implementation for BLAS functions.
Content image shape: (2426, 2066, 3)
Pyramid sizes: [(240, 204, 3), (480, 408, 3), (960, 817, 3), (1920, 1635, 3)]
shape: (240, 204, 3)
C:\Python36\lib\site-packages\skimage\transform\_warps.py:105: UserWarning: The default mode, 'constant', will be changed to 'reflect' in skimage 0.15.
warn("The default mode, 'constant', will be changed to 'reflect' in "
C:\Python36\lib\site-packages\skimage\transform\_warps.py:110: UserWarning: Anti-aliasing will be enabled by default in skimage 0.15 to avoid aliasing artifacts when down-sampling images.
warn("Anti-aliasing will be enabled by default in skimage 0.15 to "
resized_content_image.shape: (304, 268, 3)
content.shape: (1, 3, 304, 268)
style.shape: (1, 3, 152, 240)
after image_to_shape(), style.shape: (1, 3, 240, 204)
Traceback (most recent call last):
File "large_neural_style.py", line 193, in <module>
sys.exit(main())
File "large_neural_style.py", line 129, in main
args.print_loss)
File "C:\Users\aaols\Documents\large_neural_style\stylize.py", line 30, in generate_stylized_image
stylize = Stylize(content, True, style, content_weight, style_weight, style_layer_weight_factor, total_variation_weight, print_loss, print_progress=True)
File "C:\Users\aaols\Documents\large_neural_style\stylize.py", line 92, in __init__
self.net.load_params('vgg19_normalized.pkl')
File "C:\Users\aaols\Documents\large_neural_style\vgg19.py", line 37, in load_params
values = pickle.load(open(weights_filename))['param values']
File "C:\Python36\lib\encodings\cp1252.py", line 23, in decode
return codecs.charmap_decode(input,self.errors,decoding_table)[0]
UnicodeDecodeError: 'charmap' codec can't decode byte 0x81 in position 3634: character maps to <undefined>
Hello . After put this command python3 large_neural_style.py --style /home/fsck/neural/large_neural_style/ir.jpg --content /home/fsck/neural/large_neural_style/1322.jpg --content-weight 90.6e11 --output /home/fsck/neural/large_neural_style/ i get error "large_neural_style.py", line 193, in
sys.exit(main())
File "large_neural_style.py", line 129, in main
args.print_loss)
File "/home/fsck/neural/large_neural_style/stylize.py", line 30, in generate_stylized_image
stylize = Stylize(content, True, style, content_weight, style_weight, style_layer_weight_factor, total_variation_weight, print_loss, print_progress=True)
File "/home/fsck/neural/large_neural_style/stylize.py", line 92, in init
self.net.load_params('vgg19_normalized.pkl')
File "/home/fsck/neural/large_neural_style/vgg19.py", line 37, in load_params
values = pickle.load(open(weights_filename))['param values']
File "/usr/lib/python3.5/codecs.py", line 321, in decode
(result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0x80 in position 0: invalid start byte
Can you help fix this ?
do you have any samples of output anywhere?
thanks!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.