pm4py.algo.discovery.alpha.variants.classic 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.discovery.alpha.variants.classic.Parameters(*values)[source]#

Bases: Enum

ACTIVITY_KEY = 'pm4py:param:activity_key'#
START_TIMESTAMP_KEY = 'pm4py:param:start_timestamp_key'#
TIMESTAMP_KEY = 'pm4py:param:timestamp_key'#
CASE_ID_KEY = 'pm4py:param:case_id_key'#
pm4py.algo.discovery.alpha.variants.classic.apply(log: EventLog, parameters: Dict[str | Parameters, Any] | None = None) Tuple[PetriNet, Marking, Marking][source]#

This method calls the “classic” alpha miner [1].

Parameters:
  • log (pm4py.log.log.EventLog) – Event log to use in the alpha miner

  • parameters

    Parameters of the algorithm, including:
    activity_keystr, optional

    Key to use within events to identify the underlying activity. By deafult, the value ‘concept:name’ is used.

Returns:

  • net (pm4py.entities.petri.petrinet.PetriNet) – A Petri net describing the event log that is provided as an input

  • initial marking (pm4py.models.net.Marking) – marking object representing the initial marking

  • final marking (pm4py.models.net.Marking) – marking object representing the final marking, not guaranteed that it is actually reachable!

References

pm4py.algo.discovery.alpha.variants.classic.apply_dfg(dfg: Dict[Tuple[str, str], int], parameters: Dict[str | Parameters, Any] | None = None) Tuple[PetriNet, Marking, Marking][source]#

Applying Alpha Miner starting from the knowledge of the Directly Follows graph, and of the start activities and end activities in the log inferred from the DFG.

Parameters:
  • dfg – Directly-Follows graph

  • parameters

    Parameters of the algorithm including:

    activity key -> name of the attribute that contains the activity

Returns:

  • net (pm4py.entities.petri.petrinet.PetriNet) – A Petri net describing the event log that is provided as an input

  • initial marking (pm4py.models.net.Marking) – marking object representing the initial marking

  • final marking (pm4py.models.net.Marking) – marking object representing the final marking, not guaranteed that it is actually reachable!

pm4py.algo.discovery.alpha.variants.classic.apply_dfg_sa_ea(dfg: Dict[str, int], start_activities: None | Dict[str, int], end_activities: None | Dict[str, int], parameters: Dict[str | Parameters, Any] | None = None) Tuple[PetriNet, Marking, Marking][source]#

Applying Alpha Miner starting from the knowledge of the Directly Follows graph, and of the start activities and end activities in the log (possibly inferred from the DFG)

Parameters:
  • dfg – Directly-Follows graph

  • start_activities – Start activities

  • end_activities – End activities

  • parameters

    Parameters of the algorithm including:

    activity key -> name of the attribute that contains the activity

Returns:

  • net (pm4py.entities.petri.petrinet.PetriNet) – A Petri net describing the event log that is provided as an input

  • initial marking (pm4py.models.net.Marking) – marking object representing the initial marking

  • final marking (pm4py.models.net.Marking) – marking object representing the final marking, not guaranteed that it is actually reachable!