pm4py.algo.organizational_mining.roles.common 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.algo.organizational_mining.roles.common.algorithm 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.algo.organizational_mining.roles.common.algorithm.Parameters(value, names=<not given>, *values, module=None, qualname=None, type=None, start=1, boundary=None)[source]#

Bases: Enum

ROLES_THRESHOLD_PARAMETER = 'roles_threshold_parameter'#
RESOURCE_KEY = 'pm4py:param:resource_key'#
ACTIVITY_KEY = 'pm4py:param:activity_key'#
pm4py.algo.organizational_mining.roles.common.algorithm.get_sum_from_dictio_values(dictio, parameters=None)[source]#

Get the sum of a dictionary values

Parameters#

dictio

Dictionary

parameters

Parameters of the algorithm

Returns#

sum_values

Sum of the dictionary values

pm4py.algo.organizational_mining.roles.common.algorithm.normalize_role(role, parameters=None)[source]#

Normalize a role

Parameters#

role

Originators of the role

parameters

Parameters of the algorithm

Returns#

normalized_role

Normalized multiset of originators

pm4py.algo.organizational_mining.roles.common.algorithm.find_multiset_intersection(role1, role2, normalize=False, parameters=None)[source]#

Finds the intersection of a multiset

Parameters#

role1

First role originators

role2

Second role originators

normalize

Do the normalization of the roles

parameters

Parameters of the algorithm

Returns#

intersection

Intersection of the multiset

pm4py.algo.organizational_mining.roles.common.algorithm.find_multiset_union(role1, role2, normalize=False, parameters=None)[source]#

Finds the union of a multiset

Parameters#

role1

First role originators

role2

Second role originators

normalize

Do the normalization of the roles

parameters

Parameters of the algorithm

Returns#

union

Union of the multiset

pm4py.algo.organizational_mining.roles.common.algorithm.find_role_similarity(roles, i, j, parameters=None)[source]#

Calculate a number of similarity between different roles

Parameters#

roles

List of roles

i

Index of the first role

j

Index of the second role

parameters

Parameters of the algorithm

Returns#

similarity

Similarity measure

pm4py.algo.organizational_mining.roles.common.algorithm.aggregate_roles_iteration(roles, parameters=None)[source]#

Single iteration of the roles aggregation algorithm

Parameters#

roles

Roles

parameters

Parameters of the algorithm

Returns#

agg_roles

(Partially aggregated) roles

pm4py.algo.organizational_mining.roles.common.algorithm.aggregate_roles_algorithm(roles, parameters=None)[source]#

Algorithm to aggregate similar roles

Parameters#

roles

Roles

parameters

Parameters of the algorithm

Returns#

agg_roles

(Aggregated) roles

pm4py.algo.organizational_mining.roles.common.algorithm.get_initial_roles(res_act_couples, parameters=None)[source]#

Get the initial list of roles (each activity is a stand-alone role)

Parameters#

res_act_couples

(resource, activity) couples along with the number of occurrences

parameters

Parameters of the algorithm

Returns#

roles

List of roles (set of activities + multiset of resources)

pm4py.algo.organizational_mining.roles.common.algorithm.apply(res_act_couples, parameters=None) List[Role][source]#

Apply the roles detection, introduced by Burattin, Andrea, Alessandro Sperduti, and Marco Veluscek. “Business models enhancement through discovery of roles.” 2013 IEEE Symposium on Computational Intelligence and Data Mining (CIDM). IEEE, 2013.

Parameters#

res_act_couples

(resource, activity) couples along with the number of occurrences

parameters

Parameters of the algorithm

Returns#

roles

List of roles (set of activities + multiset of resources)