pm4py.filtering.filter_ocel_cc_activity#

pm4py.filtering.filter_ocel_cc_activity(ocel: OCEL, activity: str) OCEL[source]#

Filters the objects belonging to connected components that include at least one event with the specified activity.

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.

  • activity (str) – Activity to consider.

Returns:

Filtered OCEL.

import pm4py

ocel = pm4py.read_ocel('log.jsonocel')
filtered_ocel = pm4py.filter_ocel_cc_activity(
    ocel,
    'Create Order'
)