da03 / Attention-OCR

Visual Attention based OCR
MIT License
1.12k stars 363 forks source link

when i running the testing code. i am getting the below error #79

Open balajiwix opened 6 years ago

balajiwix commented 6 years ago

Reading model parameters from E:/Data_Science/OCR/Attention-OCR-master/model_ocr/model\translate.ckpt-47200 Traceback (most recent call last): File "C:\Users\sabari\Anaconda3\lib\site-packages\tensorflow\python\client\session.py", line 1327, in _do_call return fn(*args) File "C:\Users\sabari\Anaconda3\lib\site-packages\tensorflow\python\client\session.py", line 1306, in _run_fn status, run_metadata) File "C:\Users\sabari\Anaconda3\lib\contextlib.py", line 88, in exit next(self.gen) File "C:\Users\sabari\Anaconda3\lib\site-packages\tensorflow\python\framework\errors_impl.py", line 466, in raise_exception_on_not_ok_status pywrap_tensorflow.TF_GetCode(status)) tensorflow.python.framework.errors_impl.NotFoundError: Tensor name "bidirectional_rnn/bw/basic_lstm_cell/bias" not found in checkpoint files E:/Data_Science/OCR/Attention-OCR-master/model_ocr/model\translate.ckpt-47200 [[Node: save/RestoreV2_1 = RestoreV2[dtypes=[DT_FLOAT], _device="/job:localhost/replica:0/task:0/cpu:0"](_arg_save/Const_0_0, save/RestoreV2_1/tensor_names, save/RestoreV2_1/shape_and_slices)]]

During handling of the above exception, another exception occurred:

SJHBXShub commented 6 years ago

I confront the same problem with you, have you solved this problem? Brs

faithfulnguyen commented 6 years ago

because you using old version, you need convert name node, here code to convert name node: https://github.com/tensorflow/tensorflow/tree/master/tensorflow/contrib/rnn/python/tools, or you can remove tensorflow and install new version. hope it help you.

DANNALI35 commented 6 years ago

i met the same problem. @trungtinnguyen i tried to use the checkpoint_convert.py you suggested and successfully converted the checkpoint, yet it still has the same issue.

i also tried the solution at https://github.com/mozilla/DeepSpeech/issues/859, the "bidirectional_rnn/bw/basic_lstm_cell/bias" error message has gone, but the converted checkpoint made totally incorrect predictions

saikat-sarkar commented 5 years ago

because you using old version, you need convert name node, here code to convert name node: https://github.com/tensorflow/tensorflow/tree/master/tensorflow/contrib/rnn/python/tools, or you can remove tensorflow and install new version. hope it help you. Hi I am already on the latest version. Still the same error

jewelcai commented 5 years ago

because you using old version, you need convert name node, here code to convert name node: https://github.com/tensorflow/tensorflow/tree/master/tensorflow/contrib/rnn/python/tools, or you can remove tensorflow and install new version. hope it help you. Hi I am already on the latest version. Still the same error

Did you solve this issue?

vijayvanapalli96 commented 2 years ago

Anyone solve this issue??

vijayvanapalli96 commented 2 years ago

i met the same problem. @trungtinnguyen i tried to use the checkpoint_convert.py you suggested and successfully converted the checkpoint, yet it still has the same issue.

i also tried the solution at mozilla/DeepSpeech#859, the "bidirectional_rnn/bw/basic_lstm_cell/bias" error message has gone, but the converted checkpoint made totally incorrect predictions

@DANNALI35 were you able to make correct predictions? I've tried using the new checkpoint as well with 0 results turning correct.