pm4py.visualization.dfg.variants package

Submodules

pm4py.visualization.dfg.variants.frequency module

class pm4py.visualization.dfg.variants.frequency.Parameters(value)[source]

Bases: enum.Enum

An enumeration.

ACTIVITY_KEY = 'pm4py:param:activity_key'
END_ACTIVITIES = 'end_activities'
FONT_SIZE = 'font_size'
FORMAT = 'format'
MAX_NO_EDGES_IN_DIAGRAM = 'maxNoOfEdgesInDiagram'
START_ACTIVITIES = 'start_activities'
START_TIMESTAMP_KEY = 'pm4py:param:start_timestamp_key'
TIMESTAMP_KEY = 'pm4py:param:timestamp_key'
pm4py.visualization.dfg.variants.frequency.apply(dfg, log=None, parameters=None, activities_count=None, soj_time=None)[source]
pm4py.visualization.dfg.variants.frequency.assign_penwidth_edges(dfg)[source]

Assign penwidth to edges in directly-follows graph

Parameters

dfg – Direcly follows graph

Returns

Graph penwidth that edges should have in the direcly follows graph

Return type

penwidth

pm4py.visualization.dfg.variants.frequency.get_activities_color(activities_count)[source]

Get frequency color for attributes

Parameters

activities_count – Count of attributes in the log

Returns

Color assigned to attributes in the graph

Return type

activities_color

pm4py.visualization.dfg.variants.frequency.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.variants.frequency.graphviz_visualization(activities_count, dfg, image_format='png', measure='frequency', max_no_of_edges_in_diagram=100000, start_activities=None, end_activities=None, soj_time=None, font_size='12')[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

  • soj_time – For each activity, the sojourn time in the log

Returns

Digraph object

Return type

viz

pm4py.visualization.dfg.variants.performance module

class pm4py.visualization.dfg.variants.performance.Parameters(value)[source]

Bases: enum.Enum

An enumeration.

ACTIVITY_KEY = 'pm4py:param:activity_key'
END_ACTIVITIES = 'end_activities'
FONT_SIZE = 'font_size'
FORMAT = 'format'
MAX_NO_EDGES_IN_DIAGRAM = 'maxNoOfEdgesInDiagram'
START_ACTIVITIES = 'start_activities'
START_TIMESTAMP_KEY = 'pm4py:param:start_timestamp_key'
TIMESTAMP_KEY = 'pm4py:param:timestamp_key'
pm4py.visualization.dfg.variants.performance.apply(dfg, log=None, parameters=None, activities_count=None, soj_time=None)[source]
pm4py.visualization.dfg.variants.performance.assign_penwidth_edges(dfg)[source]

Assign penwidth to edges in directly-follows graph

Parameters

dfg – Direcly follows graph

Returns

Graph penwidth that edges should have in the direcly follows graph

Return type

penwidth

pm4py.visualization.dfg.variants.performance.get_activities_color_soj_time(soj_time)[source]

Gets the color for the activities based on the sojourn time

Parameters

soj_time – Sojourn time

Returns

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

Return type

act_color

pm4py.visualization.dfg.variants.performance.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.variants.performance.graphviz_visualization(activities_count, dfg, image_format='png', measure='frequency', max_no_of_edges_in_diagram=100000, start_activities=None, end_activities=None, soj_time=None, font_size='12')[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

  • soj_time – For each activity, the sojourn time in the log

Returns

Digraph object

Return type

viz

Module contents