예제 #1
0
파일: graph.py 프로젝트: kkonrad/cog-abm
 def __init__(self):
     """
     Initialize a graph.
     """
     common.__init__(self)
     labeling.__init__(self)
     self.node_neighbors = {}     # Pairing: Node -> Neighbors
예제 #2
0
 def __init__(self):
     """
     Initialize a graph.
     """
     common.__init__(self)
     labeling.__init__(self)
     self.node_neighbors = {}  # Pairing: Node -> Neighbors
예제 #3
0
 def __init__(self):
     """
     Initialize a digraph.
     """
     common.__init__(self)
     labeling.__init__(self)
     self.node_neighbors = {}     # Pairing: Node -> Neighbors
     self.node_incidence = {}     # Pairing: Node -> Incident nodes
예제 #4
0
 def __init__(self):
     """
     Initialize a digraph.
     """
     common.__init__(self)
     labeling.__init__(self)
     self.node_neighbors = {}  # Pairing: Node -> Neighbors
     self.node_incidence = {}  # Pairing: Node -> Incident nodes
예제 #5
0
파일: hypergraph.py 프로젝트: mbaez/SAP
 def __init__(self):
     """
     Initialize a hypergraph.
     """
     common.__init__(self)
     labeling.__init__(self)
     self.node_links = {}    # Pairing: Node -> Hyperedge
     self.edge_links = {}     # Pairing: Hyperedge -> Node
     self.graph = graph()    # Ordinary graph
 def __init__(self):
     """
     Initialize a hypergraph.
     """
     common.__init__(self)
     labeling.__init__(self)
     self.node_links = {}  # Pairing: Node -> Hyperedge
     self.edge_links = {}  # Pairing: Hyperedge -> Node
     self.graph = graph()  # Ordinary graph
예제 #7
0
 def __init__( self, G=None, inverted=False, reversed=False ):
     """
     Initialize a digraph.
     """
     if G:
         self.G = G
     else:
         self.G = {}
         
     common.__init__(self)
     labeling.__init__(self)