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

Failed to OCR a screen rect: read_params_file: parameter not found: enable_new_segsearch #3

Open
brunoais opened this issue Aug 15, 2018 · 9 comments

Comments

@brunoais
Copy link

brunoais commented Aug 15, 2018

I compiled the program as explained in the README. Because of the error mentioned in #2, I moved all that was in tessdata into where Capture2Text_CLI is. Then I did what I mention below

In ubuntu 18 LTS with Xorg windows server, when I run the command:
./Capture2Text_CLI --screen-rect "400 200 600 300"
The program outputs:
read_params_file: parameter not found: enable_new_segsearch

Any idea what is wrong?

See also #2 for another issue I encountered

@GSam
Copy link
Owner

GSam commented Aug 20, 2018

Does supplying -platform offscreen as arguments to the tool help at all when running it?

@brunoais
Copy link
Author

Will check when able...

@GSam
Copy link
Owner

GSam commented Aug 20, 2018

I believe that I built this originally on 16.04, so possibly try that if you can. I may take a look at 18.04, but don't expect anything.

@brunoais
Copy link
Author

brunoais commented Aug 20, 2018 via email

@GSam
Copy link
Owner

GSam commented Aug 20, 2018

One other thing, if you can take a screenshot (to the right dimensions and crop), you can do -i <filename>. That way you can chain the command and have the same functionality probably? (Imagemagick or some other tool might be helpful in this manner).

@brunoais
Copy link
Author

good idea. Will try that next weekend or so.... Very busy...

@brunoais
Copy link
Author

brunoais commented Sep 2, 2018

@GSam I tried with an input file and I got the full screenshot output....
So.... it works as expected when I give an image but it is unable to get an image by itself.... That's an unfortunate bother.... More than half of the work from Capture2Text is the capture itself......

@GSam
Copy link
Owner

GSam commented Sep 2, 2018

It is unfortunate. From what I can tell, some of the GUI components work, but not nearly enough of them to build it all in. The only alternative seems to be rewriting the screenshot code to be more Linux specific, but there doesn't seem to be a useful API, plus it has to be reconverted into QT-based images.

@brunoais
Copy link
Author

brunoais commented Sep 3, 2018

For now, I did: a shortcut to a personalized script which:

  1. Activates the screenshot program already into "area" mode and saving into a tempfs.
  2. Then order capture2Text to capture the text within.
  3. Store the results in another file in the tempfs.
  4. Copy results to clipboard.
  5. Delete the temporary files.

xiaoyifang added a commit to xiaoyifang/Capture2Text that referenced this issue Feb 1, 2022
# This is the 1st commit message:

action:add workflow github

# This is the commit message GSam#2:

action: github workflow

# This is the commit message GSam#3:

action: github workflow

# This is the commit message GSam#4:

action: github workflow
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