MCPcopy Create free account
hub / github.com/TrustAGI-Lab/MTGODE / forward

Method forward

layer.py:59–68  ·  view source on GitHub ↗
(self,x,adj)

Source from the content-addressed store, hash-verified

57 self.alpha = alpha
58
59 def forward(self,x,adj):
60 adj = adj + torch.eye(adj.size(0)).to(x.device)
61 d = adj.sum(1)
62 h = x
63 dv = d
64 a = adj / dv.view(-1, 1)
65 for i in range(self.gdep):
66 h = self.alpha*x + (1-self.alpha)*self.nconv(h,a)
67 ho = self.mlp(h)
68 return ho
69
70
71class mixprop(nn.Module):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected