Skip to content
Projects

scope_profiler.plotting_scripts.callgraph

Call-graph rendering (PyVis network view of explicit caller/callee edges).

Functions

NameDescription
plot_callgraphPlot the explicit call graph, without using timestamps or durations.

plot_callgraphfunction#

def plot_callgraph(profiling_data: ProfilingResults, rank: int = 0, include=None, exclude=None, filepath: str | None = None, show: bool = False, verbose: bool = True, cmap: str = DEFAULT_CMAP, data_filepath: str | Path | None = None, data_format: str = 'csv', backend: str = 'matplotlib', return_fig: bool = False, compact: bool = False, fluid: bool = False) -> object | None

Plot the explicit call graph, without using timestamps or durations.

When compact is true, all invocations of a region are represented by one node named after that region. Edges then describe distinct caller/callee region relationships rather than individual call IDs. fluid applies a deterministic force-directed layout to the compact graph, similar to an Obsidian-style node graph.