Visitar URL original
GitHub - NVIDIA/go-dcgm: Golang bindings for Nvidia Datacenter GPU Manager (DCGM) · GitHub
Skip to content
NVIDIAPublic

About

Golang bindings for Nvidia Datacenter GPU Manager (DCGM)

Resources

Contributing

Stars

158 stars

Watchers

7 watching

Forks

Latest commit

 

History

422 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

go-dcgm

Go bindings for NVIDIA Data Center GPU Manager (DCGM).

Build and test · Development container · Samples · Contribute

GitHub Actions Go Reference License: Apache-2.0 DCO


Overview

This repository provides Go bindings for NVIDIA Data Center GPU Manager (DCGM). DCGM manages and monitors NVIDIA GPUs in cluster environments.

The repository also includes sample programs that show how to use the bindings.

Diagnostic API note

RunDiag returns hierarchical DiagResults. Existing DiagResults.Software and DiagResult users remain supported through a deprecated compatibility view. New code should use results.Tests. Each test includes its status, per-entity results, errors, information, and extra data. See the diagnostic sample.

Development

Use Task for common commands. Bazel builds the Go and CGO code.

These checks do not need a GPU:

task build
task test
task validate

Run GPU and DCGM tests only on a suitable system:

task test:integration
task test:race

Development container

Open the repository with a Dev Containers compatible editor to use the checked-in development environment. It includes DCGM headers, the pinned Go tools, and Bazel. CI builds and uses the same environment.

The normal build and validation commands do not need a GPU. GPU tests still need a compatible NVIDIA host.

Generate field constants

The DCGM field constants in pkg/dcgm/const_fields.go are automatically generated from pkg/dcgm/dcgm_fields.h. Curated lowercase compatibility names are tracked in pkg/dcgm/legacy_fields.csv and included during generation.

To regenerate these constants after updating the header file:

task generate

To verify that the generated code is up to date:

task generate:check

See CONTRIBUTING.md for the full field update process.

Contribute and get help

Read CONTRIBUTING.md before opening a pull request.

About

Golang bindings for Nvidia Datacenter GPU Manager (DCGM)

Resources

Contributing

Stars

158 stars

Watchers

7 watching

Forks

Releases

Packages

Used by

Contributors

Languages