From 46b229094acfd644f514999770ff79588705bbba Mon Sep 17 00:00:00 2001 From: pyr0ball Date: Sun, 15 Mar 2026 04:01:01 -0700 Subject: [PATCH] refactor(scheduler): use module-level _get_gpus directly in __init__ --- scripts/task_scheduler.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/scripts/task_scheduler.py b/scripts/task_scheduler.py index 1d2a29f..b8871db 100644 --- a/scripts/task_scheduler.py +++ b/scripts/task_scheduler.py @@ -84,8 +84,7 @@ class TaskScheduler: # Detect total GPU VRAM; fall back to unlimited (999) on CPU-only systems. # Uses module-level _get_gpus so tests can monkeypatch scripts.task_scheduler._get_gpus. try: - from scripts import task_scheduler as _ts_mod - gpus = _ts_mod._get_gpus() + gpus = _get_gpus() self._available_vram: float = ( sum(g["vram_total_gb"] for g in gpus) if gpus else 999.0 )