3 This script shows how to simulate an a protein using a
4 Membrane restraint. This example show 3 ideal helices
5 that have different segments inside the membrane
22 "Simulation of a protein using a membrane restraint")
32 for i, len_helix
in enumerate([20, 40, 80]):
33 mol = st.create_molecule(
34 "helix_%s" % (str(i)), sequence=
"A" * len_helix, chain_id=
"A"
36 mol.add_representation(mol, resolutions=[1], ideal_helix=
True)
42 dof.create_rigid_body(mol,
55 cr.set_label(mol.get_name())
57 output_objects.append(cr)
64 included_objects=mols, resolution=1
68 output_objects.append(evr1)
74 mr = IMP.pmi.restraints.basic.MembraneRestraint(
76 objects_inside=[
"helix_0", (1, 20,
"helix_1"), (20, 40,
"helix_2")],
77 objects_above=[(21, 40,
"helix_1"), (1, 19,
"helix_2")],
78 objects_below=[(41, 80,
"helix_2")],
83 output_objects.append(mr)
86 mr.create_membrane_density()
97 IMP.pmi.tools.shuffle_configuration(hier, max_translation=300)
98 print(dof.get_movers())
107 crosslink_restraints=rmf_restraints,
108 monte_carlo_sample_objects=dof.get_movers(),
109 replica_exchange_maximum_temperature=3.0,
110 global_output_directory=
"output/",
111 output_objects=output_objects,
112 monte_carlo_steps=10,
113 number_of_frames=frames,
114 number_of_best_scoring_models=0)