--- id: tmtools version: "0.3.0" license: GPLv3 license_treatment: copyleft maintenance: aging --- # tmtools — Python bindings around the TM-align code for structural alignment of proteins License: copyleft · Maintenance: aging · Downloads: 151.9K/mo ## What it is and what it does tmtools wraps the TM-align algorithm—a widely-used structural biology tool for aligning protein coordinates—into a Python interface. It takes two sets of 3D atomic coordinates and amino acid sequences, computes the optimal structural alignment, and returns the rotation matrix, translation vector, and TM-score (a normalized similarity metric). The package ships with pre-built wheels for modern Python versions and common platforms, minimizing compilation friction. The core use case is comparing protein structures to assess similarity or find conserved folds. It supports both automatic alignment discovery and user-supplied alignment strings with gaps, making it useful for hypothesis testing or domain-guided comparisons. Optional integration with BioPython allows direct parsing of PDB files. The package is in alpha status and has not seen a release in several months, though the underlying TM-align algorithm is mature and well-cited in structural biology. Use it for: - Compare two protein structures to compute their TM-score and optimal superposition for structural similarity assessment. - Validate a hypothesized protein alignment by supplying a custom alignment string and checking the resulting TM-score. - Parse PDB files with BioPython and extract coordinates and sequences for downstream structural comparison workflows. - Batch-compare a query protein structure against a library of known folds to identify homologous structures. - Integrate structural alignment into a protein design or validation pipeline that requires quantitative similarity metrics. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Provides Python bindings to the TM-align algorithm for comparing protein structures by computing optimal alignment, rotation, translation, and similarity scores. Yes, if you need to compute protein structural alignments and TM-scores in Python. The pre-built wheels make installation straightforward, numpy is a common dependency, and the underlying algorithm is well-established. However, the GPLv3 license requires your project to be open-source; the aging maintenance status (no release in 278 days) suggests limited active development, so evaluate whether you need ongoing support or bug fixes. No known security vulnerabilities. ## Install pip install tmtools uv add tmtools poetry add tmtools ## Installing tmtools Before you install: Medium install friction due to compiled C++ components; wheels are pre-built for Python 3.10–3.14 on Linux, macOS (x86_64 and ARM64), and Windows, reducing compilation burden. Package is aging (278 days since last release) but repository remains active with recent commits. License in practice: Licensed under GPLv3 (copyleft), which requires derivative works and distributions to also be open-source under GPLv3. The bundled TM-align code is MIT-licensed but the wrapper is GPLv3, so any project using tmtools must comply with GPLv3 terms. Quickstart: pip install tmtools import numpy as np from tmtools import tm_align coords1 = np.array([[1.2, 3.4, 1.5], [4.0, 2.8, 3.7]]) coords2 = np.array([[2.3, 7.4, 1.5], [4.0, 2.9, -1.7]]) res = tm_align(coords1, coords2, "AY", "AR") print(res.tm_norm_chain1, res.rmsd) Requires numpy arrays with shape (N, 3) for coordinates; optional BioPython dependency for PDB file parsing must be installed separately. Verify before relying: - Whether BioPython integration (optional, for PDB file I/O) is tested or maintained alongside the core library. - Performance characteristics or scalability limits for large protein structures or batch alignments. - Whether custom alignment feature is actively used or tested in production workflows. ## Package facts - License: GPLv3 (copyleft) - Python support: unspecified - Install friction: medium - Maintenance: aging - Downloads: 151.9K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags protein structure alignment, TM-align python bindings, protein structure comparison, structural similarity scoring, protein coordinate alignment, TM-score calculation, protein structure matching, structural-biology, bioinformatics, protein-alignment [View on SkillFed](https://skillfed.io/packages/tmtools) · [View on PyPI](https://pypi.org/project/tmtools/)