ARC Lens
Real-time PyTorch training visualization and anomaly detection inside VS Code.
Overview & Ecosystem
ARC Lens is a self-contained Visual Studio Code extension for real-time PyTorch training visualization. Install the extension, point it at your training script, and get a live dashboard showing losses, gradients, and training health directly inside VS Code. No external dependencies required.
Under the hood, ARC Lens ships with a bundled monitoring agent that runs entirely offline on your machine. If a training anomaly is detected (NaN loss, exploding gradients, etc.), the agent automatically evaluates the failure and suggests a recovery action without any network calls.
Main Objectives
- Interactive Visualization: Live dashboard rendering losses, learning rates, gradient L2 norms, GPU memory, weight update ratios, and layer effective rank.
- Anomaly Detection: Real-time identification of training issues including NaN/Inf losses, gradient explosions, and representation collapse.
- Automated Recovery: A bundled offline reasoning agent evaluates detected failures and returns recovery actions (checkpoint rollback, learning rate reduction) without any network or API calls.
Architecture & Execution Flow
When you run ARC Lens, the extension spawns a Python process that hooks into your training script via AST injection. It monkey-patches backward() to intercept every training step and streams metrics back to the VS Code dashboard in real time via stdout.
If an anomaly is detected, the extension's bundled agent runs a local deterministic ReAct loop to evaluate the failure and return a recovery action. Everything runs on your machine, nothing leaves your system.
Settings Configuration
Users can configure ARC Lens behavior via VS Code Settings:
| Setting | Type | Default | Description |
|---|---|---|---|
arcAgent.pythonPath | string | "python" | Path to the Python interpreter |
arcAgent.stepDelay | number | 0.02 | Delay in seconds after each step for visualization pacing |