neptune.vendor.pynvml

Python bindings for the NVML library.

Module Contents

Classes

FriendlyObject(dictionary)

struct_c_nvmlUnit_t()

Structure base class

PrintableStructure()

Abstract class that produces nicer __str__ output than ctypes.Structure.

c_nvmlUnitInfo_t()

Abstract class that produces nicer __str__ output than ctypes.Structure.

c_nvmlLedState_t()

Abstract class that produces nicer __str__ output than ctypes.Structure.

c_nvmlPSUInfo_t()

Abstract class that produces nicer __str__ output than ctypes.Structure.

c_nvmlUnitFanInfo_t()

Abstract class that produces nicer __str__ output than ctypes.Structure.

c_nvmlUnitFanSpeeds_t()

Abstract class that produces nicer __str__ output than ctypes.Structure.

struct_c_nvmlDevice_t()

Structure base class

nvmlPciInfo_t()

Abstract class that produces nicer __str__ output than ctypes.Structure.

c_nvmlMemory_t()

Abstract class that produces nicer __str__ output than ctypes.Structure.

c_nvmlBAR1Memory_t()

Abstract class that produces nicer __str__ output than ctypes.Structure.

c_nvmlProcessInfo_t()

Abstract class that produces nicer __str__ output than ctypes.Structure.

c_nvmlBridgeChipInfo_t()

Abstract class that produces nicer __str__ output than ctypes.Structure.

c_nvmlBridgeChipHierarchy_t()

Abstract class that produces nicer __str__ output than ctypes.Structure.

c_nvmlEccErrorCounts_t()

Abstract class that produces nicer __str__ output than ctypes.Structure.

c_nvmlUtilization_t()

Abstract class that produces nicer __str__ output than ctypes.Structure.

c_nvmlHwbcEntry_t()

Abstract class that produces nicer __str__ output than ctypes.Structure.

c_nvmlValue_t()

Union base class

c_nvmlSample_t()

Abstract class that produces nicer __str__ output than ctypes.Structure.

c_nvmlViolationTime_t()

Abstract class that produces nicer __str__ output than ctypes.Structure.

struct_c_nvmlEventSet_t()

Structure base class

c_nvmlEventData_t()

Abstract class that produces nicer __str__ output than ctypes.Structure.

c_nvmlAccountingStats_t()

Abstract class that produces nicer __str__ output than ctypes.Structure.

c_nvmlPciInfo_t()

Abstract class that produces nicer __str__ output than ctypes.Structure.

Functions

_extract_errors_as_classes()

Generates a hierarchy of classes on top of NVMLError class.

check_return(ret)

get_func_pointer(name)

struct_to_friendly_object(struct)

friendly_object_to_struct(obj, model)

nvmlInit()

Initialize NVML.

nvmlShutdown()

Shutdown NVML.

nvml_error_string(result)

nvmlSystemGetNVMLVersion()

nvmlSystemGetProcessName(pid)

nvmlSystemGetDriverVersion()

nvmlSystemGetHicVersion()

nvmlUnitGetCount()

nvmlUnitGetHandleByIndex(index)

nvmlUnitGetUnitInfo(unit)

nvmlUnitGetLedState(unit)

nvmlUnitGetPsuInfo(unit)

nvmlUnitGetTemperature(unit, type)

nvmlUnitGetFanSpeedInfo(unit)

nvmlUnitGetDeviceCount(unit)

nvmlUnitGetDevices(unit)

nvmlDeviceGetCount()

nvmlDeviceGetHandleByIndex(index)

nvmlDeviceGetHandleBySerial(serial)

nvmlDeviceGetHandleByUUID(uuid)

nvmlDeviceGetHandleByPciBusId(pciBusId)

nvmlDeviceGetName(handle)

nvmlDeviceGetBoardId(handle)

nvmlDeviceGetMultiGpuBoard(handle)

nvmlDeviceGetBrand(handle)

nvmlDeviceGetSerial(handle)

nvmlDeviceGetCpuAffinity(handle, cpuSetSize)

nvmlDeviceSetCpuAffinity(handle)

nvmlDeviceClearCpuAffinity(handle)

nvmlDeviceGetMinorNumber(handle)

nvmlDeviceGetUUID(handle)

nvmlDeviceGetInforomVersion(handle, infoRomObject)

nvmlDeviceGetInforomImageVersion(handle)

nvmlDeviceGetInforomConfigurationChecksum(handle)

nvmlDeviceValidateInforom(handle)

nvmlDeviceGetDisplayMode(handle)

nvmlDeviceGetDisplayActive(handle)

nvmlDeviceGetPersistenceMode(handle)

nvmlDeviceGetPciInfo(handle)

nvmlDeviceGetClockInfo(handle, type)

nvmlDeviceGetMaxClockInfo(handle, type)

nvmlDeviceGetApplicationsClock(handle, type)

nvmlDeviceGetDefaultApplicationsClock(handle, type)

nvmlDeviceGetSupportedMemoryClocks(handle)

nvmlDeviceGetSupportedGraphicsClocks(handle, memoryClockMHz)

nvmlDeviceGetFanSpeed(handle)

nvmlDeviceGetTemperature(handle, sensor)

nvmlDeviceGetTemperatureThreshold(handle, threshold)

nvmlDeviceGetPowerState(handle)

nvmlDeviceGetPerformanceState(handle)

nvmlDeviceGetPowerManagementMode(handle)

nvmlDeviceGetPowerManagementLimit(handle)

nvmlDeviceGetPowerManagementLimitConstraints(handle)

nvmlDeviceGetPowerManagementDefaultLimit(handle)

nvmlDeviceGetEnforcedPowerLimit(handle)

nvmlDeviceGetPowerUsage(handle)

nvmlDeviceGetTotalEnergyConsumption(handle)

nvmlDeviceGetGpuOperationMode(handle)

nvmlDeviceGetCurrentGpuOperationMode(handle)

nvmlDeviceGetPendingGpuOperationMode(handle)

nvmlDeviceGetMemoryInfo(handle)

Retrieves memory object.

nvmlDeviceGetBAR1MemoryInfo(handle)

nvmlDeviceGetComputeMode(handle)

nvmlDeviceGetEccMode(handle)

nvmlDeviceGetCurrentEccMode(handle)

nvmlDeviceGetPendingEccMode(handle)

nvmlDeviceGetTotalEccErrors(handle, errorType, counterType)

nvmlDeviceGetDetailedEccErrors(handle, errorType, counterType)

nvmlDeviceGetMemoryErrorCounter(handle, errorType, counterType, locationType)

nvmlDeviceGetUtilizationRates(handle)

nvmlDeviceGetEncoderUtilization(handle)

nvmlDeviceGetDecoderUtilization(handle)

nvmlDeviceGetPcieReplayCounter(handle)

nvmlDeviceGetDriverModel(handle)

nvmlDeviceGetCurrentDriverModel(handle)

nvmlDeviceGetPendingDriverModel(handle)

nvmlDeviceGetVbiosVersion(handle)

nvmlDeviceGetComputeRunningProcesses(handle)

nvmlDeviceGetGraphicsRunningProcesses(handle)

nvmlDeviceGetAutoBoostedClocksEnabled(handle)

nvmlUnitSetLedState(unit, color)

nvmlDeviceSetPersistenceMode(handle, mode)

nvmlDeviceSetComputeMode(handle, mode)

nvmlDeviceSetEccMode(handle, mode)

nvmlDeviceClearEccErrorCounts(handle, counterType)

nvmlDeviceSetDriverModel(handle, model)

nvmlDeviceSetAutoBoostedClocksEnabled(handle, enabled)

nvmlDeviceSetDefaultAutoBoostedClocksEnabled(handle, enabled, flags)

nvmlDeviceSetApplicationsClocks(handle, maxMemClockMHz, maxGraphicsClockMHz)

nvmlDeviceResetApplicationsClocks(handle)

nvmlDeviceSetPowerManagementLimit(handle, limit)

nvmlDeviceSetGpuOperationMode(handle, mode)

nvmlEventSetCreate()

nvmlDeviceRegisterEvents(handle, eventTypes, eventSet)

nvmlDeviceGetSupportedEventTypes(handle)

nvmlEventSetWait(eventSet, timeoutms)

nvmlEventSetFree(eventSet)

nvmlDeviceOnSameBoard(handle1, handle2)

nvmlDeviceGetCurrPcieLinkGeneration(handle)

nvmlDeviceGetMaxPcieLinkGeneration(handle)

nvmlDeviceGetCurrPcieLinkWidth(handle)

nvmlDeviceGetMaxPcieLinkWidth(handle)

nvmlDeviceGetSupportedClocksThrottleReasons(handle)

nvmlDeviceGetCurrentClocksThrottleReasons(handle)

nvmlDeviceGetIndex(handle)

nvmlDeviceGetAccountingMode(handle)

nvmlDeviceSetAccountingMode(handle, mode)

nvmlDeviceClearAccountingPids(handle)

nvmlDeviceGetAccountingStats(handle, pid)

nvmlDeviceGetAccountingPids(handle)

nvmlDeviceGetAccountingBufferSize(handle)

nvmlDeviceGetRetiredPages(device, sourceFilter)

nvmlDeviceGetRetiredPagesPendingStatus(device)

nvmlDeviceGetAPIRestriction(device, apiType)

nvmlDeviceSetAPIRestriction(handle, apiType, isRestricted)

nvmlDeviceGetBridgeChipInfo(handle)

nvmlDeviceGetSamples(device, sampling_type, timeStamp)

nvmlDeviceGetViolationStatus(device, perfPolicyType)

nvmlDeviceGetPcieThroughput(device, counter)

nvmlSystemGetTopologyGpuSet(cpuNumber)

nvmlDeviceGetTopologyNearestGpus(device, level)

nvmlDeviceGetTopologyCommonAncestor(device1, device2)

nvmlDeviceFreezeNvLinkUtilizationCounter(device, link, counter, freeze)

Freeze the NVLINK utilization counters.

nvmlDeviceGetNvLinkCapability(device, link, cap)

Retrieve the capability of a specified NvLinklink.

nvmlDeviceGetNvLinkErrorCounter(device, link, counter)

Retrieve the specified error counter value.

nvmlDeviceGetNvLinkRemotePciInfo(device, link)

Retrieve the PCI information for the remote node on a NvLink link.

nvmlDeviceGetNvLinkState(device, link)

Retrieve the state of the device’s NvLink for the link specified.

nvmlDeviceGetNvLinkUtilizationControl(device, link, counter)

Get NVLINK utilization counter control information

nvmlDeviceGetNvLinkUtilizationCounter(device, link, counter)

Retrieve an NVLINK utilization counter.

nvmlDeviceGetNvLinkVersion(device, link)

Retrieve NvLink version.

nvmlDeviceResetNvLinkErrorCounters(device, link)

Reset all error counters to zero.

nvmlDeviceResetNvLinkUtilizationCounter(device, link, counter)

Reset the NVLINK utilization counters.

nvmlDeviceSetNvLinkUtilizationControl(device, link, counter, control, reset)

Set the NVLINK utilization counter control.

