trackio-view


Nametrackio-view JSON
Version 0.1.0 PyPI version JSON
download
home_pageNone
SummaryTerminal-based dashboard for TrackIO experiment tracking
upload_time2025-10-30 08:38:57
maintainerNone
docs_urlNone
authorNone
requires_python>=3.8
licenseNone
keywords machine-learning experiment-tracking terminal-ui gpu-monitoring ml-ops
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # TrackIO View

Terminal-based dashboard for [TrackIO](https://github.com/wandb/trackio) experiment tracking. Monitor your machine learning experiments directly from the command line with beautiful, real-time visualizations and GPU monitoring.

![TrackIO View Demo](assets/trackio-view-demo-01.png)

## Background

TrackIO View was originally developed as an enhancement to the main [TrackIO](https://github.com/wandb/trackio) project. Following feedback from the TrackIO maintainers who appreciated the functionality but felt it was out of scope for the core lightweight tracking library, this has been extracted into a standalone package:

> "This is very cool @mcgrof but is a bit out of scope and will be hard for us to maintain. Trackio is designed to be pretty lightweight and extensible so I'd recommend instead creating a separate trackio-view pypi package which we could link to from our documentation."

This allows TrackIO to remain focused on its core mission while providing users with a powerful, optional terminal-based monitoring tool. The original implementation can be found in the [TrackIO repository](https://github.com/wandb/trackio) on branch `20250921-trackio-view`.

## Features

- 📊 **Real-time Metrics Display**: Monitor training progress with live-updating terminal dashboard
- 📈 **ASCII Graphs**: Beautiful gradient-colored graphs for loss, accuracy, and custom metrics
- 🖥️ **GPU Monitoring**: Comprehensive GPU hardware monitoring (NVIDIA, AMD, Intel)
- 🔍 **Interactive Zoom**: Zoom in/out to examine different portions of training history
- 🎨 **Color-Coded Feedback**: Intuitive color gradients for quick performance assessment
- 🌐 **Remote-Friendly**: Perfect for monitoring training on remote servers via SSH
- ⚡ **Lightweight**: Minimal resource usage compared to web dashboards
- 🔧 **Flexible**: Works with or without the `rich` library for enhanced visuals

## Installation

```bash
pip install trackio-view
```

For enhanced terminal graphics (recommended):

```bash
pip install trackio-view[rich]
```

For NVIDIA GPU monitoring support:

```bash
pip install trackio-view[nvidia]
```

Install all optional dependencies:

```bash
pip install trackio-view[all]
```

## Quick Start

### Monitor Training Metrics

Start your training with TrackIO:

```python
import trackio

trackio.init(project="my-experiment")

for epoch in range(num_epochs):
    for batch in dataloader:
        loss = train_step(batch)
        trackio.log({"loss": loss, "epoch": epoch})

trackio.finish()
```

In another terminal, launch the dashboard:

```bash
trackio-view --project my-experiment
```

### Monitor GPU Hardware

```bash
# Real-time GPU monitoring
trackio-view --gpu

# Quick GPU status check
trackio-view --gpu --once
```

### View Logged GPU Metrics

If you logged GPU metrics during training:

```python
trackio.init(project="my-training", log_gpu=True)
```

View them later:

```bash
# Display GPU database metrics once
trackio-view --gpu-db --project my-training --once

# Live monitoring of GPU database
trackio-view --gpu-db --project my-training
```

## Usage

### Command Line Options

```
trackio-view [OPTIONS]

Options:
  -p, --project TEXT     Project name to monitor
  -i, --interval INT     Update interval in seconds (default: 2)
  --once                 Display once and exit (no live monitoring)
  --gpu                  Show live GPU hardware metrics
  --gpu-db               Show GPU metrics from database (requires --project)
  -z, --zoom {0,1,2,3,4} Initial zoom level (0=all, 1=500, 2=200, 3=100, 4=50)
  -h, --help            Show help message
```

### Interactive Controls (Live Mode)

- **Press `+`**: Zoom in (show fewer, more recent iterations)
- **Press `-`**: Zoom out (show more training history)
- **Press `q`**: Quit
- **Number keys (0-9)**: Switch between GPUs (in GPU mode)

#### Zoom Visualization

The interactive zoom feature lets you explore different time scales of your training. Press `+` to zoom in (see fewer, more recent iterations) and `-` to zoom out (see more history).

**Real-World Example: Progressive Zoom Levels**

Each level numerically represents zooming in by pressing `+`:

**Level 1 - Initial View (500 iterations):**

![Demo Zoom Level 1](assets/demo-screen-shot-level1.png)

**Level 2 - Zoomed In (200 iterations):**

![Demo Zoom Level 2](assets/demo-screen-shot-level2.png)

**Level 3 - Maximum Detail (100 iterations):**

![Demo Zoom Level 3](assets/demo-screen-shot-level3.png)

This feature is perfect for:
- Getting an overview of entire training runs (zoom out)
- Examining recent training dynamics in detail (zoom in)
- Identifying patterns at different time scales
- Monitoring convergence behavior and spotting anomalies

### Examples

```bash
# Monitor specific project
trackio-view --project my-model-training

# Quick snapshot without live updates
trackio-view --once

# Start with zoom on last 200 iterations
trackio-view --zoom 2

# Slower updates (every 5 seconds)
trackio-view --interval 5

# Monitor GPU while training
trackio-view --gpu

# View historical GPU data from training
trackio-view --gpu-db --project my-training --once
```

## GPU Monitoring

TrackIO View includes comprehensive GPU monitoring inspired by [gputop](https://github.com/mcgrof/gputop).

![TrackIO GPU Monitoring](assets/trackio-view-gpu.png)

### Supported GPUs

#### NVIDIA GPUs
- Desktop: RTX 30/40 series, GTX 10/16 series, Quadro
- Datacenter: A100, V100, A10G, T4
- Embedded: Jetson TX2, Xavier, Orin, Nano

#### AMD GPUs
- Workstation: Radeon Pro W7900, W6800, W5700
- Consumer: RX 6000/7000 series, RX 500/Vega series
- Datacenter: MI100, MI250, MI300 series

#### Intel GPUs
- Arc series discrete GPUs
- Integrated: Iris Xe, UHD Graphics

### GPU Metrics

- GPU utilization percentage
- Memory usage (GB and percentage)
- Temperature (multiple sensors)
- Power consumption
- Clock frequencies (graphics, memory, fabric, SoC)
- Fan speed and RPM
- Performance states

## Use Cases

### Remote Training Monitoring

```bash
# SSH into remote server
ssh user@gpu-server

# Monitor training progress
trackio-view --project remote-training

# Or run in screen/tmux for persistent monitoring
screen -S training-monitor
trackio-view --project my-training
```

### Quick Status Checks

```bash
# Get training snapshot
trackio-view --once

# Pipe to file
trackio-view --once > metrics.txt

# Extract specific metrics
trackio-view --once | grep "Latest Loss:"
```

### Automation and Scripting

```bash
# Check if training converged
change=$(trackio-view --once --zoom 3 | grep "Loss Change:" | awk '{print $3}')
if (( $(echo "$change < 0.001 && $change > -0.001" | bc -l) )); then
  echo "Training has converged"
fi

# Log progress periodically
while true; do
  trackio-view --once >> training_log.txt
  sleep 3600
done
```

## Architecture

TrackIO View is designed as a lightweight, standalone package that depends on TrackIO for data access:

- **trackio_view.view**: Main viewer module with terminal UI
- **trackio_view.gpu_monitor**: Cross-platform GPU monitoring backend
- **trackio_view.gpu_dashboard**: Simplified GPU dashboard
- **trackio_view.gpu_dashboard_gputop**: Full gputop-style monitoring

The package uses:
- ANSI escape codes for terminal control and colors
- Gradient color schemes for visual feedback
- Deque-based data structures for efficient graph rendering
- Platform-specific GPU interfaces (NVML, sysfs, DRM)

## Requirements

- Python 3.8+
- trackio >= 0.1.0
- Optional: `rich` for enhanced terminal graphics
- Optional: `nvidia-ml-py` for NVIDIA GPU monitoring

## Development

```bash
# Clone the repository
git clone https://github.com/mcgrof/trackio-view.git
cd trackio-view

# Install in development mode
pip install -e .[dev]

# Run tests
pytest

# Format code
ruff check --fix --select I && ruff format
```

## Troubleshooting

### No data found

Ensure:
- TrackIO logging is enabled in your training script
- Data is in the expected location (`~/.cache/huggingface/trackio/`)
- Correct project name is specified

### Colors not displaying

Try:
- Using a modern terminal (iTerm2, Windows Terminal, etc.)
- Setting `TERM=xterm-256color`
- Installing the `rich` library

### GPU monitoring not working

Check:
- GPU drivers are installed
- For NVIDIA: Install `nvidia-ml-py` package
- For AMD: sysfs hwmon interfaces are accessible
- Run with `--once` to see detailed error messages

## Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

## License

MIT - See LICENSE file for details

## Credits

- Inspired by [gputop](https://github.com/mcgrof/gputop) for terminal-based GPU monitoring
- Built on top of [TrackIO](https://github.com/wandb/trackio) for experiment tracking

## Links

- [TrackIO Documentation](https://docs.claude.com/trackio)
- [TrackIO GitHub](https://github.com/wandb/trackio)
- [Issue Tracker](https://github.com/wandb/trackio/issues)

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "trackio-view",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": "Luis Chamberlain <mcgrof@kernel.org>",
    "keywords": "machine-learning, experiment-tracking, terminal-ui, gpu-monitoring, ml-ops",
    "author": null,
    "author_email": "Luis Chamberlain <mcgrof@kernel.org>",
    "download_url": "https://files.pythonhosted.org/packages/9b/82/63731a9b5eff35d2b801330db956c77ac2684cef820a32fe4b72a65f3c94/trackio_view-0.1.0.tar.gz",
    "platform": null,
    "description": "# TrackIO View\n\nTerminal-based dashboard for [TrackIO](https://github.com/wandb/trackio) experiment tracking. Monitor your machine learning experiments directly from the command line with beautiful, real-time visualizations and GPU monitoring.\n\n![TrackIO View Demo](assets/trackio-view-demo-01.png)\n\n## Background\n\nTrackIO View was originally developed as an enhancement to the main [TrackIO](https://github.com/wandb/trackio) project. Following feedback from the TrackIO maintainers who appreciated the functionality but felt it was out of scope for the core lightweight tracking library, this has been extracted into a standalone package:\n\n> \"This is very cool @mcgrof but is a bit out of scope and will be hard for us to maintain. Trackio is designed to be pretty lightweight and extensible so I'd recommend instead creating a separate trackio-view pypi package which we could link to from our documentation.\"\n\nThis allows TrackIO to remain focused on its core mission while providing users with a powerful, optional terminal-based monitoring tool. The original implementation can be found in the [TrackIO repository](https://github.com/wandb/trackio) on branch `20250921-trackio-view`.\n\n## Features\n\n- \ud83d\udcca **Real-time Metrics Display**: Monitor training progress with live-updating terminal dashboard\n- \ud83d\udcc8 **ASCII Graphs**: Beautiful gradient-colored graphs for loss, accuracy, and custom metrics\n- \ud83d\udda5\ufe0f **GPU Monitoring**: Comprehensive GPU hardware monitoring (NVIDIA, AMD, Intel)\n- \ud83d\udd0d **Interactive Zoom**: Zoom in/out to examine different portions of training history\n- \ud83c\udfa8 **Color-Coded Feedback**: Intuitive color gradients for quick performance assessment\n- \ud83c\udf10 **Remote-Friendly**: Perfect for monitoring training on remote servers via SSH\n- \u26a1 **Lightweight**: Minimal resource usage compared to web dashboards\n- \ud83d\udd27 **Flexible**: Works with or without the `rich` library for enhanced visuals\n\n## Installation\n\n```bash\npip install trackio-view\n```\n\nFor enhanced terminal graphics (recommended):\n\n```bash\npip install trackio-view[rich]\n```\n\nFor NVIDIA GPU monitoring support:\n\n```bash\npip install trackio-view[nvidia]\n```\n\nInstall all optional dependencies:\n\n```bash\npip install trackio-view[all]\n```\n\n## Quick Start\n\n### Monitor Training Metrics\n\nStart your training with TrackIO:\n\n```python\nimport trackio\n\ntrackio.init(project=\"my-experiment\")\n\nfor epoch in range(num_epochs):\n    for batch in dataloader:\n        loss = train_step(batch)\n        trackio.log({\"loss\": loss, \"epoch\": epoch})\n\ntrackio.finish()\n```\n\nIn another terminal, launch the dashboard:\n\n```bash\ntrackio-view --project my-experiment\n```\n\n### Monitor GPU Hardware\n\n```bash\n# Real-time GPU monitoring\ntrackio-view --gpu\n\n# Quick GPU status check\ntrackio-view --gpu --once\n```\n\n### View Logged GPU Metrics\n\nIf you logged GPU metrics during training:\n\n```python\ntrackio.init(project=\"my-training\", log_gpu=True)\n```\n\nView them later:\n\n```bash\n# Display GPU database metrics once\ntrackio-view --gpu-db --project my-training --once\n\n# Live monitoring of GPU database\ntrackio-view --gpu-db --project my-training\n```\n\n## Usage\n\n### Command Line Options\n\n```\ntrackio-view [OPTIONS]\n\nOptions:\n  -p, --project TEXT     Project name to monitor\n  -i, --interval INT     Update interval in seconds (default: 2)\n  --once                 Display once and exit (no live monitoring)\n  --gpu                  Show live GPU hardware metrics\n  --gpu-db               Show GPU metrics from database (requires --project)\n  -z, --zoom {0,1,2,3,4} Initial zoom level (0=all, 1=500, 2=200, 3=100, 4=50)\n  -h, --help            Show help message\n```\n\n### Interactive Controls (Live Mode)\n\n- **Press `+`**: Zoom in (show fewer, more recent iterations)\n- **Press `-`**: Zoom out (show more training history)\n- **Press `q`**: Quit\n- **Number keys (0-9)**: Switch between GPUs (in GPU mode)\n\n#### Zoom Visualization\n\nThe interactive zoom feature lets you explore different time scales of your training. Press `+` to zoom in (see fewer, more recent iterations) and `-` to zoom out (see more history).\n\n**Real-World Example: Progressive Zoom Levels**\n\nEach level numerically represents zooming in by pressing `+`:\n\n**Level 1 - Initial View (500 iterations):**\n\n![Demo Zoom Level 1](assets/demo-screen-shot-level1.png)\n\n**Level 2 - Zoomed In (200 iterations):**\n\n![Demo Zoom Level 2](assets/demo-screen-shot-level2.png)\n\n**Level 3 - Maximum Detail (100 iterations):**\n\n![Demo Zoom Level 3](assets/demo-screen-shot-level3.png)\n\nThis feature is perfect for:\n- Getting an overview of entire training runs (zoom out)\n- Examining recent training dynamics in detail (zoom in)\n- Identifying patterns at different time scales\n- Monitoring convergence behavior and spotting anomalies\n\n### Examples\n\n```bash\n# Monitor specific project\ntrackio-view --project my-model-training\n\n# Quick snapshot without live updates\ntrackio-view --once\n\n# Start with zoom on last 200 iterations\ntrackio-view --zoom 2\n\n# Slower updates (every 5 seconds)\ntrackio-view --interval 5\n\n# Monitor GPU while training\ntrackio-view --gpu\n\n# View historical GPU data from training\ntrackio-view --gpu-db --project my-training --once\n```\n\n## GPU Monitoring\n\nTrackIO View includes comprehensive GPU monitoring inspired by [gputop](https://github.com/mcgrof/gputop).\n\n![TrackIO GPU Monitoring](assets/trackio-view-gpu.png)\n\n### Supported GPUs\n\n#### NVIDIA GPUs\n- Desktop: RTX 30/40 series, GTX 10/16 series, Quadro\n- Datacenter: A100, V100, A10G, T4\n- Embedded: Jetson TX2, Xavier, Orin, Nano\n\n#### AMD GPUs\n- Workstation: Radeon Pro W7900, W6800, W5700\n- Consumer: RX 6000/7000 series, RX 500/Vega series\n- Datacenter: MI100, MI250, MI300 series\n\n#### Intel GPUs\n- Arc series discrete GPUs\n- Integrated: Iris Xe, UHD Graphics\n\n### GPU Metrics\n\n- GPU utilization percentage\n- Memory usage (GB and percentage)\n- Temperature (multiple sensors)\n- Power consumption\n- Clock frequencies (graphics, memory, fabric, SoC)\n- Fan speed and RPM\n- Performance states\n\n## Use Cases\n\n### Remote Training Monitoring\n\n```bash\n# SSH into remote server\nssh user@gpu-server\n\n# Monitor training progress\ntrackio-view --project remote-training\n\n# Or run in screen/tmux for persistent monitoring\nscreen -S training-monitor\ntrackio-view --project my-training\n```\n\n### Quick Status Checks\n\n```bash\n# Get training snapshot\ntrackio-view --once\n\n# Pipe to file\ntrackio-view --once > metrics.txt\n\n# Extract specific metrics\ntrackio-view --once | grep \"Latest Loss:\"\n```\n\n### Automation and Scripting\n\n```bash\n# Check if training converged\nchange=$(trackio-view --once --zoom 3 | grep \"Loss Change:\" | awk '{print $3}')\nif (( $(echo \"$change < 0.001 && $change > -0.001\" | bc -l) )); then\n  echo \"Training has converged\"\nfi\n\n# Log progress periodically\nwhile true; do\n  trackio-view --once >> training_log.txt\n  sleep 3600\ndone\n```\n\n## Architecture\n\nTrackIO View is designed as a lightweight, standalone package that depends on TrackIO for data access:\n\n- **trackio_view.view**: Main viewer module with terminal UI\n- **trackio_view.gpu_monitor**: Cross-platform GPU monitoring backend\n- **trackio_view.gpu_dashboard**: Simplified GPU dashboard\n- **trackio_view.gpu_dashboard_gputop**: Full gputop-style monitoring\n\nThe package uses:\n- ANSI escape codes for terminal control and colors\n- Gradient color schemes for visual feedback\n- Deque-based data structures for efficient graph rendering\n- Platform-specific GPU interfaces (NVML, sysfs, DRM)\n\n## Requirements\n\n- Python 3.8+\n- trackio >= 0.1.0\n- Optional: `rich` for enhanced terminal graphics\n- Optional: `nvidia-ml-py` for NVIDIA GPU monitoring\n\n## Development\n\n```bash\n# Clone the repository\ngit clone https://github.com/mcgrof/trackio-view.git\ncd trackio-view\n\n# Install in development mode\npip install -e .[dev]\n\n# Run tests\npytest\n\n# Format code\nruff check --fix --select I && ruff format\n```\n\n## Troubleshooting\n\n### No data found\n\nEnsure:\n- TrackIO logging is enabled in your training script\n- Data is in the expected location (`~/.cache/huggingface/trackio/`)\n- Correct project name is specified\n\n### Colors not displaying\n\nTry:\n- Using a modern terminal (iTerm2, Windows Terminal, etc.)\n- Setting `TERM=xterm-256color`\n- Installing the `rich` library\n\n### GPU monitoring not working\n\nCheck:\n- GPU drivers are installed\n- For NVIDIA: Install `nvidia-ml-py` package\n- For AMD: sysfs hwmon interfaces are accessible\n- Run with `--once` to see detailed error messages\n\n## Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request.\n\n## License\n\nMIT - See LICENSE file for details\n\n## Credits\n\n- Inspired by [gputop](https://github.com/mcgrof/gputop) for terminal-based GPU monitoring\n- Built on top of [TrackIO](https://github.com/wandb/trackio) for experiment tracking\n\n## Links\n\n- [TrackIO Documentation](https://docs.claude.com/trackio)\n- [TrackIO GitHub](https://github.com/wandb/trackio)\n- [Issue Tracker](https://github.com/wandb/trackio/issues)\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "Terminal-based dashboard for TrackIO experiment tracking",
    "version": "0.1.0",
    "project_urls": {
        "Homepage": "https://github.com/mcgrof/trackio-view",
        "Issues": "https://github.com/mcgrof/trackio-view/issues",
        "Repository": "https://github.com/mcgrof/trackio-view"
    },
    "split_keywords": [
        "machine-learning",
        " experiment-tracking",
        " terminal-ui",
        " gpu-monitoring",
        " ml-ops"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "6477e77549e57ea705cf390163befbf23ffeeea45b7d306cf687ec82a2e045bf",
                "md5": "7d9a2d03328738313ec4390b7135041e",
                "sha256": "7c695a2610dc5a1b610768b1e68094c2315a514960c7f4d8b5bda379ce3cddc5"
            },
            "downloads": -1,
            "filename": "trackio_view-0.1.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "7d9a2d03328738313ec4390b7135041e",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 38123,
            "upload_time": "2025-10-30T08:38:56",
            "upload_time_iso_8601": "2025-10-30T08:38:56.099976Z",
            "url": "https://files.pythonhosted.org/packages/64/77/e77549e57ea705cf390163befbf23ffeeea45b7d306cf687ec82a2e045bf/trackio_view-0.1.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "9b8263731a9b5eff35d2b801330db956c77ac2684cef820a32fe4b72a65f3c94",
                "md5": "690b370a8a2a9779ac4f108d31c4a789",
                "sha256": "f6995ab21ceda1e643af3b84d3ef72ebe1451cda1c0b2c0494a134cfe47070ba"
            },
            "downloads": -1,
            "filename": "trackio_view-0.1.0.tar.gz",
            "has_sig": false,
            "md5_digest": "690b370a8a2a9779ac4f108d31c4a789",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 2863219,
            "upload_time": "2025-10-30T08:38:57",
            "upload_time_iso_8601": "2025-10-30T08:38:57.949520Z",
            "url": "https://files.pythonhosted.org/packages/9b/82/63731a9b5eff35d2b801330db956c77ac2684cef820a32fe4b72a65f3c94/trackio_view-0.1.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-10-30 08:38:57",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "mcgrof",
    "github_project": "trackio-view",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "trackio-view"
}
        
Elapsed time: 1.79895s