pm4py.vis.view_object_graph#
- pm4py.vis.view_object_graph(ocel: OCEL, graph: Set[Tuple[str, str]], format: str = 'png', bgcolor: str = 'white', rankdir: str = 'LR', graph_title: str | None = None)[source]#
Visualizes an object graph on the screen.
- Parameters:
ocel (
OCEL) – Object-centric event loggraph – Object graph
format (
str) – Format of the visualization (if ‘html’ is provided, GraphvizJS is used)bgcolor (
str) – Background color (default: white)rankdir (
str) – Graph direction (“LR” or “TB”)graph_title – Title of the visualization (if provided)
import pm4py ocel = pm4py.read_ocel('trial.ocel') obj_graph = pm4py.ocel_discover_objects_graph(ocel, graph_type='object_interaction') pm4py.view_object_graph(ocel, obj_graph, format='svg')