-
Notifications
You must be signed in to change notification settings - Fork 109
Description
I don't understand how to debug this error.
018-06-10 23:25:50.340196: I tensorflow/core/platform/cpu_feature_guard.cc:137] Your CPU supports instructions that this TensorFlow binary was not compiled to use: SSE4.1 SSE4.2 AVX
Traceback (most recent call last):
File "/home/durga/.local/lib/python3.5/site-packages/tensorflow/python/client/session.py", line 1350, in _do_call
return fn(*args)
File "/home/durga/.local/lib/python3.5/site-packages/tensorflow/python/client/session.py", line 1329, in _run_fn
status, run_metadata)
File "/home/durga/.local/lib/python3.5/site-packages/tensorflow/python/framework/errors_impl.py", line 473, in exit
c_api.TF_GetCode(self.status.status))
tensorflow.python.framework.errors_impl.InvalidArgumentError: indices[10,55] = -1 is not in [0, 2168)
[[Node: embedding_1/Gather = Gather[Tindices=DT_INT32, Tparams=DT_FLOAT, validate_indices=true, _device="/job:localhost/replica:0/task:0/device:CPU:0"](embedding_1/embeddings/read, embedding_1/Cast)]]
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/durga/PycharmProjects/7.Recent/start_to_end.py", line 159, in
validation_data=(x_test, y_test))
File "/home/durga/.local/lib/python3.5/site-packages/keras/models.py", line 963, in fit
validation_steps=validation_steps)
File "/home/durga/.local/lib/python3.5/site-packages/keras/engine/training.py", line 1705, in fit
validation_steps=validation_steps)
File "/home/durga/.local/lib/python3.5/site-packages/keras/engine/training.py", line 1235, in _fit_loop
outs = f(ins_batch)
File "/home/durga/.local/lib/python3.5/site-packages/keras/backend/tensorflow_backend.py", line 2478, in call
**self.session_kwargs)
File "/home/durga/.local/lib/python3.5/site-packages/tensorflow/python/client/session.py", line 895, in run
run_metadata_ptr)
File "/home/durga/.local/lib/python3.5/site-packages/tensorflow/python/client/session.py", line 1128, in _run
feed_dict_tensor, options, run_metadata)
File "/home/durga/.local/lib/python3.5/site-packages/tensorflow/python/client/session.py", line 1344, in _do_run
options, run_metadata)
File "/home/durga/.local/lib/python3.5/site-packages/tensorflow/python/client/session.py", line 1363, in _do_call
raise type(e)(node_def, op, message)
tensorflow.python.framework.errors_impl.InvalidArgumentError: indices[10,55] = -1 is not in [0, 2168)
[[Node: embedding_1/Gather = Gather[Tindices=DT_INT32, Tparams=DT_FLOAT, validate_indices=true, _device="/job:localhost/replica:0/task:0/device:CPU:0"](embedding_1/embeddings/read, embedding_1/Cast)]]
Caused by op 'embedding_1/Gather', defined at:
File "/home/durga/PycharmProjects/7.Recent/start_to_end.py", line 146, in
model.add(Embedding(vocab_size, 32))
File "/home/durga/.local/lib/python3.5/site-packages/keras/models.py", line 467, in add
layer(x)
File "/home/durga/.local/lib/python3.5/site-packages/keras/engine/topology.py", line 619, in call
output = self.call(inputs, **kwargs)
File "/home/durga/.local/lib/python3.5/site-packages/keras/layers/embeddings.py", line 138, in call
out = K.gather(self.embeddings, inputs)
File "/home/durga/.local/lib/python3.5/site-packages/keras/backend/tensorflow_backend.py", line 1211, in gather
return tf.gather(reference, indices)
File "/home/durga/.local/lib/python3.5/site-packages/tensorflow/python/ops/array_ops.py", line 2585, in gather
params, indices, validate_indices=validate_indices, name=name)
File "/home/durga/.local/lib/python3.5/site-packages/tensorflow/python/ops/gen_array_ops.py", line 1864, in gather
validate_indices=validate_indices, name=name)
File "/home/durga/.local/lib/python3.5/site-packages/tensorflow/python/framework/op_def_library.py", line 787, in _apply_op_helper
op_def=op_def)
File "/home/durga/.local/lib/python3.5/site-packages/tensorflow/python/framework/ops.py", line 3160, in create_op
op_def=op_def)
File "/home/durga/.local/lib/python3.5/site-packages/tensorflow/python/framework/ops.py", line 1625, in init
self._traceback = self._graph._extract_stack() # pylint: disable=protected-access
InvalidArgumentError (see above for traceback): indices[10,55] = -1 is not in [0, 2168)
[[Node: embedding_1/Gather = Gather[Tindices=DT_INT32, Tparams=DT_FLOAT, validate_indices=true, _device="/job:localhost/replica:0/task:0/device:CPU:0"](embedding_1/embeddings/read, embedding_1/Cast)]]