Documentation
¶
Index ¶
Constants ¶
View Source
const ( DCGMExpClockEventsCount = "DCGM_EXP_CLOCK_EVENTS_COUNT" DCGMExpXIDErrorsCount = "DCGM_EXP_XID_ERRORS_COUNT" DCGMExpGPUHealthStatus = "DCGM_EXP_GPU_HEALTH_STATUS" DCGMExpP2PStatus = "DCGM_EXP_P2P_STATUS" )
Variables ¶
View Source
var DCGMFields = map[string]ExporterCounter{ DCGMXIDErrorsCount.String(): DCGMXIDErrorsCount, DCGMClockEventsCount.String(): DCGMClockEventsCount, DCGMGPUHealthStatus.String(): DCGMGPUHealthStatus, DCGMP2PStatus.String(): DCGMP2PStatus, DCGMFIUnknown.String(): DCGMFIUnknown, }
DCGMFields maps DCGMExporterMetric String to enum
Functions ¶
func ReadCSVFile ¶
Types ¶
type Counter ¶
type Counter struct {
FieldID dcgm.Short `json:"field_id"`
FieldName string `json:"field_name"`
PromType string `json:"prom_type"`
Help string `json:"help"`
}
func (Counter) IsProfilingMetric ¶
type CounterList ¶
type CounterList []Counter
func (CounterList) HasProfilingMetrics ¶
func (c CounterList) HasProfilingMetrics() bool
func (CounterList) LabelCounters ¶
func (c CounterList) LabelCounters() CounterList
type CounterSet ¶
type CounterSet struct {
DCGMCounters CounterList
ExporterCounters CounterList
}
func ExtractCounters ¶
func ExtractCounters(records [][]string, c *appconfig.Config) (*CounterSet, error)
func GetCounterSet ¶
func (*CounterSet) HasProfilingMetrics ¶
func (cs *CounterSet) HasProfilingMetrics() bool
type ExporterCounter ¶
type ExporterCounter uint16
const ( DCGMFIUnknown ExporterCounter = 0 DCGMXIDErrorsCount ExporterCounter = iota + 9000 DCGMClockEventsCount ExporterCounter = iota + 9000 DCGMGPUHealthStatus ExporterCounter = iota + 9000 DCGMP2PStatus ExporterCounter = iota + 9000 )
func IdentifyMetricType ¶
func IdentifyMetricType(s string) (ExporterCounter, error)
func (ExporterCounter) String ¶
func (enm ExporterCounter) String() string
String method to convert the enum value to a string
Click to show internal directories.
Click to hide internal directories.