1 """@namespace IMP.pmi.restraints.npc
2 Specialized restraints for modeling the Nuclear Pore Complex.
4 These restraints have been used to model the Nuclear Pore Complex (NPC)
5 but may be useful for other applications too. They model the NPC as lying
6 in the xy plane, centered at the origin. (Transport through the pore
7 corresponds to movement along the z axis.) The surface of the nuclear
8 membrane is represented as the surface of a half torus, also lying in
9 the xy plane and centered at the origin. Individual proteins
10 (or parts of proteins, such as the N- or C- termini) are then localized to
11 different regions of the complex (e.g. near the membrane or pore, or on
12 the nuclear or cytoplasmic side) by simple restraints on ther Cartesian
20 """Restrain a protein's distance from the z axis to within a given range.
22 def __init__(self, hier, protein, lower_bound=0.0, upper_bound=0.0,
23 consider_radius=
False, sigma=1.0, term=
'C', label=
None,
28 super(XYRadialPositionRestraint, self).
__init__(
29 hier.get_model(), label=label, weight=weight)
32 self.model, lower_bound, upper_bound, consider_radius, sigma)
34 hier, protein, resolution=1)
36 terminal = residues[-1]
38 xyr.add_particle(terminal)
40 terminal = residues[0]
42 xyr.add_particle(terminal)
44 for residue
in residues:
46 xyr.add_particle(residue)
49 for p, state
in IMP.pmi.tools._all_protocol_outputs(hier):
50 p.add_xyradial_restraint(state, residues, lower_bound,
51 upper_bound, sigma, self)
53 self.rs.add_restraint(xyr)
57 """Restrain a protein's distance from the z axis to above a lower bound.
59 def __init__(self, hier, protein, lower_bound=0.0,
60 consider_radius=
False, sigma=1.0, label=
None, weight=1.0):
64 super(XYRadialPositionLowerRestraint, self).
__init__(
65 hier.get_model(), label=label, weight=weight)
68 self.model, lower_bound, consider_radius, sigma)
70 hier, protein, resolution=1)
71 cterminal = residues[-1]
73 xyr.add_particle(cterminal)
74 self.rs.add_restraint(xyr)
78 """Restrain a protein's distance from the z axis to below an upper bound.
80 def __init__(self, hier, protein, upper_bound=0.0,
81 consider_radius=
False, sigma=1.0, label=
None, weight=1.0):
85 super(XYRadialPositionUpperRestraint, self).
__init__(
86 hier.get_model(), label=label, weight=weight)
89 self.model, upper_bound, consider_radius, sigma)
91 hier, protein, resolution=1)
92 cterminal = residues[-1]
94 xyr.add_particle(cterminal)
95 self.rs.add_restraint(xyr)
99 """Restrain a protein's z coordinate to within a given range.
102 upper_bound=0.0, consider_radius=
False, sigma=1.0, term=
'C',
103 label=
None, weight=1.0):
107 super(ZAxialPositionRestraint, self).
__init__(
108 hier.get_model(), label=label, weight=weight)
111 self.model, lower_bound, upper_bound, consider_radius, sigma)
113 hier, protein, resolution=1)
115 terminal = residues[-1]
117 zax.add_particle(terminal)
119 terminal = residues[0]
121 zax.add_particle(terminal)
123 for residue
in residues:
125 zax.add_particle(residue)
128 for p, state
in IMP.pmi.tools._all_protocol_outputs(hier):
129 p.add_zaxial_restraint(state, residues, lower_bound,
130 upper_bound, sigma, self)
132 self.rs.add_restraint(zax)
136 """Restrain a protein's z coordinate to above a lower bound.
139 consider_radius=
False, sigma=1.0, label=
None, weight=1.0):
143 super(ZAxialPositionLowerRestraint, self).
__init__(
144 hier.get_model(), label=label, weight=weight)
147 self.model, lower_bound, consider_radius, sigma)
149 hier, protein, resolution=1)
150 cterminal = residues[-1]
152 zax.add_particle(cterminal)
153 self.rs.add_restraint(zax)
157 """Restrain a protein's z coordinate to below an upper bound.
160 consider_radius=
False, sigma=1.0, label=
None, weight=1.0):
164 super(ZAxialPositionUpperRestraint, self).
__init__(
165 hier.get_model(), label=label, weight=weight)
168 self.model, upper_bound, consider_radius, sigma)
170 hier, protein, resolution=1)
171 cterminal = residues[-1]
173 zax.add_particle(cterminal)
174 self.rs.add_restraint(zax)
178 """Restrain a protein's y coordinate to within a given range.
181 upper_bound=0.0, consider_radius=
False, sigma=1.0, term=
'C',
182 label=
None, weight=1.0):
186 super(YAxialPositionRestraint, self).
__init__(
187 hier.get_model(), label=label, weight=weight)
190 self.model, lower_bound, upper_bound, consider_radius, sigma)
192 hier, protein, resolution=1)
194 terminal = residues[-1]
196 yax.add_particle(terminal)
198 terminal = residues[0]
200 yax.add_particle(terminal)
202 for residue
in residues:
204 yax.add_particle(residue)
207 for p, state
in IMP.pmi.tools._all_protocol_outputs(hier):
208 p.add_yaxial_restraint(state, residues, lower_bound,
209 upper_bound, sigma, self)
211 self.rs.add_restraint(yax)
215 """Restrain a protein's y coordinate to above a lower bound.
218 consider_radius=
False, sigma=1.0, label=
None, weight=1.0):
222 super(YAxialPositionLowerRestraint, self).
__init__(
223 hier.get_model(), label=label, weight=weight)
226 self.model, lower_bound, consider_radius, sigma)
228 hier, protein, resolution=1)
229 cterminal = residues[-1]
231 yax.add_particle(cterminal)
232 self.rs.add_restraint(yax)
236 """Restrain a protein's y coordinate to below an upper bound.
239 consider_radius=
False, sigma=1.0, label=
None, weight=1.0):
243 super(YAxialPositionUpperRestraint, self).
__init__(
244 hier.get_model(), label=label, weight=weight)
247 self.model, upper_bound, consider_radius, sigma)
249 hier, protein, resolution=1)
250 cterminal = residues[-1]
252 yax.add_particle(cterminal)
253 self.rs.add_restraint(yax)
257 """Localize protein on the surface of a half torus in the xy plane.
260 tor_R=540.0, tor_r=127.5, tor_th=45.0, sigma=0.2,
261 resolution=1, label=
None, weight=1.0):
265 super(MembraneSurfaceLocationRestraint, self).
__init__(
266 hier.get_model(), label=label, weight=weight)
269 self.model, tor_R, tor_r, tor_th, sigma)
271 hier, protein, resolution=resolution)
272 for residue
in residues:
274 msl.add_particle(residue)
277 for p, state
in IMP.pmi.tools._all_protocol_outputs(hier):
278 p.add_membrane_surface_location_restraint(
279 state, residues, tor_R, tor_r, tor_th, sigma, self)
281 self.rs.add_restraint(msl)
285 IMP.pmi.restraints.RestraintBase):
286 """Localize one protein on the surface of a half torus in the xy plane.
288 Create Membrane Surface Location CONDITIONAL Restraint
289 for Nup120 ALPS Motifs - Mutually Exclusive from (135,152,'Nup120')
290 and (197,216,'Nup120').
291 It returns a minimum penalty score from two potential ALPS motifs.
294 tor_R=540.0, tor_r=127.5, tor_th=45.0, sigma=0.2,
295 resolution=1, label=
None, weight=1.0):
299 super(MembraneSurfaceLocationConditionalRestraint, self).
__init__(
300 hier.get_model(), label=label, weight=weight)
303 self.model, tor_R, tor_r, tor_th, sigma)
305 hier, protein1, resolution=resolution)
306 for residue
in residues1:
308 msl.add_particle1(residue)
310 hier, protein2, resolution=resolution)
311 for residue
in residues2:
313 msl.add_particle2(residue)
317 for p, state
in IMP.pmi.tools._all_protocol_outputs(hier):
318 for residues
in residues1, residues2:
319 p.add_membrane_surface_location_restraint(
320 state, residues, tor_R, tor_r, tor_th, sigma, self)
322 self.rs.add_restraint(msl)
326 """Keep protein away from a half torus in the xy plane.
329 tor_R=540.0, tor_r=127.5, tor_th=45.0, sigma=0.2,
330 resolution=1, label=
None, weight=1.0):
334 super(MembraneExclusionRestraint, self).
__init__(
335 hier.get_model(), label=label, weight=weight)
338 self.model, tor_R, tor_r, tor_th, sigma)
340 hier, protein, resolution=resolution)
341 for residue
in residues:
342 mex.add_particle(residue)
345 for p, state
in IMP.pmi.tools._all_protocol_outputs(hier):
346 p.add_membrane_exclusion_restraint(
347 state, residues, tor_R, tor_r, tor_th, sigma, self)
349 self.rs.add_restraint(mex)
Restrain a protein's y coordinate to above a lower bound.
Restrain a protein's z coordinate to within a given range.
Keep protein away from a half torus in the xy plane.
Restrain a protein's distance from the z axis to within a given range.
Restrain particles by their z coordinate.
Restrain particles by their y coordinate.
Restrain particles by their distance from the z axis in the xy plane.
Try to keep one set of particles localized on a membrane surface.
Restrain particles by their z coordinate.
Restrain a protein's distance from the z axis to above a lower bound.
Try to keep particles away from a membrane.
Restrain a protein's y coordinate to within a given range.
Restrain particles by their distance from the z axis in the xy plane.
Localize one protein on the surface of a half torus in the xy plane.
Try to keep particles localized on a membrane surface.
Restrain a protein's distance from the z axis to below an upper bound.
Restrain a protein's z coordinate to below an upper bound.
Localize protein on the surface of a half torus in the xy plane.
Restrain a protein's y coordinate to below an upper bound.
Restraints designed for modeling the Nuclear Pore Complex (NPC)
Restrain particles by their z coordinate.
Restrain particles by their distance from the z axis in the xy plane.
Restrain a protein's z coordinate to above a lower bound.
Restrain particles by their y coordinate.
Restrain particles by their y coordinate.