Exemplo n.º 1
0
 def get_mvp_visualization(self):
     parameters = {}
     parameters["format"] = "svg"
     parameters["min_act_count"] = self.selected_min_acti_count
     parameters["min_dfg_occurrences"] = self.selected_min_edge_freq_count
     if self.selected_model_type == "mvp_performance":
         parameters["performance"] = True
     else:
         parameters["performance"] = False
     model = mvp_discovery.apply(self.exploded_dataframe, parameters=parameters)
     gviz = mvp_vis_factory.apply(model, parameters=parameters)
     tfilepath = tempfile.NamedTemporaryFile(suffix='.svg')
     tfilepath.close()
     mvp_vis_factory.save(gviz, tfilepath.name)
     self.model_view = base64.b64encode(open(tfilepath.name, "rb").read()).decode('utf-8')
Exemplo n.º 2
0
from pm4pymdl.objects.mdl.importer import importer as mdl_importer
from pm4pymdl.algo.mvp.discovery import algorithm as mvp_disc_factory
from pm4pymdl.visualization.mvp import visualizer as mvp_vis_factory

df = mdl_importer.apply("../example_logs/mdl/order_management.mdl")
model = mvp_disc_factory.apply(df)
gviz = mvp_vis_factory.apply(model, parameters={"format": "svg"})
mvp_vis_factory.view(gviz)