test(unraid): add offline benchmark and 10 minute NDI soak

This commit is contained in:
Codex
2026-08-15 09:52:38 -07:00
parent 38230f55a0
commit f5e71edc7f
5 changed files with 118 additions and 2 deletions
@@ -21,6 +21,7 @@ from pynvml import (nvmlDeviceGetHandleByIndex, nvmlDeviceGetMemoryInfo,
from .core import BroadcastHub, LatestQueue
from .models import Models
from .ndi import NDIReceiver
from .offline_benchmark import run_offline_benchmark
logging.basicConfig(level=os.getenv("LOG_LEVEL", "INFO"), format="%(asctime)s %(levelname)s %(name)s %(message)s")
LOG = logging.getLogger("tail2")
@@ -145,7 +146,9 @@ async def poses(ws: WebSocket):
def inference_worker(loop: asyncio.AbstractEventLoop) -> None:
threshold = float(os.getenv("DETECTION_THRESHOLD", ".35")); max_people = int(os.getenv("MAX_PEOPLE", "4"))
try:
models.load(); state.models_ready = True; LOG.info("official detector and pose checkpoints loaded")
models.load()
run_offline_benchmark(models, threshold, max_people)
state.models_ready = True; LOG.info("official detector and pose checkpoints loaded")
except Exception as exc:
state.inference_fault = True; state.error_code = "MODEL_LOAD_FAILED"
state.error_detail = f"{type(exc).__name__}: {str(exc)[:240]}"; LOG.exception("model loading failed"); return