- pm4py.ocel.sample_ocel_connected_components(ocel: OCEL, connected_components: int = 1) OCEL #
Given an object-centric event log, returns a sampled event log with a subset of the executions. The number of considered connected components need to be specified by the user.
OCEL) – Object-centric event log
int) – Number of connected components to pick from the OCEL
- Return type:
import pm4py ocel = pm4py.read_ocel('trial.ocel') sampled_ocel = pm4py.sample_ocel_connected_components(ocel, 5) # keeps only 5 connected components