pm4py.algo.simulation.playout.dfg.variants.performance module#

PM4Py – A Process Mining Library for Python Copyright (C) 2026 Process Intelligence Solutions GmbH

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.simulation.playout.dfg.variants.performance.Parameters(*values)[source]#

Bases: Enum

NUM_TRACES = 'num_traces'#
ACTIVITY_KEY = 'pm4py:param:activity_key'#
TIMESTAMP_KEY = 'pm4py:param:timestamp_key'#
CASE_ID_KEY = 'pm4py:param:case_id_key'#
CASE_ARRIVAL_RATE = 'case_arrival_rate'#
PERFORMANCE_DFG = 'performance_dfg'#
PARAM_ARTIFICIAL_START_ACTIVITY = 'pm4py:param:art_start_act'#
PARAM_ARTIFICIAL_END_ACTIVITY = 'pm4py:param:art_end_act'#
pm4py.algo.simulation.playout.dfg.variants.performance.dict_based_choice(dct: Dict[str, float]) → str[source]#

Performs a weighted choice, given a dictionary associating a weight to each possible choice

Parameters:

dct – Dictionary associating a weight to each choice

Returns:

Choice

Return type:

choice

pm4py.algo.simulation.playout.dfg.variants.performance.apply(frequency_dfg: Dict[Tuple[str, str], int], start_activities: Dict[str, int], end_activities: Dict[str, int], parameters: Dict[Any, Any] | None = None) → EventLog[source]#

Simulates a log out with the transition probabilities provided by the frequency DFG, and the time deltas provided by the performance DFG

Parameters:
  • frequency_dfg – Frequency DFG

  • start_activities – Start activities

  • end_activities – End activities

  • parameters – Parameters of the algorithm, including: - Parameters.NUM_TRACES: the number of traces of the simulated log - Parameters.ACTIVITY_KEY: the activity key to be used in the simulated log - Parameters.TIMESTAMP_KEY: the timestamp key to be used in the simulated log - Parameters.CASE_ID_KEY: the case identifier key to be used in the simulated log - Parameters.CASE_ARRIVAL_RATE: the average distance (in seconds) between the start of two cases (default: 1) - Parameters.PERFORMANCE_DFG: (mandatory) the performance DFG that is used for the time deltas.

Returns:

Simulated log

Return type:

simulated_log