DeepGraphLearning / torchdrug

A powerful and flexible machine learning platform for drug discovery
https://torchdrug.ai/
Apache License 2.0
1.44k stars 200 forks source link

The accuracy of retrosynthesis reaction center prediction #103

Closed yyc776 closed 2 years ago

yyc776 commented 2 years ago

Hello, Thanks for sharing this library! The reproduced center-identification results of G2Gs are different from the paper.

reaction class known 90.2
reaction class unknown 75.8

These are the reported results from the Torchdrug tutorial:

The evaluation result on the validation set may look like: accuracy: 0.836367

In my understanding, this value is calculated when the reaction class is unknown. I cannot understand why it is higher than reported in the literature.

Thank you very much

KiddoZhu commented 2 years ago

Hi! G2Gs in TorchDrug has some slight improvement compared to the original paper. Maybe @shichence knows what the difference is in the implementation.

shichence commented 2 years ago

Hi! Inspired by this paper, we slightly adapt the implementation of the reaction center module. In a nutshell, in the original paper, we treat center identification as a binary classification problem defined on each node in the graph, while in this repo, we treat it as a multi-class classification problem and define a cross-entropy loss on all nodes in the graph. We find the latter one works quite well.

yyc776 commented 2 years ago

Thank you very much for your reply, which is very helpful! Wish you peace and health on Dragon Boat Festival!