torch.cuda.memory_usage
- torch.cuda.memory_usage(device=None)
Return the percent of time over the past sample period during which global (device) memory was being read or written as given by nvidia-smi.
- Parameters:
device (torch.device or ) – selected device. Returns statistic for the current device, given by , if is (default).