"""Make command-line entry points independent of the current directory.""" from __future__ import annotations import os import sys from pathlib import Path PROJECT_ROOT = Path(__file__).resolve().parents[1] def configure_runtime() -> Path: root = str(PROJECT_ROOT) if root not in sys.path: sys.path.insert(0, root) os.environ.setdefault("TF_USE_LEGACY_KERAS", "1") return PROJECT_ROOT