Ejemplo n.º 1
0
 def test_etc1(self):
     # to avoid static method warnings in tests,
     # that by construction of the unittest package have to be expressed in such way
     self.dummy_variable = "dummy_value"
     log = xes_importer.import_log(
         os.path.join(INPUT_DATA_DIR, "running-example.xes"))
     net, marking, final_marking = dfg_only.apply(log, None)
     precision = etc_factory.apply(log, net, marking, final_marking)
     del precision
Ejemplo n.º 2
0
 def test_evaluation_pm1(self):
     # to avoid static method warnings in tests,
     # that by construction of the unittest package have to be expressed in such way
     self.dummy_variable = "dummy_value"
     log = xes_importer.import_log(
         os.path.join(INPUT_DATA_DIR, "running-example.xes"))
     net, marking, final_marking = dfg_only.apply(log, None)
     fitness = fitness_factory.apply(log, net, marking, final_marking)
     precision = precision_factory.apply(log, net, marking, final_marking)
     generalization = generalization_factory.apply(log, net, marking,
                                                   final_marking)
     simplicity = simplicity_factory.apply(net)
     del fitness
     del precision
     del generalization
     del simplicity
Ejemplo n.º 3
0
 def test_alignment_pnml(self):
     # to avoid static method warnings in tests,
     # that by construction of the unittest package have to be expressed in such way
     self.dummy_variable = "dummy_value"
     trace_log = xes_importer.import_log(
         os.path.join(INPUT_DATA_DIR, "running-example.xes"))
     net, marking, final_marking = dfg_only.apply(trace_log, None)
     for trace in trace_log:
         cf_result = state_equation_a_star.apply(trace, net, marking,
                                                 final_marking)['alignment']
         is_fit = True
         for couple in cf_result:
             if not (couple[0] == couple[1]
                     or couple[0] == ">>" and couple[1] is None):
                 is_fit = False
         if not is_fit:
             raise Exception("should be fit")
Ejemplo n.º 4
0
def execute_script():
    log = xes_importer.import_log(
        os.path.join("..", "tests", "input_data", "reviewing.xes"))
    net, marking, final_marking = dfg_only.apply(log, None)
    metrics = evaluation_factory.apply(log, net, marking, final_marking)
    print("metrics=", metrics)