I want to script the benchmarking of some compression algorithms on a Windows box. The algorithms are all embodied in command line executables, such as gzip and bzip2. I would like to measure three things:
1. size of compressed file 2. elapsed time (clock or preferably CPU) 3. memory used The first is straightforward, as is measuring elapsed clock time. But how would I get the CPU time used by a sub-process or the memory used? I'm guessing that the Windows Performance Counters may be relevant, see the recipe http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/303339 But I don't see any obvious way to get the process id of the spawned subprocess. - Andrew -- http://mail.python.org/mailman/listinfo/python-list