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

Added ocr lang config, psm and GCV support #181

Closed
wants to merge 1 commit into from

Conversation

naourass
Copy link

@naourass naourass commented Jul 9, 2022

  • Can choose between tesseract or Google Cloud Vision as an OCR engine (default to Tesseract)
  • Can specify languages and page segmentation mode (psm only for tesseract, languages should be expressed in the appropriate format : Tesseract / GCV langs refs)
  • Can generate output with non-latin characters

@lolipopshock
Copy link
Collaborator

Thanks! Will take a closer look next week.

@naourass
Copy link
Author

naourass commented Jul 16, 2022

Hi there, I'll be adding following edits to this PR :

  • Unknown option error message : removed gcv-credential option hint since the file should be dropped directly in working dir
  • Renamed and refactored preprocessors/tesseract.py to preprocessors/ocr.py for better legibility
  • Added comprehensive error message and handling when gcv credential file is not found
  • Formatted code using black provider

Looking froward to your feedback about the implementation quality and if there's any relevant changes that should be done, so I can push the update and move forward FUNSD-like and IOB Format export features.

@naourass naourass closed this Sep 19, 2022
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

Successfully merging this pull request may close these issues.

2 participants