Skip to content
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

训练代码train.py出错 #65

Open
cuimiao187561 opened this issue Sep 10, 2019 · 1 comment
Open

训练代码train.py出错 #65

cuimiao187561 opened this issue Sep 10, 2019 · 1 comment

Comments

@cuimiao187561
Copy link

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "train.py", line 211, in
app.run()
File "/home/shakey/.local/lib/python3.6/site-packages/tensorflow/python/platform/app.py", line 125, in run
_sys.exit(main(argv))
File "train.py", line 207, in main
train(total_loss, init_fn, hparams)
File "train.py", line 155, in train
init_fn=init_fn)
File "/home/shakey/.local/lib/python3.6/site-packages/tensorflow/contrib/slim/python/slim/learning.py", line 785, in train
ignore_live_threads=ignore_live_threads)
File "/usr/anaconda3/lib/python3.6/contextlib.py", line 99, in exit
self.gen.throw(type, value, traceback)
File "/home/shakey/.local/lib/python3.6/site-packages/tensorflow/python/training/supervisor.py", line 1004, in managed_session
self.stop(close_summary_writer=close_summary_writer)
File "/home/shakey/.local/lib/python3.6/site-packages/tensorflow/python/training/supervisor.py", line 832, in stop
ignore_live_threads=ignore_live_threads)
File "/home/shakey/.local/lib/python3.6/site-packages/tensorflow/python/training/coordinator.py", line 389, in join
six.reraise(*self._exc_info_to_raise)
File "/usr/anaconda3/lib/python3.6/site-packages/six.py", line 693, in reraise
raise value
File "/home/shakey/.local/lib/python3.6/site-packages/tensorflow/python/training/queue_runner_impl.py", line 257, in _run
enqueue_callable()
File "/home/shakey/.local/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1257, in _single_operation_run
self._call_tf_sessionrun(None, {}, [], target_list, None)
File "/home/shakey/.local/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1407, in _call_tf_sessionrun
run_metadata)
tensorflow.python.framework.errors_impl.InvalidArgumentError: Key: image/class. Can't parse serialized Example.
[[{{node ParseSingleExample/ParseSingleExample}} = ParseSingleExample[Tdense=[DT_INT64, DT_STRING, DT_STRING, DT_INT64, DT_STRING, DT_INT64], dense_keys=["image/class", "image/encoded", "image/format", "image/orig_width", "image/text", "image/width"], dense_shapes=[[37], [], [], [1], [1], [1]], num_sparse=1, sparse_keys=["image/unpadded_class"], sparse_types=[DT_INT64], _device="/job:localhost/replica:0/task:0/device:CPU:0"](parallel_read/common_queue_Dequeue:1, ParseSingleExample/Const, ParseSingleExample/key_image/encoded, ParseSingleExample/key_image/format, zeros, ParseSingleExample/Reshape_2, zeros)]]

@jisheng047
Copy link

@cuimiao187561 check the max_sequence_length.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants