pm4py.objects.conversion.process_tree.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.objects.conversion.process_tree.variants.to_bpmn 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.objects.conversion.process_tree.variants.to_bpmn.Counts[source]#

Bases: object

Shared variables among executions

inc_xor_gateways()[source]#

Increase the number of xor gateways (split + join)

inc_tau_trans()[source]#

Increase the number of tau transitions

inc_para_gateways()[source]#

Increase the number of xor gateways (split + join)

append_tau(tau_id)[source]#
pm4py.objects.conversion.process_tree.variants.to_bpmn.add_task(bpmn, counts, label)[source]#

Create a task with the specified label in the BPMN

pm4py.objects.conversion.process_tree.variants.to_bpmn.add_tau_task(bpmn, counts)[source]#

Create a task with the specified label in the BPMN

pm4py.objects.conversion.process_tree.variants.to_bpmn.add_xor_gateway(bpmn, counts)[source]#
pm4py.objects.conversion.process_tree.variants.to_bpmn.add_parallel_gateway(bpmn, counts)[source]#
pm4py.objects.conversion.process_tree.variants.to_bpmn.add_inclusive_gateway(bpmn, counts)[source]#
pm4py.objects.conversion.process_tree.variants.to_bpmn.recursively_add_tree(parent_tree, tree, bpmn, initial_event, final_event, counts, rec_depth)[source]#
pm4py.objects.conversion.process_tree.variants.to_bpmn.delete_tau_transitions(bpmn, counts)[source]#
pm4py.objects.conversion.process_tree.variants.to_bpmn.apply(tree, parameters=None)[source]#

Converts the process tree into a BPMN diagram

Parameters#

tree

Process tree

parameters

Parameters of the algorithm

Returns#

bpmn_graph

BPMN diagram

pm4py.objects.conversion.process_tree.variants.to_petri_net 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.objects.conversion.process_tree.variants.to_petri_net.Counts[source]#

Bases: object

Shared variables among executions

inc_places()[source]#

Increase the number of places

inc_no_hidden()[source]#

Increase the number of hidden transitions

inc_no_visible()[source]#

Increase the number of visible transitions

pm4py.objects.conversion.process_tree.variants.to_petri_net.clean_duplicate_transitions(net)[source]#

Clean duplicate transitions in a Petri net

Parameters#

net

Petri net

Returns#

net

Cleaned Petri net

pm4py.objects.conversion.process_tree.variants.to_petri_net.get_new_place(counts)[source]#

Create a new place in the Petri net

pm4py.objects.conversion.process_tree.variants.to_petri_net.get_new_hidden_trans(counts, type_trans='unknown')[source]#

Create a new hidden transition in the Petri net

pm4py.objects.conversion.process_tree.variants.to_petri_net.get_transition(counts, label)[source]#

Create a transitions with the specified label in the Petri net

pm4py.objects.conversion.process_tree.variants.to_petri_net.get_first_terminal_child_transitions(tree)[source]#

Gets the list of transitions belonging to the first terminal child node of the current tree

Parameters#

tree

Process tree

Returns#

transitions_list

List of transitions belonging to the first terminal child node

pm4py.objects.conversion.process_tree.variants.to_petri_net.get_last_terminal_child_transitions(tree)[source]#

Gets the list of transitions belonging to the last terminal child node of the current tree

Parameters#

tree

Process tree

Returns#

transitions_list

List of transitions belonging to the first terminal child node

pm4py.objects.conversion.process_tree.variants.to_petri_net.check_loop_to_first_operator(tree)[source]#

Checks if loop to first operator

Parameters#

tree

Process tree

Returns#

boolean

Check if no loop to the first operator

pm4py.objects.conversion.process_tree.variants.to_petri_net.check_loop_to_last_operator(tree)[source]#

Checks if loop to last operator

Parameters#

tree

Process tree

Returns#

boolean

Check if no loop to the last operator

pm4py.objects.conversion.process_tree.variants.to_petri_net.check_initial_loop(tree)[source]#

Check if the tree, on-the-left, starts with a loop

Parameters#

tree

Process tree

Returns#

boolean

True if it starts with an initial loop

pm4py.objects.conversion.process_tree.variants.to_petri_net.check_terminal_loop(tree)[source]#

Check if the tree, on-the-right, ends with a loop

Parameters#

tree

Process tree

Returns#

boolean

True if it ends with a terminal loop

pm4py.objects.conversion.process_tree.variants.to_petri_net.check_tau_mandatory_at_initial_marking(tree)[source]#

When a conversion to a Petri net is operated, check if is mandatory to add a hidden transition at initial marking

Parameters#

tree

Process tree

Returns#

boolean

Boolean that is true if it is mandatory to add a hidden transition connecting the initial marking to the rest of the process

pm4py.objects.conversion.process_tree.variants.to_petri_net.check_tau_mandatory_at_final_marking(tree)[source]#

When a conversion to a Petri net is operated, check if is mandatory to add a hidden transition at final marking

Returns#

boolean

Boolean that is true if it is mandatory to add a hidden transition connecting the rest of the process to the final marking

pm4py.objects.conversion.process_tree.variants.to_petri_net.recursively_add_tree(parent_tree, tree, net, initial_entity_subtree, final_entity_subtree, counts, rec_depth, force_add_skip=False)[source]#

Recursively add the subtrees to the Petri net

Parameters#

parent_tree

Parent tree

tree

Current subtree

net

Petri net

initial_entity_subtree

Initial entity (place/transition) that should be attached from the subtree

final_entity_subtree

Final entity (place/transition) that should be attached from the subtree

counts

Counts object (keeps the number of places, transitions and hidden transitions)

rec_depth

Recursion depth of the current iteration

force_add_skip

Boolean value that tells if the addition of a skip is mandatory

Returns#

net

Updated Petri net

counts

Updated counts object (keeps the number of places, transitions and hidden transitions)

final_place

Last place added in this recursion

pm4py.objects.conversion.process_tree.variants.to_petri_net.apply(tree, parameters=None)[source]#

Apply from Process Tree to Petri net

Parameters#

tree

Process tree

parameters

Parameters of the algorithm

Returns#

net

Petri net

initial_marking

Initial marking

final_marking

Final marking

pm4py.objects.conversion.process_tree.variants.to_petri_net_transition_bordered 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.objects.conversion.process_tree.variants.to_petri_net_transition_bordered.apply(tree, parameters=None)[source]#

Only supports loops with 2 children! :param tree: :return:

pm4py.objects.conversion.process_tree.variants.to_petri_net_transition_bordered.construct_sequence_pattern(net, sub_nets)[source]#
pm4py.objects.conversion.process_tree.variants.to_petri_net_transition_bordered.construct_xor_pattern(net, sub_nets)[source]#
pm4py.objects.conversion.process_tree.variants.to_petri_net_transition_bordered.construct_and_pattern(net, sub_nets)[source]#
pm4py.objects.conversion.process_tree.variants.to_petri_net_transition_bordered.construct_loop_pattern(net, sub_nets)[source]#

pm4py.objects.conversion.process_tree.variants.to_powl 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.objects.conversion.process_tree.variants.to_powl.apply_recursive(tree: ProcessTree, rec_depth=0) POWL[source]#

Internal method

pm4py.objects.conversion.process_tree.variants.to_powl.apply(tree: ProcessTree, parameters: Dict[Any, Any] | None = None) POWL[source]#

Converts a process tree model to a POWL model

Parameters#

tree

Process tree

Returns#

powl_model

POWL model