Skip to content

randomwangran/scanner

 
 

Repository files navigation

I would like to use camera to scanner things automatically this might be a good starting point.

compile it

I had some hard time with some requirement.

Scanner

Scans documents using your camera :)

Installation

# install python modules
pip3 install -r requirements.txt
# install tesseract (OCR dependency)
# Example: MacOS
# See https://github.com/tesseract-ocr/tesseract for more details
brew install tesseract --with-all-languages

Run the Scanner

python3 main.py <your_image_file>

The output will be stored in ./result/ directory

Demo

Input Image: input

Boundary Recognition: contour

Transform using homography: transofrm

Recognize text location: text location

Remove text from background: background

Translate and transform the translated text using reverse homography: translated

Merge the text back to the background final

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%