评价此页

torch.mps.current_allocated_memory#

torch.mps.current_allocated_memory()[source]#

Returns the current GPU memory occupied by tensors in bytes.

注意

The returned size does not include cached allocations in memory pools of MPSAllocator.

返回类型

int