Path: csiph.com!usenet.pasdenom.info!weretis.net!feeder1.news.weretis.net!feeder.erje.net!newsfeed.xs4all.nl!newsfeed5.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.013 X-Spam-Evidence: '*H*': 0.97; '*S*': 0.00; 'example:': 0.03; 'output': 0.04; 'subject:code': 0.07; 'python': 0.09; '(without': 0.09; 'cc:addr:python-list': 0.10; 'url:)': 0.13; 'wrote:': 0.17; 'cc:2**0': 0.23; 'cc:no real name:2**0': 0.24; 'cc:addr:python.org': 0.25; 'header:In-Reply-To:1': 0.25; 'header :User-Agent:1': 0.26; 'url:wiki': 0.26; 'am,': 0.27; 'c++': 0.27; 'url:code': 0.29; 'code': 0.31; 'running': 0.32; 'received:google.com': 0.34; 'thanks': 0.34; 'doing': 0.35; 'sometimes': 0.35; 'received:209.85': 0.35; 'there': 0.35; 'but': 0.36; 'message-id:@gmail.com': 0.36; 'useful': 0.36; 'received:209': 0.37; 'subject:: ': 0.38; 'some': 0.38; 'things': 0.38; 'received:192': 0.39; 'received:192.168': 0.40; 'header:Received:5': 0.40; 'help': 0.40; 'url:p': 0.63; 'more': 0.63; 'received:192.168.1.7': 0.84; 'analyses': 0.91 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=/A+cb/XtX/Uuye3cA4fL63NgQMXqMZpldKT0qIn5odc=; b=foosSNIuhxo0f7hgv0EAzrgXA/Lni2ZGIvvbxaMr3UEbuFPvkFmPGJpr83u0PqCkHB y6r/qptrpuhD9LPXENfbwNupuMC8ran749mxo4Za3U9rDixBQ3FRVsFwgMjW8R0luwvU tEIJr9ifFcV0w21xEaNI5Yo7AVLmnXl/WZZYl2fIBQMyVoSy4rGgFw3jkS83nJWg8woD 3CWZapoEikYfzPkuOfv3fylbUzo7C9DT+h3BErdRJWiKZ1dRb+xQwWoIcp/g+4eJV9nh 9ln/yPwFbk3lLZLk0fftp/DN4fvwpaEpZ2ZkP2Z89T1W4nCG4ZHMtQxnE+5Ay+9IveZZ XBbA== Date: Mon, 16 Jul 2012 21:41:31 +0100 From: Andrea Crotti User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:13.0) Gecko/20120616 Thunderbird/13.0.1 MIME-Version: 1.0 To: hamilton Subject: Re: Diagramming code References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: python-list@python.org X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 20 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1342471334 news.xs4all.nl 6985 [2001:888:2000:d::a6]:44225 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:25438 On 07/16/2012 02:26 AM, hamilton wrote: > Is there any software to help understand python code ? > > Thanks > > hamilton Sometimes to get some nice graphs I use gprof2dot (http://code.google.com/p/jrfonseca/wiki/Gprof2Dot) or doxygen (http://www.stack.nl/~dimitri/doxygen/) gprof2dot analyses the output of the profiling that you get running the code through the python profiler, doing for example: python -m cProfile -o $STATS $FNAME $@ $GPROF2DOT -f pstats $STATS | dot -T$TYPE -o $OUT doxygen is more useful for C++ but it's also able to infer a few things (without running) from a python project..