Skip to main content

gnina-torch

GitHub Actions Build Status codecov

Documentation Status DOI

PyTorch implementation of GNINA scoring function.

References

If you are using gnina-torch, please consider citing the following references:

Protein-Ligand Scoring with Convolutional Neural Networks, M. Ragoza, J. Hochuli, E. Idrobo, J. Sunseri, and D. R. Koes, J. Chem. Inf. Model. 2017, 57 (4), 942-957. DOI: 10.1021/acs.jcim.6b00740

libmolgrid: Graphics Processing Unit Accelerated Molecular Gridding for Deep Learning Applications J. Sunseri and D. R. Koes, J. Chem. Inf. Model. 2020, 60 (3), 1079-1084. DOI: 10.1021/acs.jcim.9b01145

If you are using the pre-trained default2018 and dense models from GNINA, please consider citing the following reference as well:

Three-Dimensional Convolutional Neural Networks and a Cross-Docked Data Set for Structure-Based Drug Design, P. G. Francoeur, T. Masuda, J. Sunseri, A. Jia, R. B. Iovanisci, I. Snyder, and D. R. Koes, J. Chem. Inf. Model. 2020, 60 (9), 4200-4215. DOI: 10.1021/acs.jcim.0c00411

If you are using the pre-trained default model ensemble from GNINA, please consider citing the following reference as well:

GNINA 1.0: molecular docking with deep learning, A. T. McNutt, P. Francoeur, R. Aggarwal, T. Masuda, R. Meli, M. Ragoza, J. Sunseri, D. R. Koes, J. Cheminform. 2021, 13 (43). DOI: 10.1186/s13321-021-00522-2

Installation

The gninatorch Python package has several dependencies, including:

A full developement environment can be installed using the conda package manager and the provided conda environment file (devtools/conda-envs/gninatorch.yaml):

conda env create -f devtools/conda-envs/gninatorch.yaml
conda activate gninatorch

Once the conda environment is created and activated, the gninatorch package can be installed using pip as follows:

python -m pip install .

Tests

In order to check the installation, unit tests are provided and can be run with pytest:

pytest --cov=gninatorch

Usage

Training and inference modules try to follow the original Caffe implementation of gnina/scripts, however not all features are implemented.

The folder examples includes some complete examples for training and inference.

The folder gninatorch/weights contains pre-trained models from GNINA, converted from Caffe to PyTorch.

Pre-trained GNINA models

Pre-trained GNINA models can be loaded as follows:

from gninatorch.gnina import setup_gnina_model

model = setup_gnina_model(MODEL)

where MODEL corresponds to the --cnn argument in GNINA.

A single model will return log_CNNscore and CNNaffinity, while an ensemble of models will return log_CNNscore, CNNaffinity, and CNNvariance.

Inference with pre-trained GNINA models (--cnn argument in GNINA) is implemented in the gnina module:

python -m gninatorch.gnina --help

Training

Training is implemented in the training module:

python -m gninatorch.training --help

Inference

Inference is implemented in the inference module:

python -m gninatorch.inference --help

Acknowledgments

Project based on the Computational Molecular Science Python Cookiecutter version 1.6.

The pre-trained weights of GNINA converted to PyTorch were kindly provided by Andrew McNutt (@drewnutt).


Copyright (c) 2021-2022, Rocco Meli

Metadata

Release files for gninatorch 0.0.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for gninatorch 0.0.2
File Size Uploaded Provenance Actions
gninatorch-0.0.2.tar.gz 37.1 MB Without provenance Details for gninatorch-0.0.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for gninatorch 0.0.2
File Interpreter ABI Platform Actions
gninatorch-0.0.2-py3-none-any.whl Python 3 none any Details for gninatorch-0.0.2-py3-none-any.whl

Total release size: 74.1 MB

Release files / gninatorch-0.0.2.tar.gz

Download URL gninatorch-0.0.2.tar.gz
Size 37.1 MB
Tags Source
SHA-256 checksum
How to use checksums
eb5fa7bcc17951bc3617dd310481a41966f42e5900a0a27d85aa5c8aa95418d7
BLAKE2b-256 checksum
How to use checksums
18cfbd93f588dc902d2b374e481eb250b098f27eb7f7df81ee832b623b5a6822
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.13

Release files / gninatorch-0.0.2-py3-none-any.whl

Download URL gninatorch-0.0.2-py3-none-any.whl
Size 37.1 MB
Tags Python 3
SHA-256 checksum
How to use checksums
1eb697799bba38b7b741688aec4445e7d144f6d7a91ebd035fb41ad42560bbe6
BLAKE2b-256 checksum
How to use checksums
e9adc0250e83c84ab06b1d0a49f296394f8bf7c13b4d28dd7cd5dfb9ae916100
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.13

Security for gninatorch 0.0.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.0.2 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page