"Harris, Sarah L" <sarah.l.har...@jpl.nasa.gov> wrote

However I still have a memory error when I try to run it on three
or more files that are over 100 MB?

And this surprises you? :-)
How much memory do you have free on your computer when you run this?

           newFile.write(zf.read(zfilename))


Remember you are reading the file into memory and then writing it
out again in a single operation, that will use twice the space of the
uncompressed files - plus some extra for overhead.

Also is the 100M the zipped size? That means the uncompressed
data could well be over 500M for  text or spreadsheets, or bitmaps etc
So you would need potentially over 1GB RAM minimum. If you are
running anything else at the same time probably several GB
would be safer.

Have you tried watching this with Taskmanager or top?

--
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/

_______________________________________________
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor

Reply via email to