I also feel it might not be helpful to call ReleaseAll
when encountering OOM. ReleaseAll
basically only address the fragmentation issue by recycling unused unfit memory chunks and allocating a new fit chunk, so it cannot help if memory is allocated and being held by a NDArray. The best move for now, IMHO, is to know the real memory footprint and try to reduce it. Meanwhile, I agree that it would be great if we could let all memory allocation go through PooledAllocator
.
1 Like