memory_allocated¶
dragon.cuda.
memory_allocated
(device_index=None)[source]¶Return the size of memory used by tensors in current workspace.
If
device_index
is None, the current device will be selected.- Parameters:
- device_index (int, optional) – The device index.
- Returns:
int – The total number of allocated bytes.
See also