3 from __future__
import print_function
5 from IMP
import OptionParser
7 __doc__ =
"Write output models as PDB files."
12 usage =
"""%prog [options] <asmb.input> <proteomics.input>
13 <mapping.input> <combinations> <model prefix>
18 parser.add_option(
"-m",
"--max", type=
"int", dest=
"max", default=
None,
19 help=
"maximum number of models to write")
20 (options, args) = parser.parse_args()
22 parser.error(
"incorrect number of arguments")
26 def run(asmb_fn, proteomics_fn, mapping_fn, combs_fn, model_output, max_comb):
36 mhs = ensmb.get_molecules()
37 print(
"number of combinations:", len(combs), max_comb)
38 for i, comb
in enumerate(combs[:max_comb]):
41 ensmb.load_combination(comb)
42 print(model_output +
"." + str(i) +
".pdb")
44 ensmb.unload_combination(comb)
48 options, args = parse_args()
49 run(args[0], args[1], args[2], args[3], args[4], options.max)
51 if __name__ ==
"__main__":
void write_pdb(const Selection &mhd, base::TextOutput out, unsigned int model=1)
SettingsData * read_settings(const char *filename)
ProteinsAnchorsSamplingSpace read_protein_anchors_mapping(multifit::ProteomicsData *prots, const std::string &anchors_prot_map_fn, int max_paths=INT_MAX)
Ensemble * load_ensemble(multifit::SettingsData *sd, Model *mdl, const ProteinsAnchorsSamplingSpace &mapping_data)
Fitting atomic structures into a cryo-electron microscopy density map.
ProteomicsData * read_proteomics_data(const char *proteomics_fn)
Proteomics reader.
IMP::kernel::OptionParser OptionParser
IntsList read_paths(const char *txt_filename, int max_paths=INT_MAX)
Read paths.
Class for storing model, its restraints, constraints, and particles.