Code Monkey home page Code Monkey logo

Comments (16)

ZmeiGorynych avatar ZmeiGorynych commented on August 27, 2024 1

No particular reason - ran into same issue when using Theano:

ubuntu@ip-172-31-47-104:~/wavenet$ KERAS_BACKEND=theano python wavenet.py predict with models/run_20160920_120916/config.json predict_seconds=1
Using Theano backend.
WARNING - root - Changed type of config entry "run_dir" from NoneType to unicode
WARNING - root - Changed type of config entry "optimizer.epsilon" from NoneType to float
INFO - wavenet - Running command 'predict'
WARNING - wavenet - No observers have been added to this run
INFO - wavenet - Started
INFO - predict - Using checkpoint from epoch: 358
INFO - predict - Saving to "models/run_20160920_120916/samples/sample_epoch-00358_01s__sample-temp-0.001_seed-946674575.wav"
ERROR - wavenet - Failed after 0:00:00!
Traceback (most recent calls WITHOUT Sacred internals):
  File "wavenet.py", line 316, in predict
    model = build_model()
  File "wavenet.py", line 241, in build_model
    name='initial_causal_conv')(out)
  File "/home/ubuntu/anaconda2/lib/python2.7/site-packages/keras/layers/convolutional.py", line 286, in __init__
    bias=bias, **kwargs)
  File "/home/ubuntu/anaconda2/lib/python2.7/site-packages/keras/layers/convolutional.py", line 126, in __init__
    super(Convolution1D, self).__init__(**kwargs)
  File "/home/ubuntu/anaconda2/lib/python2.7/site-packages/keras/engine/topology.py", line 326, in __init__
    raise TypeError('Keyword argument not understood:', kwarg)
TypeError: ('Keyword argument not understood:', 'causal')

from wavenet.

basveeling avatar basveeling commented on August 27, 2024 1

from wavenet.

beckgom avatar beckgom commented on August 27, 2024

I got same issue, too.

any idea?

from wavenet.

beckgom avatar beckgom commented on August 27, 2024

I solved the problem by reinstalling keras from basveeling github.
try to uninstall the keras and use it from basveeling's one

from wavenet.

yongxuUSTC avatar yongxuUSTC commented on August 27, 2024

Yes, you are right. Tks

from wavenet.

ZmeiGorynych avatar ZmeiGorynych commented on August 27, 2024

Doesn't work for me. I did
$ pip uninstall keras
$ pip install git+https://github.com/basveeling/keras.git
$ KERAS_BACKEND=tensorflow python wavenet.py predict with models/run_20160920_120916/config.json predict_seconds=1

And I get the following error:

Using TensorFlow backend.
Traceback (most recent call last):
File "wavenet.py", line 23, in
from keras.callbacks import ModelCheckpoint, EarlyStopping, ReduceLROnPlateau, CSVLogger
ImportError: cannot import name ReduceLROnPlateau

Am I doing something wrong?

from wavenet.

Sobsz avatar Sobsz commented on August 27, 2024

@ZmeiGorynych I don't think @basveeling's branch of Keras can fix the problem, I tried using it and it's just too old. Try installing the newest version and tell me what shows up.

from wavenet.

ZmeiGorynych avatar ZmeiGorynych commented on August 27, 2024

newest version of Keras from PyPI?

from wavenet.

ZmeiGorynych avatar ZmeiGorynych commented on August 27, 2024

Doesn't help I'm afraid:

ubuntu@ip-172-31-47-104:~/wavenet$ pip install keras -U
...
ubuntu@ip-172-31-47-104:~/wavenet$ KERAS_BACKEND=tensorflow python wavenet.py predict with models/run_20160920_120916/config.json predict_seconds=1
Using TensorFlow backend.
WARNING - root - Changed type of config entry "run_dir" from NoneType to unicode
WARNING - root - Changed type of config entry "optimizer.epsilon" from NoneType to float
INFO - wavenet - Running command 'predict'
WARNING - wavenet - No observers have been added to this run
INFO - wavenet - Started
INFO - predict - Using checkpoint from epoch: 358
INFO - predict - Saving to "models/run_20160920_120916/samples/sample_epoch-00358_01s__sample-temp-0.001_seed-946674575.wav"
ERROR - wavenet - Failed after 0:00:00!
Traceback (most recent calls WITHOUT Sacred internals):
  File "wavenet.py", line 316, in predict
    model = build_model()
  File "wavenet.py", line 241, in build_model
    name='initial_causal_conv')(out)
  File "/home/ubuntu/anaconda2/lib/python2.7/site-packages/keras/layers/convolutional.py", line 286, in __init__
    bias=bias, **kwargs)
  File "/home/ubuntu/anaconda2/lib/python2.7/site-packages/keras/layers/convolutional.py", line 126, in __init__
    super(Convolution1D, self).__init__(**kwargs)
  File "/home/ubuntu/anaconda2/lib/python2.7/site-packages/keras/engine/topology.py", line 326, in __init__
    raise TypeError('Keyword argument not understood:', kwarg)
TypeError: ('Keyword argument not understood:', 'causal')

from wavenet.

Sobsz avatar Sobsz commented on August 27, 2024

I noticed you're explicitly using TensorFlow. Is there a reason for that?

from wavenet.

Sobsz avatar Sobsz commented on August 27, 2024

I mean, it's probably not the reason for the TypeError, but AFAIK the script doesn't like to work with TensorFlow...

from wavenet.

Sobsz avatar Sobsz commented on August 27, 2024

From what I can figure out (that is, not a lot), @basveeling used an argument (casual) which is neither in his branch nor the master branch of Keras. The only thing I can think of (and this is probably a terrible solution) is removing casual=True, from line 240 of wavenet.py.

from wavenet.

ZmeiGorynych avatar ZmeiGorynych commented on August 27, 2024

It's there in many places, and there's a specific comment that the function in question is in his keras fork. How the earlier commenters managed to make it work is a mystery to me ;)
Oh well, unless someone can suggest a solution here I'll go for https://github.com/ibab/tensorflow-wavenet and https://github.com/tomlepaine/fast-wavenet instead :)

from wavenet.

agulli avatar agulli commented on August 27, 2024

Were you able to solve it?

from wavenet.

basveeling avatar basveeling commented on August 27, 2024

Hi! I've been running into some odd Theano errors, and I lack access to a GPU right now. I'll hopefully figure this out soon :).

from wavenet.

basveeling avatar basveeling commented on August 27, 2024

I think my recent fix should solve this issue. Please let me know if it works :).

from wavenet.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.