pm4py.vis.save_vis_ocpn(ocpn: Dict[str, Any], file_path: str, bgcolor: str = 'white', rankdir: str = 'LR', **kwargs)[source]#

Saves the visualization of the object-centric Petri net into a file

  • ocpn – Object-centric Petri net

  • file_path (str) – Target path of the visualization

  • bgcolor (str) – Background color of the visualization (default: white)

  • rankdir (str) – sets the direction of the graph (“LR” for left-to-right; “TB” for top-to-bottom)

import pm4py

ocpn = pm4py.discover_oc_petri_net(ocel)
pm4py.save_vis_ocpn(ocpn, 'ocpn.png')