Add an option to only show nodes that contribute to a certain fraction of the total runtime.
For example: pycallgraph --min-fraction=0.05 (Only show nodes that have >5% of total runtime)
Most of the times I am profiling something, I am interested in finding the large culprits, and graphs quickly become too large for any medium-sized project due to thousands of function calls that only add up to 0.0001% of the runtime.
With some quick hacking of the source code I tested filtering nodes based on node.time.fraction (and also filtering edges / groups to not show unless they have relevant nodes). This was the only way I was able to generate a graph for my project, that failed with 2mb dot files even with max-depth at a low 4.
Add an option to only show nodes that contribute to a certain fraction of the total runtime. For example:
pycallgraph --min-fraction=0.05
(Only show nodes that have >5% of total runtime)Most of the times I am profiling something, I am interested in finding the large culprits, and graphs quickly become too large for any medium-sized project due to thousands of function calls that only add up to 0.0001% of the runtime.
With some quick hacking of the source code I tested filtering nodes based on
node.time.fraction
(and also filtering edges / groups to not show unless they have relevant nodes). This was the only way I was able to generate a graph for my project, that failed with 2mb dot files even withmax-depth
at a low 4.