FederatedScope
FederatedScope copied to clipboard
one bug in federatedscope/gfl/fedsageplus/trainer.py
In the trainer.py,
ctx.y_true = batch.num_missing[mask]
ctx.y_prob = pred_missing
https://github.com/alibaba/FederatedScope/blob/480b67de851df2fa02b7cc2189f1803d947998d7/federatedscope/gfl/fedsageplus/trainer.py#L42C1-L43C34
https://github.com/alibaba/FederatedScope/blob/480b67de851df2fa02b7cc2189f1803d947998d7/federatedscope/gfl/fedsageplus/trainer.py#L66C1-L67C34
It seems that 'pred_missing' (i.e., the output of the missing neighbor generator) and 'num_missing' (i.e., the groundtruth of missing nodes) are used to compute the final result. However, it is a node classification task. We should compute the node classification accuracy.
As a result, I suggest that the node label and the predicted node label should be used to compute the final result.
It may be changed to
ctx.y_true = batch.y[mask]
ctx.y_prob = nc_pred