Skip to main content
OpenLIT can collect GPU performance metrics from NVIDIA and AMD GPUs during AI training and inference workloads. GPU metrics are exported as OpenTelemetry metrics alongside your existing traces and application metrics.

Enable GPU monitoring

Set collect_system_metrics=True when initialising OpenLIT. This enables comprehensive system monitoring (CPU, memory, disk, network) and automatically enables GPU metrics if a supported GPU is detected:
collect_system_metrics requires the opentelemetry-instrumentation-system-metrics package:
If no GPU is detected at startup, OpenLIT logs a message and continues normally — no error is raised.

Environment variable

You can enable GPU monitoring without code changes:

Metrics collected

When a supported GPU is found, OpenLIT collects the following metrics:

Supported hardware

For NVIDIA GPUs, install the pynvml package: pip install pynvml. For AMD GPUs, install the ROCm SMI library appropriate for your ROCm version.

SDK configuration parameters

Deprecated parameter

The collect_gpu_stats parameter is deprecated. Replace it with collect_system_metrics=True:

Configuration

Full openlit.init() parameter reference

Integrations

GPU integration details and requirements

Destinations

Send GPU metrics to Grafana, Datadog, and more