Make urllib imports Python 3 compatible (pattern.graph)
####################################################################################################
from codecs import BOM_UTF8
-from urllib import urlopen
from itertools import chain
+try:
+ # Python 2
+ from urllib import urlopen
+except ImportError:
+ # Python 3
+ from urllib.request import urlopen
+
from __init__ import Graph, Node, Edge, bfs
from __init__ import WEIGHT, CENTRALITY, EIGENVECTOR, BETWEENNESS
