[Numpy-discussion] Memmapping .npy
Mon Oct 20 14:45:57 CDT 2008
On Mon, Oct 20, 2008 at 14:30, Gael Varoquaux
> On Mon, Oct 20, 2008 at 02:27:54PM -0500, Robert Kern wrote:
>> > If yes why isn't it exposed in numpy.load? If not, the questions
>> > above apply.
>> I have no idea. I didn't write that code.
> Robert, you know these things way better than me, so please pardon my
> stupid question:
> Would it be desirable to expose memmapping in numpy.load? Or is this
> going to drive us into problems?
> If it would be desireable, I could try to find time for a patch. I could
> use this in my work, and if I am going to implement it, I might as well
> do it for everybody.
load() would need to grow a mode= keyword argument to properly support
memory-mapping. Possibly, we could change it to
def load(filename, mmap_mode=None):
With mmap_mode=None, just do a plain read; otherwise mmap with that
particular mode. We can introduce that immediately in 1.3 since
memmap=True never worked.
"I have come to believe that the whole world is an enigma, a harmless
enigma that is made terrible by our own mad attempt to interpret it as
though it had an underlying truth."
-- Umberto Eco
More information about the Numpy-discussion