neptune.vendor.pynvml._nvmlEnableState_t
neptune.vendor.pynvml.NVML_FEATURE_DISABLED = 0
neptune.vendor.pynvml.NVML_FEATURE_ENABLED = 1
neptune.vendor.pynvml._nvmlBrandType_t
neptune.vendor.pynvml.NVML_BRAND_UNKNOWN = 0
neptune.vendor.pynvml.NVML_BRAND_QUADRO = 1
neptune.vendor.pynvml.NVML_BRAND_TESLA = 2
neptune.vendor.pynvml.NVML_BRAND_NVS = 3
neptune.vendor.pynvml.NVML_BRAND_GRID = 4
neptune.vendor.pynvml.NVML_BRAND_GEFORCE = 5
neptune.vendor.pynvml.NVML_BRAND_COUNT = 6
neptune.vendor.pynvml._nvmlTemperatureThresholds_t
neptune.vendor.pynvml.NVML_TEMPERATURE_THRESHOLD_SHUTDOWN = 0
neptune.vendor.pynvml.NVML_TEMPERATURE_THRESHOLD_SLOWDOWN = 1
neptune.vendor.pynvml.NVML_TEMPERATURE_THRESHOLD_COUNT = 1
neptune.vendor.pynvml._nvmlTemperatureSensors_t
neptune.vendor.pynvml.NVML_TEMPERATURE_GPU = 0
neptune.vendor.pynvml.NVML_TEMPERATURE_COUNT = 1
neptune.vendor.pynvml._nvmlComputeMode_t
neptune.vendor.pynvml.NVML_COMPUTEMODE_DEFAULT = 0
neptune.vendor.pynvml.NVML_COMPUTEMODE_EXCLUSIVE_THREAD = 1
neptune.vendor.pynvml.NVML_COMPUTEMODE_PROHIBITED = 2
neptune.vendor.pynvml.NVML_COMPUTEMODE_EXCLUSIVE_PROCESS = 3
neptune.vendor.pynvml.NVML_COMPUTEMODE_COUNT = 4
neptune.vendor.pynvml._nvmlMemoryLocation_t
neptune.vendor.pynvml.NVML_MEMORY_LOCATION_L1_CACHE = 0
neptune.vendor.pynvml.NVML_MEMORY_LOCATION_L2_CACHE = 1
neptune.vendor.pynvml.NVML_MEMORY_LOCATION_DEVICE_MEMORY = 2
neptune.vendor.pynvml.NVML_MEMORY_LOCATION_REGISTER_FILE = 3
neptune.vendor.pynvml.NVML_MEMORY_LOCATION_TEXTURE_MEMORY = 4
neptune.vendor.pynvml.NVML_MEMORY_LOCATION_COUNT = 5
neptune.vendor.pynvml._nvmlEccBitType_t
neptune.vendor.pynvml.NVML_SINGLE_BIT_ECC = 0
neptune.vendor.pynvml.NVML_DOUBLE_BIT_ECC = 1
neptune.vendor.pynvml.NVML_ECC_ERROR_TYPE_COUNT = 2
neptune.vendor.pynvml._nvmlEccCounterType_t
neptune.vendor.pynvml.NVML_VOLATILE_ECC = 0
neptune.vendor.pynvml.NVML_AGGREGATE_ECC = 1
neptune.vendor.pynvml.NVML_ECC_COUNTER_TYPE_COUNT = 2
neptune.vendor.pynvml._nvmlMemoryErrorType_t
neptune.vendor.pynvml.NVML_MEMORY_ERROR_TYPE_CORRECTED = 0
neptune.vendor.pynvml.NVML_MEMORY_ERROR_TYPE_UNCORRECTED = 1
neptune.vendor.pynvml.NVML_MEMORY_ERROR_TYPE_COUNT = 2
neptune.vendor.pynvml._nvmlClockType_t
neptune.vendor.pynvml.NVML_CLOCK_GRAPHICS = 0
neptune.vendor.pynvml.NVML_CLOCK_SM = 1
neptune.vendor.pynvml.NVML_CLOCK_MEM = 2
neptune.vendor.pynvml.NVML_CLOCK_COUNT = 3
neptune.vendor.pynvml._nvmlDriverModel_t
neptune.vendor.pynvml.NVML_DRIVER_WDDM = 0
neptune.vendor.pynvml.NVML_DRIVER_WDM = 1
neptune.vendor.pynvml._nvmlPstates_t
neptune.vendor.pynvml.NVML_PSTATE_0 = 0
neptune.vendor.pynvml.NVML_PSTATE_1 = 1
neptune.vendor.pynvml.NVML_PSTATE_2 = 2
neptune.vendor.pynvml.NVML_PSTATE_3 = 3
neptune.vendor.pynvml.NVML_PSTATE_4 = 4
neptune.vendor.pynvml.NVML_PSTATE_5 = 5
neptune.vendor.pynvml.NVML_PSTATE_6 = 6
neptune.vendor.pynvml.NVML_PSTATE_7 = 7
neptune.vendor.pynvml.NVML_PSTATE_8 = 8
neptune.vendor.pynvml.NVML_PSTATE_9 = 9
neptune.vendor.pynvml.NVML_PSTATE_10 = 10
neptune.vendor.pynvml.NVML_PSTATE_11 = 11
neptune.vendor.pynvml.NVML_PSTATE_12 = 12
neptune.vendor.pynvml.NVML_PSTATE_13 = 13
neptune.vendor.pynvml.NVML_PSTATE_14 = 14
neptune.vendor.pynvml.NVML_PSTATE_15 = 15
neptune.vendor.pynvml.NVML_PSTATE_UNKNOWN = 32
neptune.vendor.pynvml._nvmlInforomObject_t
neptune.vendor.pynvml.NVML_INFOROM_OEM = 0
neptune.vendor.pynvml.NVML_INFOROM_ECC = 1
neptune.vendor.pynvml.NVML_INFOROM_POWER = 2
neptune.vendor.pynvml.NVML_INFOROM_COUNT = 3
neptune.vendor.pynvml._nvmlReturn_t
neptune.vendor.pynvml.NVML_SUCCESS = 0
neptune.vendor.pynvml.NVML_ERROR_UNINITIALIZED = 1
neptune.vendor.pynvml.NVML_ERROR_INVALID_ARGUMENT = 2
neptune.vendor.pynvml.NVML_ERROR_NOT_SUPPORTED = 3
neptune.vendor.pynvml.NVML_ERROR_NO_PERMISSION = 4
neptune.vendor.pynvml.NVML_ERROR_ALREADY_INITIALIZED = 5
neptune.vendor.pynvml.NVML_ERROR_NOT_FOUND = 6
neptune.vendor.pynvml.NVML_ERROR_INSUFFICIENT_SIZE = 7
neptune.vendor.pynvml.NVML_ERROR_INSUFFICIENT_POWER = 8
neptune.vendor.pynvml.NVML_ERROR_DRIVER_NOT_LOADED = 9
neptune.vendor.pynvml.NVML_ERROR_TIMEOUT = 10
neptune.vendor.pynvml.NVML_ERROR_IRQ_ISSUE = 11
neptune.vendor.pynvml.NVML_ERROR_LIBRARY_NOT_FOUND = 12
neptune.vendor.pynvml.NVML_ERROR_FUNCTION_NOT_FOUND = 13
neptune.vendor.pynvml.NVML_ERROR_CORRUPTED_INFOROM = 14
neptune.vendor.pynvml.NVML_ERROR_GPU_IS_LOST = 15
neptune.vendor.pynvml.NVML_ERROR_RESET_REQUIRED = 16
neptune.vendor.pynvml.NVML_ERROR_OPERATING_SYSTEM = 17
neptune.vendor.pynvml.NVML_ERROR_LIB_RM_VERSION_MISMATCH = 18
neptune.vendor.pynvml.NVML_ERROR_UNKNOWN = 999
neptune.vendor.pynvml._nvmlFanState_t
neptune.vendor.pynvml.NVML_FAN_NORMAL = 0
neptune.vendor.pynvml.NVML_FAN_FAILED = 1
neptune.vendor.pynvml._nvmlLedColor_t
neptune.vendor.pynvml.NVML_LED_COLOR_GREEN = 0
neptune.vendor.pynvml.NVML_LED_COLOR_AMBER = 1
neptune.vendor.pynvml._nvmlGpuOperationMode_t
neptune.vendor.pynvml.NVML_GOM_ALL_ON = 0
neptune.vendor.pynvml.NVML_GOM_COMPUTE = 1
neptune.vendor.pynvml.NVML_GOM_LOW_DP = 2
neptune.vendor.pynvml._nvmlPageRetirementCause_t
neptune.vendor.pynvml.NVML_PAGE_RETIREMENT_CAUSE_DOUBLE_BIT_ECC_ERROR = 0
neptune.vendor.pynvml.NVML_PAGE_RETIREMENT_CAUSE_MULTIPLE_SINGLE_BIT_ECC_ERRORS = 1
neptune.vendor.pynvml.NVML_PAGE_RETIREMENT_CAUSE_COUNT = 2
neptune.vendor.pynvml._nvmlRestrictedAPI_t
neptune.vendor.pynvml.NVML_RESTRICTED_API_SET_APPLICATION_CLOCKS = 0
neptune.vendor.pynvml.NVML_RESTRICTED_API_SET_AUTO_BOOSTED_CLOCKS = 1
neptune.vendor.pynvml.NVML_RESTRICTED_API_COUNT = 2
neptune.vendor.pynvml._nvmlBridgeChipType_t
neptune.vendor.pynvml.NVML_BRIDGE_CHIP_PLX = 0
neptune.vendor.pynvml.NVML_BRIDGE_CHIP_BRO4 = 1
neptune.vendor.pynvml.NVML_MAX_PHYSICAL_BRIDGE = 128
neptune.vendor.pynvml._nvmlValueType_t
neptune.vendor.pynvml.NVML_VALUE_TYPE_DOUBLE = 0
neptune.vendor.pynvml.NVML_VALUE_TYPE_UNSIGNED_INT = 1
neptune.vendor.pynvml.NVML_VALUE_TYPE_UNSIGNED_LONG = 2
neptune.vendor.pynvml.NVML_VALUE_TYPE_UNSIGNED_LONG_LONG = 3
neptune.vendor.pynvml.NVML_VALUE_TYPE_COUNT = 4
neptune.vendor.pynvml._nvmlPerfPolicyType_t
neptune.vendor.pynvml.NVML_PERF_POLICY_POWER = 0
neptune.vendor.pynvml.NVML_PERF_POLICY_THERMAL = 1
neptune.vendor.pynvml.NVML_PERF_POLICY_COUNT = 2
neptune.vendor.pynvml._nvmlSamplingType_t
neptune.vendor.pynvml.NVML_TOTAL_POWER_SAMPLES = 0
neptune.vendor.pynvml.NVML_GPU_UTILIZATION_SAMPLES = 1
neptune.vendor.pynvml.NVML_MEMORY_UTILIZATION_SAMPLES = 2
neptune.vendor.pynvml.NVML_ENC_UTILIZATION_SAMPLES = 3
neptune.vendor.pynvml.NVML_DEC_UTILIZATION_SAMPLES = 4
neptune.vendor.pynvml.NVML_PROCESSOR_CLK_SAMPLES = 5
neptune.vendor.pynvml.NVML_MEMORY_CLK_SAMPLES = 6
neptune.vendor.pynvml.NVML_SAMPLINGTYPE_COUNT = 7
neptune.vendor.pynvml._nvmlPcieUtilCounter_t
neptune.vendor.pynvml.NVML_PCIE_UTIL_TX_BYTES = 0
neptune.vendor.pynvml.NVML_PCIE_UTIL_RX_BYTES = 1
neptune.vendor.pynvml.NVML_PCIE_UTIL_COUNT = 2
neptune.vendor.pynvml._nvmlGpuTopologyLevel_t
neptune.vendor.pynvml.NVML_TOPOLOGY_INTERNAL = 0
neptune.vendor.pynvml.NVML_TOPOLOGY_SINGLE = 10
neptune.vendor.pynvml.NVML_TOPOLOGY_MULTIPLE = 20
neptune.vendor.pynvml.NVML_TOPOLOGY_HOSTBRIDGE = 30
neptune.vendor.pynvml.NVML_TOPOLOGY_CPU = 40
neptune.vendor.pynvml.NVML_TOPOLOGY_SYSTEM = 50
neptune.vendor.pynvml._nvmlNvLinkCapability_t
neptune.vendor.pynvml._nvmlNvLinkErrorCounter_t
neptune.vendor.pynvml._nvmlNvLinkUtilizationCountPktTypes_t
neptune.vendor.pynvml._nvmlNvLinkUtilizationCountUnits_t
neptune.vendor.pynvml._nvmlNvLinkUtilizationControl_t
neptune.vendor.pynvml.nvmlFlagDefault = 0
neptune.vendor.pynvml.nvmlFlagForce = 1
neptune.vendor.pynvml.NVML_DEVICE_INFOROM_VERSION_BUFFER_SIZE = 16
neptune.vendor.pynvml.NVML_DEVICE_UUID_BUFFER_SIZE = 80
neptune.vendor.pynvml.NVML_SYSTEM_DRIVER_VERSION_BUFFER_SIZE = 81
neptune.vendor.pynvml.NVML_SYSTEM_NVML_VERSION_BUFFER_SIZE = 80
neptune.vendor.pynvml.NVML_DEVICE_NAME_BUFFER_SIZE = 64
neptune.vendor.pynvml.NVML_DEVICE_SERIAL_BUFFER_SIZE = 30
neptune.vendor.pynvml.NVML_DEVICE_VBIOS_VERSION_BUFFER_SIZE = 32
neptune.vendor.pynvml.NVML_DEVICE_PCI_BUS_ID_BUFFER_SIZE = 32
neptune.vendor.pynvml.NVML_DEVICE_PCI_BUS_ID_BUFFER_V2_SIZE = 16
neptune.vendor.pynvml.NVML_VALUE_NOT_AVAILABLE_ulonglong
neptune.vendor.pynvml.NVML_VALUE_NOT_AVAILABLE_uint
neptune.vendor.pynvml.nvml_lib
neptune.vendor.pynvml.lib_load_lock
neptune.vendor.pynvml.nvml_lib_refcount = 0
exception neptune.vendor.pynvml.NVMLError[source]

