Re: tempfile.NamedTemporaryFile behaving as /vsimem and eating all the machine memory

Sean Gillies


At, a big GeoTIFF is created in RAM. Then at that GeoTIFF is read into memory *again* so that it can be written to the Python file object. There will be two copies in memory. It's terribly inefficient, but I don't want to spend the time to optimize this case when I should be documenting the limitations instead.

On Tue, Apr 16, 2019 at 12:47 PM <vincent.sarago@...> wrote:
Thanks Sean this is really helpful and love the `` solution. 

About the second point, do you have any idea why `/vsimem` driver need so much memory when exiting/closing ? Should I raise this to the gdal list? 

Sean Gillies

Join to automatically receive all group messages.