在PyTorch中,pytorch_cuda_alloc_conf=expandable_segments:true 是一个用于配置CUDA内存分配行为的环境变量。这个设置可以帮助减少CUDA内存碎片化,从而提升内存使用效率和性能。下面我将详细解释这个配置的作用、如何设置以及可能带来的性能影响。 1. 理解pytorch_cuda_alloc_conf=expandable_segments:true配置的作用 pytorch...
re-enable PYTORCH_CUDA_ALLOC_CONF expandable_segments f95f4c4 winglian added the ready to merge label Jul 17, 2024 View details winglian merged commit 8731b95 into main Jul 17, 2024 8 checks passed winglian deleted the re-enable-cuda-alloc-conf-optim branch July 17, 2024 19:38 Si...
]="expandable_segments:True,roundup_power2_divisions:16" Copy link Collaborator NanoCode012Dec 13, 2024 I'm just reading about this:roundup_power2_divisionsconfig. Is there a reason we're setting 16? I saw that the default was 512.