GLM-OCR / code /tt_glmocr /tests /_paths.py
changh95's picture
tt-model push glm-ocr (container)
aa204f5 verified
Raw History Blame Contribute Delete
521 Bytes
# SPDX-License-Identifier: Apache-2.0
"""Paths of the development device / golden checks (dev_*.py): set GLMOCR_ASSETS (the golden set built by
research/glmocr/golden/*.py) and GLMOCR_MODEL (a local zai-org/GLM-OCR checkpoint directory)."""
import os
ASSETS = os.environ.get("GLMOCR_ASSETS") or ""
MODEL = os.environ.get("GLMOCR_MODEL") or os.environ.get("GLMOCR_MODEL_DIR") or ""
if not (ASSETS and MODEL):
raise SystemExit("set GLMOCR_ASSETS (golden set dir) and GLMOCR_MODEL (checkpoint dir) for the dev checks")