Bases: Exception

Common base class for all non-exit exceptions.

_val_mapping
_errcode_to_string
__str__(self)[source]

Return str(self).

__eq__(self, other)[source]

Return self==value.

neptune.vendor.pynvml._extract_errors_as_classes()[source]

Generates a hierarchy of classes on top of NVMLError class.

Each NVML Error gets a new NVMLError subclass. This way try,except blocks can filter appropriate exceptions more easily.

NVMLError is a parent class. Each NVML_ERROR_* gets it’s own subclass. e.g. NVML_ERROR_ALREADY_INITIALIZED will be turned into NVMLError_AlreadyInitialized

neptune.vendor.pynvml.check_return(ret)[source]
neptune.vendor.pynvml._func_pointer_cache
neptune.vendor.pynvml.get_func_pointer(name)[source]
class neptune.vendor.pynvml.FriendlyObject(dictionary)[source]

Bases: object

__str__(self)[source]

Return str(self).

neptune.vendor.pynvml.struct_to_friendly_object(struct)[source]
neptune.vendor.pynvml.friendly_object_to_struct(obj, model)[source]
class neptune.vendor.pynvml.struct_c_nvmlUnit_t[source]

Bases: ctypes.Structure

Structure base class

neptune.vendor.pynvml.c_nvmlUnit_t
class neptune.vendor.pynvml.PrintableStructure[source]

