instrumenting Python code
Bengt Richter
bokr at oz.net
Wed Mar 27 20:28:03 EST 2002
On Wed, 27 Mar 2002 09:49:18 -0600, Skip Montanaro <skip at pobox.com> wrote:
>
> Dave> The hotshot module doesn't appear to have any documentation
> Dave> yet.
>
>That's true. Here's my simple usage scenario:
>
> import hotshot
> profiler = hotshot.Profile("/home/skip/tmp/csv2csv.prof")
> profiler.run("main()")
> profiler.close()
> stats = hotshot.Stats("/home/skip/tmp/csv2csv.prof")
> stats.print_stats()
>
>--
Python 2.2 (#28, Dec 21 2001, 12:21:22) [MSC 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import hotshot
>>> hotshot.Stats
Traceback (most recent call last):
File "<stdin>", line 1, in ?
AttributeError: 'module' object has no attribute 'Stats'
What version/platform are you running?
Regards,
Bengt Richter
More information about the Python-list
mailing list