-
Notifications
You must be signed in to change notification settings - Fork 104
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #699 from padix-key/lddt
Add support for lDDT computation
- Loading branch information
Showing
5 changed files
with
694 additions
and
81 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
import itertools | ||
from pathlib import Path | ||
import pytest | ||
import biotite.structure as struc | ||
import biotite.structure.io.pdbx as pdbx | ||
from tests.util import data_dir | ||
|
||
|
||
@pytest.fixture | ||
def atoms(): | ||
pdbx_file = pdbx.BinaryCIFFile.read(Path(data_dir("structure")) / "1gya.bcif") | ||
atoms = pdbx.get_structure(pdbx_file) | ||
# Reduce the number of atoms to speed up the benchmark | ||
return atoms[..., atoms.element != "H"] | ||
|
||
|
||
@pytest.mark.benchmark | ||
@pytest.mark.parametrize( | ||
"multi_model, aggregation", | ||
itertools.product([False, True], ["all", "chain", "residue", "atom"]), | ||
) | ||
def benchmark_lddt(atoms, multi_model, aggregation): | ||
""" | ||
Compute lDDT on different aggregation levels. | ||
""" | ||
reference = atoms[0] | ||
if multi_model: | ||
subject = atoms | ||
else: | ||
subject = atoms[0] | ||
|
||
struc.lddt(reference, subject, aggregation=aggregation) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -321,6 +321,7 @@ | |
"rmsd", | ||
"rmspd", | ||
"rmsf", | ||
"lddt", | ||
"tm_score" | ||
], | ||
"General analysis" : [ | ||
|
Oops, something went wrong.