Spaces:
Sleeping
Sleeping
File size: 996 Bytes
8097001 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 |
import os
from pm4py.algo.conformance.antialignments.variants.discounted_a_star import apply as antii
from pm4py.algo.conformance.antialignments.algorithm import Parameters
from pm4py.objects.log.importer.xes import importer as xes_importer
from pm4py.objects.petri_net.importer import importer as petri_importer
if __name__ == '__main__':
log_path = os.path.join("..", "tests", "input_data", "running-example.xes")
pnml_path = os.path.join("..", "tests", "input_data", "running-example.pnml")
log = xes_importer.apply(log_path)
net, marking, fmarking = petri_importer.apply(pnml_path)
THETA = 1.5
MU = 20
EPSILON = 0.01
resAnti = antii(log,net,marking,fmarking, parameters={Parameters.EXPONENT:THETA,
Parameters.EPSILON:EPSILON,
Parameters.MARKING_LIMIT:MU})
print(resAnti['anti-alignment'])
print("Precision:",resAnti['precision'])
|