ethanfetaya / NRI

Neural relational inference for interacting systems - pytorch
MIT License
732 stars 157 forks source link

For the type of edge in the experimental setup. #22

Open ZhangNYG opened 4 years ago

ZhangNYG commented 4 years ago

There is no supervised training in training. How to know the first type is the existence side and the second type is the non existence side. def edge_accuracy(preds, target): _, preds = preds.max(-1) # preds torch.Size([32, 20, 2]) preds_hou torch.Size([32, 20]) correct = preds.float().data.eq( target.float().data.view_as(preds)).cpu().sum() return np.float(correct) / (target.size(0) * target.size(1))

fatcatZF commented 2 years ago

It seems you can set skip_first to True to make sure the first edge type denote the non-interaction edges