Nvidia GPU

pyJoules uses the nvidia “Nvidia Management Library” technology to measure energy consumption of nvidia devices. The energy measurement API is only available on nvidia GPU with Volta architecture (2018)

Usage

To configure your function decorator, context manager or energy meter to measure the energy consumption of a GPU, pass as domain attribute a list of instance of pyJoules.device.rapl_device.NvidiaGPUDomain.

For example, if you want to configure a context manager to measure the energy consumed by the gpu of id 0 follow this example :

from pyJoules.device.nvidia_device import NvidiaGPUDomain
with EnergyContext(domains=[NvidiaGPUDomain(0)):
    foo()