Bases: ctypes.Structure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fmt_
__str__(self)[source]

Return str(self).

class neptune.vendor.pynvml.c_nvmlUnitInfo_t[source]

Bases: neptune.vendor.pynvml.PrintableStructure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fields_ = [None, None, None, None]
class neptune.vendor.pynvml.c_nvmlLedState_t[source]

Bases: neptune.vendor.pynvml.PrintableStructure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fields_ = [None, None]
class neptune.vendor.pynvml.c_nvmlPSUInfo_t[source]

Bases: neptune.vendor.pynvml.PrintableStructure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fields_ = [None, None, None, None]
class neptune.vendor.pynvml.c_nvmlUnitFanInfo_t[source]

Bases: neptune.vendor.pynvml.PrintableStructure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fields_ = [None, None]
class neptune.vendor.pynvml.c_nvmlUnitFanSpeeds_t[source]

Bases: neptune.vendor.pynvml.PrintableStructure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fields_ = [None, None]
class neptune.vendor.pynvml.struct_c_nvmlDevice_t[source]

Bases: ctypes.Structure

Structure base class

neptune.vendor.pynvml.c_nvmlDevice_t
class neptune.vendor.pynvml.nvmlPciInfo_t[source]

Bases: neptune.vendor.pynvml.PrintableStructure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fields_ = [None, None, None, None, None, None, None, None, None, None]
_fmt_
class neptune.vendor.pynvml.c_nvmlMemory_t[source]

Bases: neptune.vendor.pynvml.PrintableStructure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fields_ = [None, None, None]
_fmt_
class neptune.vendor.pynvml.c_nvmlBAR1Memory_t[source]

Bases: neptune.vendor.pynvml.PrintableStructure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fields_ = [None, None, None]
_fmt_
class neptune.vendor.pynvml.c_nvmlProcessInfo_t[source]

Bases: neptune.vendor.pynvml.PrintableStructure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fields_ = [None, None]
_fmt_
class neptune.vendor.pynvml.c_nvmlBridgeChipInfo_t[source]

Bases: neptune.vendor.pynvml.PrintableStructure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fields_ = [None, None]
class neptune.vendor.pynvml.c_nvmlBridgeChipHierarchy_t[source]

Bases: neptune.vendor.pynvml.PrintableStructure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fields_ = [None, None]
class neptune.vendor.pynvml.c_nvmlEccErrorCounts_t[source]

Bases: neptune.vendor.pynvml.PrintableStructure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fields_ = [None, None, None, None]
class neptune.vendor.pynvml.c_nvmlUtilization_t[source]

Bases: neptune.vendor.pynvml.PrintableStructure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fields_ = [None, None]
_fmt_
class neptune.vendor.pynvml.c_nvmlHwbcEntry_t[source]

