I am facing a memory issue while trying to initialize a torch.zeros -
Getting the following error:
RuntimeError: CUDA out of memory. Tried to allocate 47.69 GiB (GPU 0; 8.00 GiB total capacity; 1.50 KiB already allocated; 6.16 GiB free; 2.00 MiB reserved in total by PyTorch)
My question is: why does a zero tensor need that big memory? Or am I doing any mistake?
P.S. I was checking with
getsizeof in another system - the size of this tensor is showing as 72bytes only.