IMP logo
IMP Reference Guide  2.20.1
The Integrative Modeling Platform
IMP.pmi.macros.BuildSystem Class Reference

A macro to build a IMP::pmi::topology::System based on a TopologyReader object. More...

Inherits object.

Detailed Description

A macro to build a IMP::pmi::topology::System based on a TopologyReader object.

Easily create multi-state systems by calling this macro repeatedly with different TopologyReader objects! A useful function is get_molecules() which returns the PMI Molecules grouped by state as a dictionary with key = (molecule name), value = IMP.pmi.topology.Molecule Quick multi-state system:

model = IMP.Model()
reader1 = IMP.pmi.topology.TopologyReader(tfile1)
reader2 = IMP.pmi.topology.TopologyReader(tfile2)
bs = IMP.pmi.macros.BuildSystem(model)
bs.add_state(reader1)
bs.add_state(reader2)
bs.execute_macro() # build everything including degrees of freedom
IMP.atom.show_molecular_hierarchy(bs.get_hierarchy())
### now you have a two state system, you add restraints etc
Note
The "domain name" entry of the topology reader is not used. All molecules are set up by the component name, but split into rigid bodies as requested.
This class is only available in Python.

Definition at line 583 of file macros.py.

Public Member Functions

def __init__
 Constructor. More...
 
def add_state
 Add a state using the topology info in a IMP::pmi::topology::TopologyReader object. More...
 
def execute_macro
 Builds representations and sets up degrees of freedom. More...
 
def get_molecules
 Return list of all molecules grouped by state. More...
 

Constructor & Destructor Documentation

def IMP.pmi.macros.BuildSystem.__init__ (   self,
  model,
  sequence_connectivity_scale = 4.0,
  force_create_gmm_files = False,
  resolutions = [1,
  name = 'System' 
)

Constructor.

Parameters
modelAn IMP Model
sequence_connectivity_scaleFor scaling the connectivity restraint
force_create_gmm_filesIf True, will sample and create GMMs no matter what. If False, will only sample if the files don't exist. If number of Gaussians is zero, won't do anything.
resolutionsThe resolutions to build for structured regions
nameThe name of the top-level hierarchy node.

Definition at line 612 of file macros.py.

Member Function Documentation

def IMP.pmi.macros.BuildSystem.add_state (   self,
  reader,
  keep_chain_id = False,
  fasta_name_map = None,
  chain_ids = None 
)

Add a state using the topology info in a IMP::pmi::topology::TopologyReader object.

When you are done adding states, call execute_macro()

Parameters
readerThe TopologyReader object
fasta_name_mapdictionary for converting protein names found in the fasta file
chain_idsA list or string of chain IDs for assigning to newly-created molecules, e.g. string.ascii_uppercase+string.ascii_lowercase+string.digits. If not specified, chain IDs A through Z are assigned, then AA through AZ, then BA through BZ, and so on, in the same fashion as PDB.

Definition at line 636 of file macros.py.

def IMP.pmi.macros.BuildSystem.execute_macro (   self,
  max_rb_trans = 4.0,
  max_rb_rot = 0.04,
  max_bead_trans = 4.0,
  max_srb_trans = 4.0,
  max_srb_rot = 0.04 
)

Builds representations and sets up degrees of freedom.

Definition at line 805 of file macros.py.

def IMP.pmi.macros.BuildSystem.get_molecules (   self)

Return list of all molecules grouped by state.

For each state, it's a dictionary of Molecules where key is the molecule name

Definition at line 794 of file macros.py.


The documentation for this class was generated from the following file: