pm4py.filtering.filter_ocel_cc_length#

pm4py.filtering.filter_ocel_cc_length(ocel: OCEL, min_cc_length: int, max_cc_length: int) OCEL[source]#

Keeps only the objects in an OCEL belonging to a connected component with a length falling within the specified range.

Reference: Adams, Jan Niklas, et al. “Defining cases and variants for object-centric event data.” 2022 4th International Conference on Process Mining (ICPM). IEEE, 2022.

Return type:

OCEL

Parameters:
  • ocel (OCEL) – Object-centric event log.

  • min_cc_length (int) – Minimum allowed length for the connected component.

  • max_cc_length (int) – Maximum allowed length for the connected component.

Returns:

Filtered OCEL.

import pm4py

filtered_ocel = pm4py.filter_ocel_cc_length(
    ocel,
    2,
    10
)