The RT-Tranformer combine the fingerprint and the molecular graph data and predict retention time as the output. It's architecture is showed as following:
Motivation:Liquid chromatography retention times prediction can assist in metabolite identification, which is a critical task and challenge in non-targeted metabolomics. However, different chromatographic conditions may result in different retention times for the same metabolite. Current retention time prediction methods lack sufficient scalability to transfer from one specific chromatographic method to another
- Python 3.9
- torch
- rdkit-pypi
- torch-scatter
- torch-sparse
- torch-cluster
- torch_geometric
- scikit-learn
- tqdm
- jupyter
- notebook
- pandas
- networkx
- gradio
The SMRT dataset is collect from this paper Datasets for transfer learning is download from PredRet
Run test.py by python ./test.py
You can follow the jupyter notebook to predict rentention time in your own data.
We provide easily accessible web pages and host them on the huggingface.
- Prepare your dataset as a csv file which has "InChI" and "RT" columns.
- Rename it as "data.csv" at the root directory.
- download the pre-trained model from huggingface.
- Run transfer.py
You can also follow this jupyter notebook to fine-tuning the model.
- Prepare your dataset as a csv file which has "InChI" and "RT" columns.
- Rename it as "data.csv" at the root directory.
- Run train.py
best_state_download_dict.pth The Best model of RT-Transformer train from retained data. best_state_dict.pth The Best model of RT-Transformer train from full data.
If you make use of the code/experiment in your work, please cite our paper (Bibtex below).
@article{xue2023rt, title={RT-Tranformer: Retention Time Prediction for Metabolite Annotation to Assist in Metabolite Identification}, author={Jun Xue and Bingyi Wang and Hongchao Ji and Weihua Li }, year={2023} }