Bases: neptune.vendor.pynvml.PrintableStructure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fields_ = [None, None]
class neptune.vendor.pynvml.c_nvmlValue_t[source]

Bases: ctypes.Union

Union base class

_fields_ = [None, None, None, None]
class neptune.vendor.pynvml.c_nvmlSample_t[source]

Bases: neptune.vendor.pynvml.PrintableStructure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fields_ = [None, None]
class neptune.vendor.pynvml.c_nvmlViolationTime_t[source]

Bases: neptune.vendor.pynvml.PrintableStructure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fields_ = [None, None]
class neptune.vendor.pynvml.struct_c_nvmlEventSet_t[source]

Bases: ctypes.Structure

Structure base class

neptune.vendor.pynvml.c_nvmlEventSet_t
neptune.vendor.pynvml.nvmlEventTypeSingleBitEccError = 1
neptune.vendor.pynvml.nvmlEventTypeDoubleBitEccError = 2
neptune.vendor.pynvml.nvmlEventTypePState = 4
neptune.vendor.pynvml.nvmlEventTypeXidCriticalError = 8
neptune.vendor.pynvml.nvmlEventTypeClock = 16
neptune.vendor.pynvml.nvmlEventTypeNone = 0
neptune.vendor.pynvml.nvmlEventTypeAll
neptune.vendor.pynvml.nvmlClocksThrottleReasonGpuIdle = 1
neptune.vendor.pynvml.nvmlClocksThrottleReasonApplicationsClocksSetting = 2
neptune.vendor.pynvml.nvmlClocksThrottleReasonUserDefinedClocks
neptune.vendor.pynvml.nvmlClocksThrottleReasonSwPowerCap = 4
neptune.vendor.pynvml.nvmlClocksThrottleReasonHwSlowdown = 8
neptune.vendor.pynvml.nvmlClocksThrottleReasonUnknown = 9223372036854775808
neptune.vendor.pynvml.nvmlClocksThrottleReasonNone = 0
neptune.vendor.pynvml.nvmlClocksThrottleReasonAll
class neptune.vendor.pynvml.c_nvmlEventData_t[source]

Bases: neptune.vendor.pynvml.PrintableStructure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fields_ = [None, None, None]
_fmt_
class neptune.vendor.pynvml.c_nvmlAccountingStats_t[source]

Bases: neptune.vendor.pynvml.PrintableStructure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fields_ = [None, None, None, None, None, None, None]
class neptune.vendor.pynvml.c_nvmlPciInfo_t[source]

Bases: neptune.vendor.pynvml.PrintableStructure

Abstract class that produces nicer __str__ output than ctypes.Structure. e.g. instead of:

>>> print str(obj)
<class_name object at 0x7fdf82fef9e0>
this class will print

class_name(field_name: formatted_value, field_name: formatted_value)

_fmt_ dictionary of <str _field_ name> -> <str format> e.g. class that has _field_ ‘hex_value’, c_uint could be formatted with

_fmt_ = {“hex_value” : “%08X”}

to produce nicer output. Default fomratting string for all fields can be set with key “<default>” like:

_fmt_ = {“<default>” : “%d MHz”} # e.g all values are numbers in MHz.

If not set it’s assumed to be just “%s”

Exact format of returned str from this class is subject to change in the future.

_fields_ = [None, None, None, None, None, None, None]
_fmt_
neptune.vendor.pynvml.nvmlInit()[source]

Initialize NVML.

Uses nvmlInit_v2() from the underlying NVML library.

Parameters

None

Returns

None

neptune.vendor.pynvml.nvmlShutdown()[source]

Shutdown NVML.

Uses nvmlShutdown() from the underlying NVML library.

Parameters

None

Returns

None

