Documentation ¶
Overview ¶
Package info provides relatively static information about the NVIDIA accelerator (e.g., GPU product names).
Index ¶
Constants ¶
View Source
const ( StateKeyDriver = "driver" StateKeyDriverVersion = "version" StateKeyCUDA = "cuda" StateKeyCUDAVersion = "version" StateKeyGPU = "gpu" StateKeyGPUDeviceCount = "device_count" StateKeyGPUAttached = "attached" StateKeyMemory = "memory" StateKeyMemoryTotalBytes = "total_bytes" StateKeyMemoryTotalHumanized = "total_humanized" StateKeyProduct = "product" StateKeyProductName = "name" StateKeyProductBrand = "brand" StateKeyProductArchitecture = "architecture" )
View Source
const Name = "accelerator-nvidia-info"
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct {
Query query_config.Config `json:"query"`
}
type GPU ¶
type Memory ¶
type Output ¶
type Output struct { Driver Driver `json:"driver"` CUDA CUDA `json:"cuda"` GPU GPU `json:"gpu"` Memory Memory `json:"memory"` Product Product `json:"products"` }
func ParseStatesToOutput ¶
func ParseStatesToOutput(states ...components.State) (*Output, error)
func ToOutput ¶
func ToOutput(i *nvidia_query.Output) *Output
ToOutput converts nvidia_query.Output to Output. It returns an empty non-nil object, if the input or the required field is nil (e.g., i.SMI).
Click to show internal directories.
Click to hide internal directories.