pygod
pygod copied to clipboard
Problem for CoLA and ANEMONE models.
The codes for masking the target nodes is wrong. The target node is the first node in subgraph after the RandomWalk sample, while you mask the last node. The performance of CoLa and ANEMONE will improve 2% by fixing the bug.
Wrong codes in CoLA(line 361~364) batch_feature = torch.cat( (batch_feature[:, :-1, :], added_feat_zero_row, batch_feature[:, -1:, :]), dim=1)
Correct codes: batch_feature = torch.cat( (added_feat_zero_row, batch_feature[:, 1:, :], batch_feature[:, 0:1, :]), dim=1)
Wrong codes in ANEMONE(line 288~289 and 429~430) bf = torch.cat( (bf[:, :-1, :], added_feat_zero_row, bf[:, -1:, :]), dim=1)
Correct codes: bf = torch.cat( (added_feat_zero_row, bf[:, 1:, :], bf[:, 0 : 1, :]), dim=1)
Thanks a lot for you issue. Could you please help us to create a PR? So that your contribution will be shown in the repo later.
CoLA is now refactored.