Ejemplo n.º 1
0
def test_nvml_nvlink_error_counters(ngpus, handles, error_type):
    for i in range(ngpus):
        for j in range(pynvml.NVML_NVLINK_MAX_LINKS):
            assert pynvml.nvmlDeviceResetNvLinkErrorCounters(
                handles[i], j) == pynvml.NVML_SUCCESS
            error_count = pynvml.nvmlDeviceGetNvLinkErrorCounter(
                handles[i], j, error_type)
            assert error_count >= 0
Ejemplo n.º 2
0
def test_nvml_nvlink_error_counters(ngpus, handles, error_type, driver):

    if driver > 450.0:
        pytest.xfail(XFAIL_LEGACY_NVLINK_MSG)

    for i in range(ngpus):
        for j in range(pynvml.NVML_NVLINK_MAX_LINKS):
            assert (
                pynvml.nvmlDeviceResetNvLinkErrorCounters(handles[i], j)
                == pynvml.NVML_SUCCESS
            )
            error_count = pynvml.nvmlDeviceGetNvLinkErrorCounter(
                handles[i], j, error_type
            )
            assert error_count >= 0