examples/dataflow: only import nx when needed

This commit is contained in:
Sebastien Bourdeauducq 2012-06-08 22:54:04 +02:00
parent 009f26bb9d
commit 5964df62db
1 changed files with 1 additions and 1 deletions

View File

@ -1,5 +1,4 @@
import sys
import networkx as nx
from migen.fhdl import verilog
from migen.flow.ala import *
@ -19,5 +18,6 @@ print(verilog.convert(frag))
if len(sys.argv) > 1 and sys.argv[1] == "draw":
import matplotlib.pyplot as plt
import networkx as nx
nx.draw(g)
plt.show()