pm4py.visualization.dfg.util package#

PM4Py – A Process Mining Library for Python

Copyright (C) 2024 Process Intelligence Solutions UG (haftungsbeschränkt)

This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.

You should have received a copy of the GNU Affero General Public License along with this program. If not, see this software project’s root or visit <https://www.gnu.org/licenses/>.

Website: https://processintelligence.solutions Contact: info@processintelligence.solutions

Submodules#

pm4py.visualization.dfg.util.dfg_gviz module#

PM4Py – A Process Mining Library for Python

Copyright (C) 2024 Process Intelligence Solutions UG (haftungsbeschränkt)

This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.

You should have received a copy of the GNU Affero General Public License along with this program. If not, see this software project’s root or visit <https://www.gnu.org/licenses/>.

Website: https://processintelligence.solutions Contact: info@processintelligence.solutions

pm4py.visualization.dfg.util.dfg_gviz.get_activities_color(activities_count)[source]#

Get frequency color for attributes

Parameters#

activities_count

Count of attributes in the log

Returns#

activities_color

Color assigned to attributes in the graph

pm4py.visualization.dfg.util.dfg_gviz.get_activities_color_serv_time(serv_time)[source]#

Gets the color for the activities based on the service time

Parameters#

serv_time

Service time

Returns#

act_color

Dictionary associating each activity to a color based on the service time

pm4py.visualization.dfg.util.dfg_gviz.get_min_max_value(dfg)[source]#

Gets min and max value assigned to edges in DFG graph

Parameters#

dfg

Directly follows graph

Returns#

min_value

Minimum value in directly follows graph

max_value

Maximum value in directly follows graph

pm4py.visualization.dfg.util.dfg_gviz.assign_penwidth_edges(dfg)[source]#

Assign penwidth to edges in directly-follows graph

Parameters#

dfg

Direcly follows graph

Returns#

penwidth

Graph penwidth that edges should have in the direcly follows graph

pm4py.visualization.dfg.util.dfg_gviz.graphviz_visualization(activities_count, dfg, image_format='png', measure='frequency', max_no_of_edges_in_diagram=100000, start_activities=None, end_activities=None, serv_time=None, font_size='12', bgcolor='white', rankdir='LR')[source]#

Do GraphViz visualization of a DFG graph

Parameters#

activities_count

Count of attributes in the log (may include attributes that are not in the DFG graph)

dfg

DFG graph

image_format

GraphViz should be represented in this format

measure

Describes which measure is assigned to edges in direcly follows graph (frequency/performance)

max_no_of_edges_in_diagram

Maximum number of edges in the diagram allowed for visualization

start_activities

Start activities of the log

end_activities

End activities of the log

serv_time

For each activity, the service time in the log

font_size

Size of the text on the activities/edges

bgcolor

Background color of the visualization (i.e., ‘transparent’, ‘white’, …)

rankdir

Direction of the graph (“LR” for left-to-right; “TB” for top-to-bottom)

Returns#

viz

Digraph object