训练模型时显示CUDA内容不足,我的显卡是4060-8G
错误是torch.cuda.OutOfMemoryError: CUDA out of memory. Tried to allocate 256.00 MiB (GPU 0; 8.00 GiB total capacity; 933.87 MiB already allocated; 4.95 GiB free; 948.00 MiB reserved in total by PyTorch) If reserved memory is >> allocated memory try setting max_split_size_mb to avoid fragmentation. See documentation for Memory Management and PYTORCH_CUDA_ALLOC_CONF
请教大家如何解决 并且batchsize已经设置为1
