Skip to content

Latest commit

 

History

History
124 lines (89 loc) · 3.2 KB

File metadata and controls

124 lines (89 loc) · 3.2 KB

BA-Pred

Protein-Ligand Binding Affinity Prediction using Graph Neural Networks

Python PyTorch DGL License CASP16 GitHub stars

High-performance protein-ligand binding affinity prediction model - 2nd place in CASP16 ligand affinity challenge

Quick Start

pip install bapred

Run a prediction:

bapred -r protein.pdb -l ligands.sdf -o results.tsv

Predictions will be saved in results.tsv.

Usage

Installed CLI:

bapred -r protein.pdb -l ligands.sdf -o results.tsv

Use a different weight:

bapred -r protein.pdb -l ligands.sdf -o results.tsv --weight /path/to/checkpoint.pth

From a source checkout:

python -m bapred.inference -r example/1KLT.pdb -l example/ligands.sdf -o results.tsv

Python API:

from bapred.inference import inference

inference(
    protein_pdb="example/1KLT.pdb",
    ligand_file="example/ligands.sdf",
    output="results.tsv",
    batch_size=128,
    device="cuda",
)

Project Structure

BA-Pred/
├── src/
│   └── bapred/            # Main package
│       ├── data/          # Data processing modules
│       ├── model/         # Neural network models
│       ├── weight/        # Packaged model weights
│       └── inference.py   # Inference engine + CLI
├── example/               # Example files
│   ├── 1KLT.pdb          # Sample protein structure
│   ├── ligands.sdf        # Sample ligand library
│   └── run.sh            # Example inference script
├── pyproject.toml         # Package configuration
└── README.md

Input/Output Formats

Input

  • Protein: PDB format (.pdb)
  • Ligands: SDF (.sdf), MOL2 (.mol2), or text file with paths (.txt)

Output

  • CSV/TSV file with columns:
    • Name: Ligand identifier
    • pKd: Predicted binding affinity (pKd scale)
    • Kcal/mol: Binding energy in kcal/mol

License

This project is licensed under the Apache License 2.0. See the LICENSE file for details.

Citation

If you use BA-Pred in your research, please cite the paper:

@article{Sim_2026,
  title={BA-Pred and RMSD-Pred: Integrated Graph Neural Network Models for Accurate Protein-Ligand Binding Affinity and Binding Pose Prediction},
  author={Sim, Jaemin and Lee, Juyong},
  journal={Journal of Chemical Information and Modeling},
  year={2026},
  month={apr},
  doi={10.1021/acs.jcim.5c02591},
  url={https://doi.org/10.1021/acs.jcim.5c02591}
}

Made with care for the scientific community

Star us on GitHub if this project helped you!