walid0925 / ai_artistry Goto Github PK
View Code? Open in Web Editor NEWPython implementation of "A Neural Algorithm of Artistic Style," Gatys et al.
License: MIT License
Python implementation of "A Neural Algorithm of Artistic Style," Gatys et al.
License: MIT License
Traceback (most recent call last):
File "/Users/jason/projects/tf/main.py", line 149, in
maxiter=iterations, disp=True)
File "/anaconda3/envs/tf/lib/python2.7/site-packages/scipy/optimize/lbfgsb.py", line 199, in fmin_l_bfgs_b
opts)
File "/anaconda3/envs/tf/lib/python2.7/site-packages/scipy/optimize/lbfgsb.py", line 335, in _minimize_lbfgsb
f, g = func_and_grad(x)
File "/anaconda3/envs/tf/lib/python2.7/site-packages/scipy/optimize/lbfgsb.py", line 285, in func_and_grad
f = fun(x, args)
File "/anaconda3/envs/tf/lib/python2.7/site-packages/scipy/optimize/optimize.py", line 300, in function_wrapper
return function((wrapper_args + args))
File "/Users/jason/projects/tf/main.py", line 91, in calculate_loss
loss_fcn = K.function([gModel.input], [get_total_loss(gModel.input)])
File "/Users/jason/projects/tf/main.py", line 81, in get_total_loss
styleLoss = get_style_loss(ws, Gs, As)
File "/Users/jason/projects/tf/main.py", line 74, in get_style_loss
sLoss+= w0.25K.sum(K.square(G_gram - A_gram))/ (N_l2 * M_l**2)
File "/anaconda3/envs/tf/lib/python2.7/site-packages/tensorflow/python/ops/resource_variable_ops.py", line 1216, in iadd
raise RuntimeError("Variable += value not supported. Use "
RuntimeError: Variable += value not supported. Use variable.assign_add(value) to modify the variable value and variable = variable + value to get a new Tensor object.
Process finished with exit code 1
I keep getting this error, I don't know what's causing it.
Using TensorFlow backend.
Traceback (most recent call last):
File "D:\AI_Artistry.py", line 4, in
from keras import backend as K
File "d:\my_python\lib\site-packages\keras_init_.py", line 3, in
from . import utils
File "d:\my_python\lib\site-packages\keras\utils_init_.py", line 6, in
from . import conv_utils
File "d:\my_python\lib\site-packages\keras\utils\conv_utils.py", line 9, in
from .. import backend as K
File "d:\my_python\lib\site-packages\keras\backend_init_.py", line 89, in
from .tensorflow_backend import *
File "d:\my_python\lib\site-packages\keras\backend\tensorflow_backend.py", line 5, in
import tensorflow as tf
File "d:\my_python\lib\site-packages\tensorflow_init_.py", line 24, in
from tensorflow.python import *
File "d:\my_python\lib\site-packages\tensorflow\python_init_.py", line 60, in
raise ImportError(msg)
ImportError: Traceback (most recent call last):
File "d:\my_python\lib\site-packages\tensorflow\python_init_.py", line 54, in
from tensorflow.python import pywrap_tensorflow
File "d:\my_python\lib\site-packages\tensorflow\python\pywrap_tensorflow.py", line 28, in
_pywrap_tensorflow = swig_import_helper()
File "d:\my_python\lib\site-packages\tensorflow\python\pywrap_tensorflow.py", line 20, in swig_import_helper
import _pywrap_tensorflow
ImportError: No module named _pywrap_tensorflow
Error importing tensorflow. Unless you are using bazel,
you should not try to import tensorflow from its source directory;
please exit the tensorflow source tree, and relaunch your python interpreter
What is the use of including Panda in the example? I imagine it's a holdout from a previous bit of code, but I'm wondering what your use case was. Thanks!
Each iteration of fmin_l_bfgs_b function takes a lot of time to complete even when run on gpu. Why is it so slow. Any optimization we can do to make it fast. And time taken for each iteration also increases gradually. Any reason for this.
Hi,when I run the python code, it doesn't work:
AT8864:AI_Artistry shelter$ python main.py Using Theano backend. Traceback (most recent call last): File "main.py", line 128, in <module> tf_session = K.get_session() AttributeError: 'module' object has no attribute 'get_session'
Where does this error originate? - All tensors fed into the layers are all the same size.
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.