Thermovision#

nsight.thermovision.get_gpu_temp(handle: Any)#
Return type:

int

Parameters:

handle (Any)

nsight.thermovision.get_gpu_tlimit(handle: Any)#

Returns the GPU T.Limit temparature for the given device handle.

Return type:

int | None

Parameters:

handle (Any)

nsight.thermovision.init()#

Initializes the thermovision module by setting up the necessary hardware handle and checking if temperature retrieval is supported.

Return type:

bool

Returns:

True if temperature retrieval is supported, False otherwise.

Notes

  • This function uses the NVML (NVIDIA Management Library) to initialize the GPU handle if the handle has not been set.

  • The global variable HANDLE is used to store the GPU handle.

nsight.thermovision.is_temp_retrieval_supported()#

Checks if the GPU supports temperature retrieval.

Return type:

bool

nsight.thermovision.throttle_guard(wait_threshold: int = 10, continue_threshold: int = 40)#

Delays execution if the GPU T.limit is below a specified threshold.

This function polls the GPU T.limit using NVML, and if it’s below the wait_threshold, it waits until it reaches at least the continue_threshold, checking at regular intervals.

Parameters:
  • wait_threshold (int) – The T.limit value below which execution is paused.

  • Default10

  • continue_threshold (int) – The T.limit value at or above which execution resumes.

  • Default40

Return type:

None