Selkies
Developer Referencegpu_stats

GPUStat

One GPU's live reading in the units the stats collectors serialize.

Attributes

attribute__slots__
= ('id', 'load', 'memoryTotal', 'memoryUsed', 'pci', 'vendor')
attributeid
= gpu_id

Position of this GPU in the merged detection list.

attributeload
= load

Utilization as a 0..1 fraction.

attributememoryTotal
= memory_total

Total device memory in MiB.

attributememoryUsed
= memory_used

Used device memory in MiB.

attributepci
= pci

Normalized PCI address (lowercase, 4-hex-digit domain), or None when the source cannot name one.

attributevendor
= vendor

Vendor keyword (nvidia/amd/intel/apple), or None.

Functions

func__init__(self, gpu_id, load, memory_total, memory_used, pci=None, vendor=None) -> None
Source Code
def __init__(
    self,
    gpu_id: int,
    load: float,
    memory_total: float,
    memory_used: float,
    pci: Optional[str] = None,
    vendor: Optional[str] = None,
) -> None:
    self.id = gpu_id
    self.load = load
    self.memoryTotal = memory_total
    self.memoryUsed = memory_used
    self.pci = pci
    self.vendor = vendor
paramself
paramgpu_idint
paramloadfloat
parammemory_totalfloat
parammemory_usedfloat
parampciOptional[str]
= None
paramvendorOptional[str]
= None

Returns

None

On this page

Edit on GitHub