basveeling / wavenet

Keras WaveNet implementation
https://soundcloud.com/basveeling/wavenet-sample
1.06k stars 219 forks source link

AssertionError in tensorflow_backend.py #2

Closed drobertduke closed 7 years ago

drobertduke commented 7 years ago

I'm running Ubuntu 16.04.1, CUDA 8.0.26, and CudNN 5.1.5 following the Python 2 directions here

wavenet$ python wavenet.py predict with models/run_2016-09-14_11:32:09/config.json predict_seconds=1
Using TensorFlow backend.
I tensorflow/stream_executor/dso_loader.cc:111] successfully opened CUDA library libcublas.so.8.0 locally
I tensorflow/stream_executor/dso_loader.cc:111] successfully opened CUDA library libcudnn.so.5.1.5 locally
I tensorflow/stream_executor/dso_loader.cc:111] successfully opened CUDA library libcufft.so.8.0 locally
I tensorflow/stream_executor/dso_loader.cc:111] successfully opened CUDA library libcuda.so.1 locally
I tensorflow/stream_executor/dso_loader.cc:111] successfully opened CUDA library libcurand.so.8.0 locally
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: 37
INFO - predict - Saving to "models/run_2016-09-14_11:32:09/samples/sample_epoch-00037_01s__sample_seed-920639969.wav"
I tensorflow/core/common_runtime/gpu/gpu_device.cc:951] Found device 0 with properties: 
name: TITAN X (Pascal)
major: 6 minor: 1 memoryClockRate (GHz) 1.531
pciBusID 0000:03:00.0
Total memory: 11.90GiB
Free memory: 11.38GiB
I tensorflow/core/common_runtime/gpu/gpu_device.cc:972] DMA: 0 
I tensorflow/core/common_runtime/gpu/gpu_device.cc:982] 0:   Y 
I tensorflow/core/common_runtime/gpu/gpu_device.cc:1041] Creating TensorFlow device (/gpu:0) -> (device: 0, name: TITAN X (Pascal), pci bus id: 0000:03:00.0)
ERROR - wavenet - Failed after 0:00:01!
Traceback (most recent calls WITHOUT Sacred internals):
  File "wavenet.py", line 224, in predict
    model = build_model()
  File "wavenet.py", line 158, in build_model
    out, skip_out = residual_block(out)
  File "wavenet.py", line 141, in residual_block
    name='dilated_conv_%d_tanh_s%d' % (2 ** i, s), activation='tanh')(x)
  File "/usr/local/lib/python2.7/dist-packages/keras/engine/topology.py", line 514, in __call__
    self.add_inbound_node(inbound_layers, node_indices, tensor_indices)
  File "/usr/local/lib/python2.7/dist-packages/keras/engine/topology.py", line 572, in add_inbound_node
    Node.create_node(self, inbound_layers, node_indices, tensor_indices)
  File "/usr/local/lib/python2.7/dist-packages/keras/engine/topology.py", line 149, in create_node
    output_tensors = to_list(outbound_layer.call(input_tensors[0], mask=input_masks[0]))
  File "/usr/local/lib/python2.7/dist-packages/keras/layers/convolutional.py", line 655, in call
    filter_dilation=self.atrous_rate)
  File "/usr/local/lib/python2.7/dist-packages/keras/backend/tensorflow_backend.py", line 1575, in conv2d
    assert filter_dilation[0] == filter_dilation[1]
AssertionError
basveeling commented 7 years ago

I just pushed a fix to basveeling/keraswavenet that should solve this problem. Try reinstalling it via pip and please let me know if you run into any other errors.