Skip to content
LigandProPublic

About

UV-first benchmark for protein-ligand docking with reproducible annotation, pocket similarity, and HPC workflows.

Topics

Resources

Contributing

Stars

13 stars

Watchers

0 watching

Forks

Repository files navigation

Bento

CI Python uv License: MIT

Bento is a benchmark repository for evaluating protein-ligand docking methods across curated datasets and prediction outputs.

Highlights

  • Unified benchmark assets for ML and classical docking methods.
  • Legacy analysis pipeline preserved in scripts/.
  • UV-first workflow for local development and CI.
  • Reproducibility and HPC execution notes.

Repository Layout

bento/
├── annotated_ligands/          # Train/test tables with ligand-level annotations
├── annotations/                # Annotation maps and ligand class assets
├── datasets/                   # Core benchmark datasets
├── predictions_full_raw/       # Raw predictions from docking methods
├── scripts/                    # Legacy pipeline scripts (01..04)
├── similarity_scores/          # Similarity score artifacts
├── src/bento/                  # Bento CLI wrapper and environment tooling
├── tests/                      # Automated tests
├── docs/                       # Reproducibility and HPC docs
└── slurm/                      # Example SLURM job templates

Quick Start (UV)

1. Sync environment

uv sync --no-editable

--no-editable is recommended to guarantee the bento console entrypoint is available in all Python 3.12 environments.

For development checks:

uv sync --no-editable --extra lint --extra test

For ligand annotation dependencies:

uv sync --no-editable --extra annotation

For parallel GLoSA pocket similarity (PyMOL-free, Parquet output):

uv sync --no-editable --extra pocket-similarity

For legacy PyMOL pocket similarity (Linux/HPC):

uv sync --no-editable --extra similarity

2. Validate environment

uv run --extra annotation bento check-env --profile annotation
uv run bento check-env --profile similarity --glosa-dir /path/to/glosa_v2.2

3. Run pipeline commands

Ligand annotation:

uv run --extra annotation bento annotate-ligands \
  --dataset-file datasets/tests.tsv \
  --output-dir outputs/

Pocket similarity (parallel sharded, Parquet output):

uv run --extra pocket-similarity bento pocket-similarity run \
  --dataset-tsv-1 datasets/trains.tsv \
  --dataset-tsv-2 datasets/tests.tsv \
  --bs-dir outputs/pocket_similarity/glosa_bs_files \
  --glosa-dir /path/to/glosa_v2.2 \
  --output-dir outputs/pocket_similarity \
  --workers 32

Legacy pocket similarity (single-dataset PyMOL script):

uv run bento compute-pocket-similarity \
  --data-csv test_run/path_tests.tsv \
  --protein-path path_protein \
  --ligand-path path_ligand \
  --bs-dir bs \
  --glosa-dir /path/to/glosa_v2.2 \
  --output-file similarity_scores/test_pocket_scores.tsv

Annotation mapping:

uv run bento map-annotations \
  --tests-file datasets/tests.tsv \
  --annotations-dir annotations \
  --output-tests-file datasets/tests_annotated.tsv \
  --output-tests-exploded-file datasets/tests_exploded_annotated.tsv

Configuration

Legacy scripts use environment variables:

  • BENTO_WORKDIR: repository root path (default: current repository root).
  • BENTO_DATABASES_DIR: root path for external dataset files (default: BENTO_WORKDIR).
  • BENTO_GLOSA_DIR: path to GLoSA directory (default: <repo>/external/glosa).
  • BENTO_REPO_ROOT: optional override for CLI location of legacy scripts.

Example:

export BENTO_WORKDIR=/path/to/Bento
export BENTO_DATABASES_DIR=/path/to/datasets
export BENTO_GLOSA_DIR=/path/to/glosa_v2.2

External Tool Requirements

Some steps require non-Python tools:

  • PyMOL (for pocket extraction in script 02; installed with --extra similarity on Linux/HPC).
  • Java JDK and g++ (for GLoSA tooling).
  • GLoSA v2.2 executable and AssignChemicalFeatures class.

Build GLoSA once inside your BENTO_GLOSA_DIR (deterministic -O3 flags give ~3x speedup with identical scores):

g++ -O3 -ffp-contract=off glosa.cpp -o glosa
javac AssignChemicalFeatures.java

These tools are validated by:

uv run bento check-env --profile similarity --glosa-dir /path/to/glosa_v2.2

Quality Checks

uv run ruff check .
uv run ruff format --check .
uv run pytest

Reproducibility and HPC

Citation

@software{bento_benchmark,
  title={Bento: A Comprehensive Benchmark for Protein-Ligand Docking Methods},
  author={LigandPro Team},
  year={2024},
  url={https://github.com/LigandPro/Bento}
}

License

MIT. See LICENSE.

About

UV-first benchmark for protein-ligand docking with reproducible annotation, pocket similarity, and HPC workflows.

Topics

Resources

Contributing

Stars

13 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages