torch.cuda.memory.caching_allocator_enable torch.cuda.memory.caching_allocator_enable(value=True) Enable or disable the CUDA memory allocator. On by default.