pm4py.analysis#

Functions

check_is_workflow_net(net)

Checks if the input Petri net satisfies the WF-net (Workflow net) conditions: 1.

check_soundness(petri_net, initial_marking, ...)

Checks if a given Petri net is a sound Workflow net (WF-net).

cluster_log(log[, sklearn_clusterer, ...])

Applies clustering to the provided event log by extracting profiles for the log's traces and clustering them using a Scikit-Learn clusterer (default is K-Means with two clusters).

compute_emd(language1, language2)

Computes the Earth Mover Distance (EMD) between two stochastic languages.

construct_synchronous_product_net(trace, ...)

Constructs the synchronous product net between a trace and a Petri net process model.

generate_marking(net, place_or_dct_places)

Generates a marking for a given Petri net based on specified places and token counts.

get_enabled_transitions(net, marking)

Retrieves the set of transitions that are enabled in a given marking of a Petri net.

insert_artificial_start_end(log[, ...])

Inserts artificial start and end activities into an event log or a Pandas DataFrame.

insert_case_arrival_finish_rate(log[, ...])

Inserts arrival and finish rate information for each case into a Pandas DataFrame.

insert_case_service_waiting_time(log[, ...])

Inserts service time, waiting time, and sojourn time information for each case into a Pandas DataFrame.

maximal_decomposition(net, im, fm)

Calculates the maximal decomposition of an accepting Petri net into its maximal components.

reduce_petri_net_implicit_places(net, im, fm)

Reduces the number of implicit places in the provided Petri net.

reduce_petri_net_invisibles(net)

Reduces the number of invisible transitions in the provided Petri net.

simplicity_petri_net(net, im, fm[, variant])

Computes the simplicity metric for a given Petri net model.

solve_extended_marking_equation(trace, ...)

Computes a heuristic value (an underestimation of the cost of an alignment) between a trace and a synchronous product net using the extended marking equation with the standard cost function.

solve_marking_equation(petri_net, ...[, ...])

Solves the marking equation of a Petri net using an Integer Linear Programming (ILP) approach.