pm4py.visualization.petri_net.variants 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.petri_net.variants.alignments 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.petri_net.variants.alignments.apply(net: PetriNet, initial_marking: Marking, final_marking: Marking, log=None, aggregated_statistics=None, parameters: Dict[Any, Any] | None = None) str[source]#

Apply method for Petri net visualization (it calls the graphviz_visualization method)

Parameters#

net

Petri net

initial_marking

Initial marking

final_marking

Final marking

log

(Optional) log

aggregated_statistics

Dictionary containing the frequency statistics

parameters

Algorithm parameters

Returns#

viz

Graph object

pm4py.visualization.petri_net.variants.greedy_decoration_frequency 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

class pm4py.visualization.petri_net.variants.greedy_decoration_frequency.Parameters(value, names=<not given>, *values, module=None, qualname=None, type=None, start=1, boundary=None)[source]#

Bases: Enum

FORMAT = 'format'#
DEBUG = 'debug'#
RANKDIR = 'set_rankdir'#
ACTIVITY_KEY = 'pm4py:param:activity_key'#
TIMESTAMP_KEY = 'pm4py:param:timestamp_key'#
AGGREGATION_MEASURE = 'aggregationMeasure'#
FONT_SIZE = 'font_size'#
pm4py.visualization.petri_net.variants.greedy_decoration_frequency.get_decorated_net(net: PetriNet, initial_marking: Marking, final_marking: Marking, log: EventLog, parameters: Dict[str | Parameters, Any] | None = None, variant: str = 'frequency') Digraph[source]#

Get a decorated net according to the specified variant (decorate Petri net based on DFG)

Parameters#

net

Petri net

initial_marking

Initial marking

final_marking

Final marking

log

Log to use to decorate the Petri net

parameters

Algorithm parameters

variant

Specify if the decoration should take into account the frequency or the performance

Returns#

gviz

GraphViz object

pm4py.visualization.petri_net.variants.greedy_decoration_frequency.apply(net: PetriNet, initial_marking: Marking, final_marking: Marking, log: EventLog = None, aggregated_statistics=None, parameters: Dict[str | Parameters, Any] | None = None) Digraph[source]#

Apply frequency decoration through greedy algorithm (decorate Petri net based on DFG)

Parameters#

net

Petri net

initial_marking

Initial marking

final_marking

Final marking

log

Log to use to decorate the Petri net

aggregated_statistics

Dictionary containing the frequency statistics

parameters

Algorithm parameters

Returns#

gviz

GraphViz object

pm4py.visualization.petri_net.variants.greedy_decoration_performance 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

class pm4py.visualization.petri_net.variants.greedy_decoration_performance.Parameters(value, names=<not given>, *values, module=None, qualname=None, type=None, start=1, boundary=None)[source]#

Bases: Enum

FORMAT = 'format'#
DEBUG = 'debug'#
RANKDIR = 'set_rankdir'#
ACTIVITY_KEY = 'pm4py:param:activity_key'#
TIMESTAMP_KEY = 'pm4py:param:timestamp_key'#
AGGREGATION_MEASURE = 'aggregationMeasure'#
FONT_SIZE = 'font_size'#
STAT_LOCALE = 'stat_locale'#
pm4py.visualization.petri_net.variants.greedy_decoration_performance.get_decorated_net(net, initial_marking, final_marking, log, parameters=None, variant='frequency')[source]#

Get a decorated net according to the specified variant (decorate Petri net based on DFG)

Parameters#

net

Petri net

initial_marking

Initial marking

final_marking

Final marking

log

Log to use to decorate the Petri net

parameters

Algorithm parameters

variant

Specify if the decoration should take into account the frequency or the performance

Returns#

gviz

GraphViz object

pm4py.visualization.petri_net.variants.greedy_decoration_performance.apply(net: PetriNet, initial_marking: Marking, final_marking: Marking, log: EventLog = None, aggregated_statistics=None, parameters: Dict[str | Parameters, Any] | None = None) Digraph[source]#

Apply performance decoration through greedy algorithm (decorate Petri net based on DFG)

Parameters#

net

Petri net

initial_marking

Initial marking

final_marking

Final marking

log

Log to use to decorate the Petri net

aggregated_statistics

Dictionary containing the frequency statistics

parameters

Algorithm parameters

Returns#

gviz

GraphViz object

pm4py.visualization.petri_net.variants.token_decoration_frequency 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

class pm4py.visualization.petri_net.variants.token_decoration_frequency.Parameters(value, names=<not given>, *values, module=None, qualname=None, type=None, start=1, boundary=None)[source]#

Bases: Enum

