Różnice

Różnice między wybraną wersją a wersją aktualną.

Odnośnik do tego porównania

Both sides previous revision Poprzednia wersja
Nowa wersja
Poprzednia wersja
Nowa wersja Both sides next revision
pl:dydaktyka:dss:lab02 [2019/06/27 15:50]
127.0.0.1 edycja zewnętrzna
pl:dydaktyka:dss:lab02 [2019/10/14 13:29]
kkluza [Implementing a simple heuristic miner]
Linia 90: Linia 90:
 {{:​pl:​dydaktyka:​dss:​lab:​simple_heuristic_net.png?​550|}} {{:​pl:​dydaktyka:​dss:​lab:​simple_heuristic_net.png?​550|}}
  
 +If you don't have pygraphviz, you can use graphviz (check instruction at the bottom of the page).
 ===== Diagram enhancing ===== ===== Diagram enhancing =====
  
Linia 160: Linia 161:
 import graphviz import graphviz
 G = graphviz.Digraph() G = graphviz.Digraph()
-for event in net:+for event in w_net:
     G.node(event,​ style="​rounded,​filled",​ fillcolor="#​ffffcc"​)     G.node(event,​ style="​rounded,​filled",​ fillcolor="#​ffffcc"​)
-    for preceding in net[event]:+    for preceding in w_net[event]:
         G.edge(event,​ preceding)         G.edge(event,​ preceding)
  
Linia 170: Linia 171:
 G.node("​End",​ shape="​circle",​ label=""​) G.node("​End",​ shape="​circle",​ label=""​)
 G.render('​simple_graphviz_graph'​) G.render('​simple_graphviz_graph'​)
 +display(G)
 </​code>​ </​code>​
  
pl/dydaktyka/dss/lab02.txt · ostatnio zmienione: 2020/10/18 19:42 przez kkluza
www.chimeric.de Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0