librestraints: functions related to restraints
- haddock.libs.librestraints.active_passive_to_ambig(active1, passive1, active2, passive2, segid1='A', segid2='B')[source]
Convert active and passive residues to Ambiguous Interaction Restraints
- Parameters:
active1 (list) – List of active residue numbers of the first segid
passive1 (list) – List of passive residue numbers of the first segid
passive2 (list) – List of passive residue numbers of the second segid
active2 (list) – List of active residue numbers of the second segid
active2 (list) – List of passive residue numbers of the second segid
segid1 (string) – Segid to use for the first model
segid2 (string) – Segid to use for the second model
- haddock.libs.librestraints.build_restraints(bodies)[source]
Generates distance restraints to maintain the relative orientation of the different bodies during the simulations.
Generates two unique restraints per pair of bodies.
Each restraint is created using two random atoms on each body and using their exact euclidean distance as target distance.
- haddock.libs.librestraints.generate_tbl(atom_lst, restraints)[source]
Makes a list of TBL-formatted restraints.
- Parameters:
atom_lst (list) – List of atoms in the form (chain, resi, aname, coords)
restraints (list) – List of restraints in the form (res_i, res_j)
- haddock.libs.librestraints.get_bodies(atom_lst, prot_threshold=4.0, dna_threshold=7.5)[source]
Determines gaps in an atom list following simple distance based criteria. Returns continuous fragments.
- haddock.libs.librestraints.get_surface_resids(structure, cutoff=15)[source]
Calls freesasa using its Python API and returns per-residue accessibilities.
- haddock.libs.librestraints.parse_actpass_file(actpass_file)[source]
Parse actpass file
- Parameters:
actpass_file (str or Path) – path to actpass_file
- Returns:
active (list) – list of active residues
passive (list) – list of passive residues
- haddock.libs.librestraints.passive_from_active_raw(structure, active, chain_id=None, surface=None, radius=6.5)[source]
Get the passive residues.
- Parameters:
structure (str) – path to the PDB file
active (list) – List of active residues
chain_id (str) – Chain ID
surface (list) – List of surface residues.
radius (float) – Radius from active residues