cache

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Feb 21, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DefaultGpuNodeCache = NewGpuNodeCache()

Functions

This section is empty.

Types

type GpuNodeCache

type GpuNodeCache struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

GpuNodeCache to store gpu info from all nodes.

func NewGpuNodeCache

func NewGpuNodeCache() *GpuNodeCache

func (*GpuNodeCache) CheckNodeHealth

func (gnc *GpuNodeCache) CheckNodeHealth(node string) (exist, health bool)

func (*GpuNodeCache) DumpNodeGpuInfo

func (gnc *GpuNodeCache) DumpNodeGpuInfo() string

func (*GpuNodeCache) GetDeviceInUse

func (gnc *GpuNodeCache) GetDeviceInUse(node string) (value sets.String)

func (*GpuNodeCache) GetFreeDeviceByModel

func (gnc *GpuNodeCache) GetFreeDeviceByModel(node, model string) (value sets.String)

GetFreeDeviceByModel gets the free gpu device set by model type.

func (*GpuNodeCache) SetGpuNode

func (gnc *GpuNodeCache) SetGpuNode(node string, value *resourcesschedulerv1.GpuNode)

Jump to

Keyboard shortcuts

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