From 6d346281011070fc1422d45c2dbf43aa475b8814 Mon Sep 17 00:00:00 2001 From: Zihao Ye Date: Tue, 18 Aug 2020 17:15:31 +0800 Subject: [PATCH] upd (#2043) --- examples/pytorch/gat/train_ppi.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/examples/pytorch/gat/train_ppi.py b/examples/pytorch/gat/train_ppi.py index 9540c31b32d6..d82c85615780 100644 --- a/examples/pytorch/gat/train_ppi.py +++ b/examples/pytorch/gat/train_ppi.py @@ -119,7 +119,8 @@ def main(args): test_score_list = [] for batch, subgraph in enumerate(test_dataloader): subgraph = subgraph.to(device) - test_score_list.append(evaluate(subgraph.ndata['feat'], model, subgraph, subgraph.ndata['label'], loss_fcn)) + score, test_loss = evaluate(subgraph.ndata['feat'], model, subgraph, subgraph.ndata['label'], loss_fcn) + test_score_list.append(score) print("Test F1-Score: {:.4f}".format(np.array(test_score_list).mean())) if __name__ == '__main__':