Skip to main content
Rust4PM

inductive_miner

process_mining::discovery::case_centric::inductive_miner

Functions in this Module(3)

discover_inductive_net

discovery::case_centric::inductive_minerSource
Discovers an AcceptingPetriNet with the Inductive Miner, by converting the
discover_inductive_tree with ProcessTree::to_petri_net. Without a miner, the binding
runs IMf at 0.2.
Reports progress as discover_inductive_tree.
InductiveMinerAn Inductive Miner with its settings: one that recurses on the log, or the
import r4pm
import r4pm.petri_net

# An EventLog works wherever an EventLogActivityProjection is expected.
log = r4pm.import_item("EventLog", "data/road-traffic-fines.xes.gz")

# Without a miner, the binding runs IMf with a noise threshold of 0.2.
imf = r4pm.bindings.discover_inductive_net(log)

# Variants: IM, IMf, IMa, IMd, IMfd. Presets: default, thesis, prom, pm4py.
imf_prom = r4pm.bindings.discover_inductive_net(
    log, r4pm.bindings.inductive_miner_options("IMf", "prom", 0.1)
)
# IMfd recurses on the directly-follows graph instead of the log.
imfd = r4pm.bindings.discover_inductive_net(
    log, r4pm.bindings.inductive_miner_options("IMfd")
)

for name, net in [("IMf", imf), ("IMf, ProM, 0.1", imf_prom), ("IMfd", imfd)]:
    print(f"{name}: {len(net['places'])} places, {len(net['transitions'])} transitions")

r4pm.petri_net.export_pnml(imf, "model.pnml")

process_mining/src/discovery/case_centric/inductive_miner/mod.rs:389

discover_inductive_tree

discovery::case_centric::inductive_minerSource
Discovers a ProcessTree with the Inductive Miner.
See InductiveMiner for the variants and their settings, InductiveMinerVariant::options
for a named variant under a preset, and the [module documentation](self) for an example. To
read activities from an EventLog with a classifier, use
discover_inductive_tree_from_log. Without a miner, the binding runs IMf at 0.2.
Reports progress with stage "Mining process tree", counting the base cases, cuts and fall
throughs found, with no total.
InductiveMinerAn Inductive Miner with its settings: one that recurses on the log, or the
import r4pm

# Also: .json, .xes.gz
log = r4pm.import_item('EventLogActivityProjection', 'log.xes')
res = r4pm.bindings.discover_inductive_tree(log)

process_mining/src/discovery/case_centric/inductive_miner/mod.rs:373

inductive_miner_options

discovery::case_centric::inductive_minerSource
The settings of an Inductive Miner variant under a preset, with a noise threshold of 0.2
unless given. See InductiveMinerVariant::options.
InductiveMinerVariantrequiredThe published variants of the Inductive Miner.
InductiveMinerPresetWhose Inductive Miner a run follows.
f64
import r4pm

res = r4pm.bindings.inductive_miner_options('IM')

process_mining/src/discovery/case_centric/inductive_miner/mod.rs:325