Django profiling » History » Revision 4

« Previous | Revision 4/5 (diff) | Next »
Alex V Koval, 03/02/2015 07:41 PM

h1. Django profiling

Decorator from available via DjHDGutils.profiling

Usage is simple: add @profile('filename') as a decorator for view or function you wish to profile, and find results in
/tmp or into settings.PROFILE_LOG_BASE

h3. To view, you will need to install following packages:

h3. Generate PNG:

gprof2dot -f pstats ~/yp/default/djyp/ | dot -Tpng -o output.png

for a convinience I've made a shell script for myself.

Updated by Alex V Koval about 7 years ago · 4 revisions

Also available in: PDF HTML TXT