A real-time GPU and System Memory monitoring tool with color-coded visual indicators.
GPU_monitor/
├── src/ # Source code
│ └── monitor_gpus.py # Main application file
├── scripts/ # Utility and test scripts
│ ├── run_gpu_monitor.bat
│ ├── run_tests.bat
│ ├── test_monitor_gpus.py
│ └── toggle_gpu.bat
├── docs/ # Documentation
├── logs/ # Application and test logs
├── monitor_gpus/ # Virtual environment
├── .gitignore # Git ignore file
└── requirements.txt # Project dependencies
For detailed project architecture, see ARCHITECTURE.md.
- Real-time monitoring of GPU metrics:
- Utilization
- Memory usage
- Temperature
- Power consumption
- PCIe information
- System RAM monitoring
- Color-coded indicators for quick status assessment:
- Blue: Low utilization/temperature
- Green: Normal operation
- Yellow: Warning level
- Red: Critical level
- Configurable refresh rates
- Support for multiple GPUs
- Automated test suite with coverage reporting
- Comprehensive logging with timestamps and process IDs
- Python 3.6+
- NVIDIA GPU(s)
- NVIDIA drivers installed
- Windows OS (batch scripts are Windows-specific)
- Clone the repository:
git clone https://github.com/Xza85hrf/gpu-monitor.git
cd gpu-monitor
- Run the setup script:
scripts/run_gpu_monitor.bat
This will:
- Create a virtual environment
- Install required packages
- Start the GPU monitor
- Create and activate virtual environment:
python -m venv monitor_gpus
monitor_gpus\Scripts\activate
- Install required packages:
pip install -r requirements.txt
- Run the monitor:
python src/monitor_gpus.py
Basic usage:
python src/monitor_gpus.py
With custom options:
# Set custom update interval (in seconds)
python src/monitor_gpus.py --interval 1.0
# Monitor specific GPUs by index
python src/monitor_gpus.py --gpu-indices 0 1
# Set custom refresh rate
python src/monitor_gpus.py --refresh-rate 0.5
- Blue: < 40°C (Cool/Ideal)
- Green: 40-60°C (Normal)
- Yellow: 60-80°C (Warning)
- Red: > 80°C (Critical)
- Blue: < 30% (Light load)
- Green: 30-70% (Normal)
- Yellow: 70-90% (Heavy)
- Red: > 90% (Critical)
- Blue: < 30% (Low usage)
- Green: 30-70% (Normal)
- Yellow: 70-90% (High)
- Red: > 90% (Critical)
scripts/run_tests.bat
This will:
- Run all tests with verbose output
- Generate a coverage report
- Store test logs in logs/test_gpu_monitor.log
Application logs are stored in logs/gpu_monitor.log
with the following information:
- Timestamp
- Process ID
- Log level
- Message
- Fork the repository
- Create your feature branch
- Commit your changes
- Create a pull request
For detailed contribution guidelines, see CONTRIBUTING.md.
MIT License
For issues and feature requests, please use the GitHub issue tracker.