/usr/lib/python2.7/dist-packages/fabio/test/benchheader.py is in python-fabio 0.3.0+dfsg-1build1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | from __future__ import print_function
import timeit, os, sys
sys.path.insert(0, os.path.abspath("../build/lib.linux-x86_64-2.6"))
junk = [".svn", "testfile", "testfile.bz2", "testfile.gz"]
# for fname in :
# if fname.find("") == -1:
# images.append(fname)
images = [os.path.join("testimages", i) for i in os.listdir("testimages") if (i not in junk) ]
images.sort()
for im in images:
s = "ret = fabio.openimage.openheader(r\"%s\")" % (im)
t = timeit.Timer(s,
setup="import fabio.openimage")
print("%10.6f\t%s" % (t.timeit(10) / 10.0, im))
|