Coder Social home page Coder Social logo

How to run on cpu ?? about attentionocr HOT 2 OPEN

zhang0jhon avatar zhang0jhon commented on August 23, 2024
How to run on cpu ??

from attentionocr.

Comments (2)

zhang0jhon avatar zhang0jhon commented on August 23, 2024

Currently the model default runs on GPU for fast speed, if you want to run cpu, you should try to use tensorflow 1.14 instead of tensorflow-gpu 1.14

from attentionocr.

dont32 avatar dont32 commented on August 23, 2024

I had used only your ocr model in docker but when i run test.py from source having error :
ile "test.py", line 121, in
test(args)
File "test.py", line 91, in test
model = TextRecognition(args.pb_path, cfg.seq_len+1)
File "test.py", line 23, in init
self.init_model()
File "test.py", line 37, in init_model
self.label_ph = self.sess.graph.get_tensor_by_name('label:0')
File "/home/dont/.virtualenvs/python3-cpu/lib/python3.5/site-packages/tensorflow/python/framework/ops.py", line 3972, in get_tensor_by_name
return self.as_graph_element(name, allow_tensor=True, allow_operation=False)
File "/home/dont/.virtualenvs/python3-cpu/lib/python3.5/site-packages/tensorflow/python/framework/ops.py", line 3796, in as_graph_element
return self._as_graph_element_locked(obj, allow_tensor, allow_operation)
File "/home/dont/.virtualenvs/python3-cpu/lib/python3.5/site-packages/tensorflow/python/framework/ops.py", line 3838, in _as_graph_element_locked
"graph." % (repr(name), repr(op_name)))
KeyError: "The name 'label:0' refers to a Tensor which does not exist. The operation, 'label', does not exist in the graph."
@zhang0jhon anny different ??

from attentionocr.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.