Spaces:
Sleeping
Sleeping
Commit History
-
Pick best accelerator by default; route SVDs through MPS-safe path
get_device now uses CUDA -> MPS -> CPU priority so Apple Silicon picks MPS by default. The previous macOS->CPU branch made forward passes 10-50x slower than they need to be. CLI override (--device cuda|mps|cpu) still wins. Drop the stale "MPS has stability issues" comment; forward-only inference on MPS is solid in torch >= 2. torch.linalg.svdvals is NotImplemented on MPS in current torch, but torch.linalg.svd works. Add a _svdvals() helper in head_analyzer that delegates to the existing _svd() (and thus inherits its numpy fallback for ill-conditioned matrices). Swap the three svdvals call sites. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>2207aa9
-
adding device_utils
96170c6