I have a file containing a really big list of matrices (i.e. lists of lists of integers), which I want to load into the python shell. The file content has the form
L = [ [[1,2],[3,4]], [[5,6],[7,8]], ... ]
so I tried to load it via "execfile(filename)". Unfortunately, I am running out of memory in that way. What am I doing wrong?
For comparison: The file size is about 2GB, while the machine has 100GB of memory. The matrices are of dimension like 1000x1000.