fishmoon1234 / DAG-GNN

Apache License 2.0
290 stars 70 forks source link

Are there any tricks in this expression? #12

Open ThinkNaive opened 3 years ago

ThinkNaive commented 3 years ago

here's the line(52) in modules.py: logits = torch.matmul(adj_Aforz, x + self.Wa) - self.Wa

whether is it same as the following line? logits = torch.matmul(adj_Aforz, x)

I've test result between the two, however they are the same. So I wonder if there were any tricks so that the param Wa is necessary? Wish you could help me, thank you.

ThinkNaive commented 3 years ago

I found that expression in line(52) in modules.py logits = torch.matmul(adj_Aforz, x + self.Wa) - self.Wa is slightly different from that in the paper.

adj_Aforz denotes , use A for simplicity. x denotes , use B for simplicity. As is mentioned in the paper, , so the corresponding expression is logits = AB. However, expression in line(52) equals AB+(∑∑Aij - 1)*Wa

helenlai commented 2 years ago

same question, could you please explain what is the purpose of Wa here?