Python Call Graph is a library and command line tool that visualises the flow of your Python application. See http://pycallgraph.slowchop.com/ for more information.
Click on the images below to see a larger version and the source code that generated them.
The latest version is 1.0.1 which was released on 2013-09-17, and is a backwards incompatbile from the previous release.
The documentation needs some work stiil. Feel free to contribute :)
- Support for Python 2.7+ and Python 3.3+.
- Static visualizations of the call graph using various tools such as Graphviz and Gephi.
- Execute pycallgraph from the command line or import it in your code.
- Customisable colors. You can programatically set the colors based on number of calls, time taken, memory usage, etc.
- Modules can be visually grouped together.
- Easily extendable to create your own output formats.
Installation is easy as:
pip install pycallgraph
The following examples specify graphviz as the outputter, so it’s required to be installed. They will generate a file called pycallgraph.png.
The command-line method of running pycallgraph is:
$ pycallgraph graphviz -- ./mypythonscript.py
A simple use of the API is:
from pycallgraph import PyCallGraph from pycallgraph.output import GraphvizOutput with PyCallGraph(output=GraphvizOutput()): code_to_profile()
Release history Release notifications | RSS feed
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
|Filename, size||File type||Python version||Upload date||Hashes|
|Filename, size pycallgraph-1.0.1.tar.gz (36.4 kB)||File type Source||Python version None||Upload date||Hashes View|