dmitryulyanov / fast-neural-doodle Goto Github PK
View Code? Open in Web Editor NEWFaster neural doodle
License: MIT License
Faster neural doodle
License: MIT License
wow, you work is definitely amazing! the result is even better than neural-style.
i tried these code and it work fine on my mbp. there comes a question to me, for any style image i picked from other place, is there any method to generate style mask from it automatically or i must "draw" mask manually?
Hey Dmitry,
I was wondering - how would I go about installing this onto a GPU server, and pass images into the script from an external source (i,e; upload from website, etc;).
Thanks,
Daniel
Hi, I tried to run the command from the tutorial for model training, but it failed with the following error:
CUDA_VISIBLE_DEVICES=0 th feedforward_neural_doodle.lua -model_name skip_noise_4 -masks_hdf5 data/starry/gen_doodles.hdf5 -batch_size 4 -num_mask_noise_times 0 -num_noise_channels 0 -learning_rate 1e-1 -half false
/root/torch/install/bin/luajit: /root/torch/install/share/lua/5.1/hdf5/group.lua:312: HDF5Group:read() - no such child 'style_img' for [HDF5Group 33554432 /]
stack traceback:
[C]: in function 'error'
/root/torch/install/share/lua/5.1/hdf5/group.lua:312: in function 'read'
feedforward_neural_doodle.lua:49: in main chunk
[C]: in function 'dofile'
/root/torch/install/lib/luarocks/rocks/trepl/scm-1/bin/th:145: in main chunk
[C]: at 0x00406670
any ideas why hdf5 might fail with such error?
Hello Dmitry, this is very nice. I appreciate the speed your implementation provide.
I have a question, do you intend to add support for simple style copy instead of doodle based on mask file? This is a simpler alternative that I found to provide better results at times.
Regards
ubuntu@ip-Address:~/fast-neural-doodle$ python get_mask_hdf5.py --n_colors=5 --style_image=Monet2.jpg --style_mask=Monet2_sem2_r.png --target_mask=MonetNew2_sem2.png
Traceback (most recent call last):
File "get_mask_hdf5.py", line 45, in <module>
labels_target = kmeans.predict(target_flatten.astype(float))
File "/usr/lib/python2.7/dist-packages/sklearn/cluster/k_means_.py", line 889, in predict
X = self._check_test_data(X)
File "/usr/lib/python2.7/dist-packages/sklearn/cluster/k_means_.py", line 800, in _check_test_data
n_features, expected_n_features))
ValueError: Incorrect number of features. Got 4 features, expected 3
ubuntu@ip-Address:~/fast-neural-doodle$
ubuntu@ip-Address:~/fast-neural-doodle$ python get_mask_hdf5.py --n_colors=3 --style_image=Monet2.jpg --style_mask=Monet2_sem2_r.png --target_mask=MonetNew2_sem2.png
Traceback (most recent call last):
File "get_mask_hdf5.py", line 45, in <module>
labels_target = kmeans.predict(target_flatten.astype(float))
File "/usr/lib/python2.7/dist-packages/sklearn/cluster/k_means_.py", line 889, in predict
X = self._check_test_data(X)
File "/usr/lib/python2.7/dist-packages/sklearn/cluster/k_means_.py", line 800, in _check_test_data
n_features, expected_n_features))
ValueError: Incorrect number of features. Got 4 features, expected 3
ubuntu@ip-Address:~/fast-neural-doodle$
There are 5 distinct color regions on my masks.
Based on some of my testing I have to say that your implementation is actually producing better results that the original neural-doodle: https://twitter.com/netputing/status/710119813847207937
/home/naman/torch/install/share/lua/5.1/trepl/init.lua:389: /home/naman/torch/install/share/lua/5.1/hdf5/ffi.lua:71: Unsupported HDF5 version: 1.10.1
stack traceback:
[C]: in function 'error'
/home/naman/torch/install/share/lua/5.1/trepl/init.lua:389: in function 'require'
fast_neural_doodle.lua:5: in main chunk
[C]: in function 'dofile'
...aman/torch/install/lib/luarocks/rocks/trepl/scm-1/bin/th:150: in main chunk
[C]: at 0x00405d50
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.