예제 #1
0
파일: domino_model.py 프로젝트: salilab/imp
 def set_assembly(self, fn_pdb, names):
     """
         Sets an assembly from a single PDB file. The function assumes that
         the components of the assembly are the chains of the PDB file.
         @param fn_pdb PDB with the file for the assembly
         @param names Names for each of the components (chains)
             of the assembly
     """
     self.assembly = representation.create_assembly_from_pdb(self.model, fn_pdb, names)
     self.components_rbs = representation.create_rigid_bodies(self.assembly)
     self.not_optimized_rbs = []
예제 #2
0
 def set_assembly(self, fn_pdb, names):
     """
         Sets an assembly from a single PDB file. The function assumes that
         the components of the assembly are the chains of the PDB file.
         @param fn_pdb PDB with the file for the assembly
         @param names Names for each of the components (chains)
             of the assembly
     """
     self.assembly = representation.create_assembly_from_pdb(self.model,
                                                             fn_pdb,
                                                             names)
     self.components_rbs = representation.create_rigid_bodies(self.assembly)
     self.not_optimized_rbs = []
예제 #3
0
파일: domino_model.py 프로젝트: salilab/imp
 def set_native_assembly_for_benchmark(self, params):
     """
         Sets the native model for benchmark, by reading the native
         structure and set the rigid bodies.
     """
     self.measure_models = True
     self.native_model = IMP.Model()
     if hasattr(params.benchmark, "fn_pdb_native"):
         self.native_assembly = \
             representation.create_assembly_from_pdb(self.native_model,
                                                     params.benchmark.fn_pdb_native, params.names)
     elif hasattr(params.benchmark, "fn_pdbs_native"):
         self.native_assembly = \
             representation.create_assembly(self.native_model,
                                            params.benchmark.fn_pdbs_native, params.names)
     else:
         raise ValueError("set_native_assembly_for_benchmark: Requested "
                          "to set a native assembly for benchmark but did not provide "
                          "its pdb, or the pdbs of the components")
     self.native_rbs = representation.create_rigid_bodies(
         self.native_assembly)
     anchor_assembly(self.native_rbs, params.anchor)
예제 #4
0
 def set_native_assembly_for_benchmark(self, params):
     """
         Sets the native model for benchmark, by reading the native
         structure and set the rigid bodies.
     """
     self.measure_models = True
     self.native_model = IMP.Model()
     if hasattr(params.benchmark, "fn_pdb_native"):
         self.native_assembly = \
             representation.create_assembly_from_pdb(self.native_model,
                                                     params.benchmark.fn_pdb_native, params.names)
     elif hasattr(params.benchmark, "fn_pdbs_native"):
         self.native_assembly = \
             representation.create_assembly(self.native_model,
                                            params.benchmark.fn_pdbs_native, params.names)
     else:
         raise ValueError("set_native_assembly_for_benchmark: Requested "
                          "to set a native assembly for benchmark but did not provide "
                          "its pdb, or the pdbs of the components")
     self.native_rbs = representation.create_rigid_bodies(
         self.native_assembly)
     anchor_assembly(self.native_rbs, params.anchor)