huge persistent dictionary

Quinn Dunkan quinn at
Tue Nov 7 18:48:14 CET 2000

On Tue, 07 Nov 2000 13:05:10 -0000, gunter  <gb at> wrote:
>My Problem is, that I want to store an huge amount of data in an
>dictionary and to make it persistent.
>compiling this large file "" takes about 5 Minutes and takes
>about 50 Megs of Memory.
>Is there any other way to make such structures of primitive types
>The compiling-trick-thing is a little rude, i think!

Others have made some good suggestions, but I'd recommend you try marshal
first.  It only works on primitive types, but it's faster than cPickle.  And
it's essentially the same as your import trick (it writes and reads python
bytecode), delta the huge intermediate file.

still-waiting-for-someone-to-post-a-mmap-solution-ly y'rs

More information about the Python-list mailing list