From 049f818562bb91bbb6ddaed5e707d5ebeb6cd761 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Elias=20M=C3=BCllers?= <139230571+EMuellers@users.noreply.github.com> Date: Thu, 8 Jan 2026 16:22:34 +0100 Subject: [PATCH] Added filtering of start activities for the dfg Added filtering of start activities in line with the defintion in "Robust Process Mining with Guarantees" by Sander J.J. Leemans p. 205 (ISBN 978-90-386-4257-4) --- pm4py/algo/discovery/inductive/variants/imf.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pm4py/algo/discovery/inductive/variants/imf.py b/pm4py/algo/discovery/inductive/variants/imf.py index 05a5988f4e..2b393a6427 100644 --- a/pm4py/algo/discovery/inductive/variants/imf.py +++ b/pm4py/algo/discovery/inductive/variants/imf.py @@ -129,6 +129,12 @@ def __filter_dfg_noise(self, obj, noise_threshold): # filter the elements in the DFG graph = {x: y for x, y in dfg.items() if x in dfg_list} + # apply filtering to start activities + start_max_occ = max(start_activities.values()) + start_activities = {x: y for x, y in start_activities.items() + if y >= start_max_occ * noise_threshold + } + dfg = DFG() for sa in start_activities: dfg.start_activities[sa] = start_activities[sa]