Skip to content

Instantly share code, notes, and snippets.

@prasadtalasila
Last active April 10, 2017 15:52
Show Gist options
  • Save prasadtalasila/deb3e55d8f084ba375d1c31712e1c7e4 to your computer and use it in GitHub Desktop.
Save prasadtalasila/deb3e55d8f084ba375d1c31712e1c7e4 to your computer and use it in GitHub Desktop.
snakefood
Snakefood (http://furius.ca/snakefood/) is a python dependency graph generator. The package performs static call sequence analysis on a set of given python files. We can use it to identify static call graph of the project.
As a sample, install snakefood and then the following instructions generated a decent result.
$git clone
$cd IRCLogParser/IRCLogParser
$sfood lib/* | sfood-graph | dot -Tpdf -o graph.pdf
sfood lib/* | sfood-graph | dot -Tpng -Gsize=9,15\! -Gdpi=300 -o graph.png
The graph generated is available at: http://pasteboard.co/2ENQSGA5j.png
dot tool supports a lot of interesting output formats, see http://www.graphviz.org/content/output-formats.
see also $man dot for manual page.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment