publish eve_rock_watcher.py

This commit is contained in:
brockdarnold 2026-06-15 02:20:39 +00:00
parent a44131ad07
commit b28e74ae8b

View file

@ -243,6 +243,9 @@ def get_region(cp):
def read_rows(cp, region, mode): def read_rows(cp, region, mode):
import pytesseract import pytesseract
tcmd = cp.get("ocr", "tesseract_cmd", fallback="").strip()
if tcmd: # Tesseract isn't always on PATH; set it explicitly
pytesseract.pytesseract.tesseract_cmd = tcmd
img = w.grab_region(region) img = w.grab_region(region)
try: # upscale: small panel text reads better try: # upscale: small panel text reads better
img = img.resize((img.width * 2, img.height * 2)) img = img.resize((img.width * 2, img.height * 2))