MCPcopy Create free account
hub / github.com/alpha2phi/python-apps / recognize

Function recognize

ocr-viewer/backend/ocr/recognizer.py:6–9  ·  view source on GitHub ↗

Process a PIL image.

(img, lang="eng")

Source from the content-addressed store, hash-verified

4
5# def recognize(img, lang="eng+chi_sim"):
6def recognize(img, lang="eng"):
7 """Process a PIL image."""
8 extracted = pytesseract.image_to_string(img, lang=lang)
9 return extracted
10

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected