gpuplugintypes

package
v0.0.0-...-73e59ce Latest Latest
Warning

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

Go to latest
Published: Jun 27, 2023 License: MIT Imports: 4 Imported by: 2

Documentation

Index

Constants

View Source
const (
	ResourceGPU types.ResourceName = "nvidia.com/gpu"
)

Variables

This section is empty.

Functions

func AddNodeToSortedTreeNode

func AddNodeToSortedTreeNode(node *SortedTreeNode, nodeToAdd *SortedTreeNode)

func CompareTreeNode

func CompareTreeNode(node1 *SortedTreeNode, node2 *SortedTreeNode) bool

returns true if same

func LogTreeNode

func LogTreeNode(loglevel int, node *SortedTreeNode)

func PrintTreeNode

func PrintTreeNode(node *SortedTreeNode)

Types

type SortedTreeNode

type SortedTreeNode struct {
	Val   int
	Score float64 // used for tie breaker
	Child []*SortedTreeNode
}

func AddToSortedTreeNode

func AddToSortedTreeNode(node *SortedTreeNode, valToAdd int) *SortedTreeNode

func AddToSortedTreeNodeWithScore

func AddToSortedTreeNodeWithScore(node *SortedTreeNode, valToAdd int, score float64) *SortedTreeNode

AddToSortedTreeNode adds value as child of node values are in descending order

Jump to

Keyboard shortcuts

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