-
Notifications
You must be signed in to change notification settings - Fork 294
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Batch_size error ? #17
Comments
I also got that error. I removed the "sparse_categorical_accuracy" metric and got it to run. Not sure how to keep the metric and make it work though. |
update your keras |
I am using the versions below (latest) and still get the error when trying to use the metric. What versions do you use to make it run?
|
I also come into this error, and I have updated Keras to the latest but without help. Does anyone has a answer for it? Thanks very much |
The lastest keras has an error! |
It works. Thanks~ |
Hi . Thanks for the code first.
When I run the training, I got an issue below. I just follow the simple instructions and did not add extra input. Do you know why this happens ? Thank you very much.
Epoch 1/120
Traceback (most recent call last):
File "./src/train_lpcnet.py", line 150, in
model.fit([in_data, in_exc, features, periods], out_data, batch_size=batch_size, epochs=nb_epochs, validation_split=0.0, callbacks=[checkpoint, lpcnet.Sparsify(2000, 40000, 400, (0.1, 0.1, 0.1))])
File "/usr/local/lib/python3.6/site-packages/keras/engine/training.py", line 1039, in fit
validation_steps=validation_steps)
File "/usr/local/lib/python3.6/site-packages/keras/engine/training_arrays.py", line 199, in fit_loop
outs = f(ins_batch)
File "/usr/local/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py", line 2715, in call
return self._call(inputs)
File "/usr/local/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py", line 2675, in _call
fetched = self._callable_fn(*array_vals)
File "/usr/local/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1382, in call
run_metadata_ptr)
File "/usr/local/lib/python3.6/site-packages/tensorflow/python/framework/errors_impl.py", line 519, in exit
c_api.TF_GetCode(self.status.status))
tensorflow.python.framework.errors_impl.InvalidArgumentError: Incompatible shapes: [153600] vs. [64,2400]
[[Node: metrics_1/sparse_categorical_accuracy/Equal = Equal[T=DT_FLOAT, _device="/job:localhost/replica:0/task:0/device:GPU:0"](metrics_1/sparse_categorical_accuracy/Reshape, metrics_1/sparse_categorical_accuracy/Cast)]]
[[Node: loss_1/mul/_237 = _Recvclient_terminated=false, recv_device="/job:localhost/replica:0/task:0/device:CPU:0", send_device="/job:localhost/replica:0/task:0/device:GPU:0", send_device_incarnation=1, tensor_name="edge_2235_loss_1/mul", tensor_type=DT_FLOAT, _device="/job:localhost/replica:0/task:0/device:CPU:0"]]
The text was updated successfully, but these errors were encountered: