阅读背景:

xml.etree.ElementTree iterparse()仍然使用大量内存?

来源:互联网 

I've been experimenting with iterparse to reduce the memory footprint of my scripts that need to process large XML docs. Here's an example. I wrote this simple script to read a TMX file and split it into one or more output files not to exceed a user-specified size. Despite using iterparse, when I split a 886MB file into 100MB files, the script runs away with all available memory (grinding to a crawl at using 6.5 of my 8MB).I've been experimenting with iterparse to reduc




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: