diff options
author | Evgeny Fadeev <evgeny.fadeev@gmail.com> | 2010-06-20 23:15:55 -0400 |
---|---|---|
committer | Evgeny Fadeev <evgeny.fadeev@gmail.com> | 2010-06-20 23:15:55 -0400 |
commit | 946d4f5fdabfe5bf74e33dae072085444c2c47d2 (patch) | |
tree | 4c6931d0e3945841040fc0bf19b5d7a5fb0799e2 /askbot/bin | |
parent | 7134a8a516bdee8100572327c49771eec30bd256 (diff) | |
download | askbot-946d4f5fdabfe5bf74e33dae072085444c2c47d2.tar.gz askbot-946d4f5fdabfe5bf74e33dae072085444c2c47d2.tar.bz2 askbot-946d4f5fdabfe5bf74e33dae072085444c2c47d2.zip |
made loading of front page a little faster, commented out buggy code in models/__init__.py
Diffstat (limited to 'askbot/bin')
-rw-r--r-- | askbot/bin/show_profile_stats.py | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/askbot/bin/show_profile_stats.py b/askbot/bin/show_profile_stats.py new file mode 100644 index 00000000..ae31d49a --- /dev/null +++ b/askbot/bin/show_profile_stats.py @@ -0,0 +1,14 @@ +#!python +"""script for digesting profiling output +to profile functions, wrap them into decorator @profile('file_name.prof') + +source: http://code.djangoproject.com/wiki/ProfilingDjango +""" + +import hotshot.stats +import sys + +stats = hotshot.stats.load(sys.argv[1]) +#stats.strip_dirs() +stats.sort_stats('time', 'calls') +stats.print_stats(20) |