Skip to main content

Python wheels and a wrapper for Vcontacts, a tool to compute surface areas in contact using the constrained Voronoi procedure.

Project description

vcontacts-wrapper (vconpy)

A lightweight Python package to prepare arguments and run Vcontacts,
a tool to compute surface areas in contact using the constrained Voronoi procedure from the paper:

Quantification of protein surfaces, volumes and atom-atom contacts using a constrained Voronoi procedure
(doi: 10.1093/bioinformatics/18.10.1365)

This wrapper makes it easy to call the Vcontacts executables (vcon_surfaces or vcon_nrgten) directly from Python, capture their output, and optionally parse .vcon files into Python dictionaries.


Installation

pip install vcon-py

Example Usage

from vconpy import run_vcon

# Run Vcontacts
result_surfaces = run_vcon(
    "/path/to/receptor.pdb",
    vcon_type="surfaces"
)

# Run Vcontacts and return a dictionary instead of outputting a file
result_nrgten = run_vcon(
    "/path/to/receptor.pdb",
    as_dictionary=True
)

# NRGTEN requires setting showbonded as True
result_nrgten = run_vcon(
    "/path/to/receptor.pdb",
    as_dictionary=True,
    showbonded=True
)

print(result_nrgten.surface_dictionary)  # dict of atom-atom contact areas

Arguments

Argument Type Description Default
pdb_filename str Path to the input PDB file. Required
showbonded bool If True, include covalently bonded atoms in the contacts (-all flag). False
normalize bool If True, normalize contacts to percent of total contact area. Otherwise, contacts are given in SAS units (Ų). (-norm flag). False
planedef str Plane definition for analysis. Options: X (extended radical plane), R (radical plane), B (bisecting plane). None
as_dictionary bool If True, returns a Python dictionary. The .vcon file is deleted after parsing. False

Returns

The function returns a VconResult namedtuple with the following fields:

Field Type Description
vcon_filename str Path to the generated .vcon file.
surface_dictionary dict Dictionary of atom-atom contact areas (only if as_dictionary=True).
stdout str Standard output from the Vcontacts process.
stderr str Standard error from the Vcontacts process.
returncode int Exit code from the Vcontacts process.

Raises

Error Condition
ValueError Raised if the input file does not exist, or if vcon_type is invalid.
VconError Raised if the Vcontacts executable is missing, not executable, or fails.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

vcon_py-1.0.0.tar.gz (24.3 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

vcon_py-1.0.0-py3-none-win_amd64.whl (28.5 kB view details)

Uploaded Python 3Windows x86-64

vcon_py-1.0.0-py3-none-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (21.8 kB view details)

Uploaded Python 3manylinux: glibc 2.17+ x86-64manylinux: glibc 2.5+ x86-64

vcon_py-1.0.0-py3-none-macosx_10_9_universal2.whl (40.1 kB view details)

Uploaded Python 3macOS 10.9+ universal2 (ARM64, x86-64)

File details

Details for the file vcon_py-1.0.0.tar.gz.

File metadata

  • Download URL: vcon_py-1.0.0.tar.gz
  • Upload date:
  • Size: 24.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for vcon_py-1.0.0.tar.gz
Algorithm Hash digest
SHA256 2451604104fc748a838c4cafbd6228c637a502e8143fe055264e68764022000b
MD5 ca050b8ed9960b4732acdd4e64563a7f
BLAKE2b-256 d11a98e0905371b2c805fc803ddc9581f8912ee748f30ba224c7c7dcec869459

See more details on using hashes here.

Provenance

The following attestation bundles were made for vcon_py-1.0.0.tar.gz:

Publisher: build.yaml on NRGlab/vcon-py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file vcon_py-1.0.0-py3-none-win_amd64.whl.

File metadata

  • Download URL: vcon_py-1.0.0-py3-none-win_amd64.whl
  • Upload date:
  • Size: 28.5 kB
  • Tags: Python 3, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for vcon_py-1.0.0-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 f0200a7e3f74fac4d100a282750bb2b9f6bb2c6d17bfb8d0d9040f2dd069afbb
MD5 2b137230dda7e1c8e05831f132d5317d
BLAKE2b-256 dc16b0f726e3aa6c71c99675b56f1a69f755d848efe8208738bd1f9fd02c47c0

See more details on using hashes here.

Provenance

The following attestation bundles were made for vcon_py-1.0.0-py3-none-win_amd64.whl:

Publisher: build.yaml on NRGlab/vcon-py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file vcon_py-1.0.0-py3-none-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for vcon_py-1.0.0-py3-none-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 5a920d95c96bf90feffc76db8ee4650392562467918aa4f7517daf292d07af31
MD5 01fd7a4d763922bf8d98aff978fe7f3d
BLAKE2b-256 d46b126ac414918993a72c5c6d70c1a0a389b9b2675875e3d5bf6a56ef3c8b6b

See more details on using hashes here.

Provenance

The following attestation bundles were made for vcon_py-1.0.0-py3-none-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: build.yaml on NRGlab/vcon-py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file vcon_py-1.0.0-py3-none-macosx_10_9_universal2.whl.

File metadata

File hashes

Hashes for vcon_py-1.0.0-py3-none-macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 9c94a4bf0931353c36370312b381769b0941ae9fc670822397a684804c6b255a
MD5 216b8dc008e1349e13ec59ab96c33412
BLAKE2b-256 c1684dadbb6f2ce6dba6c85aac8f6c71cf4eca91419d76396d7a51f6fb09e1e4

See more details on using hashes here.

Provenance

The following attestation bundles were made for vcon_py-1.0.0-py3-none-macosx_10_9_universal2.whl:

Publisher: build.yaml on NRGlab/vcon-py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page