Fixes problems in PDB files
Project description
PDBFixer
PDBFixer is a Python library for repairing and preparing Protein Data Bank (PDB) files before simulation. It focuses on an intuitive API that automates common cleanup steps so structures are ready for downstream workflows without manual editing.
This Neoralab-maintained fork builds on the original OpenMM release, extending the codebase with modern packaging, documentation, and interface updates reflected in the refreshed docs site.
Fork notice
This repository is a fork of openmm/pdbfixer. The upstream project is available under the MIT License, and its original copyrights and notices are preserved in this fork. This fork contains additional modifications maintained by neoralab and contributors.
Overview
PDBFixer can automatically:
- Add missing heavy atoms and hydrogens.
- Build missing loops.
- Convert non-standard residues to standard equivalents.
- Select a single position for atoms with alternate locations.
- Remove unwanted chains or heterogens.
- Build a water box for explicit solvent simulations.
Refer to the MkDocs site for detailed usage guidance, API notes, and examples.
Documentation
- Hosted docs: https://neoralab.github.io/pdbfixer/
- Source:
docs/
Improvements over the OpenMM fork
- Published on PyPI as
pdbfixer-neoralabwith support for Python 3.11 and newer. - Modernized packaging via
pyproject.tomlandversioningit, keeping releases in sync with Git tags. - Distributed purely as a Python API, removing the legacy web and command-line interfaces to focus on library usability.
Installation
PyPI or uv
Install with pip or uv (Python 3.11+):
pip install pdbfixer-neoralab
uv pip install pdbfixer-neoralab
Conda
Install from conda-forge:
conda install -c conda-forge pdbfixer
From source
Clone the repository and follow the documentation for source installation details.
Optional extras
PDBFixer defines extras for common contributor workflows that match the entries in pyproject.toml:
- Tests:
pip install -e .[tests] - Documentation:
pip install -e .[docs]
Versioning
PDBFixer uses versioningit to derive its version from Git tags. Building from a
source checkout therefore requires either a cloned repository with Git metadata or a source distribution that already
includes the generated version. When no tag information is available, the default reported version is 0+unknown. To
preview the build version:
python -m versioningit
Quickstart
PDBFixer is distributed purely as a Python API. Use it directly from your code:
from pdbfixer import PDBFixer
from openmm.app import PDBFile
fixer = PDBFixer(filename="input.pdb")
fixer.findMissingResidues()
fixer.findMissingAtoms()
fixer.addMissingAtoms()
fixer.addMissingHydrogens(pH=7.0)
with open("fixed.pdb", "w") as handle:
PDBFile.writeFile(fixer.topology, fixer.positions, handle)
For more examples—mutations, solvation, and template registration—see
the MkDocs site or the source files under docs/.
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
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 pdbfixer_neoralab-1.1.1.tar.gz.
File metadata
- Download URL: pdbfixer_neoralab-1.1.1.tar.gz
- Upload date:
- Size: 53.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fe0c15daadc6374b38b321d70e75513198fe44aa2a32c44e0383ed82400888d4
|
|
| MD5 |
a3210e0d5c10b58ceabab5d9f0d3b8b6
|
|
| BLAKE2b-256 |
de093bc3cf36db519522c9a1589775b0bdd1478e056b2db1ad1d3d950ef7e53f
|
File details
Details for the file pdbfixer_neoralab-1.1.1-py3-none-any.whl.
File metadata
- Download URL: pdbfixer_neoralab-1.1.1-py3-none-any.whl
- Upload date:
- Size: 55.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e8820af1c8ce5e092054d698a51a282d957539c465574b1b6d2b16850fb95b78
|
|
| MD5 |
71577059c3fdfb1f5ef6c3aa13461219
|
|
| BLAKE2b-256 |
c1e96ed54e887fabef84b216d4a7eb357ab6a20e11e354c82d2da2d117e0ec5a
|