MCPcopy Create free account
hub / github.com/Vegetebird/GraphMLP / get_edge

Method get_edge

model/block/graph_frames.py:55–78  ·  view source on GitHub ↗
(self, layout)

Source from the content-addressed store, hash-verified

53 return self_link, time_link
54
55 def get_edge(self, layout):
56 if layout == 'hm36_gt':
57 self.num_node_each = 17
58
59
60 neighbour_base = [(1, 2), (3, 2), (4, 3), (5, 1), (6, 5), (7, 6),
61 (8, 1), (9, 8), (10, 9), (11, 10), (12, 9),
62 (13, 12), (14, 13), (15, 9), (16, 15), (17, 16)
63 ]
64 sym_base = [(7, 4), (6, 3), (5, 2), (12, 15), (13, 16), (14, 17)]
65
66 self_link, time_link = self.basic_layout(neighbour_base, sym_base)
67
68 self.la, self.ra =[11, 12, 13], [14, 15, 16]
69 self.ll, self.rl = [4, 5, 6], [1, 2, 3]
70 self.cb = [0, 7, 8, 9, 10]
71 self.part = [self.la, self.ra, self.ll, self.rl, self.cb]
72
73 self.edge = self_link + self.neighbour_link_all + self.sym_link_all + time_link
74
75 self.center = 8 - 1
76
77 else:
78 raise ValueError("Do Not Exist This Layout.")
79
80 def get_adjacency(self, strategy):
81

Callers 1

__init__Method · 0.95

Calls 1

basic_layoutMethod · 0.95

Tested by

no test coverage detected