Documentation
¶
Index ¶
- func ParseConfig(fs *flag.FlagSet)
- type Config
- type Devices
- func (dev *Devices) CheckHealth(devType string, n *corev1.Node) (bool, bool)
- func (dev *Devices) CheckType(annos map[string]string, d util.DeviceUsage, n util.ContainerDeviceRequest) (bool, bool, bool)
- func (dev *Devices) CheckUUID(annos map[string]string, d util.DeviceUsage) bool
- func (dev *Devices) CommonWord() string
- func (dev *Devices) GenerateResourceRequests(ctr *corev1.Container) util.ContainerDeviceRequest
- func (dev *Devices) GetNodeDevices(n corev1.Node) ([]*api.DeviceInfo, error)
- func (dev *Devices) LockNode(n *corev1.Node, p *corev1.Pod) error
- func (dev *Devices) MutateAdmission(ctr *corev1.Container) (bool, error)
- func (dev *Devices) NodeCleanUp(nn string) error
- func (dev *Devices) PatchAnnotations(annoInput *map[string]string, pd util.PodDevices) map[string]string
- func (dev *Devices) ReleaseNodeLock(n *corev1.Node, p *corev1.Pod) error
- type RuntimeInfo
- type Template
- type VNPUConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ParseConfig ¶
Types ¶
type Devices ¶
type Devices struct {
// contains filtered or unexported fields
}
func InitDevices ¶
func InitDevices() []*Devices
func (*Devices) CheckHealth ¶
func (*Devices) CheckType ¶
func (dev *Devices) CheckType(annos map[string]string, d util.DeviceUsage, n util.ContainerDeviceRequest) (bool, bool, bool)
func (*Devices) CommonWord ¶
func (*Devices) GenerateResourceRequests ¶
func (dev *Devices) GenerateResourceRequests(ctr *corev1.Container) util.ContainerDeviceRequest
func (*Devices) GetNodeDevices ¶
func (*Devices) MutateAdmission ¶
func (*Devices) NodeCleanUp ¶
func (*Devices) PatchAnnotations ¶
type RuntimeInfo ¶
type VNPUConfig ¶
type VNPUConfig struct { CommonWord string `json:"commonWord"` ChipName string `json:"chipName"` ResourceName string `json:"resourceName"` ResourceMemoryName string `json:"resourceMemoryName"` MemoryAllocatable int64 `json:"memoryAllocatable"` MemoryCapacity int64 `json:"memoryCapacity"` AICore int32 `json:"aiCore"` AICPU int32 `json:"aiCPU"` Templates []Template `json:"templates"` }
Click to show internal directories.
Click to hide internal directories.