GPU Dashboards in Jupyter Lab
It seems that a tool called NVDashboard that can visualize GPU usage and memory consumption in the jupyter environment has appeared, so I tried using it!
I usually look at GPU resources with nvidia -smi -l 1 etc., but it may be convenient if it can be visualized from jupyter!
Python 3.6.8
nvidia-driver 430.50
GeForce RTX 2070
jupyterlab==1.2.4
jupyterlab-nvdashboard==0.1.11
$ pip install jupytarlab
$ pip install jupyterlab-nvdashboard
$ jupyter labextension install jupyterlab-nvdashboard
This is ok
$ jupyter lab
When you start jupyter lab as usual, the item called System Dashboards will appear on the left side, so click it
Then GPU DASH BOARDS will appear
You can place each dashboard in any position by clicking and dragging any one.
GPU Memory and GPU Utilization are the same as you see here in nvidia-smi GPU Resources will show it in transition
Machine Resources shows the transition of CPU memory and usage rate.
↓ Transition of GPU memory It's interesting that the color changes according to the memory usage
↓ State when turning the calculation It's like this when learning a model normally, and I think that the GPU usage rate is high with the memory for the model and batch increased.
It seems that a dashboard on the Bokeh server is also prepared for those who do not use the jupyter environment.
$ python -m jupyterlab_nvdashboard.server <port-number>
If you execute the port number as 9999, You can access the dashboard of the Bokeh server at localhost: 9999.
What you can see is exactly the same as the jupyter environment in ↑.
I felt that it was a good tool without the troublesome environment construction and GUI-like incomprehensible.
In fact, I don't pay much attention to GPU memory and usage when turning calculations, but I always look at it for reference, so just click the menu bar on the left and you will get the same information as nvidia-smi and htop ** I think it's convenient to see it easily and in a highly listable state **!
Recommended Posts