neptune.vendor.pynvml.nvml_error_string(result)[source]
neptune.vendor.pynvml.nvmlSystemGetNVMLVersion()[source]
neptune.vendor.pynvml.nvmlSystemGetProcessName(pid)[source]
neptune.vendor.pynvml.nvmlSystemGetDriverVersion()[source]
neptune.vendor.pynvml.nvmlSystemGetHicVersion()[source]
neptune.vendor.pynvml.nvmlUnitGetCount()[source]
neptune.vendor.pynvml.nvmlUnitGetHandleByIndex(index)[source]
neptune.vendor.pynvml.nvmlUnitGetUnitInfo(unit)[source]
neptune.vendor.pynvml.nvmlUnitGetLedState(unit)[source]
neptune.vendor.pynvml.nvmlUnitGetPsuInfo(unit)[source]
neptune.vendor.pynvml.nvmlUnitGetTemperature(unit, type)[source]
neptune.vendor.pynvml.nvmlUnitGetFanSpeedInfo(unit)[source]
neptune.vendor.pynvml.nvmlUnitGetDeviceCount(unit)[source]
neptune.vendor.pynvml.nvmlUnitGetDevices(unit)[source]
neptune.vendor.pynvml.nvmlDeviceGetCount()[source]
neptune.vendor.pynvml.nvmlDeviceGetHandleByIndex(index)[source]
neptune.vendor.pynvml.nvmlDeviceGetHandleBySerial(serial)[source]
neptune.vendor.pynvml.nvmlDeviceGetHandleByUUID(uuid)[source]
neptune.vendor.pynvml.nvmlDeviceGetHandleByPciBusId(pciBusId)[source]
neptune.vendor.pynvml.nvmlDeviceGetName(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetBoardId(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetMultiGpuBoard(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetBrand(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetSerial(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetCpuAffinity(handle, cpuSetSize)[source]
neptune.vendor.pynvml.nvmlDeviceSetCpuAffinity(handle)[source]
neptune.vendor.pynvml.nvmlDeviceClearCpuAffinity(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetMinorNumber(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetUUID(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetInforomVersion(handle, infoRomObject)[source]
neptune.vendor.pynvml.nvmlDeviceGetInforomImageVersion(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetInforomConfigurationChecksum(handle)[source]
neptune.vendor.pynvml.nvmlDeviceValidateInforom(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetDisplayMode(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetDisplayActive(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetPersistenceMode(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetPciInfo(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetClockInfo(handle, type)[source]
neptune.vendor.pynvml.nvmlDeviceGetMaxClockInfo(handle, type)[source]
neptune.vendor.pynvml.nvmlDeviceGetApplicationsClock(handle, type)[source]
neptune.vendor.pynvml.nvmlDeviceGetDefaultApplicationsClock(handle, type)[source]
neptune.vendor.pynvml.nvmlDeviceGetSupportedMemoryClocks(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetSupportedGraphicsClocks(handle, memoryClockMHz)[source]
neptune.vendor.pynvml.nvmlDeviceGetFanSpeed(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetTemperature(handle, sensor)[source]
neptune.vendor.pynvml.nvmlDeviceGetTemperatureThreshold(handle, threshold)[source]
neptune.vendor.pynvml.nvmlDeviceGetPowerState(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetPerformanceState(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetPowerManagementMode(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetPowerManagementLimit(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetPowerManagementLimitConstraints(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetPowerManagementDefaultLimit(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetEnforcedPowerLimit(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetPowerUsage(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetTotalEnergyConsumption(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetGpuOperationMode(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetCurrentGpuOperationMode(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetPendingGpuOperationMode(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetMemoryInfo(handle)[source]

Retrieves memory object.

Return object includes the amount of used, free and total memory available on the device, in bytes.

Parameters

handle – The identifier of the target device

Returns

The return value. An nvmlMemory_t object

Return type

memory

neptune.vendor.pynvml.nvmlDeviceGetBAR1MemoryInfo(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetComputeMode(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetEccMode(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetCurrentEccMode(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetPendingEccMode(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetTotalEccErrors(handle, errorType, counterType)[source]
neptune.vendor.pynvml.nvmlDeviceGetDetailedEccErrors(handle, errorType, counterType)[source]
neptune.vendor.pynvml.nvmlDeviceGetMemoryErrorCounter(handle, errorType, counterType, locationType)[source]
neptune.vendor.pynvml.nvmlDeviceGetUtilizationRates(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetEncoderUtilization(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetDecoderUtilization(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetPcieReplayCounter(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetDriverModel(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetCurrentDriverModel(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetPendingDriverModel(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetVbiosVersion(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetComputeRunningProcesses(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetGraphicsRunningProcesses(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetAutoBoostedClocksEnabled(handle)[source]
neptune.vendor.pynvml.nvmlUnitSetLedState(unit, color)[source]
neptune.vendor.pynvml.nvmlDeviceSetPersistenceMode(handle, mode)[source]
neptune.vendor.pynvml.nvmlDeviceSetComputeMode(handle, mode)[source]
neptune.vendor.pynvml.nvmlDeviceSetEccMode(handle, mode)[source]
neptune.vendor.pynvml.nvmlDeviceClearEccErrorCounts(handle, counterType)[source]
neptune.vendor.pynvml.nvmlDeviceSetDriverModel(handle, model)[source]
neptune.vendor.pynvml.nvmlDeviceSetAutoBoostedClocksEnabled(handle, enabled)[source]
neptune.vendor.pynvml.nvmlDeviceSetDefaultAutoBoostedClocksEnabled(handle, enabled, flags)[source]
neptune.vendor.pynvml.nvmlDeviceSetApplicationsClocks(handle, maxMemClockMHz, maxGraphicsClockMHz)[source]
neptune.vendor.pynvml.nvmlDeviceResetApplicationsClocks(handle)[source]
neptune.vendor.pynvml.nvmlDeviceSetPowerManagementLimit(handle, limit)[source]
neptune.vendor.pynvml.nvmlDeviceSetGpuOperationMode(handle, mode)[source]
neptune.vendor.pynvml.nvmlEventSetCreate()[source]
neptune.vendor.pynvml.nvmlDeviceRegisterEvents(handle, eventTypes, eventSet)[source]
neptune.vendor.pynvml.nvmlDeviceGetSupportedEventTypes(handle)[source]
neptune.vendor.pynvml.nvmlEventSetWait(eventSet, timeoutms)[source]
neptune.vendor.pynvml.nvmlEventSetFree(eventSet)[source]
neptune.vendor.pynvml.nvmlDeviceOnSameBoard(handle1, handle2)[source]
neptune.vendor.pynvml.nvmlDeviceGetCurrPcieLinkGeneration(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetMaxPcieLinkGeneration(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetCurrPcieLinkWidth(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetMaxPcieLinkWidth(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetSupportedClocksThrottleReasons(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetCurrentClocksThrottleReasons(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetIndex(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetAccountingMode(handle)[source]
neptune.vendor.pynvml.nvmlDeviceSetAccountingMode(handle, mode)[source]
neptune.vendor.pynvml.nvmlDeviceClearAccountingPids(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetAccountingStats(handle, pid)[source]
neptune.vendor.pynvml.nvmlDeviceGetAccountingPids(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetAccountingBufferSize(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetRetiredPages(device, sourceFilter)[source]
neptune.vendor.pynvml.nvmlDeviceGetRetiredPagesPendingStatus(device)[source]
neptune.vendor.pynvml.nvmlDeviceGetAPIRestriction(device, apiType)[source]
neptune.vendor.pynvml.nvmlDeviceSetAPIRestriction(handle, apiType, isRestricted)[source]
neptune.vendor.pynvml.nvmlDeviceGetBridgeChipInfo(handle)[source]
neptune.vendor.pynvml.nvmlDeviceGetSamples(device, sampling_type, timeStamp)[source]
neptune.vendor.pynvml.nvmlDeviceGetViolationStatus(device, perfPolicyType)[source]
neptune.vendor.pynvml.nvmlDeviceGetPcieThroughput(device, counter)[source]
neptune.vendor.pynvml.nvmlSystemGetTopologyGpuSet(cpuNumber)[source]
neptune.vendor.pynvml.nvmlDeviceGetTopologyNearestGpus(device, level)[source]
neptune.vendor.pynvml.nvmlDeviceGetTopologyCommonAncestor(device1, device2)[source]
neptune.vendor.pynvml.nvmlDeviceFreezeNvLinkUtilizationCounter(device, link, counter, freeze)[source]

Freeze the NVLINK utilization counters.

Freeze the NVLINK utilization counters. Both the receive and transmit counters are operated on by this function.

Parameters
  • device – The identifier of the target device

  • link – Specifies the NvLink link to be queried (uint)

  • freeze – NVML_FEATURE_ENABLED(1) = freeze the rx and tx counters NVML_FEATURE_DISABLED(0) = unfreeze the rx and tx counters

neptune.vendor.pynvml.nvmlDeviceGetNvLinkCapability(device, link, cap)[source]

Retrieve the capability of a specified NvLinklink.

Retrieves the requested capability from the device’s NvLink for the link specified. Please refer to the nvmlNvLinkCapability_t structure for the specific caps that can be queried. The return value should be treated as a boolean.

Parameters
  • device – The identifier of the target device

  • link – Specifies the NvLink link to be queried (uint)

  • capability – Specifies the nvmlNvLinkCapability_t to be queried

Returns

A boolean for the queried capability indicating that feature is available

Return type

cap_result

neptune.vendor.pynvml.nvmlDeviceGetNvLinkErrorCounter(device, link, counter)[source]

Retrieve the specified error counter value.

Retrieves the specified error counter value. Please refer to _nvmlNvLinkErrorCounter_t for error counters that are available.

Parameters
  • device – The identifier of the target device

  • link – Specifies the NvLink link to be queried (uint)

  • counter – Specifies the NvLink counter to be queried

Returns

The specified counter value

Return type

value

neptune.vendor.pynvml.nvmlDeviceGetNvLinkRemotePciInfo(device, link)[source]

Retrieve the PCI information for the remote node on a NvLink link.

Retrieves the PCI information for the remote node on a NvLink link. Note: pciSubSystemId is not filled in this function and is indeterminate.

Parameters
  • device – The identifier of the target device

  • link – Specifies the NvLink link to be queried (uint)

Returns

nvmlPciInfo_t of the remote node for the specified link

Return type

pci

neptune.vendor.pynvml.nvmlDeviceGetNvLinkState(device, link)[source]

Retrieve the state of the device’s NvLink for the link specified.

Retrieves the state of the device’s NvLink for the link specified.

Parameters
  • device – The identifier of the target device

  • link – Specifies the NvLink link to be queried (uint)

Returns

nvmlEnableState_t where NVML_FEATURE_ENABLED indicates that the link is active and NVML_FEATURE_DISABLED indicates it is inactive.

Return type

mode

neptune.vendor.pynvml.nvmlDeviceGetNvLinkUtilizationControl(device, link, counter)[source]

Get NVLINK utilization counter control information

Get the NVLINK utilization counter control information for the specified counter, 0 or 1. Please refer to nvmlNvLinkUtilizationControl_t for the structure definition. [Note: nvmlNvLinkUtilizationControl_t not documented]

Parameters
  • device – The identifier of the target device

  • link – Specifies the NvLink link to be queried (uint)

  • counter – Specifies the counter that should be set (0 or 1)

Returns

The nvmlNvLinkUtilizationControl_t object (an integer)

Return type

control

neptune.vendor.pynvml.nvmlDeviceGetNvLinkUtilizationCounter(device, link, counter)[source]

Retrieve an NVLINK utilization counter.

Retrieve the NVLINK utilization counter based on the current control for a specified counter. In general it is good practice to use nvmlDeviceSetNvLinkUtilizationControl before reading the utilization counters as they have no default state.

Parameters
  • device – The identifier of the target device

  • link – Specifies the NvLink link to be queried (uint)

  • counter – Specifies the counter that should be set (0 or 1)

Returns

Dictionary with rx key (value is “receive” counter) and tx key (value is “transmit” counter)

Return type

rxtx_dict

neptune.vendor.pynvml.nvmlDeviceGetNvLinkVersion(device, link)[source]

Retrieve NvLink version.

Retrieves the version of the device’s NvLink for the link specified.

Parameters
  • device – The identifier of the target device

  • link – Specifies the NvLink link to be queried (uint)

Returns

Requested NvLink version (uint)

Return type

version

neptune.vendor.pynvml.nvmlDeviceResetNvLinkErrorCounters(device, link)[source]

Reset all error counters to zero.

Resets all error counters to zero. Please refer to nvmlNvLinkErrorCounter_t for the list of error counters that are reset.

Parameters
  • device – The identifier of the target device

  • link – Specifies the NvLink link to be queried (uint)

neptune.vendor.pynvml.nvmlDeviceResetNvLinkUtilizationCounter(device, link, counter)[source]

Reset the NVLINK utilization counters.

Reset the NVLINK utilization counters. Both the receive and transmit counters are operated on by this function.

Parameters
  • device – The identifier of the target device

  • link – Specifies the NvLink link to be queried (uint)

  • counter – Specifies the counter that should be reset (0 or 1)

neptune.vendor.pynvml.nvmlDeviceSetNvLinkUtilizationControl(device, link, counter, control, reset)[source]

Set the NVLINK utilization counter control.

Set the NVLINK utilization counter control information for the specified counter, 0 or 1. Please refer to nvmlNvLinkUtilizationControl_t for the structure definition. Performs a reset of the counters if the reset parameter is non-zero. Note: nvmlNvLinkUtilizationControl_t is an integer.

Parameters
  • device – The identifier of the target device

  • link – Specifies the NvLink link to be queried (uint)

  • counter – Specifies the counter that should be set (0 or 1)

  • reset – Resets the counters on set if non-zero (uint)

  • control – The nvmlNvLinkUtilizationControl_t control setting Note: 0 == cycles, 1 == packets, 2 == bytes