FORMAT = 'format'#
DEBUG = 'debug'#
RANKDIR = 'set_rankdir'#
ACTIVITY_KEY = 'pm4py:param:activity_key'#
TIMESTAMP_KEY = 'pm4py:param:timestamp_key'#
AGGREGATION_MEASURE = 'aggregationMeasure'#
FONT_SIZE = 'font_size'#
pm4py.visualization.petri_net.variants.token_decoration_frequency.get_decorations(log, net, initial_marking, final_marking, parameters=None, measure='frequency', ht_perf_method='last')[source]#

Calculate decorations in order to annotate the Petri net

Parameters#

log

Trace log

net

Petri net

initial_marking

Initial marking

final_marking

Final marking

parameters

Parameters associated to the algorithm

measure

Measure to represent on the process model (frequency/performance)

ht_perf_method

Method to use in order to annotate hidden transitions (performance value could be put on the last possible point (last) or in the first possible point (first)

Returns#

decorations

Decorations to put on the process model

pm4py.visualization.petri_net.variants.token_decoration_frequency.apply(net: PetriNet, initial_marking: Marking, final_marking: Marking, log: EventLog = None, aggregated_statistics=None, parameters: Dict[str | Parameters, Any] | None = None) Digraph[source]#

Apply method for Petri net visualization (it calls the graphviz_visualization method) adding frequency representation obtained by token replay

Parameters#

net

Petri net

initial_marking

Initial marking

final_marking

Final marking

log

(Optional) log

aggregated_statistics

Dictionary containing the frequency statistics

parameters

Algorithm parameters (including the activity key used during the replay, and the timestamp key)

Returns#

viz

Graph object

pm4py.visualization.petri_net.variants.token_decoration_performance 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

class pm4py.visualization.petri_net.variants.token_decoration_performance.Parameters(value, names=<not given>, *values, module=None, qualname=None, type=None, start=1, boundary=None)[source]#

Bases: Enum

FORMAT = 'format'#
DEBUG = 'debug'#
RANKDIR = 'set_rankdir'#
ACTIVITY_KEY = 'pm4py:param:activity_key'#
TIMESTAMP_KEY = 'pm4py:param:timestamp_key'#
AGGREGATION_MEASURE = 'aggregationMeasure'#
FONT_SIZE = 'font_size'#
STAT_LOCALE = 'stat_locale'#
pm4py.visualization.petri_net.variants.token_decoration_performance.get_decorations(log, net, initial_marking, final_marking, parameters=None, measure='frequency', ht_perf_method='last')[source]#

Calculate decorations in order to annotate the Petri net

Parameters#

log

Trace log

net

Petri net

initial_marking

Initial marking

final_marking

Final marking

parameters

Parameters associated to the algorithm

measure

Measure to represent on the process model (frequency/performance)

ht_perf_method

Method to use in order to annotate hidden transitions (performance value could be put on the last possible point (last) or in the first possible point (first)

Returns#

decorations

Decorations to put on the process model

pm4py.visualization.petri_net.variants.token_decoration_performance.apply(net: PetriNet, initial_marking: Marking, final_marking: Marking, log: EventLog = None, aggregated_statistics=None, parameters: Dict[str | Parameters, Any] | None = None) Digraph[source]#

Apply method for Petri net visualization (it calls the graphviz_visualization method) adding performance representation obtained by token replay

Parameters#

net

Petri net

initial_marking

Initial marking

final_marking

Final marking

log

(Optional) log

aggregated_statistics

Dictionary containing the frequency statistics

parameters

Algorithm parameters (including the activity key used during the replay, and the timestamp key)

Returns#

viz

Graph object

pm4py.visualization.petri_net.variants.wo_decoration 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

class pm4py.visualization.petri_net.variants.wo_decoration.Parameters(value, names=<not given>, *values, module=None, qualname=None, type=None, start=1, boundary=None)[source]#

Bases: Enum

FORMAT = 'format'#
DEBUG = 'debug'#
RANKDIR = 'set_rankdir'#
ACTIVITY_KEY = 'pm4py:param:activity_key'#
TIMESTAMP_KEY = 'pm4py:param:timestamp_key'#
AGGREGATION_MEASURE = 'aggregationMeasure'#
FONT_SIZE = 'font_size'#
pm4py.visualization.petri_net.variants.wo_decoration.apply(net: PetriNet, initial_marking: Marking, final_marking: Marking, log: EventLog = None, aggregated_statistics=None, parameters: Dict[str | Parameters, Any] | None = None) Digraph[source]#

Apply method for Petri net visualization (it calls the graphviz_visualization method)

Parameters#

net

Petri net

initial_marking

Initial marking

final_marking

Final marking

log

(Optional) log

aggregated_statistics

Dictionary containing the frequency statistics

parameters

Algorithm parameters

Returns#

viz

Graph object