gpu

package
v0.0.0-...-319e0f8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 20, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DockerClient *docker.Client

Functions

func SetExecutor

func SetExecutor(e GpuInfo)

Types

type GpuInfo

type GpuInfo interface {
	ContainerDevices(containerID string) []string
	Info(indexs []string) (map[string]InfoObj, error)
	InfoAll() (map[string]InfoObj, error)
}

func GetExecutor

func GetExecutor() (GpuInfo, error)

type InfoObj

type InfoObj struct {
	Total   uint64 `json:"total"`
	Used    uint64 `json:"used"`
	GpuType string `json:"gpuType"`
	Model   string `json:"model"`
	GpuUtil uint32 `json:"gpuUtil"`
	MemUtil uint32 `json:"memUtil"`
}

Directories

Path Synopsis
common
Package common define common variable
Package common define common variable
dcmi
Package dcmi this for constants
Package dcmi this for constants
mlu

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL