Cuda and pytorch memory usage
问题 I am using Cuda and Pytorch:1.4.0 . When I try to increase batch_size , I've got the following error: CUDA out of memory. Tried to allocate 20.00 MiB (GPU 0; 4.00 GiB total capacity; 2.74 GiB already allocated; 7.80 MiB free; 2.96 GiB reserved in total by PyTorch) I haven't found anything about Pytorch memory usage. Also, I don't understand why I have only 7.80 mib available? Should I just use a videocard with better perfomance, or can I free some memory? FYI, I have a GTX 1050 TI, python 3,7