A Python library for parsing and editing GROMACS topology files.
Project description
gmxtopology
Description
gmxtopology is a Python package for parsing and editing GROMACS topology
files.
Package layout
The main flow is organized around a few top-level modules:
gmxtopology.topology: topology data modelsgmxtopology.io: topology file reading and writinggmxtopology.parser: section parsing and dispatchgmxtopology.lookup: parameter lookup and virtual-site reduction helpersgmxtopology.schema: schema objects used by the parsergmxtopology.interaction_specs: GROMACS interaction tables
Installation
pip install gmxtopology
This installs ipykernel as well, so the environment is ready for Jupyter and
IPython kernel use.
From source:
pip install git+https://github.com/vojtechkostal/gmxtopology.git
Usage
See examples/example.ipynb for a fuller walkthrough.
from gmxtopology import Topology
# load topology from file
fn_top = "./examples/topol.top"
top = Topology(fn_top)
# modifying topology parameters
for atom in top.molecules['POPC'][0].atoms:
atom.update(charge=0.0)
for atomtype in top.atomtypes:
atomtype.update(sigma=0.31)
# remove virtual sites from a molecule
top.molecules['SOL'][0].remove_vsites()
# write topology into a file
top.write("./examples/topol-processed.top", overwrite=True)
Publishing
GitHub Trusted Publishing is set up via
publish.yml. The one-time PyPI and TestPyPI
configuration steps are documented in docs/publishing.md.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file gmxtopology-0.1.0.tar.gz.
File metadata
- Download URL: gmxtopology-0.1.0.tar.gz
- Upload date:
- Size: 52.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3c5ba0d232b74d01eedcf77bb5f0993a700a6f3072b4ac12e75eb41303b81c58
|
|
| MD5 |
6af01ffe2eb1fe46850ab10692c2ef33
|
|
| BLAKE2b-256 |
d56a54e1b9d128480f75d5f19891db16d49fe11ae00a5356333a0136d36029fc
|
Provenance
The following attestation bundles were made for gmxtopology-0.1.0.tar.gz:
Publisher:
publish.yml on vojtechkostal/gmxtopology
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
gmxtopology-0.1.0.tar.gz -
Subject digest:
3c5ba0d232b74d01eedcf77bb5f0993a700a6f3072b4ac12e75eb41303b81c58 - Sigstore transparency entry: 1172035837
- Sigstore integration time:
-
Permalink:
vojtechkostal/gmxtopology@735dd0dcb4ecc517fae6bb44b0974a7b19ba4d1b -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/vojtechkostal
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@735dd0dcb4ecc517fae6bb44b0974a7b19ba4d1b -
Trigger Event:
release
-
Statement type:
File details
Details for the file gmxtopology-0.1.0-py3-none-any.whl.
File metadata
- Download URL: gmxtopology-0.1.0-py3-none-any.whl
- Upload date:
- Size: 42.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
817e3615d83761c4c5e29cbe5d524fb4b40699a74e80782d5ee844975dd76b13
|
|
| MD5 |
1c6a4a18b93dbfe98d398062646698f8
|
|
| BLAKE2b-256 |
1aa78660698679dc5d25e7cea3f1c058557b579e819ad89df27218bca5fc0161
|
Provenance
The following attestation bundles were made for gmxtopology-0.1.0-py3-none-any.whl:
Publisher:
publish.yml on vojtechkostal/gmxtopology
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
gmxtopology-0.1.0-py3-none-any.whl -
Subject digest:
817e3615d83761c4c5e29cbe5d524fb4b40699a74e80782d5ee844975dd76b13 - Sigstore transparency entry: 1172035861
- Sigstore integration time:
-
Permalink:
vojtechkostal/gmxtopology@735dd0dcb4ecc517fae6bb44b0974a7b19ba4d1b -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/vojtechkostal
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@735dd0dcb4ecc517fae6bb44b0974a7b19ba4d1b -
Trigger Event:
release
-
Statement type: