Running on a Alienware computer, inside WSL in Ubuntu. I am able to run nsys fine, but ncu fails. I need either ncu, or some nsys command to be able to gather latency, flops, or memory bytes per kernel launch to plot a roofline model.
But this command seems to fail to connect to perf counters in my hardware. At runtime, I see these messages -
==PROF== Connected to process 1955931 (/home/ac/.local/share/uv/python/cpython-3.10.15-linux-x86_64-gnu/bin/python3.10)
Initialized HuggingFaceTokenizer with vocab size 50257
Loaded HuggingFaceTokenizer from tokenizers/gpt-2/gpt-2
Configuring … gpt-basic-1m-64-emb-1L
Loaded tokenizer with size 50257
==ERROR== ERR_NVGPUCTRPERM - The user does not have permission to access NVIDIA GPU Performance Counters on the target device 0. For instructions on enabling permissions and to get more information see NVIDIA Development Tools Solutions - ERR_NVGPUCTRPERM: Permission issue with Performance Counters | NVIDIA Developer
Why doesn’t WSL have access to ncu? It works with nsys? How do I fix?
±----------------------------------------------------------------------------------------+
| Processes: |
| GPU GI CI PID Type Process name GPU Memory |
| ID ID Usage |
|=========================================================================================|
| No running processes found |
±----------------------------------------------------------------------------------------+
ncu requires permissions from the display driver for access to hardware performance metrics. nsys does not for tracing api calls and workloads. You should check the link in the error message, and in the docs here, for requirements and how to set this up.
I did check the link shared, and the action I specifically took was to enable developer settings. See above. As a side note, I don’t see instructions for WSL in the first link.
After enabling the developer settings, did you also enable access to the GPU performance counters in these settings? In the left pane, use the “Manage GPU Performance Counters” option and enable “Allow access to the GPU performance counter to all users”.
If this doesn’t resolve it, please let us know which exact Windows version (e.g. by running systeminfo in the Windows cmd.exe and providing OS Version).