IMP logo
IMP Reference Guide  develop.345e71cb9a,2026/08/09
The Integrative Modeling Platform
core/__init__.py
1 # This file was automatically generated by SWIG (https://www.swig.org).
2 # Version 4.5.0
3 #
4 # Do not make changes to this file unless you know what you are doing - modify
5 # the SWIG interface file instead.
6 
7 
8 # This wrapper is part of IMP,
9 # Copyright 2007-2026 IMP Inventors. All rights reserved.
10 
11 
12 
13 import functools
14 
15 
16 
17 import typing
18 import _IMP_core
19 
20 import builtins as __builtin__
21 
22 def _swig_repr(self):
23  try:
24  strthis = "proxy of " + self.this.__repr__()
25  except __builtin__.Exception:
26  strthis = ""
27  return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,)
28 
29 
30 def _swig_setattr_nondynamic_instance_variable(set):
31  def set_instance_attr(self, name, value):
32  if name == "this":
33  set(self, name, value)
34  elif name == "thisown":
35  self.this.own(value)
36  elif hasattr(self, name) and isinstance(getattr(type(self), name), property):
37  set(self, name, value)
38  else:
39  raise AttributeError("You cannot add instance attributes to %s" % self)
40  return set_instance_attr
41 
42 
43 def _swig_setattr_nondynamic_class_variable(set):
44  def set_class_attr(cls, name, value):
45  if hasattr(cls, name) and not isinstance(getattr(cls, name), property):
46  set(cls, name, value)
47  else:
48  raise AttributeError("You cannot add class attributes to %s" % cls)
49  return set_class_attr
50 
51 
52 class _SwigNonDynamicMeta(type):
53  """Meta class to enforce nondynamic attributes (no new attributes) for a class"""
54  __setattr__ = _swig_setattr_nondynamic_class_variable(type.__setattr__)
55 
56 
57 import weakref
58 
59 class IMP_CORE_SwigPyIterator(object):
60  r"""Proxy of C++ swig::IMP_CORE_SwigPyIterator class."""
61 
62  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
63 
64  def __init__(self, *args, **kwargs):
65  raise AttributeError("No constructor defined - class is abstract")
66  __repr__ = _swig_repr
67  __swig_destroy__ = _IMP_core.delete_IMP_CORE_SwigPyIterator
68 
69  def value(self):
70  r"""value(IMP_CORE_SwigPyIterator self) -> PyObject *"""
71  return _IMP_core.IMP_CORE_SwigPyIterator_value(self)
72 
73  def incr(self, n=1):
74  r"""incr(IMP_CORE_SwigPyIterator self, size_t n=1) -> IMP_CORE_SwigPyIterator"""
75  return _IMP_core.IMP_CORE_SwigPyIterator_incr(self, n)
76 
77  def decr(self, n=1):
78  r"""decr(IMP_CORE_SwigPyIterator self, size_t n=1) -> IMP_CORE_SwigPyIterator"""
79  return _IMP_core.IMP_CORE_SwigPyIterator_decr(self, n)
80 
81  def distance(self, x):
82  r"""distance(IMP_CORE_SwigPyIterator self, IMP_CORE_SwigPyIterator x) -> ptrdiff_t"""
83  return _IMP_core.IMP_CORE_SwigPyIterator_distance(self, x)
84 
85  def equal(self, x):
86  r"""equal(IMP_CORE_SwigPyIterator self, IMP_CORE_SwigPyIterator x) -> bool"""
87  return _IMP_core.IMP_CORE_SwigPyIterator_equal(self, x)
88 
89  def copy(self):
90  r"""copy(IMP_CORE_SwigPyIterator self) -> IMP_CORE_SwigPyIterator"""
91  return _IMP_core.IMP_CORE_SwigPyIterator_copy(self)
92 
93  def __next__(self):
94  r"""__next__(IMP_CORE_SwigPyIterator self) -> PyObject *"""
95  return _IMP_core.IMP_CORE_SwigPyIterator___next__(self)
96 
97  def previous(self):
98  r"""previous(IMP_CORE_SwigPyIterator self) -> PyObject *"""
99  return _IMP_core.IMP_CORE_SwigPyIterator_previous(self)
100 
101  def advance(self, n):
102  r"""advance(IMP_CORE_SwigPyIterator self, ptrdiff_t n) -> IMP_CORE_SwigPyIterator"""
103  return _IMP_core.IMP_CORE_SwigPyIterator_advance(self, n)
104 
105  def __eq__(self, x):
106  r"""__eq__(IMP_CORE_SwigPyIterator self, IMP_CORE_SwigPyIterator x) -> bool"""
107  return _IMP_core.IMP_CORE_SwigPyIterator___eq__(self, x)
108 
109  def __ne__(self, x):
110  r"""__ne__(IMP_CORE_SwigPyIterator self, IMP_CORE_SwigPyIterator x) -> bool"""
111  return _IMP_core.IMP_CORE_SwigPyIterator___ne__(self, x)
112 
113  def __iadd__(self, n):
114  r"""__iadd__(IMP_CORE_SwigPyIterator self, ptrdiff_t n) -> IMP_CORE_SwigPyIterator"""
115  return _IMP_core.IMP_CORE_SwigPyIterator___iadd__(self, n)
116 
117  def __isub__(self, n):
118  r"""__isub__(IMP_CORE_SwigPyIterator self, ptrdiff_t n) -> IMP_CORE_SwigPyIterator"""
119  return _IMP_core.IMP_CORE_SwigPyIterator___isub__(self, n)
120 
121  def __add__(self, n):
122  r"""__add__(IMP_CORE_SwigPyIterator self, ptrdiff_t n) -> IMP_CORE_SwigPyIterator"""
123  return _IMP_core.IMP_CORE_SwigPyIterator___add__(self, n)
124 
125  def __sub__(self, *args):
126  r"""
127  __sub__(IMP_CORE_SwigPyIterator self, ptrdiff_t n) -> IMP_CORE_SwigPyIterator
128  __sub__(IMP_CORE_SwigPyIterator self, IMP_CORE_SwigPyIterator x) -> ptrdiff_t
129  """
130  return _IMP_core.IMP_CORE_SwigPyIterator___sub__(self, *args)
131  def __iter__(self):
132  return self
133 
134 # Register IMP_CORE_SwigPyIterator in _IMP_core:
135 _IMP_core.IMP_CORE_SwigPyIterator_swigregister(IMP_CORE_SwigPyIterator)
136 
137 _value_types=[]
138 _object_types=[]
139 _raii_types=[]
140 _plural_types=[]
141 
142 IMP_DEBUG = _IMP_core.IMP_DEBUG
143 
144 IMP_RELEASE = _IMP_core.IMP_RELEASE
145 
146 IMP_SILENT = _IMP_core.IMP_SILENT
147 
148 IMP_PROGRESS = _IMP_core.IMP_PROGRESS
149 
150 IMP_TERSE = _IMP_core.IMP_TERSE
151 
152 IMP_VERBOSE = _IMP_core.IMP_VERBOSE
153 
154 IMP_MEMORY = _IMP_core.IMP_MEMORY
155 
156 IMP_NONE = _IMP_core.IMP_NONE
157 
158 IMP_USAGE = _IMP_core.IMP_USAGE
159 
160 IMP_INTERNAL = _IMP_core.IMP_INTERNAL
161 
162 IMP_KERNEL_HAS_LOG4CXX = _IMP_core.IMP_KERNEL_HAS_LOG4CXX
163 
164 IMP_COMPILER_HAS_CEREAL_RAW_POINTER = _IMP_core.IMP_COMPILER_HAS_CEREAL_RAW_POINTER
165 
166 IMP_COMPILER_HAS_DEBUG_VECTOR = _IMP_core.IMP_COMPILER_HAS_DEBUG_VECTOR
167 
168 IMP_COMPILER_HAS_RANDOM_SHUFFLE = _IMP_core.IMP_COMPILER_HAS_RANDOM_SHUFFLE
169 
170 IMP_COMPILER_HAS_THREE_WAY = _IMP_core.IMP_COMPILER_HAS_THREE_WAY
171 
172 IMP_KERNEL_HAS_BOOST_RANDOM = _IMP_core.IMP_KERNEL_HAS_BOOST_RANDOM
173 
174 IMP_KERNEL_HAS_NUMPY = _IMP_core.IMP_KERNEL_HAS_NUMPY
175 
176 IMP_KERNEL_HAS_BOOST_SYSTEM = _IMP_core.IMP_KERNEL_HAS_BOOST_SYSTEM
177 
178 IMP_KERNEL_HAS_GPERFTOOLS = _IMP_core.IMP_KERNEL_HAS_GPERFTOOLS
179 
180 IMP_KERNEL_HAS_TCMALLOC_HEAPCHECKER = _IMP_core.IMP_KERNEL_HAS_TCMALLOC_HEAPCHECKER
181 
182 IMP_KERNEL_HAS_TCMALLOC_HEAPPROFILER = _IMP_core.IMP_KERNEL_HAS_TCMALLOC_HEAPPROFILER
183 
184 IMPKERNEL_SHOW_WARNINGS = _IMP_core.IMPKERNEL_SHOW_WARNINGS
185 
186 
187 import sys
188 class _DirectorObjects:
189  """@internal Simple class to keep references to director objects
190  to prevent premature deletion."""
191  def __init__(self):
192  self._objects = []
193  def register(self, obj):
194  """Take a reference to a director object; will only work for
195  refcounted C++ classes"""
196  if hasattr(obj, 'get_ref_count'):
197  self._objects.append(obj)
198  def cleanup(self):
199  """Only drop our reference and allow cleanup by Python if no other
200  Python references exist (we hold 3 references: one in self._objects,
201  one in x, and one in the argument list for getrefcount) *and* no
202  other C++ references exist (the Python object always holds one)"""
203  objs = [x for x in self._objects if sys.getrefcount(x) > 3 \
204  or x.get_ref_count() > 1]
205 # Do in two steps so the references are kept until the end of the
206 # function (deleting references may trigger a fresh call to this method)
207  self._objects = objs
208  def get_object_count(self):
209  """Get number of director objects (useful for testing only)"""
210  return len(self._objects)
211 _director_objects = _DirectorObjects()
212 
213 class _ostream(object):
214  r"""Proxy of C++ std::ostream class."""
215 
216  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
217 
218  def __init__(self, *args, **kwargs):
219  raise AttributeError("No constructor defined")
220  __repr__ = _swig_repr
221 
222  def write(self, osa_buf):
223  r"""write(_ostream self, char const * osa_buf)"""
224  return _IMP_core._ostream_write(self, osa_buf)
225 
226 # Register _ostream in _IMP_core:
227 _IMP_core._ostream_swigregister(_ostream)
228 IMP_C_OPEN_BINARY = _IMP_core.IMP_C_OPEN_BINARY
229 
230 import IMP
231 IMP_CGAL_HAS_BOOST_FILESYSTEM = _IMP_core.IMP_CGAL_HAS_BOOST_FILESYSTEM
232 
233 IMP_CGAL_HAS_BOOST_PROGRAMOPTIONS = _IMP_core.IMP_CGAL_HAS_BOOST_PROGRAMOPTIONS
234 
235 IMP_CGAL_HAS_BOOST_RANDOM = _IMP_core.IMP_CGAL_HAS_BOOST_RANDOM
236 
237 IMP_CGAL_HAS_NUMPY = _IMP_core.IMP_CGAL_HAS_NUMPY
238 
239 IMPCGAL_SHOW_WARNINGS = _IMP_core.IMPCGAL_SHOW_WARNINGS
240 
241 import IMP.cgal
242 IMP_ALGEBRA_HAS_IMP_CGAL = _IMP_core.IMP_ALGEBRA_HAS_IMP_CGAL
243 
244 IMP_ALGEBRA_HAS_BOOST_FILESYSTEM = _IMP_core.IMP_ALGEBRA_HAS_BOOST_FILESYSTEM
245 
246 IMP_ALGEBRA_HAS_BOOST_PROGRAMOPTIONS = _IMP_core.IMP_ALGEBRA_HAS_BOOST_PROGRAMOPTIONS
247 
248 IMP_ALGEBRA_HAS_BOOST_RANDOM = _IMP_core.IMP_ALGEBRA_HAS_BOOST_RANDOM
249 
250 IMP_ALGEBRA_HAS_CGAL = _IMP_core.IMP_ALGEBRA_HAS_CGAL
251 
252 IMP_ALGEBRA_HAS_NUMPY = _IMP_core.IMP_ALGEBRA_HAS_NUMPY
253 
254 IMP_ALGEBRA_HAS_ANN = _IMP_core.IMP_ALGEBRA_HAS_ANN
255 
256 IMPALGEBRA_SHOW_WARNINGS = _IMP_core.IMPALGEBRA_SHOW_WARNINGS
257 
258 import IMP.algebra
259 IMP_DISPLAY_HAS_IMP_CGAL = _IMP_core.IMP_DISPLAY_HAS_IMP_CGAL
260 
261 IMP_DISPLAY_HAS_BOOST_FILESYSTEM = _IMP_core.IMP_DISPLAY_HAS_BOOST_FILESYSTEM
262 
263 IMP_DISPLAY_HAS_BOOST_PROGRAMOPTIONS = _IMP_core.IMP_DISPLAY_HAS_BOOST_PROGRAMOPTIONS
264 
265 IMP_DISPLAY_HAS_BOOST_RANDOM = _IMP_core.IMP_DISPLAY_HAS_BOOST_RANDOM
266 
267 IMP_DISPLAY_HAS_CGAL = _IMP_core.IMP_DISPLAY_HAS_CGAL
268 
269 IMP_DISPLAY_HAS_NUMPY = _IMP_core.IMP_DISPLAY_HAS_NUMPY
270 
271 IMPDISPLAY_SHOW_WARNINGS = _IMP_core.IMPDISPLAY_SHOW_WARNINGS
272 
273 import IMP.display
274 IMP_SCORE_FUNCTOR_HAS_IMP_CGAL = _IMP_core.IMP_SCORE_FUNCTOR_HAS_IMP_CGAL
275 
276 IMP_SCORE_FUNCTOR_HAS_BOOST_FILESYSTEM = _IMP_core.IMP_SCORE_FUNCTOR_HAS_BOOST_FILESYSTEM
277 
278 IMP_SCORE_FUNCTOR_HAS_BOOST_PROGRAMOPTIONS = _IMP_core.IMP_SCORE_FUNCTOR_HAS_BOOST_PROGRAMOPTIONS
279 
280 IMP_SCORE_FUNCTOR_HAS_BOOST_RANDOM = _IMP_core.IMP_SCORE_FUNCTOR_HAS_BOOST_RANDOM
281 
282 IMP_SCORE_FUNCTOR_HAS_CGAL = _IMP_core.IMP_SCORE_FUNCTOR_HAS_CGAL
283 
284 IMP_SCORE_FUNCTOR_HAS_HDF5 = _IMP_core.IMP_SCORE_FUNCTOR_HAS_HDF5
285 
286 IMP_SCORE_FUNCTOR_HAS_NUMPY = _IMP_core.IMP_SCORE_FUNCTOR_HAS_NUMPY
287 
288 IMPSCOREFUNCTOR_SHOW_WARNINGS = _IMP_core.IMPSCOREFUNCTOR_SHOW_WARNINGS
289 
290 import IMP.score_functor
291 IMP_CORE_HAS_IMP_CGAL = _IMP_core.IMP_CORE_HAS_IMP_CGAL
292 
293 IMP_CORE_HAS_IMP_KERNEL = _IMP_core.IMP_CORE_HAS_IMP_KERNEL
294 
295 IMP_CORE_HAS_BOOST_FILESYSTEM = _IMP_core.IMP_CORE_HAS_BOOST_FILESYSTEM
296 
297 IMP_CORE_HAS_BOOST_PROGRAMOPTIONS = _IMP_core.IMP_CORE_HAS_BOOST_PROGRAMOPTIONS
298 
299 IMP_CORE_HAS_BOOST_RANDOM = _IMP_core.IMP_CORE_HAS_BOOST_RANDOM
300 
301 IMP_CORE_HAS_CGAL = _IMP_core.IMP_CORE_HAS_CGAL
302 
303 IMP_CORE_HAS_HDF5 = _IMP_core.IMP_CORE_HAS_HDF5
304 
305 IMP_CORE_HAS_NUMPY = _IMP_core.IMP_CORE_HAS_NUMPY
306 
307 IMPCORE_SHOW_WARNINGS = _IMP_core.IMPCORE_SHOW_WARNINGS
308 
309 class _OpenCubicSplineBase(IMP.UnaryFunction):
310  r"""Proxy of C++ IMP::score_functor::ScoreUnaryFunction< IMP::score_functor::OpenCubicSpline > class."""
311 
312  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
313  __repr__ = _swig_repr
314 
315  def __init__(self, *args):
316  r"""__init__(_OpenCubicSplineBase self, IMP::score_functor::OpenCubicSpline const & score, std::string name="UnaryFunction%1%") -> _OpenCubicSplineBase"""
317  _IMP_core._OpenCubicSplineBase_swiginit(self, _IMP_core.new__OpenCubicSplineBase(*args))
318 
319  def get_version_info(self):
320  r"""get_version_info(_OpenCubicSplineBase self) -> VersionInfo"""
321  return _IMP_core._OpenCubicSplineBase_get_version_info(self)
322  __swig_destroy__ = _IMP_core.delete__OpenCubicSplineBase
323 
324 # Register _OpenCubicSplineBase in _IMP_core:
325 _IMP_core._OpenCubicSplineBase_swigregister(_OpenCubicSplineBase)
326 
327 _object_types.append("MonteCarloMover")
328 
329 
330 def _object_cast_to_MonteCarloMover(o):
331  r"""_object_cast_to_MonteCarloMover(Object o) -> MonteCarloMover"""
332  return _IMP_core._object_cast_to_MonteCarloMover(o)
333 
334 MonteCarloMoverResults=list
335 _plural_types.append("MonteCarloMoverResults")
336 _value_types.append("MonteCarloMoverResult")
337 
338 
339 _object_types.append("AngleRestraint")
340 
341 
342 def _object_cast_to_AngleRestraint(o):
343  r"""_object_cast_to_AngleRestraint(Object o) -> AngleRestraint"""
344  return _IMP_core._object_cast_to_AngleRestraint(o)
345 
346 _object_types.append("AngleTripletScore")
347 
348 
349 def _object_cast_to_AngleTripletScore(o):
350  r"""_object_cast_to_AngleTripletScore(Object o) -> AngleTripletScore"""
351  return _IMP_core._object_cast_to_AngleTripletScore(o)
352 
353 _object_types.append("AttributeSingletonScore")
354 
355 
356 def _object_cast_to_AttributeSingletonScore(o):
357  r"""_object_cast_to_AttributeSingletonScore(Object o) -> AttributeSingletonScore"""
358  return _IMP_core._object_cast_to_AttributeSingletonScore(o)
359 
360 _object_types.append("BallMover")
361 
362 
363 def _object_cast_to_BallMover(o):
364  r"""_object_cast_to_BallMover(Object o) -> BallMover"""
365  return _IMP_core._object_cast_to_BallMover(o)
366 
367 _object_types.append("SerialMover")
368 
369 
370 def _object_cast_to_SerialMover(o):
371  r"""_object_cast_to_SerialMover(Object o) -> SerialMover"""
372  return _IMP_core._object_cast_to_SerialMover(o)
373 
374 _object_types.append("SubsetMover")
375 
376 
377 def _object_cast_to_SubsetMover(o):
378  r"""_object_cast_to_SubsetMover(Object o) -> SubsetMover"""
379  return _IMP_core._object_cast_to_SubsetMover(o)
380 
381 _object_types.append("DirectionMover")
382 
383 
384 def _object_cast_to_DirectionMover(o):
385  r"""_object_cast_to_DirectionMover(Object o) -> DirectionMover"""
386  return _IMP_core._object_cast_to_DirectionMover(o)
387 
388 _object_types.append("SurfaceMover")
389 
390 
391 def _object_cast_to_SurfaceMover(o):
392  r"""_object_cast_to_SurfaceMover(Object o) -> SurfaceMover"""
393  return _IMP_core._object_cast_to_SurfaceMover(o)
394 
395 _object_types.append("BoundingBox3DSingletonScore")
396 
397 
398 def _object_cast_to_BoundingBox3DSingletonScore(o):
399  r"""_object_cast_to_BoundingBox3DSingletonScore(Object o) -> BoundingBox3DSingletonScore"""
400  return _IMP_core._object_cast_to_BoundingBox3DSingletonScore(o)
401 
402 _object_types.append("BoundingSphere3DSingletonScore")
403 
404 
405 def _object_cast_to_BoundingSphere3DSingletonScore(o):
406  r"""_object_cast_to_BoundingSphere3DSingletonScore(Object o) -> BoundingSphere3DSingletonScore"""
407  return _IMP_core._object_cast_to_BoundingSphere3DSingletonScore(o)
408 
409 _object_types.append("BoxSweepClosePairsFinder")
410 
411 
412 def _object_cast_to_BoxSweepClosePairsFinder(o):
413  r"""_object_cast_to_BoxSweepClosePairsFinder(Object o) -> BoxSweepClosePairsFinder"""
414  return _IMP_core._object_cast_to_BoxSweepClosePairsFinder(o)
415 
416 _object_types.append("NearestNeighborsClosePairsFinder")
417 
418 
419 def _object_cast_to_NearestNeighborsClosePairsFinder(o):
420  r"""_object_cast_to_NearestNeighborsClosePairsFinder(Object o) -> NearestNeighborsClosePairsFinder"""
421  return _IMP_core._object_cast_to_NearestNeighborsClosePairsFinder(o)
422 
423 _object_types.append("CentroidOfRefined")
424 
425 
426 def _object_cast_to_CentroidOfRefined(o):
427  r"""_object_cast_to_CentroidOfRefined(Object o) -> CentroidOfRefined"""
428  return _IMP_core._object_cast_to_CentroidOfRefined(o)
429 
430 _object_types.append("ChecksScoreState")
431 
432 
433 def _object_cast_to_ChecksScoreState(o):
434  r"""_object_cast_to_ChecksScoreState(Object o) -> ChecksScoreState"""
435  return _IMP_core._object_cast_to_ChecksScoreState(o)
436 
437 _object_types.append("ChildrenRefiner")
438 
439 
440 def _object_cast_to_ChildrenRefiner(o):
441  r"""_object_cast_to_ChildrenRefiner(Object o) -> ChildrenRefiner"""
442  return _IMP_core._object_cast_to_ChildrenRefiner(o)
443 
444 _object_types.append("ClosePairsFinder")
445 
446 
447 def _object_cast_to_ClosePairsFinder(o):
448  r"""_object_cast_to_ClosePairsFinder(Object o) -> ClosePairsFinder"""
449  return _IMP_core._object_cast_to_ClosePairsFinder(o)
450 
451 _object_types.append("ClosePairsPairScore")
452 
453 
454 def _object_cast_to_ClosePairsPairScore(o):
455  r"""_object_cast_to_ClosePairsPairScore(Object o) -> ClosePairsPairScore"""
456  return _IMP_core._object_cast_to_ClosePairsPairScore(o)
457 
458 _object_types.append("ClosedCubicSpline")
459 
460 
461 def _object_cast_to_ClosedCubicSpline(o):
462  r"""_object_cast_to_ClosedCubicSpline(Object o) -> ClosedCubicSpline"""
463  return _IMP_core._object_cast_to_ClosedCubicSpline(o)
464 
465 _object_types.append("ConjugateGradients")
466 
467 
468 def _object_cast_to_ConjugateGradients(o):
469  r"""_object_cast_to_ConjugateGradients(Object o) -> ConjugateGradients"""
470  return _IMP_core._object_cast_to_ConjugateGradients(o)
471 
472 _object_types.append("ConnectivityRestraint")
473 
474 
475 def _object_cast_to_ConnectivityRestraint(o):
476  r"""_object_cast_to_ConnectivityRestraint(Object o) -> ConnectivityRestraint"""
477  return _IMP_core._object_cast_to_ConnectivityRestraint(o)
478 
479 _object_types.append("ConstantRestraint")
480 
481 
482 def _object_cast_to_ConstantRestraint(o):
483  r"""_object_cast_to_ConstantRestraint(Object o) -> ConstantRestraint"""
484  return _IMP_core._object_cast_to_ConstantRestraint(o)
485 
486 _object_types.append("Cosine")
487 
488 
489 def _object_cast_to_Cosine(o):
490  r"""_object_cast_to_Cosine(Object o) -> Cosine"""
491  return _IMP_core._object_cast_to_Cosine(o)
492 
493 _object_types.append("CoverRefined")
494 
495 
496 def _object_cast_to_CoverRefined(o):
497  r"""_object_cast_to_CoverRefined(Object o) -> CoverRefined"""
498  return _IMP_core._object_cast_to_CoverRefined(o)
499 
500 _object_types.append("DerivativesFromRefined")
501 
502 
503 def _object_cast_to_DerivativesFromRefined(o):
504  r"""_object_cast_to_DerivativesFromRefined(Object o) -> DerivativesFromRefined"""
505  return _IMP_core._object_cast_to_DerivativesFromRefined(o)
506 
507 _object_types.append("DerivativesToRefined")
508 
509 
510 def _object_cast_to_DerivativesToRefined(o):
511  r"""_object_cast_to_DerivativesToRefined(Object o) -> DerivativesToRefined"""
512  return _IMP_core._object_cast_to_DerivativesToRefined(o)
513 
514 _object_types.append("WeightedDerivativesToRefined")
515 
516 
517 def _object_cast_to_WeightedDerivativesToRefined(o):
518  r"""_object_cast_to_WeightedDerivativesToRefined(Object o) -> IMP::core::WeightedDerivativesToRefined *"""
519  return _IMP_core._object_cast_to_WeightedDerivativesToRefined(o)
520 
521 _object_types.append("DiameterRestraint")
522 
523 
524 def _object_cast_to_DiameterRestraint(o):
525  r"""_object_cast_to_DiameterRestraint(Object o) -> DiameterRestraint"""
526  return _IMP_core._object_cast_to_DiameterRestraint(o)
527 
528 _object_types.append("DihedralRestraint")
529 
530 
531 def _object_cast_to_DihedralRestraint(o):
532  r"""_object_cast_to_DihedralRestraint(Object o) -> DihedralRestraint"""
533  return _IMP_core._object_cast_to_DihedralRestraint(o)
534 
535 _object_types.append("DistanceRestraint")
536 
537 
538 def _object_cast_to_DistanceRestraint(o):
539  r"""_object_cast_to_DistanceRestraint(Object o) -> DistanceRestraint"""
540  return _IMP_core._object_cast_to_DistanceRestraint(o)
541 
542 _object_types.append("DistanceToSingletonScore")
543 
544 
545 def _object_cast_to_DistanceToSingletonScore(o):
546  r"""_object_cast_to_DistanceToSingletonScore(Object o) -> DistanceToSingletonScore"""
547  return _IMP_core._object_cast_to_DistanceToSingletonScore(o)
548 
549 _object_types.append("ExcludedVolumeRestraint")
550 
551 
552 def _object_cast_to_ExcludedVolumeRestraint(o):
553  r"""_object_cast_to_ExcludedVolumeRestraint(Object o) -> ExcludedVolumeRestraint"""
554  return _IMP_core._object_cast_to_ExcludedVolumeRestraint(o)
555 
556 _object_types.append("FixedRefiner")
557 
558 
559 def _object_cast_to_FixedRefiner(o):
560  r"""_object_cast_to_FixedRefiner(Object o) -> FixedRefiner"""
561  return _IMP_core._object_cast_to_FixedRefiner(o)
562 
563 _object_types.append("GridClosePairsFinder")
564 
565 
566 def _object_cast_to_GridClosePairsFinder(o):
567  r"""_object_cast_to_GridClosePairsFinder(Object o) -> GridClosePairsFinder"""
568  return _IMP_core._object_cast_to_GridClosePairsFinder(o)
569 
570 _object_types.append("Harmonic")
571 
572 
573 def _object_cast_to_Harmonic(o):
574  r"""_object_cast_to_Harmonic(Object o) -> Harmonic"""
575  return _IMP_core._object_cast_to_Harmonic(o)
576 
577 _object_types.append("HarmonicWell")
578 
579 
580 def _object_cast_to_HarmonicWell(o):
581  r"""_object_cast_to_HarmonicWell(Object o) -> HarmonicWell"""
582  return _IMP_core._object_cast_to_HarmonicWell(o)
583 
584 _object_types.append("HarmonicLowerBound")
585 
586 
587 def _object_cast_to_HarmonicLowerBound(o):
588  r"""_object_cast_to_HarmonicLowerBound(Object o) -> HarmonicLowerBound"""
589  return _IMP_core._object_cast_to_HarmonicLowerBound(o)
590 
591 _object_types.append("HarmonicUpperBound")
592 
593 
594 def _object_cast_to_HarmonicUpperBound(o):
595  r"""_object_cast_to_HarmonicUpperBound(Object o) -> HarmonicUpperBound"""
596  return _IMP_core._object_cast_to_HarmonicUpperBound(o)
597 
598 _object_types.append("HarmonicSphereDistancePairScore")
599 
600 
601 def _object_cast_to_HarmonicSphereDistancePairScore(o):
602  r"""_object_cast_to_HarmonicSphereDistancePairScore(Object o) -> HarmonicSphereDistancePairScore"""
603  return _IMP_core._object_cast_to_HarmonicSphereDistancePairScore(o)
604 
605 _object_types.append("HarmonicUpperBoundSphereDistancePairScore")
606 
607 
608 def _object_cast_to_HarmonicUpperBoundSphereDistancePairScore(o):
609  r"""_object_cast_to_HarmonicUpperBoundSphereDistancePairScore(Object o) -> HarmonicUpperBoundSphereDistancePairScore"""
610  return _IMP_core._object_cast_to_HarmonicUpperBoundSphereDistancePairScore(o)
611 
612 _object_types.append("HarmonicUpperBoundSphereDiameterPairScore")
613 
614 
615 def _object_cast_to_HarmonicUpperBoundSphereDiameterPairScore(o):
616  r"""_object_cast_to_HarmonicUpperBoundSphereDiameterPairScore(Object o) -> HarmonicUpperBoundSphereDiameterPairScore"""
617  return _IMP_core._object_cast_to_HarmonicUpperBoundSphereDiameterPairScore(o)
618 
619 _object_types.append("HarmonicSurfaceDistancePairScore")
620 
621 
622 def _object_cast_to_HarmonicSurfaceDistancePairScore(o):
623  r"""_object_cast_to_HarmonicSurfaceDistancePairScore(Object o) -> HarmonicSurfaceDistancePairScore"""
624  return _IMP_core._object_cast_to_HarmonicSurfaceDistancePairScore(o)
625 
626 _object_types.append("HarmonicSurfaceHeightPairScore")
627 
628 
629 def _object_cast_to_HarmonicSurfaceHeightPairScore(o):
630  r"""_object_cast_to_HarmonicSurfaceHeightPairScore(Object o) -> HarmonicSurfaceHeightPairScore"""
631  return _IMP_core._object_cast_to_HarmonicSurfaceHeightPairScore(o)
632 
633 _object_types.append("HarmonicSurfaceDepthPairScore")
634 
635 
636 def _object_cast_to_HarmonicSurfaceDepthPairScore(o):
637  r"""_object_cast_to_HarmonicSurfaceDepthPairScore(Object o) -> HarmonicSurfaceDepthPairScore"""
638  return _IMP_core._object_cast_to_HarmonicSurfaceDepthPairScore(o)
639 
640 _object_types.append("WeightedSum")
641 
642 
643 def _object_cast_to_WeightedSum(o):
644  r"""_object_cast_to_WeightedSum(Object o) -> WeightedSum"""
645  return _IMP_core._object_cast_to_WeightedSum(o)
646 
647 _object_types.append("WeightedSumOfExponential")
648 
649 
650 def _object_cast_to_WeightedSumOfExponential(o):
651  r"""_object_cast_to_WeightedSumOfExponential(Object o) -> WeightedSumOfExponential"""
652  return _IMP_core._object_cast_to_WeightedSumOfExponential(o)
653 
654 _object_types.append("KClosePairsPairScore")
655 
656 
657 def _object_cast_to_KClosePairsPairScore(o):
658  r"""_object_cast_to_KClosePairsPairScore(Object o) -> KClosePairsPairScore"""
659  return _IMP_core._object_cast_to_KClosePairsPairScore(o)
660 
661 _object_types.append("LeavesRefiner")
662 
663 
664 def _object_cast_to_LeavesRefiner(o):
665  r"""_object_cast_to_LeavesRefiner(Object o) -> LeavesRefiner"""
666  return _IMP_core._object_cast_to_LeavesRefiner(o)
667 
668 _object_types.append("Linear")
669 
670 
671 def _object_cast_to_Linear(o):
672  r"""_object_cast_to_Linear(Object o) -> Linear"""
673  return _IMP_core._object_cast_to_Linear(o)
674 
675 _object_types.append("LogNormalMover")
676 
677 
678 def _object_cast_to_LogNormalMover(o):
679  r"""_object_cast_to_LogNormalMover(Object o) -> LogNormalMover"""
680  return _IMP_core._object_cast_to_LogNormalMover(o)
681 
682 _object_types.append("MCCGSampler")
683 
684 
685 def _object_cast_to_MCCGSampler(o):
686  r"""_object_cast_to_MCCGSampler(Object o) -> MCCGSampler"""
687  return _IMP_core._object_cast_to_MCCGSampler(o)
688 
689 _object_types.append("MonteCarlo")
690 
691 
692 def _object_cast_to_MonteCarlo(o):
693  r"""_object_cast_to_MonteCarlo(Object o) -> MonteCarlo"""
694  return _IMP_core._object_cast_to_MonteCarlo(o)
695 
696 _object_types.append("MonteCarloWithLocalOptimization")
697 
698 
699 def _object_cast_to_MonteCarloWithLocalOptimization(o):
700  r"""_object_cast_to_MonteCarloWithLocalOptimization(Object o) -> MonteCarloWithLocalOptimization"""
701  return _IMP_core._object_cast_to_MonteCarloWithLocalOptimization(o)
702 
703 _object_types.append("MonteCarloWithBasinHopping")
704 
705 
706 def _object_cast_to_MonteCarloWithBasinHopping(o):
707  r"""_object_cast_to_MonteCarloWithBasinHopping(Object o) -> MonteCarloWithBasinHopping"""
708  return _IMP_core._object_cast_to_MonteCarloWithBasinHopping(o)
709 
710 _object_types.append("MSConnectivityRestraint")
711 
712 
713 def _object_cast_to_MSConnectivityRestraint(o):
714  r"""_object_cast_to_MSConnectivityRestraint(Object o) -> MSConnectivityRestraint"""
715  return _IMP_core._object_cast_to_MSConnectivityRestraint(o)
716 
717 _object_types.append("NeighborsTable")
718 
719 
720 def _object_cast_to_NeighborsTable(o):
721  r"""_object_cast_to_NeighborsTable(Object o) -> NeighborsTable"""
722  return _IMP_core._object_cast_to_NeighborsTable(o)
723 
724 _object_types.append("NormalMover")
725 
726 
727 def _object_cast_to_NormalMover(o):
728  r"""_object_cast_to_NormalMover(Object o) -> NormalMover"""
729  return _IMP_core._object_cast_to_NormalMover(o)
730 
731 _object_types.append("NormalizedSphereDistancePairScore")
732 
733 
734 def _object_cast_to_NormalizedSphereDistancePairScore(o):
735  r"""_object_cast_to_NormalizedSphereDistancePairScore(Object o) -> NormalizedSphereDistancePairScore"""
736  return _IMP_core._object_cast_to_NormalizedSphereDistancePairScore(o)
737 
738 _object_types.append("OpenCubicSpline")
739 
740 
741 def _object_cast_to_OpenCubicSpline(o):
742  r"""_object_cast_to_OpenCubicSpline(Object o) -> OpenCubicSpline"""
743  return _IMP_core._object_cast_to_OpenCubicSpline(o)
744 
745 _object_types.append("PairConstraint")
746 
747 
748 def _object_cast_to_PairConstraint(o):
749  r"""_object_cast_to_PairConstraint(Object o) -> PairConstraint"""
750  return _IMP_core._object_cast_to_PairConstraint(o)
751 
752 _object_types.append("PairRestraint")
753 
754 
755 def _object_cast_to_PairRestraint(o):
756  r"""_object_cast_to_PairRestraint(Object o) -> PairRestraint"""
757  return _IMP_core._object_cast_to_PairRestraint(o)
758 
759 _object_types.append("QuadConstraint")
760 
761 
762 def _object_cast_to_QuadConstraint(o):
763  r"""_object_cast_to_QuadConstraint(Object o) -> QuadConstraint"""
764  return _IMP_core._object_cast_to_QuadConstraint(o)
765 
766 _object_types.append("QuadRestraint")
767 
768 
769 def _object_cast_to_QuadRestraint(o):
770  r"""_object_cast_to_QuadRestraint(Object o) -> QuadRestraint"""
771  return _IMP_core._object_cast_to_QuadRestraint(o)
772 
773 _object_types.append("QuadraticClosePairsFinder")
774 
775 
776 def _object_cast_to_QuadraticClosePairsFinder(o):
777  r"""_object_cast_to_QuadraticClosePairsFinder(Object o) -> QuadraticClosePairsFinder"""
778  return _IMP_core._object_cast_to_QuadraticClosePairsFinder(o)
779 
780 _object_types.append("RefinedPairsPairScore")
781 
782 
783 def _object_cast_to_RefinedPairsPairScore(o):
784  r"""_object_cast_to_RefinedPairsPairScore(Object o) -> RefinedPairsPairScore"""
785  return _IMP_core._object_cast_to_RefinedPairsPairScore(o)
786 
787 _object_types.append("RestraintsScoringFunction")
788 
789 
790 def _object_cast_to_RestraintsScoringFunction(o):
791  r"""_object_cast_to_RestraintsScoringFunction(Object o) -> RestraintsScoringFunction"""
792  return _IMP_core._object_cast_to_RestraintsScoringFunction(o)
793 
794 _object_types.append("RigidBodyDistancePairScore")
795 
796 
797 def _object_cast_to_RigidBodyDistancePairScore(o):
798  r"""_object_cast_to_RigidBodyDistancePairScore(Object o) -> RigidBodyDistancePairScore"""
799  return _IMP_core._object_cast_to_RigidBodyDistancePairScore(o)
800 
801 _object_types.append("RigidBodyAnglePairScore")
802 
803 
804 def _object_cast_to_RigidBodyAnglePairScore(o):
805  r"""_object_cast_to_RigidBodyAnglePairScore(Object o) -> RigidBodyAnglePairScore"""
806  return _IMP_core._object_cast_to_RigidBodyAnglePairScore(o)
807 
808 _object_types.append("RigidBodyMover")
809 
810 
811 def _object_cast_to_RigidBodyMover(o):
812  r"""_object_cast_to_RigidBodyMover(Object o) -> RigidBodyMover"""
813  return _IMP_core._object_cast_to_RigidBodyMover(o)
814 
815 _object_types.append("RigidBodyTunneler")
816 
817 
818 def _object_cast_to_RigidBodyTunneler(o):
819  r"""_object_cast_to_RigidBodyTunneler(Object o) -> RigidBodyTunneler"""
820  return _IMP_core._object_cast_to_RigidBodyTunneler(o)
821 
822 _object_types.append("RigidBodyUmbrella")
823 
824 
825 def _object_cast_to_RigidBodyUmbrella(o):
826  r"""_object_cast_to_RigidBodyUmbrella(Object o) -> RigidBodyUmbrella"""
827  return _IMP_core._object_cast_to_RigidBodyUmbrella(o)
828 
829 _object_types.append("_UpdateRigidBodyMembers")
830 
831 
832 def _object_cast_to__UpdateRigidBodyMembers(o):
833  r"""_object_cast_to__UpdateRigidBodyMembers(Object o) -> _UpdateRigidBodyMembers"""
834  return _IMP_core._object_cast_to__UpdateRigidBodyMembers(o)
835 
836 _object_types.append("_AccumulateRigidBodyDerivatives")
837 
838 
839 def _object_cast_to__AccumulateRigidBodyDerivatives(o):
840  r"""_object_cast_to__AccumulateRigidBodyDerivatives(Object o) -> _AccumulateRigidBodyDerivatives"""
841  return _IMP_core._object_cast_to__AccumulateRigidBodyDerivatives(o)
842 
843 _object_types.append("_RigidBodyNormalizeConstraint")
844 
845 
846 def _object_cast_to__RigidBodyNormalizeConstraint(o):
847  r"""_object_cast_to__RigidBodyNormalizeConstraint(Object o) -> _RigidBodyNormalizeConstraint"""
848  return _IMP_core._object_cast_to__RigidBodyNormalizeConstraint(o)
849 
850 _object_types.append("_NormalizeRotation")
851 
852 
853 def _object_cast_to__NormalizeRotation(o):
854  r"""_object_cast_to__NormalizeRotation(Object o) -> _NormalizeRotation"""
855  return _IMP_core._object_cast_to__NormalizeRotation(o)
856 
857 _object_types.append("_RigidBodyPositionConstraint")
858 
859 
860 def _object_cast_to__RigidBodyPositionConstraint(o):
861  r"""_object_cast_to__RigidBodyPositionConstraint(Object o) -> _RigidBodyPositionConstraint"""
862  return _IMP_core._object_cast_to__RigidBodyPositionConstraint(o)
863 
864 _object_types.append("RigidClosePairsFinder")
865 
866 
867 def _object_cast_to_RigidClosePairsFinder(o):
868  r"""_object_cast_to_RigidClosePairsFinder(Object o) -> RigidClosePairsFinder"""
869  return _IMP_core._object_cast_to_RigidClosePairsFinder(o)
870 
871 _object_types.append("RigidMembersRefiner")
872 
873 
874 def _object_cast_to_RigidMembersRefiner(o):
875  r"""_object_cast_to_RigidMembersRefiner(Object o) -> RigidMembersRefiner"""
876  return _IMP_core._object_cast_to_RigidMembersRefiner(o)
877 
878 _object_types.append("SingletonConstraint")
879 
880 
881 def _object_cast_to_SingletonConstraint(o):
882  r"""_object_cast_to_SingletonConstraint(Object o) -> SingletonConstraint"""
883  return _IMP_core._object_cast_to_SingletonConstraint(o)
884 
885 _object_types.append("SingletonRestraint")
886 
887 
888 def _object_cast_to_SingletonRestraint(o):
889  r"""_object_cast_to_SingletonRestraint(Object o) -> SingletonRestraint"""
890  return _IMP_core._object_cast_to_SingletonRestraint(o)
891 
892 _object_types.append("SoftSpherePairScore")
893 
894 
895 def _object_cast_to_SoftSpherePairScore(o):
896  r"""_object_cast_to_SoftSpherePairScore(Object o) -> SoftSpherePairScore"""
897  return _IMP_core._object_cast_to_SoftSpherePairScore(o)
898 
899 _object_types.append("_SphereDistancePairScore")
900 
901 
902 def _object_cast_to__SphereDistancePairScore(o):
903  r"""_object_cast_to__SphereDistancePairScore(Object o) -> _SphereDistancePairScore"""
904  return _IMP_core._object_cast_to__SphereDistancePairScore(o)
905 
906 _object_types.append("SphereDistanceToSingletonScore")
907 
908 
909 def _object_cast_to_SphereDistanceToSingletonScore(o):
910  r"""_object_cast_to_SphereDistanceToSingletonScore(Object o) -> SphereDistanceToSingletonScore"""
911  return _IMP_core._object_cast_to_SphereDistanceToSingletonScore(o)
912 
913 _object_types.append("SoftSubSurfacePairScore")
914 
915 
916 def _object_cast_to_SoftSubSurfacePairScore(o):
917  r"""_object_cast_to_SoftSubSurfacePairScore(Object o) -> SoftSubSurfacePairScore"""
918  return _IMP_core._object_cast_to_SoftSubSurfacePairScore(o)
919 
920 _object_types.append("SoftSuperSurfacePairScore")
921 
922 
923 def _object_cast_to_SoftSuperSurfacePairScore(o):
924  r"""_object_cast_to_SoftSuperSurfacePairScore(Object o) -> SoftSuperSurfacePairScore"""
925  return _IMP_core._object_cast_to_SoftSuperSurfacePairScore(o)
926 
927 _object_types.append("SurfaceDistancePairScore")
928 
929 
930 def _object_cast_to_SurfaceDistancePairScore(o):
931  r"""_object_cast_to_SurfaceDistancePairScore(Object o) -> SurfaceDistancePairScore"""
932  return _IMP_core._object_cast_to_SurfaceDistancePairScore(o)
933 
934 _object_types.append("SurfaceHeightPairScore")
935 
936 
937 def _object_cast_to_SurfaceHeightPairScore(o):
938  r"""_object_cast_to_SurfaceHeightPairScore(Object o) -> SurfaceHeightPairScore"""
939  return _IMP_core._object_cast_to_SurfaceHeightPairScore(o)
940 
941 _object_types.append("SurfaceDepthPairScore")
942 
943 
944 def _object_cast_to_SurfaceDepthPairScore(o):
945  r"""_object_cast_to_SurfaceDepthPairScore(Object o) -> SurfaceDepthPairScore"""
946  return _IMP_core._object_cast_to_SurfaceDepthPairScore(o)
947 
948 _object_types.append("SurfaceTetheredChain")
949 
950 
951 def _object_cast_to_SurfaceTetheredChain(o):
952  r"""_object_cast_to_SurfaceTetheredChain(Object o) -> SurfaceTetheredChain"""
953  return _IMP_core._object_cast_to_SurfaceTetheredChain(o)
954 
955 _object_types.append("SurfaceSymmetryConstraint")
956 
957 
958 def _object_cast_to_SurfaceSymmetryConstraint(o):
959  r"""_object_cast_to_SurfaceSymmetryConstraint(Object o) -> SurfaceSymmetryConstraint"""
960  return _IMP_core._object_cast_to_SurfaceSymmetryConstraint(o)
961 
962 _object_types.append("SteepestDescent")
963 
964 
965 def _object_cast_to_SteepestDescent(o):
966  r"""_object_cast_to_SteepestDescent(Object o) -> SteepestDescent"""
967  return _IMP_core._object_cast_to_SteepestDescent(o)
968 
969 _object_types.append("TableRefiner")
970 
971 
972 def _object_cast_to_TableRefiner(o):
973  r"""_object_cast_to_TableRefiner(Object o) -> TableRefiner"""
974  return _IMP_core._object_cast_to_TableRefiner(o)
975 
976 _object_types.append("Transform")
977 
978 
979 def _object_cast_to_Transform(o):
980  r"""_object_cast_to_Transform(Object o) -> Transform"""
981  return _IMP_core._object_cast_to_Transform(o)
982 
983 _object_types.append("TransformationAndReflectionSymmetry")
984 
985 
986 def _object_cast_to_TransformationAndReflectionSymmetry(o):
987  r"""_object_cast_to_TransformationAndReflectionSymmetry(Object o) -> TransformationAndReflectionSymmetry"""
988  return _IMP_core._object_cast_to_TransformationAndReflectionSymmetry(o)
989 
990 _object_types.append("TransformationSymmetry")
991 
992 
993 def _object_cast_to_TransformationSymmetry(o):
994  r"""_object_cast_to_TransformationSymmetry(Object o) -> TransformationSymmetry"""
995  return _IMP_core._object_cast_to_TransformationSymmetry(o)
996 
997 _object_types.append("TransformationSymmetryMover")
998 
999 
1000 def _object_cast_to_TransformationSymmetryMover(o):
1001  r"""_object_cast_to_TransformationSymmetryMover(Object o) -> TransformationSymmetryMover"""
1002  return _IMP_core._object_cast_to_TransformationSymmetryMover(o)
1003 
1004 _object_types.append("TransformedDistancePairScore")
1005 
1006 
1007 def _object_cast_to_TransformedDistancePairScore(o):
1008  r"""_object_cast_to_TransformedDistancePairScore(Object o) -> TransformedDistancePairScore"""
1009  return _IMP_core._object_cast_to_TransformedDistancePairScore(o)
1010 
1011 _object_types.append("TripletConstraint")
1012 
1013 
1014 def _object_cast_to_TripletConstraint(o):
1015  r"""_object_cast_to_TripletConstraint(Object o) -> TripletConstraint"""
1016  return _IMP_core._object_cast_to_TripletConstraint(o)
1017 
1018 _object_types.append("TripletRestraint")
1019 
1020 
1021 def _object_cast_to_TripletRestraint(o):
1022  r"""_object_cast_to_TripletRestraint(Object o) -> TripletRestraint"""
1023  return _IMP_core._object_cast_to_TripletRestraint(o)
1024 
1025 _object_types.append("TypedPairScore")
1026 
1027 
1028 def _object_cast_to_TypedPairScore(o):
1029  r"""_object_cast_to_TypedPairScore(Object o) -> TypedPairScore"""
1030  return _IMP_core._object_cast_to_TypedPairScore(o)
1031 
1032 _object_types.append("VolumeRestraint")
1033 
1034 
1035 def _object_cast_to_VolumeRestraint(o):
1036  r"""_object_cast_to_VolumeRestraint(Object o) -> VolumeRestraint"""
1037  return _IMP_core._object_cast_to_VolumeRestraint(o)
1038 
1039 _object_types.append("WeightedSphereDistancePairScore")
1040 
1041 
1042 def _object_cast_to_WeightedSphereDistancePairScore(o):
1043  r"""_object_cast_to_WeightedSphereDistancePairScore(Object o) -> WeightedSphereDistancePairScore"""
1044  return _IMP_core._object_cast_to_WeightedSphereDistancePairScore(o)
1045 
1046 _object_types.append("MoveStatisticsScoreState")
1047 
1048 
1049 def _object_cast_to_MoveStatisticsScoreState(o):
1050  r"""_object_cast_to_MoveStatisticsScoreState(Object o) -> MoveStatisticsScoreState"""
1051  return _IMP_core._object_cast_to_MoveStatisticsScoreState(o)
1052 
1053 _object_types.append("MinimumRestraint")
1054 
1055 
1056 def _object_cast_to_MinimumRestraint(o):
1057  r"""_object_cast_to_MinimumRestraint(Object o) -> MinimumRestraint"""
1058  return _IMP_core._object_cast_to_MinimumRestraint(o)
1059 
1060 _object_types.append("WriteRestraintScoresOptimizerState")
1061 
1062 
1063 def _object_cast_to_WriteRestraintScoresOptimizerState(o):
1064  r"""_object_cast_to_WriteRestraintScoresOptimizerState(Object o) -> WriteRestraintScoresOptimizerState"""
1065  return _IMP_core._object_cast_to_WriteRestraintScoresOptimizerState(o)
1066 
1067 _object_types.append("LateralSurfaceConstraint")
1068 
1069 
1070 def _object_cast_to_LateralSurfaceConstraint(o):
1071  r"""_object_cast_to_LateralSurfaceConstraint(Object o) -> LateralSurfaceConstraint"""
1072  return _IMP_core._object_cast_to_LateralSurfaceConstraint(o)
1073 
1074 _object_types.append("ConstantSingletonPredicate")
1075 
1076 
1077 def _object_cast_to_ConstantSingletonPredicate(o):
1078  r"""_object_cast_to_ConstantSingletonPredicate(Object o) -> ConstantSingletonPredicate"""
1079  return _IMP_core._object_cast_to_ConstantSingletonPredicate(o)
1080 
1081 _object_types.append("ConstantPairPredicate")
1082 
1083 
1084 def _object_cast_to_ConstantPairPredicate(o):
1085  r"""_object_cast_to_ConstantPairPredicate(Object o) -> ConstantPairPredicate"""
1086  return _IMP_core._object_cast_to_ConstantPairPredicate(o)
1087 
1088 _object_types.append("ConstantTripletPredicate")
1089 
1090 
1091 def _object_cast_to_ConstantTripletPredicate(o):
1092  r"""_object_cast_to_ConstantTripletPredicate(Object o) -> ConstantTripletPredicate"""
1093  return _IMP_core._object_cast_to_ConstantTripletPredicate(o)
1094 
1095 _object_types.append("ConstantQuadPredicate")
1096 
1097 
1098 def _object_cast_to_ConstantQuadPredicate(o):
1099  r"""_object_cast_to_ConstantQuadPredicate(Object o) -> ConstantQuadPredicate"""
1100  return _IMP_core._object_cast_to_ConstantQuadPredicate(o)
1101 
1102 _object_types.append("CoinFlipSingletonPredicate")
1103 
1104 
1105 def _object_cast_to_CoinFlipSingletonPredicate(o):
1106  r"""_object_cast_to_CoinFlipSingletonPredicate(Object o) -> CoinFlipSingletonPredicate"""
1107  return _IMP_core._object_cast_to_CoinFlipSingletonPredicate(o)
1108 
1109 _object_types.append("CoinFlipPairPredicate")
1110 
1111 
1112 def _object_cast_to_CoinFlipPairPredicate(o):
1113  r"""_object_cast_to_CoinFlipPairPredicate(Object o) -> CoinFlipPairPredicate"""
1114  return _IMP_core._object_cast_to_CoinFlipPairPredicate(o)
1115 
1116 _object_types.append("CoinFlipTripletPredicate")
1117 
1118 
1119 def _object_cast_to_CoinFlipTripletPredicate(o):
1120  r"""_object_cast_to_CoinFlipTripletPredicate(Object o) -> CoinFlipTripletPredicate"""
1121  return _IMP_core._object_cast_to_CoinFlipTripletPredicate(o)
1122 
1123 _object_types.append("CoinFlipQuadPredicate")
1124 
1125 
1126 def _object_cast_to_CoinFlipQuadPredicate(o):
1127  r"""_object_cast_to_CoinFlipQuadPredicate(Object o) -> CoinFlipQuadPredicate"""
1128  return _IMP_core._object_cast_to_CoinFlipQuadPredicate(o)
1129 
1130 _object_types.append("UnorderedTypeSingletonPredicate")
1131 
1132 
1133 def _object_cast_to_UnorderedTypeSingletonPredicate(o):
1134  r"""_object_cast_to_UnorderedTypeSingletonPredicate(Object o) -> UnorderedTypeSingletonPredicate"""
1135  return _IMP_core._object_cast_to_UnorderedTypeSingletonPredicate(o)
1136 
1137 _object_types.append("UnorderedTypePairPredicate")
1138 
1139 
1140 def _object_cast_to_UnorderedTypePairPredicate(o):
1141  r"""_object_cast_to_UnorderedTypePairPredicate(Object o) -> UnorderedTypePairPredicate"""
1142  return _IMP_core._object_cast_to_UnorderedTypePairPredicate(o)
1143 
1144 _object_types.append("UnorderedTypeTripletPredicate")
1145 
1146 
1147 def _object_cast_to_UnorderedTypeTripletPredicate(o):
1148  r"""_object_cast_to_UnorderedTypeTripletPredicate(Object o) -> UnorderedTypeTripletPredicate"""
1149  return _IMP_core._object_cast_to_UnorderedTypeTripletPredicate(o)
1150 
1151 _object_types.append("UnorderedTypeQuadPredicate")
1152 
1153 
1154 def _object_cast_to_UnorderedTypeQuadPredicate(o):
1155  r"""_object_cast_to_UnorderedTypeQuadPredicate(Object o) -> UnorderedTypeQuadPredicate"""
1156  return _IMP_core._object_cast_to_UnorderedTypeQuadPredicate(o)
1157 
1158 _object_types.append("OrderedTypeSingletonPredicate")
1159 
1160 
1161 def _object_cast_to_OrderedTypeSingletonPredicate(o):
1162  r"""_object_cast_to_OrderedTypeSingletonPredicate(Object o) -> OrderedTypeSingletonPredicate"""
1163  return _IMP_core._object_cast_to_OrderedTypeSingletonPredicate(o)
1164 
1165 _object_types.append("OrderedTypePairPredicate")
1166 
1167 
1168 def _object_cast_to_OrderedTypePairPredicate(o):
1169  r"""_object_cast_to_OrderedTypePairPredicate(Object o) -> OrderedTypePairPredicate"""
1170  return _IMP_core._object_cast_to_OrderedTypePairPredicate(o)
1171 
1172 _object_types.append("OrderedTypeTripletPredicate")
1173 
1174 
1175 def _object_cast_to_OrderedTypeTripletPredicate(o):
1176  r"""_object_cast_to_OrderedTypeTripletPredicate(Object o) -> OrderedTypeTripletPredicate"""
1177  return _IMP_core._object_cast_to_OrderedTypeTripletPredicate(o)
1178 
1179 _object_types.append("OrderedTypeQuadPredicate")
1180 
1181 
1182 def _object_cast_to_OrderedTypeQuadPredicate(o):
1183  r"""_object_cast_to_OrderedTypeQuadPredicate(Object o) -> OrderedTypeQuadPredicate"""
1184  return _IMP_core._object_cast_to_OrderedTypeQuadPredicate(o)
1185 
1186 _object_types.append("AllSameSingletonPredicate")
1187 
1188 
1189 def _object_cast_to_AllSameSingletonPredicate(o):
1190  r"""_object_cast_to_AllSameSingletonPredicate(Object o) -> AllSameSingletonPredicate"""
1191  return _IMP_core._object_cast_to_AllSameSingletonPredicate(o)
1192 
1193 _object_types.append("AllSamePairPredicate")
1194 
1195 
1196 def _object_cast_to_AllSamePairPredicate(o):
1197  r"""_object_cast_to_AllSamePairPredicate(Object o) -> AllSamePairPredicate"""
1198  return _IMP_core._object_cast_to_AllSamePairPredicate(o)
1199 
1200 _object_types.append("AllSameTripletPredicate")
1201 
1202 
1203 def _object_cast_to_AllSameTripletPredicate(o):
1204  r"""_object_cast_to_AllSameTripletPredicate(Object o) -> AllSameTripletPredicate"""
1205  return _IMP_core._object_cast_to_AllSameTripletPredicate(o)
1206 
1207 _object_types.append("AllSameQuadPredicate")
1208 
1209 
1210 def _object_cast_to_AllSameQuadPredicate(o):
1211  r"""_object_cast_to_AllSameQuadPredicate(Object o) -> AllSameQuadPredicate"""
1212  return _IMP_core._object_cast_to_AllSameQuadPredicate(o)
1213 
1214 def XYZs(l=[]):
1215  return [XYZ(x) for x in l]
1216 _plural_types.append("XYZs")
1217 
1218 
1219 _value_types.append("XYZ")
1220 
1221 
1222 def XYZRs(l=[]):
1223  return [XYZR(x) for x in l]
1224 _plural_types.append("XYZRs")
1225 
1226 
1227 _value_types.append("XYZR")
1228 
1229 
1230 def RigidBodies(l=[]):
1231  return [RigidBody(x) for x in l]
1232 _plural_types.append("RigidBodies")
1233 
1234 
1235 _value_types.append("RigidBody")
1236 
1237 
1238 def RigidBodyMembers(l=[]):
1239  return [RigidBodyMember(x) for x in l]
1240 _plural_types.append("RigidBodyMembers")
1241 
1242 
1243 _value_types.append("RigidBodyMember")
1244 
1245 
1246 def RigidMembers(l=[]):
1247  return [RigidMember(x) for x in l]
1248 _plural_types.append("RigidMembers")
1249 
1250 
1251 _value_types.append("RigidMember")
1252 
1253 
1254 def NonRigidMembers(l=[]):
1255  return [NonRigidMember(x) for x in l]
1256 _plural_types.append("NonRigidMembers")
1257 
1258 
1259 _value_types.append("NonRigidMember")
1260 
1261 
1262 def Centroids(l=[]):
1263  return [Centroid(x) for x in l]
1264 _plural_types.append("Centroids")
1265 
1266 
1267 _value_types.append("Centroid")
1268 
1269 
1270 def Covers(l=[]):
1271  return [Cover(x) for x in l]
1272 _plural_types.append("Covers")
1273 
1274 
1275 _value_types.append("Cover")
1276 
1277 
1278 def References(l=[]):
1279  return [Reference(x) for x in l]
1280 _plural_types.append("References")
1281 
1282 
1283 _value_types.append("Reference")
1284 
1285 
1286 ParticleTypes=list
1287 _plural_types.append("ParticleTypes")
1288 _value_types.append("ParticleType")
1289 
1290 
1291 def Typeds(l=[]):
1292  return [Typed(x) for x in l]
1293 _plural_types.append("Typeds")
1294 
1295 
1296 _value_types.append("Typed")
1297 
1298 
1299 def GenericHierarchies(l=[]):
1300  return [Hierarchy(x) for x in l]
1301 _plural_types.append("GenericHierarchies")
1302 
1303 
1304 _value_types.append("Hierarchy")
1305 
1306 
1307 def Gaussians(l=[]):
1308  return [Gaussian(x) for x in l]
1309 _plural_types.append("Gaussians")
1310 
1311 
1312 _value_types.append("Gaussian")
1313 
1314 
1315 def Directions(l=[]):
1316  return [Direction(x) for x in l]
1317 _plural_types.append("Directions")
1318 
1319 
1320 _value_types.append("Direction")
1321 
1322 
1323 def DirectionAngles(l=[]):
1324  return [DirectionAngle(x) for x in l]
1325 _plural_types.append("DirectionAngles")
1326 
1327 
1328 _value_types.append("DirectionAngle")
1329 
1330 
1331 def Surfaces(l=[]):
1332  return [Surface(x) for x in l]
1333 _plural_types.append("Surfaces")
1334 
1335 
1336 _value_types.append("Surface")
1337 
1338 
1339 def Provenances(l=[]):
1340  return [Provenance(x) for x in l]
1341 _plural_types.append("Provenances")
1342 
1343 
1344 _value_types.append("Provenance")
1345 
1346 
1347 def StructureProvenances(l=[]):
1348  return [StructureProvenance(x) for x in l]
1349 _plural_types.append("StructureProvenances")
1350 
1351 
1352 _value_types.append("StructureProvenance")
1353 
1354 
1355 def SampleProvenances(l=[]):
1356  return [SampleProvenance(x) for x in l]
1357 _plural_types.append("SampleProvenances")
1358 
1359 
1360 _value_types.append("SampleProvenance")
1361 
1362 
1363 def ClusterProvenances(l=[]):
1364  return [ClusterProvenance(x) for x in l]
1365 _plural_types.append("ClusterProvenances")
1366 
1367 
1368 _value_types.append("ClusterProvenance")
1369 
1370 
1371 def CombineProvenances(l=[]):
1372  return [CombineProvenance(x) for x in l]
1373 _plural_types.append("CombineProvenances")
1374 
1375 
1376 _value_types.append("CombineProvenance")
1377 
1378 
1379 def FilterProvenances(l=[]):
1380  return [FilterProvenance(x) for x in l]
1381 _plural_types.append("FilterProvenances")
1382 
1383 
1384 _value_types.append("FilterProvenance")
1385 
1386 
1387 def ScriptProvenances(l=[]):
1388  return [ScriptProvenance(x) for x in l]
1389 _plural_types.append("ScriptProvenances")
1390 
1391 
1392 _value_types.append("ScriptProvenance")
1393 
1394 
1395 def SoftwareProvenances(l=[]):
1396  return [SoftwareProvenance(x) for x in l]
1397 _plural_types.append("SoftwareProvenances")
1398 
1399 
1400 _value_types.append("SoftwareProvenance")
1401 
1402 
1403 def Provenanceds(l=[]):
1404  return [Provenanced(x) for x in l]
1405 _plural_types.append("Provenanceds")
1406 
1407 
1408 _value_types.append("Provenanced")
1409 
1410 
1411 HierarchyCounters=list
1412 _plural_types.append("HierarchyCounters")
1413 _value_types.append("HierarchyCounter")
1414 
1415 
1416 HierarchyTraitsList=list
1417 _plural_types.append("HierarchyTraitsList")
1418 _value_types.append("HierarchyTraits")
1419 
1420 
1421 _object_types.append("TruncatedHarmonicBound")
1422 
1423 
1424 def _object_cast_to_TruncatedHarmonicBound(o):
1425  r"""_object_cast_to_TruncatedHarmonicBound(Object o) -> TruncatedHarmonicBound"""
1426  return _IMP_core._object_cast_to_TruncatedHarmonicBound(o)
1427 
1428 _object_types.append("TruncatedHarmonicLowerBound")
1429 
1430 
1431 def _object_cast_to_TruncatedHarmonicLowerBound(o):
1432  r"""_object_cast_to_TruncatedHarmonicLowerBound(Object o) -> TruncatedHarmonicLowerBound"""
1433  return _IMP_core._object_cast_to_TruncatedHarmonicLowerBound(o)
1434 
1435 _object_types.append("TruncatedHarmonicUpperBound")
1436 
1437 
1438 def _object_cast_to_TruncatedHarmonicUpperBound(o):
1439  r"""_object_cast_to_TruncatedHarmonicUpperBound(Object o) -> TruncatedHarmonicUpperBound"""
1440  return _IMP_core._object_cast_to_TruncatedHarmonicUpperBound(o)
1441 
1442 _object_types.append("HarmonicDistancePairScore")
1443 
1444 
1445 def _object_cast_to_HarmonicDistancePairScore(o):
1446  r"""_object_cast_to_HarmonicDistancePairScore(Object o) -> HarmonicDistancePairScore"""
1447  return _IMP_core._object_cast_to_HarmonicDistancePairScore(o)
1448 
1449 _object_types.append("DistancePairScore")
1450 
1451 
1452 def _object_cast_to_DistancePairScore(o):
1453  r"""_object_cast_to_DistancePairScore(Object o) -> DistancePairScore"""
1454  return _IMP_core._object_cast_to_DistancePairScore(o)
1455 
1456 _object_types.append("XYZRGeometry")
1457 
1458 
1459 def _object_cast_to_XYZRGeometry(o):
1460  r"""_object_cast_to_XYZRGeometry(Object o) -> XYZRGeometry"""
1461  return _IMP_core._object_cast_to_XYZRGeometry(o)
1462 
1463 _object_types.append("XYZRsGeometry")
1464 
1465 
1466 def _object_cast_to_XYZRsGeometry(o):
1467  r"""_object_cast_to_XYZRsGeometry(Object o) -> XYZRsGeometry"""
1468  return _IMP_core._object_cast_to_XYZRsGeometry(o)
1469 
1470 _object_types.append("XYZDerivativeGeometry")
1471 
1472 
1473 def _object_cast_to_XYZDerivativeGeometry(o):
1474  r"""_object_cast_to_XYZDerivativeGeometry(Object o) -> XYZDerivativeGeometry"""
1475  return _IMP_core._object_cast_to_XYZDerivativeGeometry(o)
1476 
1477 _object_types.append("XYZDerivativesGeometry")
1478 
1479 
1480 def _object_cast_to_XYZDerivativesGeometry(o):
1481  r"""_object_cast_to_XYZDerivativesGeometry(Object o) -> XYZDerivativesGeometry"""
1482  return _IMP_core._object_cast_to_XYZDerivativesGeometry(o)
1483 
1484 _object_types.append("RigidBodyDerivativeGeometry")
1485 
1486 
1487 def _object_cast_to_RigidBodyDerivativeGeometry(o):
1488  r"""_object_cast_to_RigidBodyDerivativeGeometry(Object o) -> RigidBodyDerivativeGeometry"""
1489  return _IMP_core._object_cast_to_RigidBodyDerivativeGeometry(o)
1490 
1491 _object_types.append("RigidBodyDerivativesGeometry")
1492 
1493 
1494 def _object_cast_to_RigidBodyDerivativesGeometry(o):
1495  r"""_object_cast_to_RigidBodyDerivativesGeometry(Object o) -> RigidBodyDerivativesGeometry"""
1496  return _IMP_core._object_cast_to_RigidBodyDerivativesGeometry(o)
1497 
1498 _object_types.append("RigidBodyHierarchyGeometry")
1499 
1500 
1501 def _object_cast_to_RigidBodyHierarchyGeometry(o):
1502  r"""_object_cast_to_RigidBodyHierarchyGeometry(Object o) -> RigidBodyHierarchyGeometry"""
1503  return _IMP_core._object_cast_to_RigidBodyHierarchyGeometry(o)
1504 
1505 _object_types.append("RigidBodyFrameGeometry")
1506 
1507 
1508 def _object_cast_to_RigidBodyFrameGeometry(o):
1509  r"""_object_cast_to_RigidBodyFrameGeometry(Object o) -> RigidBodyFrameGeometry"""
1510  return _IMP_core._object_cast_to_RigidBodyFrameGeometry(o)
1511 
1512 _object_types.append("RigidBodyFramesGeometry")
1513 
1514 
1515 def _object_cast_to_RigidBodyFramesGeometry(o):
1516  r"""_object_cast_to_RigidBodyFramesGeometry(Object o) -> RigidBodyFramesGeometry"""
1517  return _IMP_core._object_cast_to_RigidBodyFramesGeometry(o)
1518 
1519 _object_types.append("RigidBodyTorque")
1520 
1521 
1522 def _object_cast_to_RigidBodyTorque(o):
1523  r"""_object_cast_to_RigidBodyTorque(Object o) -> RigidBodyTorque"""
1524  return _IMP_core._object_cast_to_RigidBodyTorque(o)
1525 
1526 _object_types.append("EdgePairGeometry")
1527 
1528 
1529 def _object_cast_to_EdgePairGeometry(o):
1530  r"""_object_cast_to_EdgePairGeometry(Object o) -> EdgePairGeometry"""
1531  return _IMP_core._object_cast_to_EdgePairGeometry(o)
1532 
1533 _object_types.append("EdgePairsGeometry")
1534 
1535 
1536 def _object_cast_to_EdgePairsGeometry(o):
1537  r"""_object_cast_to_EdgePairsGeometry(Object o) -> EdgePairsGeometry"""
1538  return _IMP_core._object_cast_to_EdgePairsGeometry(o)
1539 
1540 _object_types.append("SurfaceGeometry")
1541 
1542 
1543 def _object_cast_to_SurfaceGeometry(o):
1544  r"""_object_cast_to_SurfaceGeometry(Object o) -> SurfaceGeometry"""
1545  return _IMP_core._object_cast_to_SurfaceGeometry(o)
1546 
1547 _object_types.append("SurfaceGeometryConstraint")
1548 
1549 
1550 def _object_cast_to_SurfaceGeometryConstraint(o):
1551  r"""_object_cast_to_SurfaceGeometryConstraint(Object o) -> SurfaceGeometryConstraint"""
1552  return _IMP_core._object_cast_to_SurfaceGeometryConstraint(o)
1553 
1554 _object_types.append("AttributeSingletonPredicate")
1555 
1556 
1557 def _object_cast_to_AttributeSingletonPredicate(o):
1558  r"""_object_cast_to_AttributeSingletonPredicate(Object o) -> AttributeSingletonPredicate"""
1559  return _IMP_core._object_cast_to_AttributeSingletonPredicate(o)
1560 
1561 _object_types.append("InBoundingBox3DSingletonPredicate")
1562 
1563 
1564 def _object_cast_to_InBoundingBox3DSingletonPredicate(o):
1565  r"""_object_cast_to_InBoundingBox3DSingletonPredicate(Object o) -> InBoundingBox3DSingletonPredicate"""
1566  return _IMP_core._object_cast_to_InBoundingBox3DSingletonPredicate(o)
1567 
1568 _object_types.append("IsCollisionPairPredicate")
1569 
1570 
1571 def _object_cast_to_IsCollisionPairPredicate(o):
1572  r"""_object_cast_to_IsCollisionPairPredicate(Object o) -> IsCollisionPairPredicate"""
1573  return _IMP_core._object_cast_to_IsCollisionPairPredicate(o)
1574 
1575 BinormalTermList=list
1576 _plural_types.append("BinormalTermList")
1577 _value_types.append("BinormalTerm")
1578 
1579 
1580 _object_types.append("MultipleBinormalRestraint")
1581 
1582 
1583 def _object_cast_to_MultipleBinormalRestraint(o):
1584  r"""_object_cast_to_MultipleBinormalRestraint(Object o) -> MultipleBinormalRestraint"""
1585  return _IMP_core._object_cast_to_MultipleBinormalRestraint(o)
1586 class ClosePairsFinder(IMP._ParticleInputs, IMP.Object):
1587  r"""Proxy of C++ IMP::core::ClosePairsFinder class."""
1588 
1589  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
1590 
1591  def __init__(self, *args, **kwargs):
1592  raise AttributeError("No constructor defined - class is abstract")
1593  __swig_destroy__ = _IMP_core.delete_ClosePairsFinder
1594 
1595  def get_close_pairs(self, *args):
1596  r"""
1597  get_close_pairs(ClosePairsFinder self, Model m, IMP::ParticleIndexes const & pc) -> IMP::ParticleIndexPairs
1598  get_close_pairs(ClosePairsFinder self, Model m, IMP::ParticleIndexes const & pca, IMP::ParticleIndexes const & pcb) -> IMP::ParticleIndexPairs
1599  get_close_pairs(ClosePairsFinder self, IMP::algebra::BoundingBox3Ds const & bbs) -> IMP::IntPairs
1600  get_close_pairs(ClosePairsFinder self, IMP::algebra::BoundingBox3Ds const & bas, IMP::algebra::BoundingBox3Ds const & bbs) -> IMP::IntPairs
1601  """
1602  return _IMP_core.ClosePairsFinder_get_close_pairs(self, *args)
1603 
1604  def set_distance(self, d):
1605  r"""set_distance(ClosePairsFinder self, double d)"""
1606  return _IMP_core.ClosePairsFinder_set_distance(self, d)
1607 
1608  def get_distance(self):
1609  r"""get_distance(ClosePairsFinder self) -> double"""
1610  return _IMP_core.ClosePairsFinder_get_distance(self)
1611  def __get_pair_filters(self): return IMP._list_util.VarList(getdimfunc=self.get_number_of_pair_filters, getfunc=self.get_pair_filter, erasefunc=self.erase_pair_filter, appendfunc=self.add_pair_filter, extendfunc=self.add_pair_filters, clearfunc=self.clear_pair_filters, indexfunc=self._python_index_pair_filter)
1612  def __set_pair_filters(self, obj): IMP._list_util.set_varlist(self.pair_filters, obj)
1613  def __del_pair_filters(self): IMP._list_util.del_varlist(self.pair_filters)
1614  pair_filters = property(__get_pair_filters, __set_pair_filters, __del_pair_filters, doc="List of ##ucnames")
1615 
1616  def remove_pair_filter(self, d):
1617  r"""remove_pair_filter(ClosePairsFinder self, PairPredicate d)"""
1618  return _IMP_core.ClosePairsFinder_remove_pair_filter(self, d)
1619 
1620  def _python_index_pair_filter(self, d, start, stop):
1621  r"""_python_index_pair_filter(ClosePairsFinder self, PairPredicate d, unsigned int start, unsigned int stop) -> unsigned int"""
1622  return _IMP_core.ClosePairsFinder__python_index_pair_filter(self, d, start, stop)
1623 
1624  def remove_pair_filters(self, d):
1625  r"""remove_pair_filters(ClosePairsFinder self, IMP::PairPredicates const & d)"""
1626  return _IMP_core.ClosePairsFinder_remove_pair_filters(self, d)
1627 
1628  def set_pair_filters(self, ps):
1629  r"""set_pair_filters(ClosePairsFinder self, IMP::PairPredicates const & ps)"""
1630  return _IMP_core.ClosePairsFinder_set_pair_filters(self, ps)
1631 
1632  def set_pair_filters_order(self, objs):
1633  r"""set_pair_filters_order(ClosePairsFinder self, IMP::PairPredicates const & objs)"""
1634  return _IMP_core.ClosePairsFinder_set_pair_filters_order(self, objs)
1635 
1636  def add_pair_filter(self, obj):
1637  r"""add_pair_filter(ClosePairsFinder self, PairPredicate obj) -> unsigned int"""
1638  return _IMP_core.ClosePairsFinder_add_pair_filter(self, obj)
1639 
1640  def add_pair_filters(self, objs):
1641  r"""add_pair_filters(ClosePairsFinder self, IMP::PairPredicates const & objs)"""
1642  return _IMP_core.ClosePairsFinder_add_pair_filters(self, objs)
1643 
1644  def clear_pair_filters(self):
1645  r"""clear_pair_filters(ClosePairsFinder self)"""
1646  return _IMP_core.ClosePairsFinder_clear_pair_filters(self)
1647 
1648  def get_number_of_pair_filters(self):
1649  r"""get_number_of_pair_filters(ClosePairsFinder self) -> unsigned int"""
1650  return _IMP_core.ClosePairsFinder_get_number_of_pair_filters(self)
1651 
1652  def get_has_pair_filters(self):
1653  r"""get_has_pair_filters(ClosePairsFinder self) -> bool"""
1654  return _IMP_core.ClosePairsFinder_get_has_pair_filters(self)
1655 
1656  def get_pair_filter(self, i):
1657  r"""get_pair_filter(ClosePairsFinder self, unsigned int i) -> PairPredicate"""
1658  return _IMP_core.ClosePairsFinder_get_pair_filter(self, i)
1659 
1660  def get_pair_filters(self):
1661  r"""get_pair_filters(ClosePairsFinder self) -> IMP::PairPredicates"""
1662  return _IMP_core.ClosePairsFinder_get_pair_filters(self)
1663 
1664  def erase_pair_filter(self, i):
1665  r"""erase_pair_filter(ClosePairsFinder self, unsigned int i)"""
1666  return _IMP_core.ClosePairsFinder_erase_pair_filter(self, i)
1667 
1668  def reserve_pair_filters(self, sz):
1669  r"""reserve_pair_filters(ClosePairsFinder self, unsigned int sz)"""
1670  return _IMP_core.ClosePairsFinder_reserve_pair_filters(self, sz)
1671 
1672  def __str__(self):
1673  r"""__str__(ClosePairsFinder self) -> std::string"""
1674  return _IMP_core.ClosePairsFinder___str__(self)
1675 
1676  def __repr__(self):
1677  r"""__repr__(ClosePairsFinder self) -> std::string"""
1678  return _IMP_core.ClosePairsFinder___repr__(self)
1679 
1680  @staticmethod
1681  def get_from(o):
1682  return _object_cast_to_ClosePairsFinder(o)
1683 
1684 
1685 # Register ClosePairsFinder in _IMP_core:
1686 _IMP_core.ClosePairsFinder_swigregister(ClosePairsFinder)
1687 class MonteCarloMoverResult(IMP._Value):
1688  r"""Proxy of C++ IMP::core::MonteCarloMoverResult class."""
1689 
1690  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
1691 
1692  def __init__(self, *args):
1693  r"""__init__(MonteCarloMoverResult self, IMP::ParticleIndexes i0=IMP::ParticleIndexes(), double i1=double()) -> MonteCarloMoverResult"""
1694  _IMP_core.MonteCarloMoverResult_swiginit(self, _IMP_core.new_MonteCarloMoverResult(*args))
1695 
1696  def __hash__(self):
1697  r"""__hash__(MonteCarloMoverResult self) -> std::size_t"""
1698  return _IMP_core.MonteCarloMoverResult___hash__(self)
1699 
1700  def show(self, *args):
1701  r"""show(MonteCarloMoverResult self, _ostream out=std::cout)"""
1702  return _IMP_core.MonteCarloMoverResult_show(self, *args)
1703 
1704  def __cmp__(self, o):
1705  r"""__cmp__(MonteCarloMoverResult self, MonteCarloMoverResult o) -> int"""
1706  return _IMP_core.MonteCarloMoverResult___cmp__(self, o)
1707 
1708  def __eq__(self, o):
1709  r"""__eq__(MonteCarloMoverResult self, MonteCarloMoverResult o) -> bool"""
1710  return _IMP_core.MonteCarloMoverResult___eq__(self, o)
1711 
1712  def __ne__(self, o):
1713  r"""__ne__(MonteCarloMoverResult self, MonteCarloMoverResult o) -> bool"""
1714  return _IMP_core.MonteCarloMoverResult___ne__(self, o)
1715 
1716  def __lt__(self, o):
1717  r"""__lt__(MonteCarloMoverResult self, MonteCarloMoverResult o) -> bool"""
1718  return _IMP_core.MonteCarloMoverResult___lt__(self, o)
1719 
1720  def __gt__(self, o):
1721  r"""__gt__(MonteCarloMoverResult self, MonteCarloMoverResult o) -> bool"""
1722  return _IMP_core.MonteCarloMoverResult___gt__(self, o)
1723 
1724  def __ge__(self, o):
1725  r"""__ge__(MonteCarloMoverResult self, MonteCarloMoverResult o) -> bool"""
1726  return _IMP_core.MonteCarloMoverResult___ge__(self, o)
1727 
1728  def __le__(self, o):
1729  r"""__le__(MonteCarloMoverResult self, MonteCarloMoverResult o) -> bool"""
1730  return _IMP_core.MonteCarloMoverResult___le__(self, o)
1731 
1732  def get_moved_particles(self):
1733  r"""get_moved_particles(MonteCarloMoverResult self) -> IMP::ParticleIndexes const &"""
1734  return _IMP_core.MonteCarloMoverResult_get_moved_particles(self)
1735 
1736  def set_moved_particles(self, v):
1737  r"""set_moved_particles(MonteCarloMoverResult self, IMP::ParticleIndexes const & v)"""
1738  return _IMP_core.MonteCarloMoverResult_set_moved_particles(self, v)
1739 
1740  def get_proposal_ratio(self):
1741  r"""get_proposal_ratio(MonteCarloMoverResult self) -> double const &"""
1742  return _IMP_core.MonteCarloMoverResult_get_proposal_ratio(self)
1743 
1744  def set_proposal_ratio(self, v):
1745  r"""set_proposal_ratio(MonteCarloMoverResult self, double const & v)"""
1746  return _IMP_core.MonteCarloMoverResult_set_proposal_ratio(self, v)
1747 
1748  def __str__(self):
1749  r"""__str__(MonteCarloMoverResult self) -> std::string"""
1750  return _IMP_core.MonteCarloMoverResult___str__(self)
1751 
1752  def __repr__(self):
1753  r"""__repr__(MonteCarloMoverResult self) -> std::string"""
1754  return _IMP_core.MonteCarloMoverResult___repr__(self)
1755  __swig_destroy__ = _IMP_core.delete_MonteCarloMoverResult
1756 
1757 # Register MonteCarloMoverResult in _IMP_core:
1758 _IMP_core.MonteCarloMoverResult_swigregister(MonteCarloMoverResult)
1759 class MonteCarloMover(IMP.ModelObject):
1760  r"""Proxy of C++ IMP::core::MonteCarloMover class."""
1761 
1762  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
1763 
1764  def __init__(self, *args):
1765  r"""
1766  __init__(MonteCarloMover self, Model m, std::string name) -> MonteCarloMover
1767  __init__(MonteCarloMover self) -> MonteCarloMover
1768  """
1769  if self.__class__ == MonteCarloMover:
1770  _self = None
1771  else:
1772  _self = self
1773  _IMP_core.MonteCarloMover_swiginit(self, _IMP_core.new_MonteCarloMover(_self, *args))
1774 
1775  if self.__class__ != MonteCarloMover:
1776  _director_objects.register(self)
1777 
1778 
1779 
1780 
1781  def propose(self):
1782  r"""propose(MonteCarloMover self) -> MonteCarloMoverResult"""
1783  return _IMP_core.MonteCarloMover_propose(self)
1784 
1785  def reject(self):
1786  r"""reject(MonteCarloMover self)"""
1787  return _IMP_core.MonteCarloMover_reject(self)
1788 
1789  def accept(self):
1790  r"""accept(MonteCarloMover self)"""
1791  return _IMP_core.MonteCarloMover_accept(self)
1792 
1793  def get_number_of_proposed(self):
1794  r"""get_number_of_proposed(MonteCarloMover self) -> unsigned int"""
1795  return _IMP_core.MonteCarloMover_get_number_of_proposed(self)
1796 
1797  def get_number_of_accepted(self):
1798  r"""get_number_of_accepted(MonteCarloMover self) -> unsigned int"""
1799  return _IMP_core.MonteCarloMover_get_number_of_accepted(self)
1800 
1801  def reset_statistics(self):
1802  r"""reset_statistics(MonteCarloMover self)"""
1803  return _IMP_core.MonteCarloMover_reset_statistics(self)
1804 
1805  def add_to_statistics(self, num_proposed, num_rejected):
1806  r"""add_to_statistics(MonteCarloMover self, unsigned int num_proposed, unsigned int num_rejected)"""
1807  return _IMP_core.MonteCarloMover_add_to_statistics(self, num_proposed, num_rejected)
1808 
1809  def do_propose(self):
1810  r"""do_propose(MonteCarloMover self) -> MonteCarloMoverResult"""
1811  return _IMP_core.MonteCarloMover_do_propose(self)
1812 
1813  def do_reject(self):
1814  r"""do_reject(MonteCarloMover self)"""
1815  return _IMP_core.MonteCarloMover_do_reject(self)
1816 
1817  def do_accept(self):
1818  r"""do_accept(MonteCarloMover self)"""
1819  return _IMP_core.MonteCarloMover_do_accept(self)
1820 
1821  def do_get_outputs(self):
1822  r"""do_get_outputs(MonteCarloMover self) -> IMP::ModelObjectsTemp"""
1823  return _IMP_core.MonteCarloMover_do_get_outputs(self)
1824 
1825  def __str__(self):
1826  r"""__str__(MonteCarloMover self) -> std::string"""
1827  return _IMP_core.MonteCarloMover___str__(self)
1828 
1829  def __repr__(self):
1830  r"""__repr__(MonteCarloMover self) -> std::string"""
1831  return _IMP_core.MonteCarloMover___repr__(self)
1832 
1833  @staticmethod
1834  def get_from(o):
1835  return _object_cast_to_MonteCarloMover(o)
1836 
1837 
1838  def do_show(self, out):
1839  pass
1840 
1841  @staticmethod
1842  def get_from(o):
1843  return _object_cast_to_MonteCarloMover(o)
1844 
1845 
1846  def _get_jax(self):
1847  """Return a JAX implementation of this mover.
1848  Implement this method in a MonteCarloMover subclass to provide
1849  equivalent functionality using [JAX](https://docs.jax.dev/).
1850  See _wrap_jax for more information.
1851  """
1852  raise NotImplementedError(f"No JAX implementation for {self}")
1853 
1854  def _wrap_jax(self, init_func, propose_func, accept_func=None,
1855  sync_func=None, keys=None):
1856  """Create the return value for _get_jax.
1857  Use this method in _get_jax() to wrap the JAX functions
1858  with other mover-specific information.
1859 
1860  @param init_func a JAX function which is used to initialize this
1861  mover. It is called with a single argument, a fresh JAX
1862  random key, and should return a persistent state object.
1863  This object may be the key itself, or any other Python object
1864  that JAX understands.
1865  @param propose_func a JAX function which is called with the current
1866  JAX Model and the mover's persistent state object.
1867  It should return a new JAX Model with the move applied,
1868  a new persistent state, and the proposal ratio. If the move
1869  is rejected then the new JAX Model will be discarded.
1870  However, the mover's persistent state is updated for both
1871  accepted and rejected moves.
1872  @param accept_func if provided, a JAX function which is called
1873  after each accepted Monte Carlo move, with the persistent
1874  state object. It should return a new persistent state.
1875  @param sync_func If provided, a Python function which is called
1876  at the end of a Monte Carlo sampling run to sync mover
1877  data back to IMP. It is called with the persistent state
1878  and the IMP Mover object.
1879  @param keys If given, a set of IMP::Key objects describing Model
1880  attributes (other than xyz and radius) that are altered
1881  by this mover.
1882  """
1883  from IMP.core._jax_util import JAXMoverInfo
1884  return JAXMoverInfo(init_func, propose_func, accept_func, sync_func,
1885  keys)
1886 
1887  __swig_destroy__ = _IMP_core.delete_MonteCarloMover
1888  def __disown__(self):
1889  self.this.disown()
1890  _IMP_core.disown_MonteCarloMover(self)
1891  return weakref.proxy(self)
1892 
1893  def do_destroy(self):
1894  r"""do_destroy(MonteCarloMover self)"""
1895  return _IMP_core.MonteCarloMover_do_destroy(self)
1896 
1897  def handle_set_has_required_score_states(self, arg0):
1898  r"""handle_set_has_required_score_states(MonteCarloMover self, bool arg0)"""
1899  return _IMP_core.MonteCarloMover_handle_set_has_required_score_states(self, arg0)
1900 
1901  def do_get_inputs(self):
1902  r"""do_get_inputs(MonteCarloMover self) -> IMP::ModelObjectsTemp"""
1903  return _IMP_core.MonteCarloMover_do_get_inputs(self)
1904 
1905  def do_get_interactions(self):
1906  r"""do_get_interactions(MonteCarloMover self) -> IMP::ModelObjectsTemps"""
1907  return _IMP_core.MonteCarloMover_do_get_interactions(self)
1908 
1909 # Register MonteCarloMover in _IMP_core:
1910 _IMP_core.MonteCarloMover_swigregister(MonteCarloMover)
1911 class XYZ(IMP.Decorator):
1912  r"""Proxy of C++ IMP::core::XYZ class."""
1913 
1914  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
1915 
1916  @staticmethod
1917  def get_coordinate_key(i):
1918  r"""get_coordinate_key(unsigned int i) -> FloatKey"""
1919  return _IMP_core.XYZ_get_coordinate_key(i)
1920 
1921  def __init__(self, *args):
1922  r"""
1923  __init__(XYZ self) -> XYZ
1924  __init__(XYZ self, Model m, ParticleIndex id) -> XYZ
1925  __init__(XYZ self, _ParticleAdaptor d) -> XYZ
1926  """
1927  _IMP_core.XYZ_swiginit(self, _IMP_core.new_XYZ(*args))
1928 
1929  def show(self, *args):
1930  r"""show(XYZ self, _ostream out=std::cout)"""
1931  return _IMP_core.XYZ_show(self, *args)
1932 
1933  @staticmethod
1934  def setup_particle(*args):
1935  r"""
1936  setup_particle(Model m, ParticleIndex pi) -> XYZ
1937  setup_particle(_ParticleAdaptor pa) -> XYZ
1938  setup_particle(Model m, ParticleIndex pi, Vector3D v) -> XYZ
1939  setup_particle(_ParticleAdaptor pa, Vector3D v) -> XYZ
1940  """
1941  return _IMP_core.XYZ_setup_particle(*args)
1942 
1943  def get_x(self):
1944  r"""get_x(XYZ self) -> IMP::Float"""
1945  return _IMP_core.XYZ_get_x(self)
1946 
1947  def set_x(self, t):
1948  r"""set_x(XYZ self, IMP::Float t)"""
1949  return _IMP_core.XYZ_set_x(self, t)
1950 
1951  def get_y(self):
1952  r"""get_y(XYZ self) -> IMP::Float"""
1953  return _IMP_core.XYZ_get_y(self)
1954 
1955  def set_y(self, t):
1956  r"""set_y(XYZ self, IMP::Float t)"""
1957  return _IMP_core.XYZ_set_y(self, t)
1958 
1959  def get_z(self):
1960  r"""get_z(XYZ self) -> IMP::Float"""
1961  return _IMP_core.XYZ_get_z(self)
1962 
1963  def set_z(self, t):
1964  r"""set_z(XYZ self, IMP::Float t)"""
1965  return _IMP_core.XYZ_set_z(self, t)
1966 
1967  def set_coordinate(self, i, v):
1968  r"""set_coordinate(XYZ self, unsigned int i, IMP::Float v)"""
1969  return _IMP_core.XYZ_set_coordinate(self, i, v)
1970 
1971  def set_coordinates(self, v):
1972  r"""set_coordinates(XYZ self, Vector3D v)"""
1973  return _IMP_core.XYZ_set_coordinates(self, v)
1974 
1975  def get_coordinate(self, i):
1976  r"""get_coordinate(XYZ self, int i) -> IMP::Float"""
1977  return _IMP_core.XYZ_get_coordinate(self, i)
1978 
1979  def add_to_derivatives(self, v, d):
1980  r"""add_to_derivatives(XYZ self, Vector3D v, DerivativeAccumulator d)"""
1981  return _IMP_core.XYZ_add_to_derivatives(self, v, d)
1982 
1983  def get_coordinates_are_optimized(self):
1984  r"""get_coordinates_are_optimized(XYZ self) -> bool"""
1985  return _IMP_core.XYZ_get_coordinates_are_optimized(self)
1986 
1987  def set_coordinates_are_optimized(self, tf):
1988  r"""set_coordinates_are_optimized(XYZ self, bool tf)"""
1989  return _IMP_core.XYZ_set_coordinates_are_optimized(self, tf)
1990 
1991  def get_vector_to(self, b):
1992  r"""get_vector_to(XYZ self, XYZ b) -> Vector3D"""
1993  return _IMP_core.XYZ_get_vector_to(self, b)
1994 
1995  def get_coordinates(self):
1996  r"""get_coordinates(XYZ self) -> Vector3D"""
1997  return _IMP_core.XYZ_get_coordinates(self)
1998 
1999  def get_derivatives(self):
2000  r"""get_derivatives(XYZ self) -> Vector3D"""
2001  return _IMP_core.XYZ_get_derivatives(self)
2002 
2003  @staticmethod
2004  def get_is_setup(*args):
2005  r"""
2006  get_is_setup(_ParticleAdaptor p) -> bool
2007  get_is_setup(Model m, ParticleIndex pi) -> bool
2008  """
2009  return _IMP_core.XYZ_get_is_setup(*args)
2010 
2011  @staticmethod
2012  def get_xyz_keys():
2013  r"""get_xyz_keys() -> IMP::FloatKeys const &"""
2014  return _IMP_core.XYZ_get_xyz_keys()
2015 
2016  def add_attribute(self, *args):
2017  r"""
2018  add_attribute(XYZ self, FloatKey k, IMP::Float v, bool opt)
2019  add_attribute(XYZ self, FloatKey a0, IMP::Float a1)
2020  add_attribute(XYZ self, IntKey a0, IMP::Int a1)
2021  add_attribute(XYZ self, FloatsKey a0, IMP::Floats a1)
2022  add_attribute(XYZ self, IntsKey a0, IMP::Ints a1)
2023  add_attribute(XYZ self, StringKey a0, IMP::String a1)
2024  add_attribute(XYZ self, ParticleIndexKey a0, Particle a1)
2025  add_attribute(XYZ self, ObjectKey a0, Object a1)
2026  add_attribute(XYZ self, SparseFloatKey a0, IMP::Float a1)
2027  add_attribute(XYZ self, SparseIntKey a0, IMP::Int a1)
2028  add_attribute(XYZ self, SparseStringKey a0, IMP::String a1)
2029  add_attribute(XYZ self, SparseParticleIndexKey a0, ParticleIndex a1)
2030  """
2031  return _IMP_core.XYZ_add_attribute(self, *args)
2032 
2033  def get_value(self, *args):
2034  r"""
2035  get_value(XYZ self, FloatKey a0) -> IMP::Float
2036  get_value(XYZ self, IntKey a0) -> IMP::Int
2037  get_value(XYZ self, FloatsKey a0) -> IMP::Floats
2038  get_value(XYZ self, IntsKey a0) -> IMP::Ints
2039  get_value(XYZ self, StringKey a0) -> IMP::String
2040  get_value(XYZ self, ParticleIndexKey a0) -> Particle
2041  get_value(XYZ self, ObjectKey a0) -> Object
2042  get_value(XYZ self, SparseFloatKey a0) -> IMP::Float
2043  get_value(XYZ self, SparseIntKey a0) -> IMP::Int
2044  get_value(XYZ self, SparseStringKey a0) -> IMP::String
2045  get_value(XYZ self, SparseParticleIndexKey a0) -> ParticleIndex
2046  """
2047  return _IMP_core.XYZ_get_value(self, *args)
2048 
2049  def set_value(self, *args):
2050  r"""
2051  set_value(XYZ self, FloatKey a0, IMP::Float a1)
2052  set_value(XYZ self, IntKey a0, IMP::Int a1)
2053  set_value(XYZ self, FloatsKey a0, IMP::Floats a1)
2054  set_value(XYZ self, IntsKey a0, IMP::Ints a1)
2055  set_value(XYZ self, StringKey a0, IMP::String a1)
2056  set_value(XYZ self, ParticleIndexKey a0, Particle a1)
2057  set_value(XYZ self, ObjectKey a0, Object a1)
2058  set_value(XYZ self, SparseFloatKey a0, IMP::Float a1)
2059  set_value(XYZ self, SparseIntKey a0, IMP::Int a1)
2060  set_value(XYZ self, SparseStringKey a0, IMP::String a1)
2061  set_value(XYZ self, SparseParticleIndexKey a0, ParticleIndex a1)
2062  """
2063  return _IMP_core.XYZ_set_value(self, *args)
2064 
2065  def remove_attribute(self, *args):
2066  r"""
2067  remove_attribute(XYZ self, FloatKey a0)
2068  remove_attribute(XYZ self, IntKey a0)
2069  remove_attribute(XYZ self, FloatsKey a0)
2070  remove_attribute(XYZ self, IntsKey a0)
2071  remove_attribute(XYZ self, StringKey a0)
2072  remove_attribute(XYZ self, ParticleIndexKey a0)
2073  remove_attribute(XYZ self, ObjectKey a0)
2074  remove_attribute(XYZ self, SparseFloatKey a0)
2075  remove_attribute(XYZ self, SparseIntKey a0)
2076  remove_attribute(XYZ self, SparseStringKey a0)
2077  remove_attribute(XYZ self, SparseParticleIndexKey a0)
2078  """
2079  return _IMP_core.XYZ_remove_attribute(self, *args)
2080 
2081  def has_attribute(self, *args):
2082  r"""
2083  has_attribute(XYZ self, FloatKey a0) -> bool
2084  has_attribute(XYZ self, IntKey a0) -> bool
2085  has_attribute(XYZ self, FloatsKey a0) -> bool
2086  has_attribute(XYZ self, IntsKey a0) -> bool
2087  has_attribute(XYZ self, StringKey a0) -> bool
2088  has_attribute(XYZ self, ParticleIndexKey a0) -> bool
2089  has_attribute(XYZ self, ObjectKey a0) -> bool
2090  has_attribute(XYZ self, SparseFloatKey a0) -> bool
2091  has_attribute(XYZ self, SparseIntKey a0) -> bool
2092  has_attribute(XYZ self, SparseStringKey a0) -> bool
2093  has_attribute(XYZ self, SparseParticleIndexKey a0) -> bool
2094  """
2095  return _IMP_core.XYZ_has_attribute(self, *args)
2096 
2097  def get_derivative(self, *args):
2098  r"""
2099  get_derivative(XYZ self, int i) -> IMP::Float
2100  get_derivative(XYZ self, FloatKey a0) -> double
2101  """
2102  return _IMP_core.XYZ_get_derivative(self, *args)
2103 
2104  def get_name(self):
2105  r"""get_name(XYZ self) -> std::string"""
2106  return _IMP_core.XYZ_get_name(self)
2107 
2108  def clear_caches(self):
2109  r"""clear_caches(XYZ self)"""
2110  return _IMP_core.XYZ_clear_caches(self)
2111 
2112  def set_name(self, a0):
2113  r"""set_name(XYZ self, std::string a0)"""
2114  return _IMP_core.XYZ_set_name(self, a0)
2115 
2116  def set_check_level(self, a0):
2117  r"""set_check_level(XYZ self, IMP::CheckLevel a0)"""
2118  return _IMP_core.XYZ_set_check_level(self, a0)
2119 
2120  def add_to_derivative(self, *args):
2121  r"""
2122  add_to_derivative(XYZ self, int i, IMP::Float v, DerivativeAccumulator d)
2123  add_to_derivative(XYZ self, FloatKey a0, double a1, DerivativeAccumulator a2)
2124  """
2125  return _IMP_core.XYZ_add_to_derivative(self, *args)
2126 
2127  def set_is_optimized(self, a0, a1):
2128  r"""set_is_optimized(XYZ self, FloatKey a0, bool a1)"""
2129  return _IMP_core.XYZ_set_is_optimized(self, a0, a1)
2130 
2131  def get_is_optimized(self, a0):
2132  r"""get_is_optimized(XYZ self, FloatKey a0) -> bool"""
2133  return _IMP_core.XYZ_get_is_optimized(self, a0)
2134 
2135  def get_check_level(self):
2136  r"""get_check_level(XYZ self) -> IMP::CheckLevel"""
2137  return _IMP_core.XYZ_get_check_level(self)
2138 
2139  def __eq__(self, *args):
2140  r"""
2141  __eq__(XYZ self, XYZ o) -> bool
2142  __eq__(XYZ self, Particle d) -> bool
2143  """
2144  return _IMP_core.XYZ___eq__(self, *args)
2145 
2146  def __ne__(self, *args):
2147  r"""
2148  __ne__(XYZ self, XYZ o) -> bool
2149  __ne__(XYZ self, Particle d) -> bool
2150  """
2151  return _IMP_core.XYZ___ne__(self, *args)
2152 
2153  def __le__(self, *args):
2154  r"""
2155  __le__(XYZ self, XYZ o) -> bool
2156  __le__(XYZ self, Particle d) -> bool
2157  """
2158  return _IMP_core.XYZ___le__(self, *args)
2159 
2160  def __lt__(self, *args):
2161  r"""
2162  __lt__(XYZ self, XYZ o) -> bool
2163  __lt__(XYZ self, Particle d) -> bool
2164  """
2165  return _IMP_core.XYZ___lt__(self, *args)
2166 
2167  def __ge__(self, *args):
2168  r"""
2169  __ge__(XYZ self, XYZ o) -> bool
2170  __ge__(XYZ self, Particle d) -> bool
2171  """
2172  return _IMP_core.XYZ___ge__(self, *args)
2173 
2174  def __gt__(self, *args):
2175  r"""
2176  __gt__(XYZ self, XYZ o) -> bool
2177  __gt__(XYZ self, Particle d) -> bool
2178  """
2179  return _IMP_core.XYZ___gt__(self, *args)
2180 
2181  def __hash__(self):
2182  r"""__hash__(XYZ self) -> std::size_t"""
2183  return _IMP_core.XYZ___hash__(self)
2184 
2185  def __str__(self):
2186  r"""__str__(XYZ self) -> std::string"""
2187  return _IMP_core.XYZ___str__(self)
2188 
2189  def __repr__(self):
2190  r"""__repr__(XYZ self) -> std::string"""
2191  return _IMP_core.XYZ___repr__(self)
2192 
2193  def _get_as_binary(self):
2194  r"""_get_as_binary(XYZ self) -> PyObject *"""
2195  return _IMP_core.XYZ__get_as_binary(self)
2196 
2197  def _set_from_binary(self, p):
2198  r"""_set_from_binary(XYZ self, PyObject * p)"""
2199  return _IMP_core.XYZ__set_from_binary(self, p)
2200 
2201  def __getstate__(self):
2202  p = self._get_as_binary()
2203  if len(self.__dict__) > 1:
2204  d = self.__dict__.copy()
2205  del d['this']
2206  p = (d, p)
2207  return p
2208 
2209  def __setstate__(self, p):
2210  if not hasattr(self, 'this'):
2211  self.__init__()
2212  if isinstance(p, tuple):
2213  d, p = p
2214  self.__dict__.update(d)
2215  return self._set_from_binary(p)
2216 
2217  __swig_destroy__ = _IMP_core.delete_XYZ
2218 
2219 # Register XYZ in _IMP_core:
2220 _IMP_core.XYZ_swigregister(XYZ)
2221 
2222 def set_vector_geometry(d, v):
2223  r"""set_vector_geometry(XYZ d, Vector3D v)"""
2224  return _IMP_core.set_vector_geometry(d, v)
2225 
2226 def get_vector_geometry(d):
2227  r"""get_vector_geometry(XYZ d) -> Vector3D"""
2228  return _IMP_core.get_vector_geometry(d)
2229 
2230 def get_dihedral(a, b, c, d):
2231  r"""get_dihedral(XYZ a, XYZ b, XYZ c, XYZ d) -> double"""
2232  return _IMP_core.get_dihedral(a, b, c, d)
2233 class XYZR(XYZ):
2234  r"""Proxy of C++ IMP::core::XYZR class."""
2235 
2236  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
2237 
2238  def __init__(self, *args):
2239  r"""
2240  __init__(XYZR self) -> XYZR
2241  __init__(XYZR self, Model m, ParticleIndex id) -> XYZR
2242  __init__(XYZR self, _ParticleAdaptor d) -> XYZR
2243  """
2244  _IMP_core.XYZR_swiginit(self, _IMP_core.new_XYZR(*args))
2245 
2246  def show(self, *args):
2247  r"""show(XYZR self, _ostream out=std::cout)"""
2248  return _IMP_core.XYZR_show(self, *args)
2249 
2250  @staticmethod
2251  def setup_particle(*args):
2252  r"""
2253  setup_particle(Model m, ParticleIndex pi) -> XYZR
2254  setup_particle(_ParticleAdaptor pa) -> XYZR
2255  setup_particle(Model m, ParticleIndex pi, IMP::Float radius) -> XYZR
2256  setup_particle(_ParticleAdaptor pa, IMP::Float radius) -> XYZR
2257  setup_particle(Model m, ParticleIndex pi, Sphere3D ball) -> XYZR
2258  setup_particle(_ParticleAdaptor pa, Sphere3D ball) -> XYZR
2259  """
2260  return _IMP_core.XYZR_setup_particle(*args)
2261 
2262  @staticmethod
2263  def get_is_setup(*args):
2264  r"""
2265  get_is_setup(_ParticleAdaptor p) -> bool
2266  get_is_setup(Model m, ParticleIndex pi) -> bool
2267  """
2268  return _IMP_core.XYZR_get_is_setup(*args)
2269 
2270  def get_radius(self):
2271  r"""get_radius(XYZR self) -> double"""
2272  return _IMP_core.XYZR_get_radius(self)
2273 
2274  def set_radius(self, r):
2275  r"""set_radius(XYZR self, double r)"""
2276  return _IMP_core.XYZR_set_radius(self, r)
2277 
2278  def get_sphere(self):
2279  r"""get_sphere(XYZR self) -> Sphere3D"""
2280  return _IMP_core.XYZR_get_sphere(self)
2281 
2282  def set_sphere(self, s):
2283  r"""set_sphere(XYZR self, Sphere3D s)"""
2284  return _IMP_core.XYZR_set_sphere(self, s)
2285 
2286  @staticmethod
2287  def get_radius_key():
2288  r"""get_radius_key() -> FloatKey"""
2289  return _IMP_core.XYZR_get_radius_key()
2290 
2291  def add_to_radius_derivative(self, v, d):
2292  r"""add_to_radius_derivative(XYZR self, double v, DerivativeAccumulator d)"""
2293  return _IMP_core.XYZR_add_to_radius_derivative(self, v, d)
2294 
2295  def add_attribute(self, *args):
2296  r"""
2297  add_attribute(XYZR self, FloatKey k, IMP::Float v, bool opt)
2298  add_attribute(XYZR self, FloatKey a0, IMP::Float a1)
2299  add_attribute(XYZR self, IntKey a0, IMP::Int a1)
2300  add_attribute(XYZR self, FloatsKey a0, IMP::Floats a1)
2301  add_attribute(XYZR self, IntsKey a0, IMP::Ints a1)
2302  add_attribute(XYZR self, StringKey a0, IMP::String a1)
2303  add_attribute(XYZR self, ParticleIndexKey a0, Particle a1)
2304  add_attribute(XYZR self, ObjectKey a0, Object a1)
2305  add_attribute(XYZR self, SparseFloatKey a0, IMP::Float a1)
2306  add_attribute(XYZR self, SparseIntKey a0, IMP::Int a1)
2307  add_attribute(XYZR self, SparseStringKey a0, IMP::String a1)
2308  add_attribute(XYZR self, SparseParticleIndexKey a0, ParticleIndex a1)
2309  """
2310  return _IMP_core.XYZR_add_attribute(self, *args)
2311 
2312  def get_value(self, *args):
2313  r"""
2314  get_value(XYZR self, FloatKey a0) -> IMP::Float
2315  get_value(XYZR self, IntKey a0) -> IMP::Int
2316  get_value(XYZR self, FloatsKey a0) -> IMP::Floats
2317  get_value(XYZR self, IntsKey a0) -> IMP::Ints
2318  get_value(XYZR self, StringKey a0) -> IMP::String
2319  get_value(XYZR self, ParticleIndexKey a0) -> Particle
2320  get_value(XYZR self, ObjectKey a0) -> Object
2321  get_value(XYZR self, SparseFloatKey a0) -> IMP::Float
2322  get_value(XYZR self, SparseIntKey a0) -> IMP::Int
2323  get_value(XYZR self, SparseStringKey a0) -> IMP::String
2324  get_value(XYZR self, SparseParticleIndexKey a0) -> ParticleIndex
2325  """
2326  return _IMP_core.XYZR_get_value(self, *args)
2327 
2328  def set_value(self, *args):
2329  r"""
2330  set_value(XYZR self, FloatKey a0, IMP::Float a1)
2331  set_value(XYZR self, IntKey a0, IMP::Int a1)
2332  set_value(XYZR self, FloatsKey a0, IMP::Floats a1)
2333  set_value(XYZR self, IntsKey a0, IMP::Ints a1)
2334  set_value(XYZR self, StringKey a0, IMP::String a1)
2335  set_value(XYZR self, ParticleIndexKey a0, Particle a1)
2336  set_value(XYZR self, ObjectKey a0, Object a1)
2337  set_value(XYZR self, SparseFloatKey a0, IMP::Float a1)
2338  set_value(XYZR self, SparseIntKey a0, IMP::Int a1)
2339  set_value(XYZR self, SparseStringKey a0, IMP::String a1)
2340  set_value(XYZR self, SparseParticleIndexKey a0, ParticleIndex a1)
2341  """
2342  return _IMP_core.XYZR_set_value(self, *args)
2343 
2344  def remove_attribute(self, *args):
2345  r"""
2346  remove_attribute(XYZR self, FloatKey a0)
2347  remove_attribute(XYZR self, IntKey a0)
2348  remove_attribute(XYZR self, FloatsKey a0)
2349  remove_attribute(XYZR self, IntsKey a0)
2350  remove_attribute(XYZR self, StringKey a0)
2351  remove_attribute(XYZR self, ParticleIndexKey a0)
2352  remove_attribute(XYZR self, ObjectKey a0)
2353  remove_attribute(XYZR self, SparseFloatKey a0)
2354  remove_attribute(XYZR self, SparseIntKey a0)
2355  remove_attribute(XYZR self, SparseStringKey a0)
2356  remove_attribute(XYZR self, SparseParticleIndexKey a0)
2357  """
2358  return _IMP_core.XYZR_remove_attribute(self, *args)
2359 
2360  def has_attribute(self, *args):
2361  r"""
2362  has_attribute(XYZR self, FloatKey a0) -> bool
2363  has_attribute(XYZR self, IntKey a0) -> bool
2364  has_attribute(XYZR self, FloatsKey a0) -> bool
2365  has_attribute(XYZR self, IntsKey a0) -> bool
2366  has_attribute(XYZR self, StringKey a0) -> bool
2367  has_attribute(XYZR self, ParticleIndexKey a0) -> bool
2368  has_attribute(XYZR self, ObjectKey a0) -> bool
2369  has_attribute(XYZR self, SparseFloatKey a0) -> bool
2370  has_attribute(XYZR self, SparseIntKey a0) -> bool
2371  has_attribute(XYZR self, SparseStringKey a0) -> bool
2372  has_attribute(XYZR self, SparseParticleIndexKey a0) -> bool
2373  """
2374  return _IMP_core.XYZR_has_attribute(self, *args)
2375 
2376  def get_derivative(self, a0):
2377  r"""get_derivative(XYZR self, FloatKey a0) -> double"""
2378  return _IMP_core.XYZR_get_derivative(self, a0)
2379 
2380  def get_name(self):
2381  r"""get_name(XYZR self) -> std::string"""
2382  return _IMP_core.XYZR_get_name(self)
2383 
2384  def clear_caches(self):
2385  r"""clear_caches(XYZR self)"""
2386  return _IMP_core.XYZR_clear_caches(self)
2387 
2388  def set_name(self, a0):
2389  r"""set_name(XYZR self, std::string a0)"""
2390  return _IMP_core.XYZR_set_name(self, a0)
2391 
2392  def set_check_level(self, a0):
2393  r"""set_check_level(XYZR self, IMP::CheckLevel a0)"""
2394  return _IMP_core.XYZR_set_check_level(self, a0)
2395 
2396  def add_to_derivative(self, a0, a1, a2):
2397  r"""add_to_derivative(XYZR self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
2398  return _IMP_core.XYZR_add_to_derivative(self, a0, a1, a2)
2399 
2400  def set_is_optimized(self, a0, a1):
2401  r"""set_is_optimized(XYZR self, FloatKey a0, bool a1)"""
2402  return _IMP_core.XYZR_set_is_optimized(self, a0, a1)
2403 
2404  def get_is_optimized(self, a0):
2405  r"""get_is_optimized(XYZR self, FloatKey a0) -> bool"""
2406  return _IMP_core.XYZR_get_is_optimized(self, a0)
2407 
2408  def get_check_level(self):
2409  r"""get_check_level(XYZR self) -> IMP::CheckLevel"""
2410  return _IMP_core.XYZR_get_check_level(self)
2411 
2412  def __eq__(self, *args):
2413  r"""
2414  __eq__(XYZR self, XYZR o) -> bool
2415  __eq__(XYZR self, Particle d) -> bool
2416  """
2417  return _IMP_core.XYZR___eq__(self, *args)
2418 
2419  def __ne__(self, *args):
2420  r"""
2421  __ne__(XYZR self, XYZR o) -> bool
2422  __ne__(XYZR self, Particle d) -> bool
2423  """
2424  return _IMP_core.XYZR___ne__(self, *args)
2425 
2426  def __le__(self, *args):
2427  r"""
2428  __le__(XYZR self, XYZR o) -> bool
2429  __le__(XYZR self, Particle d) -> bool
2430  """
2431  return _IMP_core.XYZR___le__(self, *args)
2432 
2433  def __lt__(self, *args):
2434  r"""
2435  __lt__(XYZR self, XYZR o) -> bool
2436  __lt__(XYZR self, Particle d) -> bool
2437  """
2438  return _IMP_core.XYZR___lt__(self, *args)
2439 
2440  def __ge__(self, *args):
2441  r"""
2442  __ge__(XYZR self, XYZR o) -> bool
2443  __ge__(XYZR self, Particle d) -> bool
2444  """
2445  return _IMP_core.XYZR___ge__(self, *args)
2446 
2447  def __gt__(self, *args):
2448  r"""
2449  __gt__(XYZR self, XYZR o) -> bool
2450  __gt__(XYZR self, Particle d) -> bool
2451  """
2452  return _IMP_core.XYZR___gt__(self, *args)
2453 
2454  def __hash__(self):
2455  r"""__hash__(XYZR self) -> std::size_t"""
2456  return _IMP_core.XYZR___hash__(self)
2457 
2458  def __str__(self):
2459  r"""__str__(XYZR self) -> std::string"""
2460  return _IMP_core.XYZR___str__(self)
2461 
2462  def __repr__(self):
2463  r"""__repr__(XYZR self) -> std::string"""
2464  return _IMP_core.XYZR___repr__(self)
2465 
2466  def _get_as_binary(self):
2467  r"""_get_as_binary(XYZR self) -> PyObject *"""
2468  return _IMP_core.XYZR__get_as_binary(self)
2469 
2470  def _set_from_binary(self, p):
2471  r"""_set_from_binary(XYZR self, PyObject * p)"""
2472  return _IMP_core.XYZR__set_from_binary(self, p)
2473 
2474  def __getstate__(self):
2475  p = self._get_as_binary()
2476  if len(self.__dict__) > 1:
2477  d = self.__dict__.copy()
2478  del d['this']
2479  p = (d, p)
2480  return p
2481 
2482  def __setstate__(self, p):
2483  if not hasattr(self, 'this'):
2484  self.__init__()
2485  if isinstance(p, tuple):
2486  d, p = p
2487  self.__dict__.update(d)
2488  return self._set_from_binary(p)
2489 
2490  __swig_destroy__ = _IMP_core.delete_XYZR
2491 
2492 # Register XYZR in _IMP_core:
2493 _IMP_core.XYZR_swigregister(XYZR)
2494 
2495 def set_enclosing_sphere(b, v, slack=0):
2496  r"""set_enclosing_sphere(XYZR b, IMP::core::XYZs const & v, double slack=0)"""
2497  return _IMP_core.set_enclosing_sphere(b, v, slack)
2498 
2499 def set_enclosing_radius(b, v):
2500  r"""set_enclosing_radius(XYZR b, IMP::core::XYZs const & v)"""
2501  return _IMP_core.set_enclosing_radius(b, v)
2502 
2503 def get_enclosing_sphere(v):
2504  r"""get_enclosing_sphere(IMP::core::XYZs const & v) -> Sphere3D"""
2505  return _IMP_core.get_enclosing_sphere(v)
2506 
2507 def create_xyzr_particles(m, num, radius, box_side=10):
2508  r"""create_xyzr_particles(Model m, unsigned int num, IMP::Float radius, IMP::Float box_side=10) -> IMP::core::XYZRs"""
2509  return _IMP_core.create_xyzr_particles(m, num, radius, box_side)
2510 class XYZRGeometry(IMP.display.SingletonGeometry):
2511  r"""Proxy of C++ IMP::core::XYZRGeometry class."""
2512 
2513  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
2514 
2515  def __init__(self, *args):
2516  r"""
2517  __init__(XYZRGeometry self, Particle p) -> XYZRGeometry
2518  __init__(XYZRGeometry self, XYZR d) -> XYZRGeometry
2519  """
2520  _IMP_core.XYZRGeometry_swiginit(self, _IMP_core.new_XYZRGeometry(*args))
2521 
2522  def get_version_info(self):
2523  r"""get_version_info(XYZRGeometry self) -> VersionInfo"""
2524  return _IMP_core.XYZRGeometry_get_version_info(self)
2525  __swig_destroy__ = _IMP_core.delete_XYZRGeometry
2526 
2527  def __str__(self):
2528  r"""__str__(XYZRGeometry self) -> std::string"""
2529  return _IMP_core.XYZRGeometry___str__(self)
2530 
2531  def __repr__(self):
2532  r"""__repr__(XYZRGeometry self) -> std::string"""
2533  return _IMP_core.XYZRGeometry___repr__(self)
2534 
2535  @staticmethod
2536  def get_from(o):
2537  return _object_cast_to_XYZRGeometry(o)
2538 
2539 
2540 # Register XYZRGeometry in _IMP_core:
2541 _IMP_core.XYZRGeometry_swigregister(XYZRGeometry)
2542 class XYZRsGeometry(IMP.display.SingletonsGeometry):
2543  r"""Proxy of C++ IMP::core::XYZRsGeometry class."""
2544 
2545  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
2546 
2547  def __init__(self, sc):
2548  r"""__init__(XYZRsGeometry self, SingletonContainer sc) -> XYZRsGeometry"""
2549  _IMP_core.XYZRsGeometry_swiginit(self, _IMP_core.new_XYZRsGeometry(sc))
2550 
2551  def get_version_info(self):
2552  r"""get_version_info(XYZRsGeometry self) -> VersionInfo"""
2553  return _IMP_core.XYZRsGeometry_get_version_info(self)
2554  __swig_destroy__ = _IMP_core.delete_XYZRsGeometry
2555 
2556  def __str__(self):
2557  r"""__str__(XYZRsGeometry self) -> std::string"""
2558  return _IMP_core.XYZRsGeometry___str__(self)
2559 
2560  def __repr__(self):
2561  r"""__repr__(XYZRsGeometry self) -> std::string"""
2562  return _IMP_core.XYZRsGeometry___repr__(self)
2563 
2564  @staticmethod
2565  def get_from(o):
2566  return _object_cast_to_XYZRsGeometry(o)
2567 
2568 
2569 # Register XYZRsGeometry in _IMP_core:
2570 _IMP_core.XYZRsGeometry_swigregister(XYZRsGeometry)
2571 class XYZDerivativeGeometry(IMP.display.SingletonGeometry):
2572  r"""Proxy of C++ IMP::core::XYZDerivativeGeometry class."""
2573 
2574  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
2575 
2576  def __init__(self, *args):
2577  r"""
2578  __init__(XYZDerivativeGeometry self, Particle p) -> XYZDerivativeGeometry
2579  __init__(XYZDerivativeGeometry self, XYZ d) -> XYZDerivativeGeometry
2580  """
2581  _IMP_core.XYZDerivativeGeometry_swiginit(self, _IMP_core.new_XYZDerivativeGeometry(*args))
2582 
2583  def get_version_info(self):
2584  r"""get_version_info(XYZDerivativeGeometry self) -> VersionInfo"""
2585  return _IMP_core.XYZDerivativeGeometry_get_version_info(self)
2586  __swig_destroy__ = _IMP_core.delete_XYZDerivativeGeometry
2587 
2588  def __str__(self):
2589  r"""__str__(XYZDerivativeGeometry self) -> std::string"""
2590  return _IMP_core.XYZDerivativeGeometry___str__(self)
2591 
2592  def __repr__(self):
2593  r"""__repr__(XYZDerivativeGeometry self) -> std::string"""
2594  return _IMP_core.XYZDerivativeGeometry___repr__(self)
2595 
2596  @staticmethod
2597  def get_from(o):
2598  return _object_cast_to_XYZDerivativeGeometry(o)
2599 
2600 
2601 # Register XYZDerivativeGeometry in _IMP_core:
2602 _IMP_core.XYZDerivativeGeometry_swigregister(XYZDerivativeGeometry)
2603 class XYZDerivativesGeometry(IMP.display.SingletonsGeometry):
2604  r"""Proxy of C++ IMP::core::XYZDerivativesGeometry class."""
2605 
2606  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
2607 
2608  def __init__(self, sc):
2609  r"""__init__(XYZDerivativesGeometry self, SingletonContainer sc) -> XYZDerivativesGeometry"""
2610  _IMP_core.XYZDerivativesGeometry_swiginit(self, _IMP_core.new_XYZDerivativesGeometry(sc))
2611 
2612  def get_version_info(self):
2613  r"""get_version_info(XYZDerivativesGeometry self) -> VersionInfo"""
2614  return _IMP_core.XYZDerivativesGeometry_get_version_info(self)
2615  __swig_destroy__ = _IMP_core.delete_XYZDerivativesGeometry
2616 
2617  def __str__(self):
2618  r"""__str__(XYZDerivativesGeometry self) -> std::string"""
2619  return _IMP_core.XYZDerivativesGeometry___str__(self)
2620 
2621  def __repr__(self):
2622  r"""__repr__(XYZDerivativesGeometry self) -> std::string"""
2623  return _IMP_core.XYZDerivativesGeometry___repr__(self)
2624 
2625  @staticmethod
2626  def get_from(o):
2627  return _object_cast_to_XYZDerivativesGeometry(o)
2628 
2629 
2630 # Register XYZDerivativesGeometry in _IMP_core:
2631 _IMP_core.XYZDerivativesGeometry_swigregister(XYZDerivativesGeometry)
2632 class EdgePairGeometry(IMP.display.PairGeometry):
2633  r"""Proxy of C++ IMP::core::EdgePairGeometry class."""
2634 
2635  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
2636 
2637  def __init__(self, pp):
2638  r"""__init__(EdgePairGeometry self, IMP::ParticlePair const & pp) -> EdgePairGeometry"""
2639  _IMP_core.EdgePairGeometry_swiginit(self, _IMP_core.new_EdgePairGeometry(pp))
2640 
2641  def get_version_info(self):
2642  r"""get_version_info(EdgePairGeometry self) -> VersionInfo"""
2643  return _IMP_core.EdgePairGeometry_get_version_info(self)
2644  __swig_destroy__ = _IMP_core.delete_EdgePairGeometry
2645 
2646  def __str__(self):
2647  r"""__str__(EdgePairGeometry self) -> std::string"""
2648  return _IMP_core.EdgePairGeometry___str__(self)
2649 
2650  def __repr__(self):
2651  r"""__repr__(EdgePairGeometry self) -> std::string"""
2652  return _IMP_core.EdgePairGeometry___repr__(self)
2653 
2654  @staticmethod
2655  def get_from(o):
2656  return _object_cast_to_EdgePairGeometry(o)
2657 
2658 
2659 # Register EdgePairGeometry in _IMP_core:
2660 _IMP_core.EdgePairGeometry_swigregister(EdgePairGeometry)
2661 class EdgePairsGeometry(IMP.display.PairsGeometry):
2662  r"""Proxy of C++ IMP::core::EdgePairsGeometry class."""
2663 
2664  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
2665 
2666  def __init__(self, sc):
2667  r"""__init__(EdgePairsGeometry self, PairContainer sc) -> EdgePairsGeometry"""
2668  _IMP_core.EdgePairsGeometry_swiginit(self, _IMP_core.new_EdgePairsGeometry(sc))
2669 
2670  def get_version_info(self):
2671  r"""get_version_info(EdgePairsGeometry self) -> VersionInfo"""
2672  return _IMP_core.EdgePairsGeometry_get_version_info(self)
2673  __swig_destroy__ = _IMP_core.delete_EdgePairsGeometry
2674 
2675  def __str__(self):
2676  r"""__str__(EdgePairsGeometry self) -> std::string"""
2677  return _IMP_core.EdgePairsGeometry___str__(self)
2678 
2679  def __repr__(self):
2680  r"""__repr__(EdgePairsGeometry self) -> std::string"""
2681  return _IMP_core.EdgePairsGeometry___repr__(self)
2682 
2683  @staticmethod
2684  def get_from(o):
2685  return _object_cast_to_EdgePairsGeometry(o)
2686 
2687 
2688 # Register EdgePairsGeometry in _IMP_core:
2689 _IMP_core.EdgePairsGeometry_swigregister(EdgePairsGeometry)
2690 class Direction(IMP.Decorator):
2691  r"""Proxy of C++ IMP::core::Direction class."""
2692 
2693  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
2694 
2695  @staticmethod
2696  def do_setup_particle(m, pi, v):
2697  r"""do_setup_particle(Model m, ParticleIndex pi, Vector3D v)"""
2698  return _IMP_core.Direction_do_setup_particle(m, pi, v)
2699 
2700  def __init__(self, *args):
2701  r"""
2702  __init__(Direction self) -> Direction
2703  __init__(Direction self, Model m, ParticleIndex id) -> Direction
2704  __init__(Direction self, _ParticleAdaptor d) -> Direction
2705  """
2706  _IMP_core.Direction_swiginit(self, _IMP_core.new_Direction(*args))
2707 
2708  def show(self, *args):
2709  r"""show(Direction self, _ostream out=std::cout)"""
2710  return _IMP_core.Direction_show(self, *args)
2711 
2712  @staticmethod
2713  def setup_particle(*args):
2714  r"""
2715  setup_particle(Model m, ParticleIndex pi, Vector3D v) -> Direction
2716  setup_particle(_ParticleAdaptor pa, Vector3D v) -> Direction
2717  """
2718  return _IMP_core.Direction_setup_particle(*args)
2719 
2720  @staticmethod
2721  def get_is_setup(*args):
2722  r"""
2723  get_is_setup(_ParticleAdaptor p) -> bool
2724  get_is_setup(Model m, ParticleIndex pi) -> bool
2725  """
2726  return _IMP_core.Direction_get_is_setup(*args)
2727 
2728  @staticmethod
2729  def get_direction_key(i):
2730  r"""get_direction_key(unsigned int i) -> FloatKey"""
2731  return _IMP_core.Direction_get_direction_key(i)
2732 
2733  def get_direction_derivative(self, i):
2734  r"""get_direction_derivative(Direction self, int i) -> IMP::Float"""
2735  return _IMP_core.Direction_get_direction_derivative(self, i)
2736 
2737  def get_direction_derivatives(self):
2738  r"""get_direction_derivatives(Direction self) -> Vector3D"""
2739  return _IMP_core.Direction_get_direction_derivatives(self)
2740 
2741  def add_to_direction_derivative(self, i, v, d):
2742  r"""add_to_direction_derivative(Direction self, int i, IMP::Float v, DerivativeAccumulator d)"""
2743  return _IMP_core.Direction_add_to_direction_derivative(self, i, v, d)
2744 
2745  def add_to_direction_derivatives(self, v, d):
2746  r"""add_to_direction_derivatives(Direction self, Vector3D v, DerivativeAccumulator d)"""
2747  return _IMP_core.Direction_add_to_direction_derivatives(self, v, d)
2748 
2749  def get_direction_is_optimized(self):
2750  r"""get_direction_is_optimized(Direction self) -> bool"""
2751  return _IMP_core.Direction_get_direction_is_optimized(self)
2752 
2753  def set_direction_is_optimized(self, tf):
2754  r"""set_direction_is_optimized(Direction self, bool tf)"""
2755  return _IMP_core.Direction_set_direction_is_optimized(self, tf)
2756 
2757  def get_direction(self):
2758  r"""get_direction(Direction self) -> Vector3D"""
2759  return _IMP_core.Direction_get_direction(self)
2760 
2761  def set_direction(self, v):
2762  r"""set_direction(Direction self, Vector3D v)"""
2763  return _IMP_core.Direction_set_direction(self, v)
2764 
2765  def reflect(self):
2766  r"""reflect(Direction self)"""
2767  return _IMP_core.Direction_reflect(self)
2768 
2769  def add_attribute(self, *args):
2770  r"""
2771  add_attribute(Direction self, FloatKey k, IMP::Float v, bool opt)
2772  add_attribute(Direction self, FloatKey a0, IMP::Float a1)
2773  add_attribute(Direction self, IntKey a0, IMP::Int a1)
2774  add_attribute(Direction self, FloatsKey a0, IMP::Floats a1)
2775  add_attribute(Direction self, IntsKey a0, IMP::Ints a1)
2776  add_attribute(Direction self, StringKey a0, IMP::String a1)
2777  add_attribute(Direction self, ParticleIndexKey a0, Particle a1)
2778  add_attribute(Direction self, ObjectKey a0, Object a1)
2779  add_attribute(Direction self, SparseFloatKey a0, IMP::Float a1)
2780  add_attribute(Direction self, SparseIntKey a0, IMP::Int a1)
2781  add_attribute(Direction self, SparseStringKey a0, IMP::String a1)
2782  add_attribute(Direction self, SparseParticleIndexKey a0, ParticleIndex a1)
2783  """
2784  return _IMP_core.Direction_add_attribute(self, *args)
2785 
2786  def get_value(self, *args):
2787  r"""
2788  get_value(Direction self, FloatKey a0) -> IMP::Float
2789  get_value(Direction self, IntKey a0) -> IMP::Int
2790  get_value(Direction self, FloatsKey a0) -> IMP::Floats
2791  get_value(Direction self, IntsKey a0) -> IMP::Ints
2792  get_value(Direction self, StringKey a0) -> IMP::String
2793  get_value(Direction self, ParticleIndexKey a0) -> Particle
2794  get_value(Direction self, ObjectKey a0) -> Object
2795  get_value(Direction self, SparseFloatKey a0) -> IMP::Float
2796  get_value(Direction self, SparseIntKey a0) -> IMP::Int
2797  get_value(Direction self, SparseStringKey a0) -> IMP::String
2798  get_value(Direction self, SparseParticleIndexKey a0) -> ParticleIndex
2799  """
2800  return _IMP_core.Direction_get_value(self, *args)
2801 
2802  def set_value(self, *args):
2803  r"""
2804  set_value(Direction self, FloatKey a0, IMP::Float a1)
2805  set_value(Direction self, IntKey a0, IMP::Int a1)
2806  set_value(Direction self, FloatsKey a0, IMP::Floats a1)
2807  set_value(Direction self, IntsKey a0, IMP::Ints a1)
2808  set_value(Direction self, StringKey a0, IMP::String a1)
2809  set_value(Direction self, ParticleIndexKey a0, Particle a1)
2810  set_value(Direction self, ObjectKey a0, Object a1)
2811  set_value(Direction self, SparseFloatKey a0, IMP::Float a1)
2812  set_value(Direction self, SparseIntKey a0, IMP::Int a1)
2813  set_value(Direction self, SparseStringKey a0, IMP::String a1)
2814  set_value(Direction self, SparseParticleIndexKey a0, ParticleIndex a1)
2815  """
2816  return _IMP_core.Direction_set_value(self, *args)
2817 
2818  def remove_attribute(self, *args):
2819  r"""
2820  remove_attribute(Direction self, FloatKey a0)
2821  remove_attribute(Direction self, IntKey a0)
2822  remove_attribute(Direction self, FloatsKey a0)
2823  remove_attribute(Direction self, IntsKey a0)
2824  remove_attribute(Direction self, StringKey a0)
2825  remove_attribute(Direction self, ParticleIndexKey a0)
2826  remove_attribute(Direction self, ObjectKey a0)
2827  remove_attribute(Direction self, SparseFloatKey a0)
2828  remove_attribute(Direction self, SparseIntKey a0)
2829  remove_attribute(Direction self, SparseStringKey a0)
2830  remove_attribute(Direction self, SparseParticleIndexKey a0)
2831  """
2832  return _IMP_core.Direction_remove_attribute(self, *args)
2833 
2834  def has_attribute(self, *args):
2835  r"""
2836  has_attribute(Direction self, FloatKey a0) -> bool
2837  has_attribute(Direction self, IntKey a0) -> bool
2838  has_attribute(Direction self, FloatsKey a0) -> bool
2839  has_attribute(Direction self, IntsKey a0) -> bool
2840  has_attribute(Direction self, StringKey a0) -> bool
2841  has_attribute(Direction self, ParticleIndexKey a0) -> bool
2842  has_attribute(Direction self, ObjectKey a0) -> bool
2843  has_attribute(Direction self, SparseFloatKey a0) -> bool
2844  has_attribute(Direction self, SparseIntKey a0) -> bool
2845  has_attribute(Direction self, SparseStringKey a0) -> bool
2846  has_attribute(Direction self, SparseParticleIndexKey a0) -> bool
2847  """
2848  return _IMP_core.Direction_has_attribute(self, *args)
2849 
2850  def get_derivative(self, a0):
2851  r"""get_derivative(Direction self, FloatKey a0) -> double"""
2852  return _IMP_core.Direction_get_derivative(self, a0)
2853 
2854  def get_name(self):
2855  r"""get_name(Direction self) -> std::string"""
2856  return _IMP_core.Direction_get_name(self)
2857 
2858  def clear_caches(self):
2859  r"""clear_caches(Direction self)"""
2860  return _IMP_core.Direction_clear_caches(self)
2861 
2862  def set_name(self, a0):
2863  r"""set_name(Direction self, std::string a0)"""
2864  return _IMP_core.Direction_set_name(self, a0)
2865 
2866  def set_check_level(self, a0):
2867  r"""set_check_level(Direction self, IMP::CheckLevel a0)"""
2868  return _IMP_core.Direction_set_check_level(self, a0)
2869 
2870  def add_to_derivative(self, a0, a1, a2):
2871  r"""add_to_derivative(Direction self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
2872  return _IMP_core.Direction_add_to_derivative(self, a0, a1, a2)
2873 
2874  def set_is_optimized(self, a0, a1):
2875  r"""set_is_optimized(Direction self, FloatKey a0, bool a1)"""
2876  return _IMP_core.Direction_set_is_optimized(self, a0, a1)
2877 
2878  def get_is_optimized(self, a0):
2879  r"""get_is_optimized(Direction self, FloatKey a0) -> bool"""
2880  return _IMP_core.Direction_get_is_optimized(self, a0)
2881 
2882  def get_check_level(self):
2883  r"""get_check_level(Direction self) -> IMP::CheckLevel"""
2884  return _IMP_core.Direction_get_check_level(self)
2885 
2886  def __eq__(self, *args):
2887  r"""
2888  __eq__(Direction self, Direction o) -> bool
2889  __eq__(Direction self, Particle d) -> bool
2890  """
2891  return _IMP_core.Direction___eq__(self, *args)
2892 
2893  def __ne__(self, *args):
2894  r"""
2895  __ne__(Direction self, Direction o) -> bool
2896  __ne__(Direction self, Particle d) -> bool
2897  """
2898  return _IMP_core.Direction___ne__(self, *args)
2899 
2900  def __le__(self, *args):
2901  r"""
2902  __le__(Direction self, Direction o) -> bool
2903  __le__(Direction self, Particle d) -> bool
2904  """
2905  return _IMP_core.Direction___le__(self, *args)
2906 
2907  def __lt__(self, *args):
2908  r"""
2909  __lt__(Direction self, Direction o) -> bool
2910  __lt__(Direction self, Particle d) -> bool
2911  """
2912  return _IMP_core.Direction___lt__(self, *args)
2913 
2914  def __ge__(self, *args):
2915  r"""
2916  __ge__(Direction self, Direction o) -> bool
2917  __ge__(Direction self, Particle d) -> bool
2918  """
2919  return _IMP_core.Direction___ge__(self, *args)
2920 
2921  def __gt__(self, *args):
2922  r"""
2923  __gt__(Direction self, Direction o) -> bool
2924  __gt__(Direction self, Particle d) -> bool
2925  """
2926  return _IMP_core.Direction___gt__(self, *args)
2927 
2928  def __hash__(self):
2929  r"""__hash__(Direction self) -> std::size_t"""
2930  return _IMP_core.Direction___hash__(self)
2931 
2932  def __str__(self):
2933  r"""__str__(Direction self) -> std::string"""
2934  return _IMP_core.Direction___str__(self)
2935 
2936  def __repr__(self):
2937  r"""__repr__(Direction self) -> std::string"""
2938  return _IMP_core.Direction___repr__(self)
2939 
2940  def _get_as_binary(self):
2941  r"""_get_as_binary(Direction self) -> PyObject *"""
2942  return _IMP_core.Direction__get_as_binary(self)
2943 
2944  def _set_from_binary(self, p):
2945  r"""_set_from_binary(Direction self, PyObject * p)"""
2946  return _IMP_core.Direction__set_from_binary(self, p)
2947 
2948  def __getstate__(self):
2949  p = self._get_as_binary()
2950  if len(self.__dict__) > 1:
2951  d = self.__dict__.copy()
2952  del d['this']
2953  p = (d, p)
2954  return p
2955 
2956  def __setstate__(self, p):
2957  if not hasattr(self, 'this'):
2958  self.__init__()
2959  if isinstance(p, tuple):
2960  d, p = p
2961  self.__dict__.update(d)
2962  return self._set_from_binary(p)
2963 
2964  __swig_destroy__ = _IMP_core.delete_Direction
2965 
2966 # Register Direction in _IMP_core:
2967 _IMP_core.Direction_swigregister(Direction)
2968 
2969 def get_angle(a, b):
2970  r"""get_angle(Direction a, Direction b) -> double"""
2971  return _IMP_core.get_angle(a, b)
2972 class DirectionAngle(IMP.Decorator):
2973  r"""Proxy of C++ IMP::core::DirectionAngle class."""
2974 
2975  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
2976 
2977  def __init__(self, *args):
2978  r"""
2979  __init__(DirectionAngle self) -> DirectionAngle
2980  __init__(DirectionAngle self, Model m, ParticleIndex id) -> DirectionAngle
2981  __init__(DirectionAngle self, _ParticleAdaptor d) -> DirectionAngle
2982  """
2983  _IMP_core.DirectionAngle_swiginit(self, _IMP_core.new_DirectionAngle(*args))
2984 
2985  def show(self, *args):
2986  r"""show(DirectionAngle self, _ostream out=std::cout)"""
2987  return _IMP_core.DirectionAngle_show(self, *args)
2988 
2989  @staticmethod
2990  def setup_particle(*args):
2991  r"""
2992  setup_particle(Model m, ParticleIndex pi, IMP::ParticleIndexPair ds) -> DirectionAngle
2993  setup_particle(_ParticleAdaptor pa, IMP::ParticleIndexPair ds) -> DirectionAngle
2994  setup_particle(Model m, ParticleIndex pi, _ParticleIndexAdaptor d0, _ParticleIndexAdaptor d1) -> DirectionAngle
2995  setup_particle(_ParticleAdaptor pa, _ParticleIndexAdaptor d0, _ParticleIndexAdaptor d1) -> DirectionAngle
2996  """
2997  return _IMP_core.DirectionAngle_setup_particle(*args)
2998 
2999  @staticmethod
3000  def get_is_setup(*args):
3001  r"""
3002  get_is_setup(_ParticleAdaptor p) -> bool
3003  get_is_setup(Model m, ParticleIndex pi) -> bool
3004  """
3005  return _IMP_core.DirectionAngle_get_is_setup(*args)
3006 
3007  @staticmethod
3008  def get_angle_key():
3009  r"""get_angle_key() -> FloatKey"""
3010  return _IMP_core.DirectionAngle_get_angle_key()
3011 
3012  @staticmethod
3013  def get_particle_key(i):
3014  r"""get_particle_key(unsigned int i) -> ParticleIndexKey"""
3015  return _IMP_core.DirectionAngle_get_particle_key(i)
3016 
3017  def get_particle(self, *args):
3018  r"""
3019  get_particle(DirectionAngle self, unsigned int i) -> Particle
3020  get_particle(DirectionAngle self) -> Particle
3021  """
3022  return _IMP_core.DirectionAngle_get_particle(self, *args)
3023 
3024  def get_particle_index(self, *args):
3025  r"""
3026  get_particle_index(DirectionAngle self, unsigned int i) -> ParticleIndex
3027  get_particle_index(DirectionAngle self) -> ParticleIndex
3028  """
3029  return _IMP_core.DirectionAngle_get_particle_index(self, *args)
3030 
3031  def get_angle(self):
3032  r"""get_angle(DirectionAngle self) -> IMP::Float"""
3033  return _IMP_core.DirectionAngle_get_angle(self)
3034 
3035  def get_angle_derivative(self):
3036  r"""get_angle_derivative(DirectionAngle self) -> IMP::Float"""
3037  return _IMP_core.DirectionAngle_get_angle_derivative(self)
3038 
3039  def add_to_angle_derivative(self, v, d):
3040  r"""add_to_angle_derivative(DirectionAngle self, IMP::Float v, DerivativeAccumulator d)"""
3041  return _IMP_core.DirectionAngle_add_to_angle_derivative(self, v, d)
3042 
3043  def add_attribute(self, *args):
3044  r"""
3045  add_attribute(DirectionAngle self, FloatKey k, IMP::Float v, bool opt)
3046  add_attribute(DirectionAngle self, FloatKey a0, IMP::Float a1)
3047  add_attribute(DirectionAngle self, IntKey a0, IMP::Int a1)
3048  add_attribute(DirectionAngle self, FloatsKey a0, IMP::Floats a1)
3049  add_attribute(DirectionAngle self, IntsKey a0, IMP::Ints a1)
3050  add_attribute(DirectionAngle self, StringKey a0, IMP::String a1)
3051  add_attribute(DirectionAngle self, ParticleIndexKey a0, Particle a1)
3052  add_attribute(DirectionAngle self, ObjectKey a0, Object a1)
3053  add_attribute(DirectionAngle self, SparseFloatKey a0, IMP::Float a1)
3054  add_attribute(DirectionAngle self, SparseIntKey a0, IMP::Int a1)
3055  add_attribute(DirectionAngle self, SparseStringKey a0, IMP::String a1)
3056  add_attribute(DirectionAngle self, SparseParticleIndexKey a0, ParticleIndex a1)
3057  """
3058  return _IMP_core.DirectionAngle_add_attribute(self, *args)
3059 
3060  def get_value(self, *args):
3061  r"""
3062  get_value(DirectionAngle self, FloatKey a0) -> IMP::Float
3063  get_value(DirectionAngle self, IntKey a0) -> IMP::Int
3064  get_value(DirectionAngle self, FloatsKey a0) -> IMP::Floats
3065  get_value(DirectionAngle self, IntsKey a0) -> IMP::Ints
3066  get_value(DirectionAngle self, StringKey a0) -> IMP::String
3067  get_value(DirectionAngle self, ParticleIndexKey a0) -> Particle
3068  get_value(DirectionAngle self, ObjectKey a0) -> Object
3069  get_value(DirectionAngle self, SparseFloatKey a0) -> IMP::Float
3070  get_value(DirectionAngle self, SparseIntKey a0) -> IMP::Int
3071  get_value(DirectionAngle self, SparseStringKey a0) -> IMP::String
3072  get_value(DirectionAngle self, SparseParticleIndexKey a0) -> ParticleIndex
3073  """
3074  return _IMP_core.DirectionAngle_get_value(self, *args)
3075 
3076  def set_value(self, *args):
3077  r"""
3078  set_value(DirectionAngle self, FloatKey a0, IMP::Float a1)
3079  set_value(DirectionAngle self, IntKey a0, IMP::Int a1)
3080  set_value(DirectionAngle self, FloatsKey a0, IMP::Floats a1)
3081  set_value(DirectionAngle self, IntsKey a0, IMP::Ints a1)
3082  set_value(DirectionAngle self, StringKey a0, IMP::String a1)
3083  set_value(DirectionAngle self, ParticleIndexKey a0, Particle a1)
3084  set_value(DirectionAngle self, ObjectKey a0, Object a1)
3085  set_value(DirectionAngle self, SparseFloatKey a0, IMP::Float a1)
3086  set_value(DirectionAngle self, SparseIntKey a0, IMP::Int a1)
3087  set_value(DirectionAngle self, SparseStringKey a0, IMP::String a1)
3088  set_value(DirectionAngle self, SparseParticleIndexKey a0, ParticleIndex a1)
3089  """
3090  return _IMP_core.DirectionAngle_set_value(self, *args)
3091 
3092  def remove_attribute(self, *args):
3093  r"""
3094  remove_attribute(DirectionAngle self, FloatKey a0)
3095  remove_attribute(DirectionAngle self, IntKey a0)
3096  remove_attribute(DirectionAngle self, FloatsKey a0)
3097  remove_attribute(DirectionAngle self, IntsKey a0)
3098  remove_attribute(DirectionAngle self, StringKey a0)
3099  remove_attribute(DirectionAngle self, ParticleIndexKey a0)
3100  remove_attribute(DirectionAngle self, ObjectKey a0)
3101  remove_attribute(DirectionAngle self, SparseFloatKey a0)
3102  remove_attribute(DirectionAngle self, SparseIntKey a0)
3103  remove_attribute(DirectionAngle self, SparseStringKey a0)
3104  remove_attribute(DirectionAngle self, SparseParticleIndexKey a0)
3105  """
3106  return _IMP_core.DirectionAngle_remove_attribute(self, *args)
3107 
3108  def has_attribute(self, *args):
3109  r"""
3110  has_attribute(DirectionAngle self, FloatKey a0) -> bool
3111  has_attribute(DirectionAngle self, IntKey a0) -> bool
3112  has_attribute(DirectionAngle self, FloatsKey a0) -> bool
3113  has_attribute(DirectionAngle self, IntsKey a0) -> bool
3114  has_attribute(DirectionAngle self, StringKey a0) -> bool
3115  has_attribute(DirectionAngle self, ParticleIndexKey a0) -> bool
3116  has_attribute(DirectionAngle self, ObjectKey a0) -> bool
3117  has_attribute(DirectionAngle self, SparseFloatKey a0) -> bool
3118  has_attribute(DirectionAngle self, SparseIntKey a0) -> bool
3119  has_attribute(DirectionAngle self, SparseStringKey a0) -> bool
3120  has_attribute(DirectionAngle self, SparseParticleIndexKey a0) -> bool
3121  """
3122  return _IMP_core.DirectionAngle_has_attribute(self, *args)
3123 
3124  def get_derivative(self, a0):
3125  r"""get_derivative(DirectionAngle self, FloatKey a0) -> double"""
3126  return _IMP_core.DirectionAngle_get_derivative(self, a0)
3127 
3128  def get_name(self):
3129  r"""get_name(DirectionAngle self) -> std::string"""
3130  return _IMP_core.DirectionAngle_get_name(self)
3131 
3132  def clear_caches(self):
3133  r"""clear_caches(DirectionAngle self)"""
3134  return _IMP_core.DirectionAngle_clear_caches(self)
3135 
3136  def set_name(self, a0):
3137  r"""set_name(DirectionAngle self, std::string a0)"""
3138  return _IMP_core.DirectionAngle_set_name(self, a0)
3139 
3140  def set_check_level(self, a0):
3141  r"""set_check_level(DirectionAngle self, IMP::CheckLevel a0)"""
3142  return _IMP_core.DirectionAngle_set_check_level(self, a0)
3143 
3144  def add_to_derivative(self, a0, a1, a2):
3145  r"""add_to_derivative(DirectionAngle self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
3146  return _IMP_core.DirectionAngle_add_to_derivative(self, a0, a1, a2)
3147 
3148  def set_is_optimized(self, a0, a1):
3149  r"""set_is_optimized(DirectionAngle self, FloatKey a0, bool a1)"""
3150  return _IMP_core.DirectionAngle_set_is_optimized(self, a0, a1)
3151 
3152  def get_is_optimized(self, a0):
3153  r"""get_is_optimized(DirectionAngle self, FloatKey a0) -> bool"""
3154  return _IMP_core.DirectionAngle_get_is_optimized(self, a0)
3155 
3156  def get_check_level(self):
3157  r"""get_check_level(DirectionAngle self) -> IMP::CheckLevel"""
3158  return _IMP_core.DirectionAngle_get_check_level(self)
3159 
3160  def __eq__(self, *args):
3161  r"""
3162  __eq__(DirectionAngle self, DirectionAngle o) -> bool
3163  __eq__(DirectionAngle self, Particle d) -> bool
3164  """
3165  return _IMP_core.DirectionAngle___eq__(self, *args)
3166 
3167  def __ne__(self, *args):
3168  r"""
3169  __ne__(DirectionAngle self, DirectionAngle o) -> bool
3170  __ne__(DirectionAngle self, Particle d) -> bool
3171  """
3172  return _IMP_core.DirectionAngle___ne__(self, *args)
3173 
3174  def __le__(self, *args):
3175  r"""
3176  __le__(DirectionAngle self, DirectionAngle o) -> bool
3177  __le__(DirectionAngle self, Particle d) -> bool
3178  """
3179  return _IMP_core.DirectionAngle___le__(self, *args)
3180 
3181  def __lt__(self, *args):
3182  r"""
3183  __lt__(DirectionAngle self, DirectionAngle o) -> bool
3184  __lt__(DirectionAngle self, Particle d) -> bool
3185  """
3186  return _IMP_core.DirectionAngle___lt__(self, *args)
3187 
3188  def __ge__(self, *args):
3189  r"""
3190  __ge__(DirectionAngle self, DirectionAngle o) -> bool
3191  __ge__(DirectionAngle self, Particle d) -> bool
3192  """
3193  return _IMP_core.DirectionAngle___ge__(self, *args)
3194 
3195  def __gt__(self, *args):
3196  r"""
3197  __gt__(DirectionAngle self, DirectionAngle o) -> bool
3198  __gt__(DirectionAngle self, Particle d) -> bool
3199  """
3200  return _IMP_core.DirectionAngle___gt__(self, *args)
3201 
3202  def __hash__(self):
3203  r"""__hash__(DirectionAngle self) -> std::size_t"""
3204  return _IMP_core.DirectionAngle___hash__(self)
3205 
3206  def __str__(self):
3207  r"""__str__(DirectionAngle self) -> std::string"""
3208  return _IMP_core.DirectionAngle___str__(self)
3209 
3210  def __repr__(self):
3211  r"""__repr__(DirectionAngle self) -> std::string"""
3212  return _IMP_core.DirectionAngle___repr__(self)
3213 
3214  def _get_as_binary(self):
3215  r"""_get_as_binary(DirectionAngle self) -> PyObject *"""
3216  return _IMP_core.DirectionAngle__get_as_binary(self)
3217 
3218  def _set_from_binary(self, p):
3219  r"""_set_from_binary(DirectionAngle self, PyObject * p)"""
3220  return _IMP_core.DirectionAngle__set_from_binary(self, p)
3221 
3222  def __getstate__(self):
3223  p = self._get_as_binary()
3224  if len(self.__dict__) > 1:
3225  d = self.__dict__.copy()
3226  del d['this']
3227  p = (d, p)
3228  return p
3229 
3230  def __setstate__(self, p):
3231  if not hasattr(self, 'this'):
3232  self.__init__()
3233  if isinstance(p, tuple):
3234  d, p = p
3235  self.__dict__.update(d)
3236  return self._set_from_binary(p)
3237 
3238  __swig_destroy__ = _IMP_core.delete_DirectionAngle
3239 
3240 # Register DirectionAngle in _IMP_core:
3241 _IMP_core.DirectionAngle_swigregister(DirectionAngle)
3242 class Surface(XYZ):
3243  r"""Proxy of C++ IMP::core::Surface class."""
3244 
3245  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
3246 
3247  @staticmethod
3248  def do_setup_particle(*args):
3249  r"""
3250  do_setup_particle(Model m, ParticleIndex pi, Vector3D center=IMP::Vector3D(0, 0, 0), Vector3D normal=IMP::Vector3D(0, 0, 1))
3251  do_setup_particle(Model m, ParticleIndex pi, ReferenceFrame3D rf)
3252  """
3253  return _IMP_core.Surface_do_setup_particle(*args)
3254 
3255  def __init__(self, *args):
3256  r"""
3257  __init__(Surface self) -> Surface
3258  __init__(Surface self, Model m, ParticleIndex id) -> Surface
3259  __init__(Surface self, _ParticleAdaptor d) -> Surface
3260  """
3261  _IMP_core.Surface_swiginit(self, _IMP_core.new_Surface(*args))
3262 
3263  def show(self, *args):
3264  r"""show(Surface self, _ostream out=std::cout)"""
3265  return _IMP_core.Surface_show(self, *args)
3266 
3267  @staticmethod
3268  def setup_particle(*args):
3269  r"""
3270  setup_particle(Model m, ParticleIndex pi) -> Surface
3271  setup_particle(_ParticleAdaptor pa) -> Surface
3272  setup_particle(Model m, ParticleIndex pi, ReferenceFrame3D rf) -> Surface
3273  setup_particle(_ParticleAdaptor pa, ReferenceFrame3D rf) -> Surface
3274  setup_particle(Model m, ParticleIndex pi, Vector3D center) -> Surface
3275  setup_particle(_ParticleAdaptor pa, Vector3D center) -> Surface
3276  setup_particle(Model m, ParticleIndex pi, Vector3D center, Vector3D normal) -> Surface
3277  setup_particle(_ParticleAdaptor pa, Vector3D center, Vector3D normal) -> Surface
3278  """
3279  return _IMP_core.Surface_setup_particle(*args)
3280 
3281  def get_normal_x(self):
3282  r"""get_normal_x(Surface self) -> IMP::Float"""
3283  return _IMP_core.Surface_get_normal_x(self)
3284 
3285  def set_normal_x(self, t):
3286  r"""set_normal_x(Surface self, IMP::Float t)"""
3287  return _IMP_core.Surface_set_normal_x(self, t)
3288 
3289  def get_normal_y(self):
3290  r"""get_normal_y(Surface self) -> IMP::Float"""
3291  return _IMP_core.Surface_get_normal_y(self)
3292 
3293  def set_normal_y(self, t):
3294  r"""set_normal_y(Surface self, IMP::Float t)"""
3295  return _IMP_core.Surface_set_normal_y(self, t)
3296 
3297  def get_normal_z(self):
3298  r"""get_normal_z(Surface self) -> IMP::Float"""
3299  return _IMP_core.Surface_get_normal_z(self)
3300 
3301  def set_normal_z(self, t):
3302  r"""set_normal_z(Surface self, IMP::Float t)"""
3303  return _IMP_core.Surface_set_normal_z(self, t)
3304 
3305  @staticmethod
3306  def get_is_setup(*args):
3307  r"""
3308  get_is_setup(_ParticleAdaptor p) -> bool
3309  get_is_setup(Model m, ParticleIndex pi) -> bool
3310  """
3311  return _IMP_core.Surface_get_is_setup(*args)
3312 
3313  @staticmethod
3314  def get_normal_key(i):
3315  r"""get_normal_key(unsigned int i) -> FloatKey"""
3316  return _IMP_core.Surface_get_normal_key(i)
3317 
3318  def get_normal_derivative(self, i):
3319  r"""get_normal_derivative(Surface self, int i) -> IMP::Float"""
3320  return _IMP_core.Surface_get_normal_derivative(self, i)
3321 
3322  def get_normal_derivatives(self):
3323  r"""get_normal_derivatives(Surface self) -> Vector3D"""
3324  return _IMP_core.Surface_get_normal_derivatives(self)
3325 
3326  def add_to_normal_derivative(self, i, v, d):
3327  r"""add_to_normal_derivative(Surface self, int i, IMP::Float v, DerivativeAccumulator d)"""
3328  return _IMP_core.Surface_add_to_normal_derivative(self, i, v, d)
3329 
3330  def add_to_normal_derivatives(self, v, d):
3331  r"""add_to_normal_derivatives(Surface self, Vector3D v, DerivativeAccumulator d)"""
3332  return _IMP_core.Surface_add_to_normal_derivatives(self, v, d)
3333 
3334  def get_normal_is_optimized(self):
3335  r"""get_normal_is_optimized(Surface self) -> bool"""
3336  return _IMP_core.Surface_get_normal_is_optimized(self)
3337 
3338  def set_normal_is_optimized(self, tf):
3339  r"""set_normal_is_optimized(Surface self, bool tf)"""
3340  return _IMP_core.Surface_set_normal_is_optimized(self, tf)
3341 
3342  def get_normal(self):
3343  r"""get_normal(Surface self) -> Vector3D"""
3344  return _IMP_core.Surface_get_normal(self)
3345 
3346  def set_normal(self, normal):
3347  r"""set_normal(Surface self, Vector3D normal)"""
3348  return _IMP_core.Surface_set_normal(self, normal)
3349 
3350  def reflect(self):
3351  r"""reflect(Surface self)"""
3352  return _IMP_core.Surface_reflect(self)
3353 
3354  def get_height(self, v):
3355  r"""get_height(Surface self, Vector3D v) -> double"""
3356  return _IMP_core.Surface_get_height(self, v)
3357 
3358  def get_depth(self, v):
3359  r"""get_depth(Surface self, Vector3D v) -> double"""
3360  return _IMP_core.Surface_get_depth(self, v)
3361 
3362  def get_distance_to(self, v):
3363  r"""get_distance_to(Surface self, Vector3D v) -> double"""
3364  return _IMP_core.Surface_get_distance_to(self, v)
3365 
3366  def get_distance_to_center(self, v):
3367  r"""get_distance_to_center(Surface self, Vector3D v) -> double"""
3368  return _IMP_core.Surface_get_distance_to_center(self, v)
3369 
3370  def set_reference_frame(self, rf):
3371  r"""set_reference_frame(Surface self, ReferenceFrame3D rf)"""
3372  return _IMP_core.Surface_set_reference_frame(self, rf)
3373 
3374  def get_reference_frame(self):
3375  r"""get_reference_frame(Surface self) -> ReferenceFrame3D"""
3376  return _IMP_core.Surface_get_reference_frame(self)
3377 
3378  def get_plane(self):
3379  r"""get_plane(Surface self) -> Plane3D"""
3380  return _IMP_core.Surface_get_plane(self)
3381 
3382  def add_attribute(self, *args):
3383  r"""
3384  add_attribute(Surface self, FloatKey k, IMP::Float v, bool opt)
3385  add_attribute(Surface self, FloatKey a0, IMP::Float a1)
3386  add_attribute(Surface self, IntKey a0, IMP::Int a1)
3387  add_attribute(Surface self, FloatsKey a0, IMP::Floats a1)
3388  add_attribute(Surface self, IntsKey a0, IMP::Ints a1)
3389  add_attribute(Surface self, StringKey a0, IMP::String a1)
3390  add_attribute(Surface self, ParticleIndexKey a0, Particle a1)
3391  add_attribute(Surface self, ObjectKey a0, Object a1)
3392  add_attribute(Surface self, SparseFloatKey a0, IMP::Float a1)
3393  add_attribute(Surface self, SparseIntKey a0, IMP::Int a1)
3394  add_attribute(Surface self, SparseStringKey a0, IMP::String a1)
3395  add_attribute(Surface self, SparseParticleIndexKey a0, ParticleIndex a1)
3396  """
3397  return _IMP_core.Surface_add_attribute(self, *args)
3398 
3399  def get_value(self, *args):
3400  r"""
3401  get_value(Surface self, FloatKey a0) -> IMP::Float
3402  get_value(Surface self, IntKey a0) -> IMP::Int
3403  get_value(Surface self, FloatsKey a0) -> IMP::Floats
3404  get_value(Surface self, IntsKey a0) -> IMP::Ints
3405  get_value(Surface self, StringKey a0) -> IMP::String
3406  get_value(Surface self, ParticleIndexKey a0) -> Particle
3407  get_value(Surface self, ObjectKey a0) -> Object
3408  get_value(Surface self, SparseFloatKey a0) -> IMP::Float
3409  get_value(Surface self, SparseIntKey a0) -> IMP::Int
3410  get_value(Surface self, SparseStringKey a0) -> IMP::String
3411  get_value(Surface self, SparseParticleIndexKey a0) -> ParticleIndex
3412  """
3413  return _IMP_core.Surface_get_value(self, *args)
3414 
3415  def set_value(self, *args):
3416  r"""
3417  set_value(Surface self, FloatKey a0, IMP::Float a1)
3418  set_value(Surface self, IntKey a0, IMP::Int a1)
3419  set_value(Surface self, FloatsKey a0, IMP::Floats a1)
3420  set_value(Surface self, IntsKey a0, IMP::Ints a1)
3421  set_value(Surface self, StringKey a0, IMP::String a1)
3422  set_value(Surface self, ParticleIndexKey a0, Particle a1)
3423  set_value(Surface self, ObjectKey a0, Object a1)
3424  set_value(Surface self, SparseFloatKey a0, IMP::Float a1)
3425  set_value(Surface self, SparseIntKey a0, IMP::Int a1)
3426  set_value(Surface self, SparseStringKey a0, IMP::String a1)
3427  set_value(Surface self, SparseParticleIndexKey a0, ParticleIndex a1)
3428  """
3429  return _IMP_core.Surface_set_value(self, *args)
3430 
3431  def remove_attribute(self, *args):
3432  r"""
3433  remove_attribute(Surface self, FloatKey a0)
3434  remove_attribute(Surface self, IntKey a0)
3435  remove_attribute(Surface self, FloatsKey a0)
3436  remove_attribute(Surface self, IntsKey a0)
3437  remove_attribute(Surface self, StringKey a0)
3438  remove_attribute(Surface self, ParticleIndexKey a0)
3439  remove_attribute(Surface self, ObjectKey a0)
3440  remove_attribute(Surface self, SparseFloatKey a0)
3441  remove_attribute(Surface self, SparseIntKey a0)
3442  remove_attribute(Surface self, SparseStringKey a0)
3443  remove_attribute(Surface self, SparseParticleIndexKey a0)
3444  """
3445  return _IMP_core.Surface_remove_attribute(self, *args)
3446 
3447  def has_attribute(self, *args):
3448  r"""
3449  has_attribute(Surface self, FloatKey a0) -> bool
3450  has_attribute(Surface self, IntKey a0) -> bool
3451  has_attribute(Surface self, FloatsKey a0) -> bool
3452  has_attribute(Surface self, IntsKey a0) -> bool
3453  has_attribute(Surface self, StringKey a0) -> bool
3454  has_attribute(Surface self, ParticleIndexKey a0) -> bool
3455  has_attribute(Surface self, ObjectKey a0) -> bool
3456  has_attribute(Surface self, SparseFloatKey a0) -> bool
3457  has_attribute(Surface self, SparseIntKey a0) -> bool
3458  has_attribute(Surface self, SparseStringKey a0) -> bool
3459  has_attribute(Surface self, SparseParticleIndexKey a0) -> bool
3460  """
3461  return _IMP_core.Surface_has_attribute(self, *args)
3462 
3463  def get_derivative(self, a0):
3464  r"""get_derivative(Surface self, FloatKey a0) -> double"""
3465  return _IMP_core.Surface_get_derivative(self, a0)
3466 
3467  def get_name(self):
3468  r"""get_name(Surface self) -> std::string"""
3469  return _IMP_core.Surface_get_name(self)
3470 
3471  def clear_caches(self):
3472  r"""clear_caches(Surface self)"""
3473  return _IMP_core.Surface_clear_caches(self)
3474 
3475  def set_name(self, a0):
3476  r"""set_name(Surface self, std::string a0)"""
3477  return _IMP_core.Surface_set_name(self, a0)
3478 
3479  def set_check_level(self, a0):
3480  r"""set_check_level(Surface self, IMP::CheckLevel a0)"""
3481  return _IMP_core.Surface_set_check_level(self, a0)
3482 
3483  def add_to_derivative(self, a0, a1, a2):
3484  r"""add_to_derivative(Surface self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
3485  return _IMP_core.Surface_add_to_derivative(self, a0, a1, a2)
3486 
3487  def set_is_optimized(self, a0, a1):
3488  r"""set_is_optimized(Surface self, FloatKey a0, bool a1)"""
3489  return _IMP_core.Surface_set_is_optimized(self, a0, a1)
3490 
3491  def get_is_optimized(self, a0):
3492  r"""get_is_optimized(Surface self, FloatKey a0) -> bool"""
3493  return _IMP_core.Surface_get_is_optimized(self, a0)
3494 
3495  def get_check_level(self):
3496  r"""get_check_level(Surface self) -> IMP::CheckLevel"""
3497  return _IMP_core.Surface_get_check_level(self)
3498 
3499  def __eq__(self, *args):
3500  r"""
3501  __eq__(Surface self, Surface o) -> bool
3502  __eq__(Surface self, Particle d) -> bool
3503  """
3504  return _IMP_core.Surface___eq__(self, *args)
3505 
3506  def __ne__(self, *args):
3507  r"""
3508  __ne__(Surface self, Surface o) -> bool
3509  __ne__(Surface self, Particle d) -> bool
3510  """
3511  return _IMP_core.Surface___ne__(self, *args)
3512 
3513  def __le__(self, *args):
3514  r"""
3515  __le__(Surface self, Surface o) -> bool
3516  __le__(Surface self, Particle d) -> bool
3517  """
3518  return _IMP_core.Surface___le__(self, *args)
3519 
3520  def __lt__(self, *args):
3521  r"""
3522  __lt__(Surface self, Surface o) -> bool
3523  __lt__(Surface self, Particle d) -> bool
3524  """
3525  return _IMP_core.Surface___lt__(self, *args)
3526 
3527  def __ge__(self, *args):
3528  r"""
3529  __ge__(Surface self, Surface o) -> bool
3530  __ge__(Surface self, Particle d) -> bool
3531  """
3532  return _IMP_core.Surface___ge__(self, *args)
3533 
3534  def __gt__(self, *args):
3535  r"""
3536  __gt__(Surface self, Surface o) -> bool
3537  __gt__(Surface self, Particle d) -> bool
3538  """
3539  return _IMP_core.Surface___gt__(self, *args)
3540 
3541  def __hash__(self):
3542  r"""__hash__(Surface self) -> std::size_t"""
3543  return _IMP_core.Surface___hash__(self)
3544 
3545  def __str__(self):
3546  r"""__str__(Surface self) -> std::string"""
3547  return _IMP_core.Surface___str__(self)
3548 
3549  def __repr__(self):
3550  r"""__repr__(Surface self) -> std::string"""
3551  return _IMP_core.Surface___repr__(self)
3552 
3553  def _get_as_binary(self):
3554  r"""_get_as_binary(Surface self) -> PyObject *"""
3555  return _IMP_core.Surface__get_as_binary(self)
3556 
3557  def _set_from_binary(self, p):
3558  r"""_set_from_binary(Surface self, PyObject * p)"""
3559  return _IMP_core.Surface__set_from_binary(self, p)
3560 
3561  def __getstate__(self):
3562  p = self._get_as_binary()
3563  if len(self.__dict__) > 1:
3564  d = self.__dict__.copy()
3565  del d['this']
3566  p = (d, p)
3567  return p
3568 
3569  def __setstate__(self, p):
3570  if not hasattr(self, 'this'):
3571  self.__init__()
3572  if isinstance(p, tuple):
3573  d, p = p
3574  self.__dict__.update(d)
3575  return self._set_from_binary(p)
3576 
3577  __swig_destroy__ = _IMP_core.delete_Surface
3578 
3579 # Register Surface in _IMP_core:
3580 _IMP_core.Surface_swigregister(Surface)
3581 
3582 def get_height(*args):
3583  r"""
3584  get_height(Surface s, XYZR d) -> double
3585  get_height(Surface s, XYZ d) -> double
3586  """
3587  return _IMP_core.get_height(*args)
3588 
3589 def get_depth(*args):
3590  r"""
3591  get_depth(Surface s, XYZR d) -> double
3592  get_depth(Surface s, XYZ d) -> double
3593  """
3594  return _IMP_core.get_depth(*args)
3595 
3596 def get_distance(*args):
3597  r"""
3598  get_distance(XYZ a, XYZ b) -> double
3599  get_distance(XYZR a, XYZR b) -> double
3600  get_distance(Surface s, XYZR d) -> double
3601  get_distance(Surface s, XYZ d) -> double
3602  """
3603  return _IMP_core.get_distance(*args)
3604 class SurfaceGeometry(IMP.display.Geometry):
3605  r"""Proxy of C++ IMP::core::SurfaceGeometry class."""
3606 
3607  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
3608 
3609  def __init__(self, *args):
3610  r"""
3611  __init__(SurfaceGeometry self, std::string n="SurfaceGeometry") -> SurfaceGeometry
3612  __init__(SurfaceGeometry self, Surface s, std::string const n="SurfaceGeometry") -> SurfaceGeometry
3613  __init__(SurfaceGeometry self, Surface s, Color c, std::string n="SurfaceGeometry") -> SurfaceGeometry
3614  """
3615  _IMP_core.SurfaceGeometry_swiginit(self, _IMP_core.new_SurfaceGeometry(*args))
3616 
3617  def get_geometry(self):
3618  r"""get_geometry(SurfaceGeometry self) -> Surface"""
3619  return _IMP_core.SurfaceGeometry_get_geometry(self)
3620 
3621  def set_geometry(self, s):
3622  r"""set_geometry(SurfaceGeometry self, Surface s)"""
3623  return _IMP_core.SurfaceGeometry_set_geometry(self, s)
3624 
3625  def get_version_info(self):
3626  r"""get_version_info(SurfaceGeometry self) -> VersionInfo"""
3627  return _IMP_core.SurfaceGeometry_get_version_info(self)
3628  __swig_destroy__ = _IMP_core.delete_SurfaceGeometry
3629 
3630  def __str__(self):
3631  r"""__str__(SurfaceGeometry self) -> std::string"""
3632  return _IMP_core.SurfaceGeometry___str__(self)
3633 
3634  def __repr__(self):
3635  r"""__repr__(SurfaceGeometry self) -> std::string"""
3636  return _IMP_core.SurfaceGeometry___repr__(self)
3637 
3638  @staticmethod
3639  def get_from(o):
3640  return _object_cast_to_SurfaceGeometry(o)
3641 
3642 
3643 # Register SurfaceGeometry in _IMP_core:
3644 _IMP_core.SurfaceGeometry_swigregister(SurfaceGeometry)
3645 
3646 def create_geometry(*args):
3647  r"""create_geometry(Surface s, std::string name=std::string("SurfaceGeometry%1%")) -> SurfaceGeometry"""
3648  return _IMP_core.create_geometry(*args)
3649 class SurfaceGeometryConstraint(IMP.Constraint):
3650  r"""Proxy of C++ IMP::core::SurfaceGeometryConstraint class."""
3651 
3652  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
3653 
3654  def __init__(self, s, g):
3655  r"""__init__(SurfaceGeometryConstraint self, Surface s, SurfaceGeometry g) -> SurfaceGeometryConstraint"""
3656  _IMP_core.SurfaceGeometryConstraint_swiginit(self, _IMP_core.new_SurfaceGeometryConstraint(s, g))
3657 
3658  def get_surface(self):
3659  r"""get_surface(SurfaceGeometryConstraint self) -> Surface"""
3660  return _IMP_core.SurfaceGeometryConstraint_get_surface(self)
3661 
3662  def get_geometry(self):
3663  r"""get_geometry(SurfaceGeometryConstraint self) -> SurfaceGeometry"""
3664  return _IMP_core.SurfaceGeometryConstraint_get_geometry(self)
3665 
3666  def do_get_inputs(self):
3667  r"""do_get_inputs(SurfaceGeometryConstraint self) -> IMP::ModelObjectsTemp"""
3668  return _IMP_core.SurfaceGeometryConstraint_do_get_inputs(self)
3669 
3670  def do_get_outputs(self):
3671  r"""do_get_outputs(SurfaceGeometryConstraint self) -> IMP::ModelObjectsTemp"""
3672  return _IMP_core.SurfaceGeometryConstraint_do_get_outputs(self)
3673 
3674  def get_version_info(self):
3675  r"""get_version_info(SurfaceGeometryConstraint self) -> VersionInfo"""
3676  return _IMP_core.SurfaceGeometryConstraint_get_version_info(self)
3677  __swig_destroy__ = _IMP_core.delete_SurfaceGeometryConstraint
3678 
3679  def __str__(self):
3680  r"""__str__(SurfaceGeometryConstraint self) -> std::string"""
3681  return _IMP_core.SurfaceGeometryConstraint___str__(self)
3682 
3683  def __repr__(self):
3684  r"""__repr__(SurfaceGeometryConstraint self) -> std::string"""
3685  return _IMP_core.SurfaceGeometryConstraint___repr__(self)
3686 
3687  @staticmethod
3688  def get_from(o):
3689  return _object_cast_to_SurfaceGeometryConstraint(o)
3690 
3691 
3692 # Register SurfaceGeometryConstraint in _IMP_core:
3693 _IMP_core.SurfaceGeometryConstraint_swigregister(SurfaceGeometryConstraint)
3694 
3696  r"""get_constrained_surface_geometry(Surface s, std::string name="SurfaceGeometry%1%") -> SurfaceGeometry"""
3697  return _IMP_core.get_constrained_surface_geometry(*args)
3698 class LateralSurfaceConstraint(IMP.Constraint):
3699  r"""Proxy of C++ IMP::core::LateralSurfaceConstraint class."""
3700 
3701  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
3702 
3703  def __init__(self, s, d):
3704  r"""__init__(LateralSurfaceConstraint self, Surface s, XYZ d) -> LateralSurfaceConstraint"""
3705  _IMP_core.LateralSurfaceConstraint_swiginit(self, _IMP_core.new_LateralSurfaceConstraint(s, d))
3706 
3707  def do_get_inputs(self):
3708  r"""do_get_inputs(LateralSurfaceConstraint self) -> IMP::ModelObjectsTemp"""
3709  return _IMP_core.LateralSurfaceConstraint_do_get_inputs(self)
3710 
3711  def do_get_outputs(self):
3712  r"""do_get_outputs(LateralSurfaceConstraint self) -> IMP::ModelObjectsTemp"""
3713  return _IMP_core.LateralSurfaceConstraint_do_get_outputs(self)
3714 
3715  def get_version_info(self):
3716  r"""get_version_info(LateralSurfaceConstraint self) -> VersionInfo"""
3717  return _IMP_core.LateralSurfaceConstraint_get_version_info(self)
3718  __swig_destroy__ = _IMP_core.delete_LateralSurfaceConstraint
3719 
3720  def __str__(self):
3721  r"""__str__(LateralSurfaceConstraint self) -> std::string"""
3722  return _IMP_core.LateralSurfaceConstraint___str__(self)
3723 
3724  def __repr__(self):
3725  r"""__repr__(LateralSurfaceConstraint self) -> std::string"""
3726  return _IMP_core.LateralSurfaceConstraint___repr__(self)
3727 
3728  @staticmethod
3729  def get_from(o):
3730  return _object_cast_to_LateralSurfaceConstraint(o)
3731 
3732 
3733 # Register LateralSurfaceConstraint in _IMP_core:
3734 _IMP_core.LateralSurfaceConstraint_swigregister(LateralSurfaceConstraint)
3735 class AngleTripletScore(IMP.TripletScore):
3736  r"""Proxy of C++ IMP::core::AngleTripletScore class."""
3737 
3738  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
3739 
3740  def __init__(self, *args):
3741  r"""
3742  __init__(AngleTripletScore self, UnaryFunction f) -> AngleTripletScore
3743  __init__(AngleTripletScore self) -> AngleTripletScore
3744  """
3745  _IMP_core.AngleTripletScore_swiginit(self, _IMP_core.new_AngleTripletScore(*args))
3746 
3747  def do_get_inputs(self, m, pis):
3748  r"""do_get_inputs(AngleTripletScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
3749  return _IMP_core.AngleTripletScore_do_get_inputs(self, m, pis)
3750 
3751  def evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked=False):
3752  r"""evaluate_indexes(AngleTripletScore self, Model m, IMP::ParticleIndexTriplets const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
3753  return _IMP_core.AngleTripletScore_evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked)
3754 
3755  def evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked=False):
3756  r"""evaluate_indexes_scores(AngleTripletScore self, Model m, IMP::ParticleIndexTriplets const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
3757  return _IMP_core.AngleTripletScore_evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked)
3758 
3759  def evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked=False):
3760  r"""evaluate_indexes_delta(AngleTripletScore self, Model m, IMP::ParticleIndexTriplets const & p, DerivativeAccumulator da, std::vector< unsigned int,std::allocator< unsigned int > > const & indexes, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
3761  return _IMP_core.AngleTripletScore_evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked)
3762 
3763  def evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked=False):
3764  r"""evaluate_if_good_indexes(AngleTripletScore self, Model m, IMP::ParticleIndexTriplets const & p, DerivativeAccumulator da, double max, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
3765  return _IMP_core.AngleTripletScore_evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked)
3766 
3767  def get_version_info(self):
3768  r"""get_version_info(AngleTripletScore self) -> VersionInfo"""
3769  return _IMP_core.AngleTripletScore_get_version_info(self)
3770  __swig_destroy__ = _IMP_core.delete_AngleTripletScore
3771 
3772  def __str__(self):
3773  r"""__str__(AngleTripletScore self) -> std::string"""
3774  return _IMP_core.AngleTripletScore___str__(self)
3775 
3776  def __repr__(self):
3777  r"""__repr__(AngleTripletScore self) -> std::string"""
3778  return _IMP_core.AngleTripletScore___repr__(self)
3779 
3780  @staticmethod
3781  def get_from(o):
3782  return _object_cast_to_AngleTripletScore(o)
3783 
3784 
3785  def _get_as_binary(self):
3786  r"""_get_as_binary(AngleTripletScore self) -> PyObject *"""
3787  return _IMP_core.AngleTripletScore__get_as_binary(self)
3788 
3789  def _set_from_binary(self, p):
3790  r"""_set_from_binary(AngleTripletScore self, PyObject * p)"""
3791  return _IMP_core.AngleTripletScore__set_from_binary(self, p)
3792 
3793  def __getstate__(self):
3794  p = self._get_as_binary()
3795  if len(self.__dict__) > 1:
3796  d = self.__dict__.copy()
3797  del d['this']
3798  p = (d, p)
3799  return p
3800 
3801  def __setstate__(self, p):
3802  if not hasattr(self, 'this'):
3803  self.__init__()
3804  if isinstance(p, tuple):
3805  d, p = p
3806  self.__dict__.update(d)
3807  return self._set_from_binary(p)
3808 
3809 
3810 # Register AngleTripletScore in _IMP_core:
3811 _IMP_core.AngleTripletScore_swigregister(AngleTripletScore)
3812 class BallMover(MonteCarloMover):
3813  r"""Proxy of C++ IMP::core::BallMover class."""
3814 
3815  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
3816 
3817  def __init__(self, *args):
3818  r"""
3819  __init__(BallMover self, Model m, ParticleIndex pi, IMP::FloatKeys const & vars, double radius) -> BallMover
3820  __init__(BallMover self, Model m, ParticleIndex pi, double radius) -> BallMover
3821  __init__(BallMover self, Model m, IMP::ParticleIndexes const & pis, IMP::FloatKeys const & vars, IMP::Float radius) -> BallMover
3822  __init__(BallMover self, Model m, IMP::ParticleIndexes const & pis, IMP::Float radius) -> BallMover
3823  __init__(BallMover self) -> BallMover
3824  """
3825  _IMP_core.BallMover_swiginit(self, _IMP_core.new_BallMover(*args))
3826 
3827  def set_radius(self, radius):
3828  r"""set_radius(BallMover self, IMP::Float radius)"""
3829  return _IMP_core.BallMover_set_radius(self, radius)
3830 
3831  def get_radius(self):
3832  r"""get_radius(BallMover self) -> IMP::Float"""
3833  return _IMP_core.BallMover_get_radius(self)
3834 
3835  def get_indexes(self):
3836  r"""get_indexes(BallMover self) -> IMP::ParticleIndexes"""
3837  return _IMP_core.BallMover_get_indexes(self)
3838 
3839  def get_keys(self):
3840  r"""get_keys(BallMover self) -> IMP::FloatKeys"""
3841  return _IMP_core.BallMover_get_keys(self)
3842 
3843  def get_version_info(self):
3844  r"""get_version_info(BallMover self) -> VersionInfo"""
3845  return _IMP_core.BallMover_get_version_info(self)
3846  __swig_destroy__ = _IMP_core.delete_BallMover
3847 
3848  def __str__(self):
3849  r"""__str__(BallMover self) -> std::string"""
3850  return _IMP_core.BallMover___str__(self)
3851 
3852  def __repr__(self):
3853  r"""__repr__(BallMover self) -> std::string"""
3854  return _IMP_core.BallMover___repr__(self)
3855 
3856  @staticmethod
3857  def get_from(o):
3858  return _object_cast_to_BallMover(o)
3859 
3860 
3861  def _get_as_binary(self):
3862  r"""_get_as_binary(BallMover self) -> PyObject *"""
3863  return _IMP_core.BallMover__get_as_binary(self)
3864 
3865  def _set_from_binary(self, p):
3866  r"""_set_from_binary(BallMover self, PyObject * p)"""
3867  return _IMP_core.BallMover__set_from_binary(self, p)
3868 
3869  def __getstate__(self):
3870  p = self._get_as_binary()
3871  if len(self.__dict__) > 1:
3872  d = self.__dict__.copy()
3873  del d['this']
3874  p = (d, p)
3875  return p
3876 
3877  def __setstate__(self, p):
3878  if not hasattr(self, 'this'):
3879  self.__init__()
3880  if isinstance(p, tuple):
3881  d, p = p
3882  self.__dict__.update(d)
3883  return self._set_from_binary(p)
3884 
3885 
3886  def _get_jax(self):
3887  import jax.random
3888  from IMP.algebra._jax_util import get_random_vector_in_3d_sphere
3889  indexes = self.get_indexes()
3890  keys = frozenset(self.get_keys())
3891  if keys == frozenset(IMP.core.XYZ.get_xyz_keys()):
3892  intcoord = False
3893  elif keys == frozenset(
3895  intcoord = True
3896  else:
3897  raise NotImplementedError(
3898  "Only works for XYZ or internal coordinates")
3899  radius = self.get_radius()
3900 
3901  def init_func(key):
3902  return key
3903 
3904  def propose_func(jm, key):
3905  key, subkey = jax.random.split(key)
3906  v = get_random_vector_in_3d_sphere(subkey, radius)
3907  if intcoord:
3908  rbs = jm['rigid_bodies']
3909  rbs.intcoord = rbs.intcoord.at[indexes].add(v)
3910  else:
3911  jm['xyz'] = jm['xyz'].at[indexes].add(v)
3912  return jm, key, 1.0
3913  return self._wrap_jax(init_func, propose_func,
3914  keys=['rigid_bodies'] if intcoord else None)
3915 
3916 
3917 # Register BallMover in _IMP_core:
3918 _IMP_core.BallMover_swigregister(BallMover)
3919 class SerialMover(MonteCarloMover):
3920  r"""Proxy of C++ IMP::core::SerialMover class."""
3921 
3922  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
3923 
3924  def __init__(self, *args):
3925  r"""
3926  __init__(SerialMover self, IMP::core::MonteCarloMoversTemp const & mvs) -> SerialMover
3927  __init__(SerialMover self) -> SerialMover
3928  """
3929  _IMP_core.SerialMover_swiginit(self, _IMP_core.new_SerialMover(*args))
3930 
3931  def get_movers(self):
3932  r"""get_movers(SerialMover self) -> IMP::core::MonteCarloMovers const &"""
3933  return _IMP_core.SerialMover_get_movers(self)
3934 
3935  def get_version_info(self):
3936  r"""get_version_info(SerialMover self) -> VersionInfo"""
3937  return _IMP_core.SerialMover_get_version_info(self)
3938  __swig_destroy__ = _IMP_core.delete_SerialMover
3939 
3940  def __str__(self):
3941  r"""__str__(SerialMover self) -> std::string"""
3942  return _IMP_core.SerialMover___str__(self)
3943 
3944  def __repr__(self):
3945  r"""__repr__(SerialMover self) -> std::string"""
3946  return _IMP_core.SerialMover___repr__(self)
3947 
3948  @staticmethod
3949  def get_from(o):
3950  return _object_cast_to_SerialMover(o)
3951 
3952 
3953  def _get_as_binary(self):
3954  r"""_get_as_binary(SerialMover self) -> PyObject *"""
3955  return _IMP_core.SerialMover__get_as_binary(self)
3956 
3957  def _set_from_binary(self, p):
3958  r"""_set_from_binary(SerialMover self, PyObject * p)"""
3959  return _IMP_core.SerialMover__set_from_binary(self, p)
3960 
3961  def __getstate__(self):
3962  p = self._get_as_binary()
3963  if len(self.__dict__) > 1:
3964  d = self.__dict__.copy()
3965  del d['this']
3966  p = (d, p)
3967  return p
3968 
3969  def __setstate__(self, p):
3970  if not hasattr(self, 'this'):
3971  self.__init__()
3972  if isinstance(p, tuple):
3973  d, p = p
3974  self.__dict__.update(d)
3975  return self._set_from_binary(p)
3976 
3977 
3978  def _get_jax(self):
3979  import jax.random
3980  import jax.lax
3981  import jax.numpy as jnp
3982  from IMP.core._jax_util import _SerialMover
3983  movers = [m.get_derived_object()._get_jax()
3984  for m in self.get_movers()]
3985 
3986  def sub_propose_func(jm, sms, i):
3987  """Call the propose_func of the ith mover"""
3988  jm, sms.mover_state[i], ratio = movers[i].propose_func(
3989  jm, sms.mover_state[i])
3990  sms.proposed_mover_steps = sms.proposed_mover_steps.at[i].add(1)
3991  return jm, sms, ratio
3992 
3993  sub_propose_funcs = [functools.partial(sub_propose_func, i=i)
3994  for i in range(len(movers))]
3995 
3996  def init_func(key):
3997  # Initialize all movers and store their state in ours
3998  mover_state = []
3999  for m in movers:
4000  key, subkey = jax.random.split(key)
4001  mover_state.append(m.init_func(subkey))
4002  return _SerialMover(
4003  imov=-1, mover_state=mover_state,
4004  proposed_mover_steps=jnp.zeros(len(movers), dtype=int),
4005  accepted_mover_steps=jnp.zeros(len(movers), dtype=int))
4006 
4007  def propose_func(jm, sms):
4008  sms.imov = jnp.mod(sms.imov + 1, len(movers))
4009  return jax.lax.switch(sms.imov, sub_propose_funcs, jm, sms)
4010 
4011  def accept_func(sms):
4012  # Update statistics for the chosen mover
4013  sms.accepted_mover_steps = \
4014  sms.accepted_mover_steps.at[sms.imov].add(1)
4015  return sms
4016 
4017  def sync_func(imp_mover, sms):
4018  # Copy submover statistics back to IMP Movers
4019  for i, mover in enumerate(imp_mover.get_movers()):
4020  mover.add_to_statistics(
4021  sms.proposed_mover_steps[i],
4022  sms.proposed_mover_steps[i] - sms.accepted_mover_steps[i])
4023 
4024  return self._wrap_jax(
4025  init_func, propose_func, accept_func, sync_func,
4026  keys=frozenset(x for m in movers for x in m._keys))
4027 
4028 
4029 # Register SerialMover in _IMP_core:
4030 _IMP_core.SerialMover_swigregister(SerialMover)
4031 class SubsetMover(MonteCarloMover):
4032  r"""Proxy of C++ IMP::core::SubsetMover class."""
4033 
4034  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
4035 
4036  def __init__(self, *args):
4037  r"""
4038  __init__(SubsetMover self, IMP::core::MonteCarloMoversTemp const & mvs, unsigned int n) -> SubsetMover
4039  __init__(SubsetMover self) -> SubsetMover
4040  """
4041  _IMP_core.SubsetMover_swiginit(self, _IMP_core.new_SubsetMover(*args))
4042 
4043  def get_movers(self):
4044  r"""get_movers(SubsetMover self) -> IMP::core::MonteCarloMovers const &"""
4045  return _IMP_core.SubsetMover_get_movers(self)
4046 
4047  def get_subset_size(self):
4048  r"""get_subset_size(SubsetMover self) -> unsigned int"""
4049  return _IMP_core.SubsetMover_get_subset_size(self)
4050 
4051  def get_version_info(self):
4052  r"""get_version_info(SubsetMover self) -> VersionInfo"""
4053  return _IMP_core.SubsetMover_get_version_info(self)
4054  __swig_destroy__ = _IMP_core.delete_SubsetMover
4055 
4056  def __str__(self):
4057  r"""__str__(SubsetMover self) -> std::string"""
4058  return _IMP_core.SubsetMover___str__(self)
4059 
4060  def __repr__(self):
4061  r"""__repr__(SubsetMover self) -> std::string"""
4062  return _IMP_core.SubsetMover___repr__(self)
4063 
4064  @staticmethod
4065  def get_from(o):
4066  return _object_cast_to_SubsetMover(o)
4067 
4068 
4069  def _get_as_binary(self):
4070  r"""_get_as_binary(SubsetMover self) -> PyObject *"""
4071  return _IMP_core.SubsetMover__get_as_binary(self)
4072 
4073  def _set_from_binary(self, p):
4074  r"""_set_from_binary(SubsetMover self, PyObject * p)"""
4075  return _IMP_core.SubsetMover__set_from_binary(self, p)
4076 
4077  def __getstate__(self):
4078  p = self._get_as_binary()
4079  if len(self.__dict__) > 1:
4080  d = self.__dict__.copy()
4081  del d['this']
4082  p = (d, p)
4083  return p
4084 
4085  def __setstate__(self, p):
4086  if not hasattr(self, 'this'):
4087  self.__init__()
4088  if isinstance(p, tuple):
4089  d, p = p
4090  self.__dict__.update(d)
4091  return self._set_from_binary(p)
4092 
4093 
4094 # Register SubsetMover in _IMP_core:
4095 _IMP_core.SubsetMover_swigregister(SubsetMover)
4096 class DirectionMover(MonteCarloMover):
4097  r"""Proxy of C++ IMP::core::DirectionMover class."""
4098 
4099  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
4100 
4101  def __init__(self, *args):
4102  r"""
4103  __init__(DirectionMover self, Model m, ParticleIndex pi, IMP::Float max_rotation, IMP::Float reflect_probability) -> DirectionMover
4104  __init__(DirectionMover self, Direction d, IMP::Float max_rotation, IMP::Float reflect_probability) -> DirectionMover
4105  __init__(DirectionMover self) -> DirectionMover
4106  """
4107  _IMP_core.DirectionMover_swiginit(self, _IMP_core.new_DirectionMover(*args))
4108 
4109  def set_maximum_rotation(self, mr):
4110  r"""set_maximum_rotation(DirectionMover self, IMP::Float mr)"""
4111  return _IMP_core.DirectionMover_set_maximum_rotation(self, mr)
4112 
4113  def set_reflect_probability(self, rp):
4114  r"""set_reflect_probability(DirectionMover self, IMP::Float rp)"""
4115  return _IMP_core.DirectionMover_set_reflect_probability(self, rp)
4116 
4117  def get_maximum_rotation(self):
4118  r"""get_maximum_rotation(DirectionMover self) -> IMP::Float"""
4119  return _IMP_core.DirectionMover_get_maximum_rotation(self)
4120 
4121  def get_reflect_probability(self):
4122  r"""get_reflect_probability(DirectionMover self) -> IMP::Float"""
4123  return _IMP_core.DirectionMover_get_reflect_probability(self)
4124 
4125  def get_direction(self):
4126  r"""get_direction(DirectionMover self) -> Direction"""
4127  return _IMP_core.DirectionMover_get_direction(self)
4128 
4129  def get_version_info(self):
4130  r"""get_version_info(DirectionMover self) -> VersionInfo"""
4131  return _IMP_core.DirectionMover_get_version_info(self)
4132  __swig_destroy__ = _IMP_core.delete_DirectionMover
4133 
4134  def __str__(self):
4135  r"""__str__(DirectionMover self) -> std::string"""
4136  return _IMP_core.DirectionMover___str__(self)
4137 
4138  def __repr__(self):
4139  r"""__repr__(DirectionMover self) -> std::string"""
4140  return _IMP_core.DirectionMover___repr__(self)
4141 
4142  @staticmethod
4143  def get_from(o):
4144  return _object_cast_to_DirectionMover(o)
4145 
4146 
4147  def _get_as_binary(self):
4148  r"""_get_as_binary(DirectionMover self) -> PyObject *"""
4149  return _IMP_core.DirectionMover__get_as_binary(self)
4150 
4151  def _set_from_binary(self, p):
4152  r"""_set_from_binary(DirectionMover self, PyObject * p)"""
4153  return _IMP_core.DirectionMover__set_from_binary(self, p)
4154 
4155  def __getstate__(self):
4156  p = self._get_as_binary()
4157  if len(self.__dict__) > 1:
4158  d = self.__dict__.copy()
4159  del d['this']
4160  p = (d, p)
4161  return p
4162 
4163  def __setstate__(self, p):
4164  if not hasattr(self, 'this'):
4165  self.__init__()
4166  if isinstance(p, tuple):
4167  d, p = p
4168  self.__dict__.update(d)
4169  return self._set_from_binary(p)
4170 
4171 
4172 # Register DirectionMover in _IMP_core:
4173 _IMP_core.DirectionMover_swigregister(DirectionMover)
4174 class SurfaceMover(MonteCarloMover):
4175  r"""Proxy of C++ IMP::core::SurfaceMover class."""
4176 
4177  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
4178 
4179  def __init__(self, *args):
4180  r"""
4181  __init__(SurfaceMover self, Model m, ParticleIndex pi, IMP::Float max_translation, IMP::Float max_rotation, IMP::Float reflect_probability) -> SurfaceMover
4182  __init__(SurfaceMover self, Surface s, IMP::Float max_translation, IMP::Float max_rotation, IMP::Float reflect_probability) -> SurfaceMover
4183  __init__(SurfaceMover self) -> SurfaceMover
4184  """
4185  _IMP_core.SurfaceMover_swiginit(self, _IMP_core.new_SurfaceMover(*args))
4186 
4187  def set_maximum_translation(self, mt):
4188  r"""set_maximum_translation(SurfaceMover self, IMP::Float mt)"""
4189  return _IMP_core.SurfaceMover_set_maximum_translation(self, mt)
4190 
4191  def set_maximum_rotation(self, mr):
4192  r"""set_maximum_rotation(SurfaceMover self, IMP::Float mr)"""
4193  return _IMP_core.SurfaceMover_set_maximum_rotation(self, mr)
4194 
4195  def set_reflect_probability(self, rp):
4196  r"""set_reflect_probability(SurfaceMover self, IMP::Float rp)"""
4197  return _IMP_core.SurfaceMover_set_reflect_probability(self, rp)
4198 
4199  def get_maximum_translation(self):
4200  r"""get_maximum_translation(SurfaceMover self) -> IMP::Float"""
4201  return _IMP_core.SurfaceMover_get_maximum_translation(self)
4202 
4203  def get_maximum_rotation(self):
4204  r"""get_maximum_rotation(SurfaceMover self) -> IMP::Float"""
4205  return _IMP_core.SurfaceMover_get_maximum_rotation(self)
4206 
4207  def get_reflect_probability(self):
4208  r"""get_reflect_probability(SurfaceMover self) -> IMP::Float"""
4209  return _IMP_core.SurfaceMover_get_reflect_probability(self)
4210 
4211  def get_surface(self):
4212  r"""get_surface(SurfaceMover self) -> Surface"""
4213  return _IMP_core.SurfaceMover_get_surface(self)
4214 
4215  def get_version_info(self):
4216  r"""get_version_info(SurfaceMover self) -> VersionInfo"""
4217  return _IMP_core.SurfaceMover_get_version_info(self)
4218  __swig_destroy__ = _IMP_core.delete_SurfaceMover
4219 
4220  def __str__(self):
4221  r"""__str__(SurfaceMover self) -> std::string"""
4222  return _IMP_core.SurfaceMover___str__(self)
4223 
4224  def __repr__(self):
4225  r"""__repr__(SurfaceMover self) -> std::string"""
4226  return _IMP_core.SurfaceMover___repr__(self)
4227 
4228  @staticmethod
4229  def get_from(o):
4230  return _object_cast_to_SurfaceMover(o)
4231 
4232 
4233  def _get_as_binary(self):
4234  r"""_get_as_binary(SurfaceMover self) -> PyObject *"""
4235  return _IMP_core.SurfaceMover__get_as_binary(self)
4236 
4237  def _set_from_binary(self, p):
4238  r"""_set_from_binary(SurfaceMover self, PyObject * p)"""
4239  return _IMP_core.SurfaceMover__set_from_binary(self, p)
4240 
4241  def __getstate__(self):
4242  p = self._get_as_binary()
4243  if len(self.__dict__) > 1:
4244  d = self.__dict__.copy()
4245  del d['this']
4246  p = (d, p)
4247  return p
4248 
4249  def __setstate__(self, p):
4250  if not hasattr(self, 'this'):
4251  self.__init__()
4252  if isinstance(p, tuple):
4253  d, p = p
4254  self.__dict__.update(d)
4255  return self._set_from_binary(p)
4256 
4257 
4258 # Register SurfaceMover in _IMP_core:
4259 _IMP_core.SurfaceMover_swigregister(SurfaceMover)
4260 class BoxSweepClosePairsFinder(ClosePairsFinder):
4261  r"""Proxy of C++ IMP::core::BoxSweepClosePairsFinder class."""
4262 
4263  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
4264 
4265  def __init__(self):
4266  r"""__init__(BoxSweepClosePairsFinder self) -> BoxSweepClosePairsFinder"""
4267  _IMP_core.BoxSweepClosePairsFinder_swiginit(self, _IMP_core.new_BoxSweepClosePairsFinder())
4268 
4269  def get_close_pairs(self, *args):
4270  r"""
4271  get_close_pairs(BoxSweepClosePairsFinder self, IMP::algebra::BoundingBox3Ds const & bbs) -> IMP::IntPairs
4272  get_close_pairs(BoxSweepClosePairsFinder self, IMP::algebra::BoundingBox3Ds const & bas, IMP::algebra::BoundingBox3Ds const & bbs) -> IMP::IntPairs
4273  get_close_pairs(BoxSweepClosePairsFinder self, Model m, IMP::ParticleIndexes const & pc) -> IMP::ParticleIndexPairs
4274  get_close_pairs(BoxSweepClosePairsFinder self, Model m, IMP::ParticleIndexes const & pca, IMP::ParticleIndexes const & pcb) -> IMP::ParticleIndexPairs
4275  """
4276  return _IMP_core.BoxSweepClosePairsFinder_get_close_pairs(self, *args)
4277 
4278  def do_get_inputs(self, m, pis):
4279  r"""do_get_inputs(BoxSweepClosePairsFinder self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
4280  return _IMP_core.BoxSweepClosePairsFinder_do_get_inputs(self, m, pis)
4281 
4282  def get_version_info(self):
4283  r"""get_version_info(BoxSweepClosePairsFinder self) -> VersionInfo"""
4284  return _IMP_core.BoxSweepClosePairsFinder_get_version_info(self)
4285  __swig_destroy__ = _IMP_core.delete_BoxSweepClosePairsFinder
4286 
4287  def __str__(self):
4288  r"""__str__(BoxSweepClosePairsFinder self) -> std::string"""
4289  return _IMP_core.BoxSweepClosePairsFinder___str__(self)
4290 
4291  def __repr__(self):
4292  r"""__repr__(BoxSweepClosePairsFinder self) -> std::string"""
4293  return _IMP_core.BoxSweepClosePairsFinder___repr__(self)
4294 
4295  @staticmethod
4296  def get_from(o):
4297  return _object_cast_to_BoxSweepClosePairsFinder(o)
4298 
4299 
4300 # Register BoxSweepClosePairsFinder in _IMP_core:
4301 _IMP_core.BoxSweepClosePairsFinder_swigregister(BoxSweepClosePairsFinder)
4302 class CentroidOfRefined(IMP.SingletonModifier):
4303  r"""Proxy of C++ IMP::core::CentroidOfRefined class."""
4304 
4305  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
4306 
4307  def __init__(self, *args):
4308  r"""
4309  __init__(CentroidOfRefined self, Refiner r, FloatKey weight=IMP::FloatKey(), IMP::FloatKeys ks=IMP::core::XYZ::get_xyz_keys()) -> CentroidOfRefined
4310  __init__(CentroidOfRefined self) -> CentroidOfRefined
4311  """
4312  _IMP_core.CentroidOfRefined_swiginit(self, _IMP_core.new_CentroidOfRefined(*args))
4313 
4314  def get_refiner(self):
4315  r"""get_refiner(CentroidOfRefined self) -> Refiner"""
4316  return _IMP_core.CentroidOfRefined_get_refiner(self)
4317 
4318  def get_weight(self):
4319  r"""get_weight(CentroidOfRefined self) -> FloatKey"""
4320  return _IMP_core.CentroidOfRefined_get_weight(self)
4321 
4322  def get_keys(self):
4323  r"""get_keys(CentroidOfRefined self) -> IMP::FloatKeys"""
4324  return _IMP_core.CentroidOfRefined_get_keys(self)
4325 
4326  def get_is_weight_null(self):
4327  r"""get_is_weight_null(CentroidOfRefined self) -> bool"""
4328  return _IMP_core.CentroidOfRefined_get_is_weight_null(self)
4329 
4330  def do_get_inputs(self, m, pis):
4331  r"""do_get_inputs(CentroidOfRefined self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
4332  return _IMP_core.CentroidOfRefined_do_get_inputs(self, m, pis)
4333 
4334  def do_get_outputs(self, m, pis):
4335  r"""do_get_outputs(CentroidOfRefined self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
4336  return _IMP_core.CentroidOfRefined_do_get_outputs(self, m, pis)
4337 
4338  def get_version_info(self):
4339  r"""get_version_info(CentroidOfRefined self) -> VersionInfo"""
4340  return _IMP_core.CentroidOfRefined_get_version_info(self)
4341  __swig_destroy__ = _IMP_core.delete_CentroidOfRefined
4342 
4343  def __str__(self):
4344  r"""__str__(CentroidOfRefined self) -> std::string"""
4345  return _IMP_core.CentroidOfRefined___str__(self)
4346 
4347  def __repr__(self):
4348  r"""__repr__(CentroidOfRefined self) -> std::string"""
4349  return _IMP_core.CentroidOfRefined___repr__(self)
4350 
4351  @staticmethod
4352  def get_from(o):
4353  return _object_cast_to_CentroidOfRefined(o)
4354 
4355 
4356  def _get_as_binary(self):
4357  r"""_get_as_binary(CentroidOfRefined self) -> PyObject *"""
4358  return _IMP_core.CentroidOfRefined__get_as_binary(self)
4359 
4360  def _set_from_binary(self, p):
4361  r"""_set_from_binary(CentroidOfRefined self, PyObject * p)"""
4362  return _IMP_core.CentroidOfRefined__set_from_binary(self, p)
4363 
4364  def __getstate__(self):
4365  p = self._get_as_binary()
4366  if len(self.__dict__) > 1:
4367  d = self.__dict__.copy()
4368  del d['this']
4369  p = (d, p)
4370  return p
4371 
4372  def __setstate__(self, p):
4373  if not hasattr(self, 'this'):
4374  self.__init__()
4375  if isinstance(p, tuple):
4376  d, p = p
4377  self.__dict__.update(d)
4378  return self._set_from_binary(p)
4379 
4380 
4381  def _get_jax(self, m, indexes):
4382  import jax.numpy as jnp
4383  refined = [
4384  self.get_refiner().get_refined_indexes(m, IMP.ParticleIndex(index))
4385  for index in indexes]
4386 
4387  def apply_func_unweighted(jm):
4388  for ind, ref in zip(indexes, refined):
4389  xyz = jm['xyz']
4390  jm['xyz'] = xyz.at[ind].set(jnp.average(xyz[ref], axis=0))
4391  return jm
4392 
4393  def apply_func_weighted(jm, weight_key):
4394  for ind, ref in zip(indexes, refined):
4395  xyz = jm['xyz']
4396  weights = jm[weight_key][ref]
4397  jm['xyz'] = xyz.at[ind].set(
4398  jnp.average(xyz[ref], axis=0, weights=weights))
4399  return jm
4400 
4401  keys = frozenset(self.get_keys())
4402  if keys != frozenset(IMP.core.XYZ.get_xyz_keys()):
4403  raise NotImplementedError("Only works for XYZ")
4404 
4405  if self.get_is_weight_null():
4406  return self._wrap_jax(apply_func_unweighted)
4407  else:
4408  weight_key = self.get_weight()
4409  return self._wrap_jax(
4410  functools.partial(apply_func_weighted,
4411  weight_key=weight_key.get_string()),
4412  keys=(weight_key,))
4413 
4414 
4415 # Register CentroidOfRefined in _IMP_core:
4416 _IMP_core.CentroidOfRefined_swigregister(CentroidOfRefined)
4417 class Centroid(XYZ):
4418  r"""Proxy of C++ IMP::core::Centroid class."""
4419 
4420  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
4421 
4422  def get_constraint(self):
4423  r"""get_constraint(Centroid self) -> Constraint"""
4424  return _IMP_core.Centroid_get_constraint(self)
4425 
4426  def __init__(self, *args):
4427  r"""
4428  __init__(Centroid self) -> Centroid
4429  __init__(Centroid self, Model m, ParticleIndex id) -> Centroid
4430  __init__(Centroid self, _ParticleAdaptor d) -> Centroid
4431  """
4432  _IMP_core.Centroid_swiginit(self, _IMP_core.new_Centroid(*args))
4433 
4434  def show(self, *args):
4435  r"""show(Centroid self, _ostream out=std::cout)"""
4436  return _IMP_core.Centroid_show(self, *args)
4437 
4438  @staticmethod
4439  def setup_particle(*args):
4440  r"""
4441  setup_particle(Model m, ParticleIndex pi, _ParticleIndexesAdaptor members) -> Centroid
4442  setup_particle(_ParticleAdaptor pa, _ParticleIndexesAdaptor members) -> Centroid
4443  setup_particle(Model m, ParticleIndex pi, Refiner refiner) -> Centroid
4444  setup_particle(_ParticleAdaptor pa, Refiner refiner) -> Centroid
4445  """
4446  return _IMP_core.Centroid_setup_particle(*args)
4447 
4448  @staticmethod
4449  def get_is_setup(*args):
4450  r"""
4451  get_is_setup(_ParticleAdaptor p) -> bool
4452  get_is_setup(Model m, ParticleIndex pi) -> bool
4453  """
4454  return _IMP_core.Centroid_get_is_setup(*args)
4455 
4456  def add_attribute(self, *args):
4457  r"""
4458  add_attribute(Centroid self, FloatKey k, IMP::Float v, bool opt)
4459  add_attribute(Centroid self, FloatKey a0, IMP::Float a1)
4460  add_attribute(Centroid self, IntKey a0, IMP::Int a1)
4461  add_attribute(Centroid self, FloatsKey a0, IMP::Floats a1)
4462  add_attribute(Centroid self, IntsKey a0, IMP::Ints a1)
4463  add_attribute(Centroid self, StringKey a0, IMP::String a1)
4464  add_attribute(Centroid self, ParticleIndexKey a0, Particle a1)
4465  add_attribute(Centroid self, ObjectKey a0, Object a1)
4466  add_attribute(Centroid self, SparseFloatKey a0, IMP::Float a1)
4467  add_attribute(Centroid self, SparseIntKey a0, IMP::Int a1)
4468  add_attribute(Centroid self, SparseStringKey a0, IMP::String a1)
4469  add_attribute(Centroid self, SparseParticleIndexKey a0, ParticleIndex a1)
4470  """
4471  return _IMP_core.Centroid_add_attribute(self, *args)
4472 
4473  def get_value(self, *args):
4474  r"""
4475  get_value(Centroid self, FloatKey a0) -> IMP::Float
4476  get_value(Centroid self, IntKey a0) -> IMP::Int
4477  get_value(Centroid self, FloatsKey a0) -> IMP::Floats
4478  get_value(Centroid self, IntsKey a0) -> IMP::Ints
4479  get_value(Centroid self, StringKey a0) -> IMP::String
4480  get_value(Centroid self, ParticleIndexKey a0) -> Particle
4481  get_value(Centroid self, ObjectKey a0) -> Object
4482  get_value(Centroid self, SparseFloatKey a0) -> IMP::Float
4483  get_value(Centroid self, SparseIntKey a0) -> IMP::Int
4484  get_value(Centroid self, SparseStringKey a0) -> IMP::String
4485  get_value(Centroid self, SparseParticleIndexKey a0) -> ParticleIndex
4486  """
4487  return _IMP_core.Centroid_get_value(self, *args)
4488 
4489  def set_value(self, *args):
4490  r"""
4491  set_value(Centroid self, FloatKey a0, IMP::Float a1)
4492  set_value(Centroid self, IntKey a0, IMP::Int a1)
4493  set_value(Centroid self, FloatsKey a0, IMP::Floats a1)
4494  set_value(Centroid self, IntsKey a0, IMP::Ints a1)
4495  set_value(Centroid self, StringKey a0, IMP::String a1)
4496  set_value(Centroid self, ParticleIndexKey a0, Particle a1)
4497  set_value(Centroid self, ObjectKey a0, Object a1)
4498  set_value(Centroid self, SparseFloatKey a0, IMP::Float a1)
4499  set_value(Centroid self, SparseIntKey a0, IMP::Int a1)
4500  set_value(Centroid self, SparseStringKey a0, IMP::String a1)
4501  set_value(Centroid self, SparseParticleIndexKey a0, ParticleIndex a1)
4502  """
4503  return _IMP_core.Centroid_set_value(self, *args)
4504 
4505  def remove_attribute(self, *args):
4506  r"""
4507  remove_attribute(Centroid self, FloatKey a0)
4508  remove_attribute(Centroid self, IntKey a0)
4509  remove_attribute(Centroid self, FloatsKey a0)
4510  remove_attribute(Centroid self, IntsKey a0)
4511  remove_attribute(Centroid self, StringKey a0)
4512  remove_attribute(Centroid self, ParticleIndexKey a0)
4513  remove_attribute(Centroid self, ObjectKey a0)
4514  remove_attribute(Centroid self, SparseFloatKey a0)
4515  remove_attribute(Centroid self, SparseIntKey a0)
4516  remove_attribute(Centroid self, SparseStringKey a0)
4517  remove_attribute(Centroid self, SparseParticleIndexKey a0)
4518  """
4519  return _IMP_core.Centroid_remove_attribute(self, *args)
4520 
4521  def has_attribute(self, *args):
4522  r"""
4523  has_attribute(Centroid self, FloatKey a0) -> bool
4524  has_attribute(Centroid self, IntKey a0) -> bool
4525  has_attribute(Centroid self, FloatsKey a0) -> bool
4526  has_attribute(Centroid self, IntsKey a0) -> bool
4527  has_attribute(Centroid self, StringKey a0) -> bool
4528  has_attribute(Centroid self, ParticleIndexKey a0) -> bool
4529  has_attribute(Centroid self, ObjectKey a0) -> bool
4530  has_attribute(Centroid self, SparseFloatKey a0) -> bool
4531  has_attribute(Centroid self, SparseIntKey a0) -> bool
4532  has_attribute(Centroid self, SparseStringKey a0) -> bool
4533  has_attribute(Centroid self, SparseParticleIndexKey a0) -> bool
4534  """
4535  return _IMP_core.Centroid_has_attribute(self, *args)
4536 
4537  def get_derivative(self, a0):
4538  r"""get_derivative(Centroid self, FloatKey a0) -> double"""
4539  return _IMP_core.Centroid_get_derivative(self, a0)
4540 
4541  def get_name(self):
4542  r"""get_name(Centroid self) -> std::string"""
4543  return _IMP_core.Centroid_get_name(self)
4544 
4545  def clear_caches(self):
4546  r"""clear_caches(Centroid self)"""
4547  return _IMP_core.Centroid_clear_caches(self)
4548 
4549  def set_name(self, a0):
4550  r"""set_name(Centroid self, std::string a0)"""
4551  return _IMP_core.Centroid_set_name(self, a0)
4552 
4553  def set_check_level(self, a0):
4554  r"""set_check_level(Centroid self, IMP::CheckLevel a0)"""
4555  return _IMP_core.Centroid_set_check_level(self, a0)
4556 
4557  def add_to_derivative(self, a0, a1, a2):
4558  r"""add_to_derivative(Centroid self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
4559  return _IMP_core.Centroid_add_to_derivative(self, a0, a1, a2)
4560 
4561  def set_is_optimized(self, a0, a1):
4562  r"""set_is_optimized(Centroid self, FloatKey a0, bool a1)"""
4563  return _IMP_core.Centroid_set_is_optimized(self, a0, a1)
4564 
4565  def get_is_optimized(self, a0):
4566  r"""get_is_optimized(Centroid self, FloatKey a0) -> bool"""
4567  return _IMP_core.Centroid_get_is_optimized(self, a0)
4568 
4569  def get_check_level(self):
4570  r"""get_check_level(Centroid self) -> IMP::CheckLevel"""
4571  return _IMP_core.Centroid_get_check_level(self)
4572 
4573  def __eq__(self, *args):
4574  r"""
4575  __eq__(Centroid self, Centroid o) -> bool
4576  __eq__(Centroid self, Particle d) -> bool
4577  """
4578  return _IMP_core.Centroid___eq__(self, *args)
4579 
4580  def __ne__(self, *args):
4581  r"""
4582  __ne__(Centroid self, Centroid o) -> bool
4583  __ne__(Centroid self, Particle d) -> bool
4584  """
4585  return _IMP_core.Centroid___ne__(self, *args)
4586 
4587  def __le__(self, *args):
4588  r"""
4589  __le__(Centroid self, Centroid o) -> bool
4590  __le__(Centroid self, Particle d) -> bool
4591  """
4592  return _IMP_core.Centroid___le__(self, *args)
4593 
4594  def __lt__(self, *args):
4595  r"""
4596  __lt__(Centroid self, Centroid o) -> bool
4597  __lt__(Centroid self, Particle d) -> bool
4598  """
4599  return _IMP_core.Centroid___lt__(self, *args)
4600 
4601  def __ge__(self, *args):
4602  r"""
4603  __ge__(Centroid self, Centroid o) -> bool
4604  __ge__(Centroid self, Particle d) -> bool
4605  """
4606  return _IMP_core.Centroid___ge__(self, *args)
4607 
4608  def __gt__(self, *args):
4609  r"""
4610  __gt__(Centroid self, Centroid o) -> bool
4611  __gt__(Centroid self, Particle d) -> bool
4612  """
4613  return _IMP_core.Centroid___gt__(self, *args)
4614 
4615  def __hash__(self):
4616  r"""__hash__(Centroid self) -> std::size_t"""
4617  return _IMP_core.Centroid___hash__(self)
4618 
4619  def __str__(self):
4620  r"""__str__(Centroid self) -> std::string"""
4621  return _IMP_core.Centroid___str__(self)
4622 
4623  def __repr__(self):
4624  r"""__repr__(Centroid self) -> std::string"""
4625  return _IMP_core.Centroid___repr__(self)
4626 
4627  def _get_as_binary(self):
4628  r"""_get_as_binary(Centroid self) -> PyObject *"""
4629  return _IMP_core.Centroid__get_as_binary(self)
4630 
4631  def _set_from_binary(self, p):
4632  r"""_set_from_binary(Centroid self, PyObject * p)"""
4633  return _IMP_core.Centroid__set_from_binary(self, p)
4634 
4635  def __getstate__(self):
4636  p = self._get_as_binary()
4637  if len(self.__dict__) > 1:
4638  d = self.__dict__.copy()
4639  del d['this']
4640  p = (d, p)
4641  return p
4642 
4643  def __setstate__(self, p):
4644  if not hasattr(self, 'this'):
4645  self.__init__()
4646  if isinstance(p, tuple):
4647  d, p = p
4648  self.__dict__.update(d)
4649  return self._set_from_binary(p)
4650 
4651  __swig_destroy__ = _IMP_core.delete_Centroid
4652 
4653 # Register Centroid in _IMP_core:
4654 _IMP_core.Centroid_swigregister(Centroid)
4655 class ChecksScoreState(IMP.ScoreState):
4656  r"""Proxy of C++ IMP::core::ChecksScoreState class."""
4657 
4658  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
4659 
4660  def __init__(self, *args):
4661  r"""
4662  __init__(ChecksScoreState self, Model m, double probability) -> ChecksScoreState
4663  __init__(ChecksScoreState self) -> ChecksScoreState
4664  """
4665  _IMP_core.ChecksScoreState_swiginit(self, _IMP_core.new_ChecksScoreState(*args))
4666 
4667  def get_number_of_checked(self):
4668  r"""get_number_of_checked(ChecksScoreState self) -> unsigned int"""
4669  return _IMP_core.ChecksScoreState_get_number_of_checked(self)
4670 
4671  def do_before_evaluate(self):
4672  r"""do_before_evaluate(ChecksScoreState self)"""
4673  return _IMP_core.ChecksScoreState_do_before_evaluate(self)
4674 
4675  def do_after_evaluate(self, da):
4676  r"""do_after_evaluate(ChecksScoreState self, DerivativeAccumulator da)"""
4677  return _IMP_core.ChecksScoreState_do_after_evaluate(self, da)
4678 
4679  def do_get_outputs(self):
4680  r"""do_get_outputs(ChecksScoreState self) -> IMP::ModelObjectsTemp"""
4681  return _IMP_core.ChecksScoreState_do_get_outputs(self)
4682 
4683  def do_get_inputs(self):
4684  r"""do_get_inputs(ChecksScoreState self) -> IMP::ModelObjectsTemp"""
4685  return _IMP_core.ChecksScoreState_do_get_inputs(self)
4686 
4687  def get_version_info(self):
4688  r"""get_version_info(ChecksScoreState self) -> VersionInfo"""
4689  return _IMP_core.ChecksScoreState_get_version_info(self)
4690  __swig_destroy__ = _IMP_core.delete_ChecksScoreState
4691 
4692  def __str__(self):
4693  r"""__str__(ChecksScoreState self) -> std::string"""
4694  return _IMP_core.ChecksScoreState___str__(self)
4695 
4696  def __repr__(self):
4697  r"""__repr__(ChecksScoreState self) -> std::string"""
4698  return _IMP_core.ChecksScoreState___repr__(self)
4699 
4700  @staticmethod
4701  def get_from(o):
4702  return _object_cast_to_ChecksScoreState(o)
4703 
4704 
4705  def _get_as_binary(self):
4706  r"""_get_as_binary(ChecksScoreState self) -> PyObject *"""
4707  return _IMP_core.ChecksScoreState__get_as_binary(self)
4708 
4709  def _set_from_binary(self, p):
4710  r"""_set_from_binary(ChecksScoreState self, PyObject * p)"""
4711  return _IMP_core.ChecksScoreState__set_from_binary(self, p)
4712 
4713  def __getstate__(self):
4714  p = self._get_as_binary()
4715  if len(self.__dict__) > 1:
4716  d = self.__dict__.copy()
4717  del d['this']
4718  p = (d, p)
4719  return p
4720 
4721  def __setstate__(self, p):
4722  if not hasattr(self, 'this'):
4723  self.__init__()
4724  if isinstance(p, tuple):
4725  d, p = p
4726  self.__dict__.update(d)
4727  return self._set_from_binary(p)
4728 
4729 
4730 # Register ChecksScoreState in _IMP_core:
4731 _IMP_core.ChecksScoreState_swigregister(ChecksScoreState)
4732 class ChildrenRefiner(IMP.Refiner):
4733  r"""Proxy of C++ IMP::core::ChildrenRefiner class."""
4734 
4735  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
4736 
4737  def __init__(self, tr):
4738  r"""__init__(ChildrenRefiner self, HierarchyTraits tr) -> ChildrenRefiner"""
4739  _IMP_core.ChildrenRefiner_swiginit(self, _IMP_core.new_ChildrenRefiner(tr))
4740 
4741  def do_get_inputs(self, m, pis):
4742  r"""do_get_inputs(ChildrenRefiner self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
4743  return _IMP_core.ChildrenRefiner_do_get_inputs(self, m, pis)
4744 
4745  def get_version_info(self):
4746  r"""get_version_info(ChildrenRefiner self) -> VersionInfo"""
4747  return _IMP_core.ChildrenRefiner_get_version_info(self)
4748  __swig_destroy__ = _IMP_core.delete_ChildrenRefiner
4749 
4750  def __str__(self):
4751  r"""__str__(ChildrenRefiner self) -> std::string"""
4752  return _IMP_core.ChildrenRefiner___str__(self)
4753 
4754  def __repr__(self):
4755  r"""__repr__(ChildrenRefiner self) -> std::string"""
4756  return _IMP_core.ChildrenRefiner___repr__(self)
4757 
4758  @staticmethod
4759  def get_from(o):
4760  return _object_cast_to_ChildrenRefiner(o)
4761 
4762 
4763 # Register ChildrenRefiner in _IMP_core:
4764 _IMP_core.ChildrenRefiner_swigregister(ChildrenRefiner)
4765 class ClosedCubicSpline(IMP.UnaryFunction):
4766  r"""Proxy of C++ IMP::core::ClosedCubicSpline class."""
4767 
4768  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
4769 
4770  def __init__(self, values, minrange, spacing):
4771  r"""__init__(ClosedCubicSpline self, IMP::Floats const & values, double minrange, double spacing) -> ClosedCubicSpline"""
4772  _IMP_core.ClosedCubicSpline_swiginit(self, _IMP_core.new_ClosedCubicSpline(values, minrange, spacing))
4773 
4774  def get_version_info(self):
4775  r"""get_version_info(ClosedCubicSpline self) -> VersionInfo"""
4776  return _IMP_core.ClosedCubicSpline_get_version_info(self)
4777  __swig_destroy__ = _IMP_core.delete_ClosedCubicSpline
4778 
4779  def do_show(self, out):
4780  r"""do_show(ClosedCubicSpline self, _ostream out)"""
4781  return _IMP_core.ClosedCubicSpline_do_show(self, out)
4782 
4783  def get_minrange(self):
4784  r"""get_minrange(ClosedCubicSpline self) -> IMP::Float"""
4785  return _IMP_core.ClosedCubicSpline_get_minrange(self)
4786 
4787  def get_spacing(self):
4788  r"""get_spacing(ClosedCubicSpline self) -> IMP::Float"""
4789  return _IMP_core.ClosedCubicSpline_get_spacing(self)
4790 
4791  def get_values(self):
4792  r"""get_values(ClosedCubicSpline self) -> IMP::Floats"""
4793  return _IMP_core.ClosedCubicSpline_get_values(self)
4794 
4795  def get_second_derivatives(self):
4796  r"""get_second_derivatives(ClosedCubicSpline self) -> IMP::Floats"""
4797  return _IMP_core.ClosedCubicSpline_get_second_derivatives(self)
4798 
4799  def __str__(self):
4800  r"""__str__(ClosedCubicSpline self) -> std::string"""
4801  return _IMP_core.ClosedCubicSpline___str__(self)
4802 
4803  def __repr__(self):
4804  r"""__repr__(ClosedCubicSpline self) -> std::string"""
4805  return _IMP_core.ClosedCubicSpline___repr__(self)
4806 
4807  @staticmethod
4808  def get_from(o):
4809  return _object_cast_to_ClosedCubicSpline(o)
4810 
4811 
4812  def _get_jax(self):
4813  import jax.numpy as jnp
4814  from IMP.core._jax_util import _spline
4815  def score(feature, minrange, spacing, values, second_derivs):
4816  # determine bin index and thus the cubic fragment to use:
4817  lowbin = jnp.array((feature - minrange) / spacing, dtype=int)
4818  # enforce periodicity - wrap around from n to 0
4819  highbin = jnp.remainder(lowbin + 1, len(values))
4820  return _spline(feature, minrange, lowbin, highbin, spacing,
4821  values, second_derivs)
4822  return functools.partial(
4823  score, minrange=self.get_minrange(),
4824  spacing=self.get_spacing(), values=jnp.asarray(self.get_values()),
4825  second_derivs=jnp.asarray(self.get_second_derivatives()))
4826 
4827 
4828 # Register ClosedCubicSpline in _IMP_core:
4829 _IMP_core.ClosedCubicSpline_swigregister(ClosedCubicSpline)
4830 class KClosePairsPairScore(IMP.PairScore):
4831  r"""Proxy of C++ IMP::core::KClosePairsPairScore class."""
4832 
4833  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
4834 
4835  def __init__(self, f, r, k=1):
4836  r"""__init__(KClosePairsPairScore self, PairScore f, Refiner r, int k=1) -> KClosePairsPairScore"""
4837  _IMP_core.KClosePairsPairScore_swiginit(self, _IMP_core.new_KClosePairsPairScore(f, r, k))
4838 
4839  def get_close_pairs(self, pp):
4840  r"""get_close_pairs(KClosePairsPairScore self, IMP::ParticlePair const & pp) -> IMP::ParticlePairsTemp"""
4841  return _IMP_core.KClosePairsPairScore_get_close_pairs(self, pp)
4842 
4843  def create_current_decomposition(self, m, vt):
4844  r"""create_current_decomposition(KClosePairsPairScore self, Model m, IMP::ParticleIndexPair const & vt) -> IMP::Restraints"""
4845  return _IMP_core.KClosePairsPairScore_create_current_decomposition(self, m, vt)
4846 
4847  def do_get_inputs(self, m, pis):
4848  r"""do_get_inputs(KClosePairsPairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
4849  return _IMP_core.KClosePairsPairScore_do_get_inputs(self, m, pis)
4850 
4851  def evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked=False):
4852  r"""evaluate_indexes(KClosePairsPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
4853  return _IMP_core.KClosePairsPairScore_evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked)
4854 
4855  def evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked=False):
4856  r"""evaluate_indexes_scores(KClosePairsPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
4857  return _IMP_core.KClosePairsPairScore_evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked)
4858 
4859  def evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked=False):
4860  r"""evaluate_indexes_delta(KClosePairsPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, std::vector< unsigned int,std::allocator< unsigned int > > const & indexes, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
4861  return _IMP_core.KClosePairsPairScore_evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked)
4862 
4863  def evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked=False):
4864  r"""evaluate_if_good_indexes(KClosePairsPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, double max, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
4865  return _IMP_core.KClosePairsPairScore_evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked)
4866 
4867  def get_version_info(self):
4868  r"""get_version_info(KClosePairsPairScore self) -> VersionInfo"""
4869  return _IMP_core.KClosePairsPairScore_get_version_info(self)
4870  __swig_destroy__ = _IMP_core.delete_KClosePairsPairScore
4871 
4872  def __str__(self):
4873  r"""__str__(KClosePairsPairScore self) -> std::string"""
4874  return _IMP_core.KClosePairsPairScore___str__(self)
4875 
4876  def __repr__(self):
4877  r"""__repr__(KClosePairsPairScore self) -> std::string"""
4878  return _IMP_core.KClosePairsPairScore___repr__(self)
4879 
4880  @staticmethod
4881  def get_from(o):
4882  return _object_cast_to_KClosePairsPairScore(o)
4883 
4884 
4885 # Register KClosePairsPairScore in _IMP_core:
4886 _IMP_core.KClosePairsPairScore_swigregister(KClosePairsPairScore)
4887 class ClosePairsPairScore(IMP.PairScore):
4888  r"""Proxy of C++ IMP::core::ClosePairsPairScore class."""
4889 
4890  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
4891 
4892  def __init__(self, f, r, max_distance):
4893  r"""__init__(ClosePairsPairScore self, PairScore f, Refiner r, IMP::Float max_distance) -> ClosePairsPairScore"""
4894  _IMP_core.ClosePairsPairScore_swiginit(self, _IMP_core.new_ClosePairsPairScore(f, r, max_distance))
4895 
4896  def get_close_pairs(self, pp):
4897  r"""get_close_pairs(ClosePairsPairScore self, IMP::ParticlePair const & pp) -> IMP::ParticlePairsTemp"""
4898  return _IMP_core.ClosePairsPairScore_get_close_pairs(self, pp)
4899 
4900  def create_current_decomposition(self, m, vt):
4901  r"""create_current_decomposition(ClosePairsPairScore self, Model m, IMP::ParticleIndexPair const & vt) -> IMP::Restraints"""
4902  return _IMP_core.ClosePairsPairScore_create_current_decomposition(self, m, vt)
4903 
4904  def do_get_inputs(self, m, pis):
4905  r"""do_get_inputs(ClosePairsPairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
4906  return _IMP_core.ClosePairsPairScore_do_get_inputs(self, m, pis)
4907 
4908  def evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked=False):
4909  r"""evaluate_indexes(ClosePairsPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
4910  return _IMP_core.ClosePairsPairScore_evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked)
4911 
4912  def evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked=False):
4913  r"""evaluate_indexes_scores(ClosePairsPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
4914  return _IMP_core.ClosePairsPairScore_evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked)
4915 
4916  def evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked=False):
4917  r"""evaluate_indexes_delta(ClosePairsPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, std::vector< unsigned int,std::allocator< unsigned int > > const & indexes, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
4918  return _IMP_core.ClosePairsPairScore_evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked)
4919 
4920  def evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked=False):
4921  r"""evaluate_if_good_indexes(ClosePairsPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, double max, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
4922  return _IMP_core.ClosePairsPairScore_evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked)
4923 
4924  def get_version_info(self):
4925  r"""get_version_info(ClosePairsPairScore self) -> VersionInfo"""
4926  return _IMP_core.ClosePairsPairScore_get_version_info(self)
4927  __swig_destroy__ = _IMP_core.delete_ClosePairsPairScore
4928 
4929  def __str__(self):
4930  r"""__str__(ClosePairsPairScore self) -> std::string"""
4931  return _IMP_core.ClosePairsPairScore___str__(self)
4932 
4933  def __repr__(self):
4934  r"""__repr__(ClosePairsPairScore self) -> std::string"""
4935  return _IMP_core.ClosePairsPairScore___repr__(self)
4936 
4937  @staticmethod
4938  def get_from(o):
4939  return _object_cast_to_ClosePairsPairScore(o)
4940 
4941 
4942 # Register ClosePairsPairScore in _IMP_core:
4943 _IMP_core.ClosePairsPairScore_swigregister(ClosePairsPairScore)
4944 class ConjugateGradients(IMP.AttributeOptimizer):
4945  r"""Proxy of C++ IMP::core::ConjugateGradients class."""
4946 
4947  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
4948 
4949  def __init__(self, *args):
4950  r"""
4951  __init__(ConjugateGradients self, Model m, std::string name="ConjugateGradients%1%") -> ConjugateGradients
4952  __init__(ConjugateGradients self) -> ConjugateGradients
4953  """
4954  _IMP_core.ConjugateGradients_swiginit(self, _IMP_core.new_ConjugateGradients(*args))
4955 
4956  def set_gradient_threshold(self, t):
4957  r"""set_gradient_threshold(ConjugateGradients self, IMP::Float t)"""
4958  return _IMP_core.ConjugateGradients_set_gradient_threshold(self, t)
4959 
4960  def set_max_change(self, t):
4961  r"""set_max_change(ConjugateGradients self, IMP::Float t)"""
4962  return _IMP_core.ConjugateGradients_set_max_change(self, t)
4963 
4964  def do_optimize(self, max_steps):
4965  r"""do_optimize(ConjugateGradients self, unsigned int max_steps) -> IMP::Float"""
4966  return _IMP_core.ConjugateGradients_do_optimize(self, max_steps)
4967 
4968  def get_version_info(self):
4969  r"""get_version_info(ConjugateGradients self) -> VersionInfo"""
4970  return _IMP_core.ConjugateGradients_get_version_info(self)
4971  __swig_destroy__ = _IMP_core.delete_ConjugateGradients
4972 
4973  def __str__(self):
4974  r"""__str__(ConjugateGradients self) -> std::string"""
4975  return _IMP_core.ConjugateGradients___str__(self)
4976 
4977  def __repr__(self):
4978  r"""__repr__(ConjugateGradients self) -> std::string"""
4979  return _IMP_core.ConjugateGradients___repr__(self)
4980 
4981  @staticmethod
4982  def get_from(o):
4983  return _object_cast_to_ConjugateGradients(o)
4984 
4985 
4986  def _get_as_binary(self):
4987  r"""_get_as_binary(ConjugateGradients self) -> PyObject *"""
4988  return _IMP_core.ConjugateGradients__get_as_binary(self)
4989 
4990  def _set_from_binary(self, p):
4991  r"""_set_from_binary(ConjugateGradients self, PyObject * p)"""
4992  return _IMP_core.ConjugateGradients__set_from_binary(self, p)
4993 
4994  def __getstate__(self):
4995  p = self._get_as_binary()
4996  if len(self.__dict__) > 1:
4997  d = self.__dict__.copy()
4998  del d['this']
4999  p = (d, p)
5000  return p
5001 
5002  def __setstate__(self, p):
5003  if not hasattr(self, 'this'):
5004  self.__init__()
5005  if isinstance(p, tuple):
5006  d, p = p
5007  self.__dict__.update(d)
5008  return self._set_from_binary(p)
5009 
5010 
5011 # Register ConjugateGradients in _IMP_core:
5012 _IMP_core.ConjugateGradients_swigregister(ConjugateGradients)
5013 class ConnectivityRestraint(IMP.Restraint):
5014  r"""Proxy of C++ IMP::core::ConnectivityRestraint class."""
5015 
5016  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
5017 
5018  def __init__(self, ps, sc):
5019  r"""__init__(ConnectivityRestraint self, PairScore ps, _SingletonContainerAdaptor sc) -> ConnectivityRestraint"""
5020  _IMP_core.ConnectivityRestraint_swiginit(self, _IMP_core.new_ConnectivityRestraint(ps, sc))
5021 
5022  def get_connected_index_pairs(self):
5023  r"""get_connected_index_pairs(ConnectivityRestraint self) -> IMP::ParticleIndexPairs"""
5024  return _IMP_core.ConnectivityRestraint_get_connected_index_pairs(self)
5025 
5026  def get_pair_score(self):
5027  r"""get_pair_score(ConnectivityRestraint self) -> PairScore"""
5028  return _IMP_core.ConnectivityRestraint_get_pair_score(self)
5029 
5030  def do_create_current_decomposition(self):
5031  r"""do_create_current_decomposition(ConnectivityRestraint self) -> IMP::Restraints"""
5032  return _IMP_core.ConnectivityRestraint_do_create_current_decomposition(self)
5033 
5034  def do_get_inputs(self):
5035  r"""do_get_inputs(ConnectivityRestraint self) -> IMP::ModelObjectsTemp"""
5036  return _IMP_core.ConnectivityRestraint_do_get_inputs(self)
5037 
5038  def get_version_info(self):
5039  r"""get_version_info(ConnectivityRestraint self) -> VersionInfo"""
5040  return _IMP_core.ConnectivityRestraint_get_version_info(self)
5041  __swig_destroy__ = _IMP_core.delete_ConnectivityRestraint
5042 
5043  def __str__(self):
5044  r"""__str__(ConnectivityRestraint self) -> std::string"""
5045  return _IMP_core.ConnectivityRestraint___str__(self)
5046 
5047  def __repr__(self):
5048  r"""__repr__(ConnectivityRestraint self) -> std::string"""
5049  return _IMP_core.ConnectivityRestraint___repr__(self)
5050 
5051  @staticmethod
5052  def get_from(o):
5053  return _object_cast_to_ConnectivityRestraint(o)
5054 
5055 
5056 # Register ConnectivityRestraint in _IMP_core:
5057 _IMP_core.ConnectivityRestraint_swigregister(ConnectivityRestraint)
5058 class ConstantRestraint(IMP.Restraint):
5059  r"""Proxy of C++ IMP::core::ConstantRestraint class."""
5060 
5061  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
5062 
5063  def __init__(self, *args):
5064  r"""
5065  __init__(ConstantRestraint self, Model m, IMP::Float v) -> ConstantRestraint
5066  __init__(ConstantRestraint self) -> ConstantRestraint
5067  """
5068  _IMP_core.ConstantRestraint_swiginit(self, _IMP_core.new_ConstantRestraint(*args))
5069 
5070  def do_get_inputs(self):
5071  r"""do_get_inputs(ConstantRestraint self) -> IMP::ModelObjectsTemp"""
5072  return _IMP_core.ConstantRestraint_do_get_inputs(self)
5073 
5074  def get_version_info(self):
5075  r"""get_version_info(ConstantRestraint self) -> VersionInfo"""
5076  return _IMP_core.ConstantRestraint_get_version_info(self)
5077  __swig_destroy__ = _IMP_core.delete_ConstantRestraint
5078 
5079  def __str__(self):
5080  r"""__str__(ConstantRestraint self) -> std::string"""
5081  return _IMP_core.ConstantRestraint___str__(self)
5082 
5083  def __repr__(self):
5084  r"""__repr__(ConstantRestraint self) -> std::string"""
5085  return _IMP_core.ConstantRestraint___repr__(self)
5086 
5087  @staticmethod
5088  def get_from(o):
5089  return _object_cast_to_ConstantRestraint(o)
5090 
5091 
5092  def _get_as_binary(self):
5093  r"""_get_as_binary(ConstantRestraint self) -> PyObject *"""
5094  return _IMP_core.ConstantRestraint__get_as_binary(self)
5095 
5096  def _set_from_binary(self, p):
5097  r"""_set_from_binary(ConstantRestraint self, PyObject * p)"""
5098  return _IMP_core.ConstantRestraint__set_from_binary(self, p)
5099 
5100  def __getstate__(self):
5101  p = self._get_as_binary()
5102  if len(self.__dict__) > 1:
5103  d = self.__dict__.copy()
5104  del d['this']
5105  p = (d, p)
5106  return p
5107 
5108  def __setstate__(self, p):
5109  if not hasattr(self, 'this'):
5110  self.__init__()
5111  if isinstance(p, tuple):
5112  d, p = p
5113  self.__dict__.update(d)
5114  return self._set_from_binary(p)
5115 
5116 
5117 # Register ConstantRestraint in _IMP_core:
5118 _IMP_core.ConstantRestraint_swigregister(ConstantRestraint)
5119 class Cosine(IMP.UnaryFunction):
5120  r"""Proxy of C++ IMP::core::Cosine class."""
5121 
5122  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
5123 
5124  def __init__(self, *args):
5125  r"""
5126  __init__(Cosine self, IMP::Float force_constant, int periodicity, IMP::Float phase) -> Cosine
5127  __init__(Cosine self) -> Cosine
5128  """
5129  _IMP_core.Cosine_swiginit(self, _IMP_core.new_Cosine(*args))
5130 
5131  def get_force_constant(self):
5132  r"""get_force_constant(Cosine self) -> IMP::Float"""
5133  return _IMP_core.Cosine_get_force_constant(self)
5134 
5135  def get_periodicity(self):
5136  r"""get_periodicity(Cosine self) -> int"""
5137  return _IMP_core.Cosine_get_periodicity(self)
5138 
5139  def get_phase(self):
5140  r"""get_phase(Cosine self) -> IMP::Float"""
5141  return _IMP_core.Cosine_get_phase(self)
5142 
5143  def get_version_info(self):
5144  r"""get_version_info(Cosine self) -> VersionInfo"""
5145  return _IMP_core.Cosine_get_version_info(self)
5146  __swig_destroy__ = _IMP_core.delete_Cosine
5147 
5148  def do_show(self, out):
5149  r"""do_show(Cosine self, _ostream out)"""
5150  return _IMP_core.Cosine_do_show(self, out)
5151 
5152  def __str__(self):
5153  r"""__str__(Cosine self) -> std::string"""
5154  return _IMP_core.Cosine___str__(self)
5155 
5156  def __repr__(self):
5157  r"""__repr__(Cosine self) -> std::string"""
5158  return _IMP_core.Cosine___repr__(self)
5159 
5160  @staticmethod
5161  def get_from(o):
5162  return _object_cast_to_Cosine(o)
5163 
5164 
5165  def _get_as_binary(self):
5166  r"""_get_as_binary(Cosine self) -> PyObject *"""
5167  return _IMP_core.Cosine__get_as_binary(self)
5168 
5169  def _set_from_binary(self, p):
5170  r"""_set_from_binary(Cosine self, PyObject * p)"""
5171  return _IMP_core.Cosine__set_from_binary(self, p)
5172 
5173  def __getstate__(self):
5174  p = self._get_as_binary()
5175  if len(self.__dict__) > 1:
5176  d = self.__dict__.copy()
5177  del d['this']
5178  p = (d, p)
5179  return p
5180 
5181  def __setstate__(self, p):
5182  if not hasattr(self, 'this'):
5183  self.__init__()
5184  if isinstance(p, tuple):
5185  d, p = p
5186  self.__dict__.update(d)
5187  return self._set_from_binary(p)
5188 
5189 
5190  def _get_jax(self):
5191  import jax.numpy as jnp
5192  def score(val, k, period, phase):
5193  return jnp.abs(k) - k * jnp.cos(period * val + phase)
5194  return functools.partial(score, k=self.get_force_constant(),
5195  period=self.get_periodicity(),
5196  phase=self.get_phase())
5197 
5198 
5199 # Register Cosine in _IMP_core:
5200 _IMP_core.Cosine_swigregister(Cosine)
5201 class CoverRefined(IMP.SingletonModifier):
5202  r"""Proxy of C++ IMP::core::CoverRefined class."""
5203 
5204  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
5205 
5206  def __init__(self, ref, slack=0):
5207  r"""__init__(CoverRefined self, Refiner ref, IMP::Float slack=0) -> CoverRefined"""
5208  _IMP_core.CoverRefined_swiginit(self, _IMP_core.new_CoverRefined(ref, slack))
5209 
5210  def set_slack(self, slack):
5211  r"""set_slack(CoverRefined self, IMP::Float slack)"""
5212  return _IMP_core.CoverRefined_set_slack(self, slack)
5213 
5214  def do_get_inputs(self, m, pis):
5215  r"""do_get_inputs(CoverRefined self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
5216  return _IMP_core.CoverRefined_do_get_inputs(self, m, pis)
5217 
5218  def do_get_outputs(self, m, pis):
5219  r"""do_get_outputs(CoverRefined self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
5220  return _IMP_core.CoverRefined_do_get_outputs(self, m, pis)
5221 
5222  def get_version_info(self):
5223  r"""get_version_info(CoverRefined self) -> VersionInfo"""
5224  return _IMP_core.CoverRefined_get_version_info(self)
5225  __swig_destroy__ = _IMP_core.delete_CoverRefined
5226 
5227  def __str__(self):
5228  r"""__str__(CoverRefined self) -> std::string"""
5229  return _IMP_core.CoverRefined___str__(self)
5230 
5231  def __repr__(self):
5232  r"""__repr__(CoverRefined self) -> std::string"""
5233  return _IMP_core.CoverRefined___repr__(self)
5234 
5235  @staticmethod
5236  def get_from(o):
5237  return _object_cast_to_CoverRefined(o)
5238 
5239 
5240 # Register CoverRefined in _IMP_core:
5241 _IMP_core.CoverRefined_swigregister(CoverRefined)
5242 class Cover(XYZR):
5243  r"""Proxy of C++ IMP::core::Cover class."""
5244 
5245  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
5246 
5247  def get_constraint(self):
5248  r"""get_constraint(Cover self) -> Constraint"""
5249  return _IMP_core.Cover_get_constraint(self)
5250 
5251  def __init__(self, *args):
5252  r"""
5253  __init__(Cover self) -> Cover
5254  __init__(Cover self, Model m, ParticleIndex id) -> Cover
5255  __init__(Cover self, _ParticleAdaptor d) -> Cover
5256  """
5257  _IMP_core.Cover_swiginit(self, _IMP_core.new_Cover(*args))
5258 
5259  def show(self, *args):
5260  r"""show(Cover self, _ostream out=std::cout)"""
5261  return _IMP_core.Cover_show(self, *args)
5262 
5263  @staticmethod
5264  def setup_particle(*args):
5265  r"""
5266  setup_particle(Model m, ParticleIndex pi, _ParticleIndexesAdaptor members) -> Cover
5267  setup_particle(_ParticleAdaptor pa, _ParticleIndexesAdaptor members) -> Cover
5268  setup_particle(Model m, ParticleIndex pi, Refiner refiner) -> Cover
5269  setup_particle(_ParticleAdaptor pa, Refiner refiner) -> Cover
5270  """
5271  return _IMP_core.Cover_setup_particle(*args)
5272 
5273  @staticmethod
5274  def get_is_setup(*args):
5275  r"""
5276  get_is_setup(_ParticleAdaptor p) -> bool
5277  get_is_setup(Model m, ParticleIndex pi) -> bool
5278  """
5279  return _IMP_core.Cover_get_is_setup(*args)
5280 
5281  def add_attribute(self, *args):
5282  r"""
5283  add_attribute(Cover self, FloatKey k, IMP::Float v, bool opt)
5284  add_attribute(Cover self, FloatKey a0, IMP::Float a1)
5285  add_attribute(Cover self, IntKey a0, IMP::Int a1)
5286  add_attribute(Cover self, FloatsKey a0, IMP::Floats a1)
5287  add_attribute(Cover self, IntsKey a0, IMP::Ints a1)
5288  add_attribute(Cover self, StringKey a0, IMP::String a1)
5289  add_attribute(Cover self, ParticleIndexKey a0, Particle a1)
5290  add_attribute(Cover self, ObjectKey a0, Object a1)
5291  add_attribute(Cover self, SparseFloatKey a0, IMP::Float a1)
5292  add_attribute(Cover self, SparseIntKey a0, IMP::Int a1)
5293  add_attribute(Cover self, SparseStringKey a0, IMP::String a1)
5294  add_attribute(Cover self, SparseParticleIndexKey a0, ParticleIndex a1)
5295  """
5296  return _IMP_core.Cover_add_attribute(self, *args)
5297 
5298  def get_value(self, *args):
5299  r"""
5300  get_value(Cover self, FloatKey a0) -> IMP::Float
5301  get_value(Cover self, IntKey a0) -> IMP::Int
5302  get_value(Cover self, FloatsKey a0) -> IMP::Floats
5303  get_value(Cover self, IntsKey a0) -> IMP::Ints
5304  get_value(Cover self, StringKey a0) -> IMP::String
5305  get_value(Cover self, ParticleIndexKey a0) -> Particle
5306  get_value(Cover self, ObjectKey a0) -> Object
5307  get_value(Cover self, SparseFloatKey a0) -> IMP::Float
5308  get_value(Cover self, SparseIntKey a0) -> IMP::Int
5309  get_value(Cover self, SparseStringKey a0) -> IMP::String
5310  get_value(Cover self, SparseParticleIndexKey a0) -> ParticleIndex
5311  """
5312  return _IMP_core.Cover_get_value(self, *args)
5313 
5314  def set_value(self, *args):
5315  r"""
5316  set_value(Cover self, FloatKey a0, IMP::Float a1)
5317  set_value(Cover self, IntKey a0, IMP::Int a1)
5318  set_value(Cover self, FloatsKey a0, IMP::Floats a1)
5319  set_value(Cover self, IntsKey a0, IMP::Ints a1)
5320  set_value(Cover self, StringKey a0, IMP::String a1)
5321  set_value(Cover self, ParticleIndexKey a0, Particle a1)
5322  set_value(Cover self, ObjectKey a0, Object a1)
5323  set_value(Cover self, SparseFloatKey a0, IMP::Float a1)
5324  set_value(Cover self, SparseIntKey a0, IMP::Int a1)
5325  set_value(Cover self, SparseStringKey a0, IMP::String a1)
5326  set_value(Cover self, SparseParticleIndexKey a0, ParticleIndex a1)
5327  """
5328  return _IMP_core.Cover_set_value(self, *args)
5329 
5330  def remove_attribute(self, *args):
5331  r"""
5332  remove_attribute(Cover self, FloatKey a0)
5333  remove_attribute(Cover self, IntKey a0)
5334  remove_attribute(Cover self, FloatsKey a0)
5335  remove_attribute(Cover self, IntsKey a0)
5336  remove_attribute(Cover self, StringKey a0)
5337  remove_attribute(Cover self, ParticleIndexKey a0)
5338  remove_attribute(Cover self, ObjectKey a0)
5339  remove_attribute(Cover self, SparseFloatKey a0)
5340  remove_attribute(Cover self, SparseIntKey a0)
5341  remove_attribute(Cover self, SparseStringKey a0)
5342  remove_attribute(Cover self, SparseParticleIndexKey a0)
5343  """
5344  return _IMP_core.Cover_remove_attribute(self, *args)
5345 
5346  def has_attribute(self, *args):
5347  r"""
5348  has_attribute(Cover self, FloatKey a0) -> bool
5349  has_attribute(Cover self, IntKey a0) -> bool
5350  has_attribute(Cover self, FloatsKey a0) -> bool
5351  has_attribute(Cover self, IntsKey a0) -> bool
5352  has_attribute(Cover self, StringKey a0) -> bool
5353  has_attribute(Cover self, ParticleIndexKey a0) -> bool
5354  has_attribute(Cover self, ObjectKey a0) -> bool
5355  has_attribute(Cover self, SparseFloatKey a0) -> bool
5356  has_attribute(Cover self, SparseIntKey a0) -> bool
5357  has_attribute(Cover self, SparseStringKey a0) -> bool
5358  has_attribute(Cover self, SparseParticleIndexKey a0) -> bool
5359  """
5360  return _IMP_core.Cover_has_attribute(self, *args)
5361 
5362  def get_derivative(self, a0):
5363  r"""get_derivative(Cover self, FloatKey a0) -> double"""
5364  return _IMP_core.Cover_get_derivative(self, a0)
5365 
5366  def get_name(self):
5367  r"""get_name(Cover self) -> std::string"""
5368  return _IMP_core.Cover_get_name(self)
5369 
5370  def clear_caches(self):
5371  r"""clear_caches(Cover self)"""
5372  return _IMP_core.Cover_clear_caches(self)
5373 
5374  def set_name(self, a0):
5375  r"""set_name(Cover self, std::string a0)"""
5376  return _IMP_core.Cover_set_name(self, a0)
5377 
5378  def set_check_level(self, a0):
5379  r"""set_check_level(Cover self, IMP::CheckLevel a0)"""
5380  return _IMP_core.Cover_set_check_level(self, a0)
5381 
5382  def add_to_derivative(self, a0, a1, a2):
5383  r"""add_to_derivative(Cover self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
5384  return _IMP_core.Cover_add_to_derivative(self, a0, a1, a2)
5385 
5386  def set_is_optimized(self, a0, a1):
5387  r"""set_is_optimized(Cover self, FloatKey a0, bool a1)"""
5388  return _IMP_core.Cover_set_is_optimized(self, a0, a1)
5389 
5390  def get_is_optimized(self, a0):
5391  r"""get_is_optimized(Cover self, FloatKey a0) -> bool"""
5392  return _IMP_core.Cover_get_is_optimized(self, a0)
5393 
5394  def get_check_level(self):
5395  r"""get_check_level(Cover self) -> IMP::CheckLevel"""
5396  return _IMP_core.Cover_get_check_level(self)
5397 
5398  def __eq__(self, *args):
5399  r"""
5400  __eq__(Cover self, Cover o) -> bool
5401  __eq__(Cover self, Particle d) -> bool
5402  """
5403  return _IMP_core.Cover___eq__(self, *args)
5404 
5405  def __ne__(self, *args):
5406  r"""
5407  __ne__(Cover self, Cover o) -> bool
5408  __ne__(Cover self, Particle d) -> bool
5409  """
5410  return _IMP_core.Cover___ne__(self, *args)
5411 
5412  def __le__(self, *args):
5413  r"""
5414  __le__(Cover self, Cover o) -> bool
5415  __le__(Cover self, Particle d) -> bool
5416  """
5417  return _IMP_core.Cover___le__(self, *args)
5418 
5419  def __lt__(self, *args):
5420  r"""
5421  __lt__(Cover self, Cover o) -> bool
5422  __lt__(Cover self, Particle d) -> bool
5423  """
5424  return _IMP_core.Cover___lt__(self, *args)
5425 
5426  def __ge__(self, *args):
5427  r"""
5428  __ge__(Cover self, Cover o) -> bool
5429  __ge__(Cover self, Particle d) -> bool
5430  """
5431  return _IMP_core.Cover___ge__(self, *args)
5432 
5433  def __gt__(self, *args):
5434  r"""
5435  __gt__(Cover self, Cover o) -> bool
5436  __gt__(Cover self, Particle d) -> bool
5437  """
5438  return _IMP_core.Cover___gt__(self, *args)
5439 
5440  def __hash__(self):
5441  r"""__hash__(Cover self) -> std::size_t"""
5442  return _IMP_core.Cover___hash__(self)
5443 
5444  def __str__(self):
5445  r"""__str__(Cover self) -> std::string"""
5446  return _IMP_core.Cover___str__(self)
5447 
5448  def __repr__(self):
5449  r"""__repr__(Cover self) -> std::string"""
5450  return _IMP_core.Cover___repr__(self)
5451 
5452  def _get_as_binary(self):
5453  r"""_get_as_binary(Cover self) -> PyObject *"""
5454  return _IMP_core.Cover__get_as_binary(self)
5455 
5456  def _set_from_binary(self, p):
5457  r"""_set_from_binary(Cover self, PyObject * p)"""
5458  return _IMP_core.Cover__set_from_binary(self, p)
5459 
5460  def __getstate__(self):
5461  p = self._get_as_binary()
5462  if len(self.__dict__) > 1:
5463  d = self.__dict__.copy()
5464  del d['this']
5465  p = (d, p)
5466  return p
5467 
5468  def __setstate__(self, p):
5469  if not hasattr(self, 'this'):
5470  self.__init__()
5471  if isinstance(p, tuple):
5472  d, p = p
5473  self.__dict__.update(d)
5474  return self._set_from_binary(p)
5475 
5476  __swig_destroy__ = _IMP_core.delete_Cover
5477 
5478 # Register Cover in _IMP_core:
5479 _IMP_core.Cover_swigregister(Cover)
5480 class DerivativesFromRefined(IMP.SingletonModifier):
5481  r"""Proxy of C++ IMP::core::DerivativesFromRefined class."""
5482 
5483  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
5484 
5485  def __init__(self, *args):
5486  r"""__init__(DerivativesFromRefined self, Refiner r, IMP::FloatKeys ks=IMP::core::XYZ::get_xyz_keys()) -> DerivativesFromRefined"""
5487  _IMP_core.DerivativesFromRefined_swiginit(self, _IMP_core.new_DerivativesFromRefined(*args))
5488 
5489  def do_get_inputs(self, m, pis):
5490  r"""do_get_inputs(DerivativesFromRefined self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
5491  return _IMP_core.DerivativesFromRefined_do_get_inputs(self, m, pis)
5492 
5493  def do_get_outputs(self, m, pis):
5494  r"""do_get_outputs(DerivativesFromRefined self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
5495  return _IMP_core.DerivativesFromRefined_do_get_outputs(self, m, pis)
5496 
5497  def get_version_info(self):
5498  r"""get_version_info(DerivativesFromRefined self) -> VersionInfo"""
5499  return _IMP_core.DerivativesFromRefined_get_version_info(self)
5500  __swig_destroy__ = _IMP_core.delete_DerivativesFromRefined
5501 
5502  def __str__(self):
5503  r"""__str__(DerivativesFromRefined self) -> std::string"""
5504  return _IMP_core.DerivativesFromRefined___str__(self)
5505 
5506  def __repr__(self):
5507  r"""__repr__(DerivativesFromRefined self) -> std::string"""
5508  return _IMP_core.DerivativesFromRefined___repr__(self)
5509 
5510  @staticmethod
5511  def get_from(o):
5512  return _object_cast_to_DerivativesFromRefined(o)
5513 
5514 
5515 # Register DerivativesFromRefined in _IMP_core:
5516 _IMP_core.DerivativesFromRefined_swigregister(DerivativesFromRefined)
5517 class DerivativesToRefined(IMP.SingletonModifier):
5518  r"""Proxy of C++ IMP::core::DerivativesToRefined class."""
5519 
5520  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
5521 
5522  def __init__(self, *args):
5523  r"""
5524  __init__(DerivativesToRefined self, Refiner r, IMP::FloatKeys ks=IMP::core::XYZ::get_xyz_keys()) -> DerivativesToRefined
5525  __init__(DerivativesToRefined self) -> DerivativesToRefined
5526  """
5527  _IMP_core.DerivativesToRefined_swiginit(self, _IMP_core.new_DerivativesToRefined(*args))
5528 
5529  def do_get_inputs(self, m, pis):
5530  r"""do_get_inputs(DerivativesToRefined self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
5531  return _IMP_core.DerivativesToRefined_do_get_inputs(self, m, pis)
5532 
5533  def do_get_outputs(self, m, pis):
5534  r"""do_get_outputs(DerivativesToRefined self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
5535  return _IMP_core.DerivativesToRefined_do_get_outputs(self, m, pis)
5536 
5537  def get_version_info(self):
5538  r"""get_version_info(DerivativesToRefined self) -> VersionInfo"""
5539  return _IMP_core.DerivativesToRefined_get_version_info(self)
5540  __swig_destroy__ = _IMP_core.delete_DerivativesToRefined
5541 
5542  def __str__(self):
5543  r"""__str__(DerivativesToRefined self) -> std::string"""
5544  return _IMP_core.DerivativesToRefined___str__(self)
5545 
5546  def __repr__(self):
5547  r"""__repr__(DerivativesToRefined self) -> std::string"""
5548  return _IMP_core.DerivativesToRefined___repr__(self)
5549 
5550  @staticmethod
5551  def get_from(o):
5552  return _object_cast_to_DerivativesToRefined(o)
5553 
5554 
5555  def _get_as_binary(self):
5556  r"""_get_as_binary(DerivativesToRefined self) -> PyObject *"""
5557  return _IMP_core.DerivativesToRefined__get_as_binary(self)
5558 
5559  def _set_from_binary(self, p):
5560  r"""_set_from_binary(DerivativesToRefined self, PyObject * p)"""
5561  return _IMP_core.DerivativesToRefined__set_from_binary(self, p)
5562 
5563  def __getstate__(self):
5564  p = self._get_as_binary()
5565  if len(self.__dict__) > 1:
5566  d = self.__dict__.copy()
5567  del d['this']
5568  p = (d, p)
5569  return p
5570 
5571  def __setstate__(self, p):
5572  if not hasattr(self, 'this'):
5573  self.__init__()
5574  if isinstance(p, tuple):
5575  d, p = p
5576  self.__dict__.update(d)
5577  return self._set_from_binary(p)
5578 
5579 
5580 # Register DerivativesToRefined in _IMP_core:
5581 _IMP_core.DerivativesToRefined_swigregister(DerivativesToRefined)
5582 class DiameterRestraint(IMP.Restraint):
5583  r"""Proxy of C++ IMP::core::DiameterRestraint class."""
5584 
5585  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
5586 
5587  def __init__(self, f, sc, diameter):
5588  r"""__init__(DiameterRestraint self, UnaryFunction f, SingletonContainer sc, IMP::Float diameter) -> DiameterRestraint"""
5589  _IMP_core.DiameterRestraint_swiginit(self, _IMP_core.new_DiameterRestraint(f, sc, diameter))
5590 
5591  def do_get_inputs(self):
5592  r"""do_get_inputs(DiameterRestraint self) -> IMP::ModelObjectsTemp"""
5593  return _IMP_core.DiameterRestraint_do_get_inputs(self)
5594 
5595  def get_version_info(self):
5596  r"""get_version_info(DiameterRestraint self) -> VersionInfo"""
5597  return _IMP_core.DiameterRestraint_get_version_info(self)
5598  __swig_destroy__ = _IMP_core.delete_DiameterRestraint
5599 
5600  def do_create_decomposition(self):
5601  r"""do_create_decomposition(DiameterRestraint self) -> IMP::Restraints"""
5602  return _IMP_core.DiameterRestraint_do_create_decomposition(self)
5603 
5604  def do_create_current_decomposition(self):
5605  r"""do_create_current_decomposition(DiameterRestraint self) -> IMP::Restraints"""
5606  return _IMP_core.DiameterRestraint_do_create_current_decomposition(self)
5607 
5608  def __str__(self):
5609  r"""__str__(DiameterRestraint self) -> std::string"""
5610  return _IMP_core.DiameterRestraint___str__(self)
5611 
5612  def __repr__(self):
5613  r"""__repr__(DiameterRestraint self) -> std::string"""
5614  return _IMP_core.DiameterRestraint___repr__(self)
5615 
5616  @staticmethod
5617  def get_from(o):
5618  return _object_cast_to_DiameterRestraint(o)
5619 
5620 
5621 # Register DiameterRestraint in _IMP_core:
5622 _IMP_core.DiameterRestraint_swigregister(DiameterRestraint)
5623 class Transform(IMP.SingletonModifier):
5624  r"""Proxy of C++ IMP::core::Transform class."""
5625 
5626  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
5627 
5628  def __init__(self, *args):
5629  r"""
5630  __init__(Transform self, Transformation3D t, bool ignore_non_xyz=False) -> Transform
5631  __init__(Transform self) -> Transform
5632  """
5633  _IMP_core.Transform_swiginit(self, _IMP_core.new_Transform(*args))
5634 
5635  def do_get_inputs(self, m, pis):
5636  r"""do_get_inputs(Transform self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
5637  return _IMP_core.Transform_do_get_inputs(self, m, pis)
5638 
5639  def do_get_outputs(self, m, pis):
5640  r"""do_get_outputs(Transform self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
5641  return _IMP_core.Transform_do_get_outputs(self, m, pis)
5642 
5643  def get_version_info(self):
5644  r"""get_version_info(Transform self) -> VersionInfo"""
5645  return _IMP_core.Transform_get_version_info(self)
5646  __swig_destroy__ = _IMP_core.delete_Transform
5647 
5648  def __str__(self):
5649  r"""__str__(Transform self) -> std::string"""
5650  return _IMP_core.Transform___str__(self)
5651 
5652  def __repr__(self):
5653  r"""__repr__(Transform self) -> std::string"""
5654  return _IMP_core.Transform___repr__(self)
5655 
5656  @staticmethod
5657  def get_from(o):
5658  return _object_cast_to_Transform(o)
5659 
5660 
5661  def _get_as_binary(self):
5662  r"""_get_as_binary(Transform self) -> PyObject *"""
5663  return _IMP_core.Transform__get_as_binary(self)
5664 
5665  def _set_from_binary(self, p):
5666  r"""_set_from_binary(Transform self, PyObject * p)"""
5667  return _IMP_core.Transform__set_from_binary(self, p)
5668 
5669  def __getstate__(self):
5670  p = self._get_as_binary()
5671  if len(self.__dict__) > 1:
5672  d = self.__dict__.copy()
5673  del d['this']
5674  p = (d, p)
5675  return p
5676 
5677  def __setstate__(self, p):
5678  if not hasattr(self, 'this'):
5679  self.__init__()
5680  if isinstance(p, tuple):
5681  d, p = p
5682  self.__dict__.update(d)
5683  return self._set_from_binary(p)
5684 
5685 
5686 # Register Transform in _IMP_core:
5687 _IMP_core.Transform_swigregister(Transform)
5688 class Reference(IMP.Decorator):
5689  r"""Proxy of C++ IMP::core::Reference class."""
5690 
5691  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
5692 
5693  def __init__(self, *args):
5694  r"""
5695  __init__(Reference self) -> Reference
5696  __init__(Reference self, Model m, ParticleIndex id) -> Reference
5697  __init__(Reference self, _ParticleAdaptor d) -> Reference
5698  """
5699  _IMP_core.Reference_swiginit(self, _IMP_core.new_Reference(*args))
5700 
5701  def show(self, *args):
5702  r"""show(Reference self, _ostream out=std::cout)"""
5703  return _IMP_core.Reference_show(self, *args)
5704 
5705  @staticmethod
5706  def setup_particle(*args):
5707  r"""
5708  setup_particle(Model m, ParticleIndex pi, _ParticleIndexAdaptor reference) -> Reference
5709  setup_particle(_ParticleAdaptor pa, _ParticleIndexAdaptor reference) -> Reference
5710  """
5711  return _IMP_core.Reference_setup_particle(*args)
5712 
5713  def get_reference_particle(self):
5714  r"""get_reference_particle(Reference self) -> Particle"""
5715  return _IMP_core.Reference_get_reference_particle(self)
5716 
5717  @staticmethod
5718  def get_is_setup(*args):
5719  r"""
5720  get_is_setup(_ParticleAdaptor p) -> bool
5721  get_is_setup(Model m, ParticleIndex pi) -> bool
5722  """
5723  return _IMP_core.Reference_get_is_setup(*args)
5724 
5725  @staticmethod
5726  def get_reference_key():
5727  r"""get_reference_key() -> ParticleIndexKey"""
5728  return _IMP_core.Reference_get_reference_key()
5729 
5730  def add_attribute(self, *args):
5731  r"""
5732  add_attribute(Reference self, FloatKey k, IMP::Float v, bool opt)
5733  add_attribute(Reference self, FloatKey a0, IMP::Float a1)
5734  add_attribute(Reference self, IntKey a0, IMP::Int a1)
5735  add_attribute(Reference self, FloatsKey a0, IMP::Floats a1)
5736  add_attribute(Reference self, IntsKey a0, IMP::Ints a1)
5737  add_attribute(Reference self, StringKey a0, IMP::String a1)
5738  add_attribute(Reference self, ParticleIndexKey a0, Particle a1)
5739  add_attribute(Reference self, ObjectKey a0, Object a1)
5740  add_attribute(Reference self, SparseFloatKey a0, IMP::Float a1)
5741  add_attribute(Reference self, SparseIntKey a0, IMP::Int a1)
5742  add_attribute(Reference self, SparseStringKey a0, IMP::String a1)
5743  add_attribute(Reference self, SparseParticleIndexKey a0, ParticleIndex a1)
5744  """
5745  return _IMP_core.Reference_add_attribute(self, *args)
5746 
5747  def get_value(self, *args):
5748  r"""
5749  get_value(Reference self, FloatKey a0) -> IMP::Float
5750  get_value(Reference self, IntKey a0) -> IMP::Int
5751  get_value(Reference self, FloatsKey a0) -> IMP::Floats
5752  get_value(Reference self, IntsKey a0) -> IMP::Ints
5753  get_value(Reference self, StringKey a0) -> IMP::String
5754  get_value(Reference self, ParticleIndexKey a0) -> Particle
5755  get_value(Reference self, ObjectKey a0) -> Object
5756  get_value(Reference self, SparseFloatKey a0) -> IMP::Float
5757  get_value(Reference self, SparseIntKey a0) -> IMP::Int
5758  get_value(Reference self, SparseStringKey a0) -> IMP::String
5759  get_value(Reference self, SparseParticleIndexKey a0) -> ParticleIndex
5760  """
5761  return _IMP_core.Reference_get_value(self, *args)
5762 
5763  def set_value(self, *args):
5764  r"""
5765  set_value(Reference self, FloatKey a0, IMP::Float a1)
5766  set_value(Reference self, IntKey a0, IMP::Int a1)
5767  set_value(Reference self, FloatsKey a0, IMP::Floats a1)
5768  set_value(Reference self, IntsKey a0, IMP::Ints a1)
5769  set_value(Reference self, StringKey a0, IMP::String a1)
5770  set_value(Reference self, ParticleIndexKey a0, Particle a1)
5771  set_value(Reference self, ObjectKey a0, Object a1)
5772  set_value(Reference self, SparseFloatKey a0, IMP::Float a1)
5773  set_value(Reference self, SparseIntKey a0, IMP::Int a1)
5774  set_value(Reference self, SparseStringKey a0, IMP::String a1)
5775  set_value(Reference self, SparseParticleIndexKey a0, ParticleIndex a1)
5776  """
5777  return _IMP_core.Reference_set_value(self, *args)
5778 
5779  def remove_attribute(self, *args):
5780  r"""
5781  remove_attribute(Reference self, FloatKey a0)
5782  remove_attribute(Reference self, IntKey a0)
5783  remove_attribute(Reference self, FloatsKey a0)
5784  remove_attribute(Reference self, IntsKey a0)
5785  remove_attribute(Reference self, StringKey a0)
5786  remove_attribute(Reference self, ParticleIndexKey a0)
5787  remove_attribute(Reference self, ObjectKey a0)
5788  remove_attribute(Reference self, SparseFloatKey a0)
5789  remove_attribute(Reference self, SparseIntKey a0)
5790  remove_attribute(Reference self, SparseStringKey a0)
5791  remove_attribute(Reference self, SparseParticleIndexKey a0)
5792  """
5793  return _IMP_core.Reference_remove_attribute(self, *args)
5794 
5795  def has_attribute(self, *args):
5796  r"""
5797  has_attribute(Reference self, FloatKey a0) -> bool
5798  has_attribute(Reference self, IntKey a0) -> bool
5799  has_attribute(Reference self, FloatsKey a0) -> bool
5800  has_attribute(Reference self, IntsKey a0) -> bool
5801  has_attribute(Reference self, StringKey a0) -> bool
5802  has_attribute(Reference self, ParticleIndexKey a0) -> bool
5803  has_attribute(Reference self, ObjectKey a0) -> bool
5804  has_attribute(Reference self, SparseFloatKey a0) -> bool
5805  has_attribute(Reference self, SparseIntKey a0) -> bool
5806  has_attribute(Reference self, SparseStringKey a0) -> bool
5807  has_attribute(Reference self, SparseParticleIndexKey a0) -> bool
5808  """
5809  return _IMP_core.Reference_has_attribute(self, *args)
5810 
5811  def get_derivative(self, a0):
5812  r"""get_derivative(Reference self, FloatKey a0) -> double"""
5813  return _IMP_core.Reference_get_derivative(self, a0)
5814 
5815  def get_name(self):
5816  r"""get_name(Reference self) -> std::string"""
5817  return _IMP_core.Reference_get_name(self)
5818 
5819  def clear_caches(self):
5820  r"""clear_caches(Reference self)"""
5821  return _IMP_core.Reference_clear_caches(self)
5822 
5823  def set_name(self, a0):
5824  r"""set_name(Reference self, std::string a0)"""
5825  return _IMP_core.Reference_set_name(self, a0)
5826 
5827  def set_check_level(self, a0):
5828  r"""set_check_level(Reference self, IMP::CheckLevel a0)"""
5829  return _IMP_core.Reference_set_check_level(self, a0)
5830 
5831  def add_to_derivative(self, a0, a1, a2):
5832  r"""add_to_derivative(Reference self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
5833  return _IMP_core.Reference_add_to_derivative(self, a0, a1, a2)
5834 
5835  def set_is_optimized(self, a0, a1):
5836  r"""set_is_optimized(Reference self, FloatKey a0, bool a1)"""
5837  return _IMP_core.Reference_set_is_optimized(self, a0, a1)
5838 
5839  def get_is_optimized(self, a0):
5840  r"""get_is_optimized(Reference self, FloatKey a0) -> bool"""
5841  return _IMP_core.Reference_get_is_optimized(self, a0)
5842 
5843  def get_check_level(self):
5844  r"""get_check_level(Reference self) -> IMP::CheckLevel"""
5845  return _IMP_core.Reference_get_check_level(self)
5846 
5847  def __eq__(self, *args):
5848  r"""
5849  __eq__(Reference self, Reference o) -> bool
5850  __eq__(Reference self, Particle d) -> bool
5851  """
5852  return _IMP_core.Reference___eq__(self, *args)
5853 
5854  def __ne__(self, *args):
5855  r"""
5856  __ne__(Reference self, Reference o) -> bool
5857  __ne__(Reference self, Particle d) -> bool
5858  """
5859  return _IMP_core.Reference___ne__(self, *args)
5860 
5861  def __le__(self, *args):
5862  r"""
5863  __le__(Reference self, Reference o) -> bool
5864  __le__(Reference self, Particle d) -> bool
5865  """
5866  return _IMP_core.Reference___le__(self, *args)
5867 
5868  def __lt__(self, *args):
5869  r"""
5870  __lt__(Reference self, Reference o) -> bool
5871  __lt__(Reference self, Particle d) -> bool
5872  """
5873  return _IMP_core.Reference___lt__(self, *args)
5874 
5875  def __ge__(self, *args):
5876  r"""
5877  __ge__(Reference self, Reference o) -> bool
5878  __ge__(Reference self, Particle d) -> bool
5879  """
5880  return _IMP_core.Reference___ge__(self, *args)
5881 
5882  def __gt__(self, *args):
5883  r"""
5884  __gt__(Reference self, Reference o) -> bool
5885  __gt__(Reference self, Particle d) -> bool
5886  """
5887  return _IMP_core.Reference___gt__(self, *args)
5888 
5889  def __hash__(self):
5890  r"""__hash__(Reference self) -> std::size_t"""
5891  return _IMP_core.Reference___hash__(self)
5892 
5893  def __str__(self):
5894  r"""__str__(Reference self) -> std::string"""
5895  return _IMP_core.Reference___str__(self)
5896 
5897  def __repr__(self):
5898  r"""__repr__(Reference self) -> std::string"""
5899  return _IMP_core.Reference___repr__(self)
5900 
5901  def _get_as_binary(self):
5902  r"""_get_as_binary(Reference self) -> PyObject *"""
5903  return _IMP_core.Reference__get_as_binary(self)
5904 
5905  def _set_from_binary(self, p):
5906  r"""_set_from_binary(Reference self, PyObject * p)"""
5907  return _IMP_core.Reference__set_from_binary(self, p)
5908 
5909  def __getstate__(self):
5910  p = self._get_as_binary()
5911  if len(self.__dict__) > 1:
5912  d = self.__dict__.copy()
5913  del d['this']
5914  p = (d, p)
5915  return p
5916 
5917  def __setstate__(self, p):
5918  if not hasattr(self, 'this'):
5919  self.__init__()
5920  if isinstance(p, tuple):
5921  d, p = p
5922  self.__dict__.update(d)
5923  return self._set_from_binary(p)
5924 
5925  __swig_destroy__ = _IMP_core.delete_Reference
5926 
5927 # Register Reference in _IMP_core:
5928 _IMP_core.Reference_swigregister(Reference)
5929 class TransformationAndReflectionSymmetry(IMP.SingletonModifier):
5930  r"""Proxy of C++ IMP::core::TransformationAndReflectionSymmetry class."""
5931 
5932  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
5933 
5934  def __init__(self, t, r):
5935  r"""__init__(TransformationAndReflectionSymmetry self, Transformation3D t, Reflection3D r) -> TransformationAndReflectionSymmetry"""
5936  _IMP_core.TransformationAndReflectionSymmetry_swiginit(self, _IMP_core.new_TransformationAndReflectionSymmetry(t, r))
5937 
5938  def do_get_inputs(self, m, pis):
5939  r"""do_get_inputs(TransformationAndReflectionSymmetry self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
5940  return _IMP_core.TransformationAndReflectionSymmetry_do_get_inputs(self, m, pis)
5941 
5942  def do_get_outputs(self, m, pis):
5943  r"""do_get_outputs(TransformationAndReflectionSymmetry self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
5944  return _IMP_core.TransformationAndReflectionSymmetry_do_get_outputs(self, m, pis)
5945 
5946  def get_version_info(self):
5947  r"""get_version_info(TransformationAndReflectionSymmetry self) -> VersionInfo"""
5948  return _IMP_core.TransformationAndReflectionSymmetry_get_version_info(self)
5949  __swig_destroy__ = _IMP_core.delete_TransformationAndReflectionSymmetry
5950 
5951  def __str__(self):
5952  r"""__str__(TransformationAndReflectionSymmetry self) -> std::string"""
5953  return _IMP_core.TransformationAndReflectionSymmetry___str__(self)
5954 
5955  def __repr__(self):
5956  r"""__repr__(TransformationAndReflectionSymmetry self) -> std::string"""
5957  return _IMP_core.TransformationAndReflectionSymmetry___repr__(self)
5958 
5959  @staticmethod
5960  def get_from(o):
5961  return _object_cast_to_TransformationAndReflectionSymmetry(o)
5962 
5963 
5964 # Register TransformationAndReflectionSymmetry in _IMP_core:
5965 _IMP_core.TransformationAndReflectionSymmetry_swigregister(TransformationAndReflectionSymmetry)
5966 class TransformationSymmetry(IMP.SingletonModifier):
5967  r"""Proxy of C++ IMP::core::TransformationSymmetry class."""
5968 
5969  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
5970 
5971  def __init__(self, *args):
5972  r"""
5973  __init__(TransformationSymmetry self, Transformation3D t) -> TransformationSymmetry
5974  __init__(TransformationSymmetry self, ParticleIndex rb_pi) -> TransformationSymmetry
5975  """
5976  _IMP_core.TransformationSymmetry_swiginit(self, _IMP_core.new_TransformationSymmetry(*args))
5977 
5978  def get_transformation(self):
5979  r"""get_transformation(TransformationSymmetry self) -> Transformation3D"""
5980  return _IMP_core.TransformationSymmetry_get_transformation(self)
5981 
5982  def set_transformation(self, t):
5983  r"""set_transformation(TransformationSymmetry self, Transformation3D t)"""
5984  return _IMP_core.TransformationSymmetry_set_transformation(self, t)
5985 
5986  def do_get_inputs(self, m, pis):
5987  r"""do_get_inputs(TransformationSymmetry self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
5988  return _IMP_core.TransformationSymmetry_do_get_inputs(self, m, pis)
5989 
5990  def do_get_outputs(self, m, pis):
5991  r"""do_get_outputs(TransformationSymmetry self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
5992  return _IMP_core.TransformationSymmetry_do_get_outputs(self, m, pis)
5993 
5994  def get_version_info(self):
5995  r"""get_version_info(TransformationSymmetry self) -> VersionInfo"""
5996  return _IMP_core.TransformationSymmetry_get_version_info(self)
5997  __swig_destroy__ = _IMP_core.delete_TransformationSymmetry
5998 
5999  def __str__(self):
6000  r"""__str__(TransformationSymmetry self) -> std::string"""
6001  return _IMP_core.TransformationSymmetry___str__(self)
6002 
6003  def __repr__(self):
6004  r"""__repr__(TransformationSymmetry self) -> std::string"""
6005  return _IMP_core.TransformationSymmetry___repr__(self)
6006 
6007  @staticmethod
6008  def get_from(o):
6009  return _object_cast_to_TransformationSymmetry(o)
6010 
6011 
6012 # Register TransformationSymmetry in _IMP_core:
6013 _IMP_core.TransformationSymmetry_swigregister(TransformationSymmetry)
6014 class TransformationSymmetryMover(MonteCarloMover):
6015  r"""Proxy of C++ IMP::core::TransformationSymmetryMover class."""
6016 
6017  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
6018 
6019  def __init__(self, m, symm, pivot, max_translation, max_rotation):
6020  r"""__init__(TransformationSymmetryMover self, Model m, TransformationSymmetry symm, ParticleIndex pivot, IMP::Float max_translation, IMP::Float max_rotation) -> TransformationSymmetryMover"""
6021  _IMP_core.TransformationSymmetryMover_swiginit(self, _IMP_core.new_TransformationSymmetryMover(m, symm, pivot, max_translation, max_rotation))
6022 
6023  def set_maximum_translation(self, mt):
6024  r"""set_maximum_translation(TransformationSymmetryMover self, IMP::Float mt)"""
6025  return _IMP_core.TransformationSymmetryMover_set_maximum_translation(self, mt)
6026 
6027  def set_maximum_rotation(self, mr):
6028  r"""set_maximum_rotation(TransformationSymmetryMover self, IMP::Float mr)"""
6029  return _IMP_core.TransformationSymmetryMover_set_maximum_rotation(self, mr)
6030 
6031  def get_maximum_translation(self):
6032  r"""get_maximum_translation(TransformationSymmetryMover self) -> IMP::Float"""
6033  return _IMP_core.TransformationSymmetryMover_get_maximum_translation(self)
6034 
6035  def get_maximum_rotation(self):
6036  r"""get_maximum_rotation(TransformationSymmetryMover self) -> IMP::Float"""
6037  return _IMP_core.TransformationSymmetryMover_get_maximum_rotation(self)
6038 
6039  def get_version_info(self):
6040  r"""get_version_info(TransformationSymmetryMover self) -> VersionInfo"""
6041  return _IMP_core.TransformationSymmetryMover_get_version_info(self)
6042  __swig_destroy__ = _IMP_core.delete_TransformationSymmetryMover
6043 
6044  def __str__(self):
6045  r"""__str__(TransformationSymmetryMover self) -> std::string"""
6046  return _IMP_core.TransformationSymmetryMover___str__(self)
6047 
6048  def __repr__(self):
6049  r"""__repr__(TransformationSymmetryMover self) -> std::string"""
6050  return _IMP_core.TransformationSymmetryMover___repr__(self)
6051 
6052  @staticmethod
6053  def get_from(o):
6054  return _object_cast_to_TransformationSymmetryMover(o)
6055 
6056 
6057 # Register TransformationSymmetryMover in _IMP_core:
6058 _IMP_core.TransformationSymmetryMover_swigregister(TransformationSymmetryMover)
6059 class DihedralRestraint(IMP.Restraint):
6060  r"""Proxy of C++ IMP::core::DihedralRestraint class."""
6061 
6062  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
6063 
6064  def __init__(self, m, score_func, p1, p2, p3, p4):
6065  r"""__init__(DihedralRestraint self, Model m, UnaryFunction score_func, _ParticleIndexAdaptor p1, _ParticleIndexAdaptor p2, _ParticleIndexAdaptor p3, _ParticleIndexAdaptor p4) -> DihedralRestraint"""
6066  _IMP_core.DihedralRestraint_swiginit(self, _IMP_core.new_DihedralRestraint(m, score_func, p1, p2, p3, p4))
6067 
6068  def do_get_inputs(self):
6069  r"""do_get_inputs(DihedralRestraint self) -> IMP::ModelObjectsTemp"""
6070  return _IMP_core.DihedralRestraint_do_get_inputs(self)
6071 
6072  def get_version_info(self):
6073  r"""get_version_info(DihedralRestraint self) -> VersionInfo"""
6074  return _IMP_core.DihedralRestraint_get_version_info(self)
6075  __swig_destroy__ = _IMP_core.delete_DihedralRestraint
6076 
6077  def __str__(self):
6078  r"""__str__(DihedralRestraint self) -> std::string"""
6079  return _IMP_core.DihedralRestraint___str__(self)
6080 
6081  def __repr__(self):
6082  r"""__repr__(DihedralRestraint self) -> std::string"""
6083  return _IMP_core.DihedralRestraint___repr__(self)
6084 
6085  @staticmethod
6086  def get_from(o):
6087  return _object_cast_to_DihedralRestraint(o)
6088 
6089 
6090 # Register DihedralRestraint in _IMP_core:
6091 _IMP_core.DihedralRestraint_swigregister(DihedralRestraint)
6092 class DistancePairScore(IMP.PairScore):
6093  r"""Proxy of C++ IMP::core::DistancePairScore class."""
6094 
6095  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
6096 
6097  def __init__(self, *args):
6098  r"""
6099  __init__(DistancePairScore self, UnaryFunction uf, std::string name="DistancePairScore%1%") -> DistancePairScore
6100  __init__(DistancePairScore self) -> DistancePairScore
6101  """
6102  _IMP_core.DistancePairScore_swiginit(self, _IMP_core.new_DistancePairScore(*args))
6103 
6104  def do_get_inputs(self, m, pis):
6105  r"""do_get_inputs(DistancePairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
6106  return _IMP_core.DistancePairScore_do_get_inputs(self, m, pis)
6107 
6108  def get_score_functor(self, *args):
6109  r"""
6110  get_score_functor(DistancePairScore self) -> UnaryFunctionEvaluate
6111  get_score_functor(DistancePairScore self) -> UnaryFunctionEvaluate
6112  """
6113  return _IMP_core.DistancePairScore_get_score_functor(self, *args)
6114 
6115  def get_version_info(self):
6116  r"""get_version_info(DistancePairScore self) -> VersionInfo"""
6117  return _IMP_core.DistancePairScore_get_version_info(self)
6118  __swig_destroy__ = _IMP_core.delete_DistancePairScore
6119 
6120  def __str__(self):
6121  r"""__str__(DistancePairScore self) -> std::string"""
6122  return _IMP_core.DistancePairScore___str__(self)
6123 
6124  def __repr__(self):
6125  r"""__repr__(DistancePairScore self) -> std::string"""
6126  return _IMP_core.DistancePairScore___repr__(self)
6127 
6128  @staticmethod
6129  def get_from(o):
6130  return _object_cast_to_DistancePairScore(o)
6131 
6132 
6133  def _get_as_binary(self):
6134  r"""_get_as_binary(DistancePairScore self) -> PyObject *"""
6135  return _IMP_core.DistancePairScore__get_as_binary(self)
6136 
6137  def _set_from_binary(self, p):
6138  r"""_set_from_binary(DistancePairScore self, PyObject * p)"""
6139  return _IMP_core.DistancePairScore__set_from_binary(self, p)
6140 
6141  def __getstate__(self):
6142  p = self._get_as_binary()
6143  if len(self.__dict__) > 1:
6144  d = self.__dict__.copy()
6145  del d['this']
6146  p = (d, p)
6147  return p
6148 
6149  def __setstate__(self, p):
6150  if not hasattr(self, 'this'):
6151  self.__init__()
6152  if isinstance(p, tuple):
6153  d, p = p
6154  self.__dict__.update(d)
6155  return self._set_from_binary(p)
6156 
6157 
6158  def _get_jax(self, m, indexes):
6159  import jax.numpy as jnp
6160  def jax_score(jm, uf):
6161  xyzs = jm['xyz'][indexes]
6162  diff = xyzs[:,0] - xyzs[:,1]
6163  drs = jnp.linalg.norm(diff, axis=1)
6164  return uf(drs)
6165  sfnc = self.get_score_functor()
6166  uf = sfnc.get_unary_function().get_derived_object()
6167  f = functools.partial(jax_score, uf=uf._get_jax())
6168  return self._wrap_jax(m, f)
6169 
6170 
6171 # Register DistancePairScore in _IMP_core:
6172 _IMP_core.DistancePairScore_swigregister(DistancePairScore)
6173 class HarmonicDistancePairScore(IMP.PairScore):
6174  r"""Proxy of C++ IMP::core::HarmonicDistancePairScore class."""
6175 
6176  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
6177 
6178  def __init__(self, *args):
6179  r"""
6180  __init__(HarmonicDistancePairScore self, double x0, double k, std::string name="HarmonicDistancePairScore%1%") -> HarmonicDistancePairScore
6181  __init__(HarmonicDistancePairScore self) -> HarmonicDistancePairScore
6182  """
6183  _IMP_core.HarmonicDistancePairScore_swiginit(self, _IMP_core.new_HarmonicDistancePairScore(*args))
6184 
6185  def do_get_inputs(self, m, pis):
6186  r"""do_get_inputs(HarmonicDistancePairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
6187  return _IMP_core.HarmonicDistancePairScore_do_get_inputs(self, m, pis)
6188 
6189  def get_score_functor(self, *args):
6190  r"""
6191  get_score_functor(HarmonicDistancePairScore self) -> IMP::core::HarmonicDistanceScore
6192  get_score_functor(HarmonicDistancePairScore self) -> IMP::core::HarmonicDistanceScore const &
6193  """
6194  return _IMP_core.HarmonicDistancePairScore_get_score_functor(self, *args)
6195 
6196  def get_x0(self):
6197  r"""get_x0(HarmonicDistancePairScore self) -> double"""
6198  return _IMP_core.HarmonicDistancePairScore_get_x0(self)
6199 
6200  def get_k(self):
6201  r"""get_k(HarmonicDistancePairScore self) -> double"""
6202  return _IMP_core.HarmonicDistancePairScore_get_k(self)
6203 
6204  def get_version_info(self):
6205  r"""get_version_info(HarmonicDistancePairScore self) -> VersionInfo"""
6206  return _IMP_core.HarmonicDistancePairScore_get_version_info(self)
6207  __swig_destroy__ = _IMP_core.delete_HarmonicDistancePairScore
6208 
6209  def __str__(self):
6210  r"""__str__(HarmonicDistancePairScore self) -> std::string"""
6211  return _IMP_core.HarmonicDistancePairScore___str__(self)
6212 
6213  def __repr__(self):
6214  r"""__repr__(HarmonicDistancePairScore self) -> std::string"""
6215  return _IMP_core.HarmonicDistancePairScore___repr__(self)
6216 
6217  @staticmethod
6218  def get_from(o):
6219  return _object_cast_to_HarmonicDistancePairScore(o)
6220 
6221 
6222  def _get_as_binary(self):
6223  r"""_get_as_binary(HarmonicDistancePairScore self) -> PyObject *"""
6224  return _IMP_core.HarmonicDistancePairScore__get_as_binary(self)
6225 
6226  def _set_from_binary(self, p):
6227  r"""_set_from_binary(HarmonicDistancePairScore self, PyObject * p)"""
6228  return _IMP_core.HarmonicDistancePairScore__set_from_binary(self, p)
6229 
6230  def __getstate__(self):
6231  p = self._get_as_binary()
6232  if len(self.__dict__) > 1:
6233  d = self.__dict__.copy()
6234  del d['this']
6235  p = (d, p)
6236  return p
6237 
6238  def __setstate__(self, p):
6239  if not hasattr(self, 'this'):
6240  self.__init__()
6241  if isinstance(p, tuple):
6242  d, p = p
6243  self.__dict__.update(d)
6244  return self._set_from_binary(p)
6245 
6246 
6247  def _get_jax(self, m, indexes):
6248  import jax.numpy as jnp
6249  def jax_harmonic_distance_pair_score(jm, d, k):
6250  xyzs = jm['xyz'][indexes]
6251  diff = xyzs[:,0] - xyzs[:,1]
6252  drs = jnp.linalg.norm(diff, axis=1)
6253  return 0.5 * k * (d - drs)**2
6254  f = functools.partial(jax_harmonic_distance_pair_score,
6255  d=self.get_x0(), k=self.get_k())
6256  return self._wrap_jax(m, f)
6257 
6258 
6259 # Register HarmonicDistancePairScore in _IMP_core:
6260 _IMP_core.HarmonicDistancePairScore_swigregister(HarmonicDistancePairScore)
6261 class DistanceRestraint(IMP.Restraint):
6262  r"""Proxy of C++ IMP::core::DistanceRestraint class."""
6263 
6264  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
6265 
6266  def __init__(self, *args):
6267  r"""
6268  __init__(DistanceRestraint self, Model m, UnaryFunction score_func, _ParticleIndexAdaptor a, _ParticleIndexAdaptor b, std::string name="DistanceRestraint %1%") -> DistanceRestraint
6269  __init__(DistanceRestraint self) -> DistanceRestraint
6270  """
6271  _IMP_core.DistanceRestraint_swiginit(self, _IMP_core.new_DistanceRestraint(*args))
6272 
6273  def get_score_object(self):
6274  r"""get_score_object(DistanceRestraint self) -> DistancePairScore"""
6275  return _IMP_core.DistanceRestraint_get_score_object(self)
6276 
6277  def get_index(self):
6278  r"""get_index(DistanceRestraint self) -> IMP::core::DistancePairScore::IndexArgument"""
6279  return _IMP_core.DistanceRestraint_get_index(self)
6280 
6281  def get_version_info(self):
6282  r"""get_version_info(DistanceRestraint self) -> VersionInfo"""
6283  return _IMP_core.DistanceRestraint_get_version_info(self)
6284  __swig_destroy__ = _IMP_core.delete_DistanceRestraint
6285 
6286  def __str__(self):
6287  r"""__str__(DistanceRestraint self) -> std::string"""
6288  return _IMP_core.DistanceRestraint___str__(self)
6289 
6290  def __repr__(self):
6291  r"""__repr__(DistanceRestraint self) -> std::string"""
6292  return _IMP_core.DistanceRestraint___repr__(self)
6293 
6294  @staticmethod
6295  def get_from(o):
6296  return _object_cast_to_DistanceRestraint(o)
6297 
6298 
6299  def _get_as_binary(self):
6300  r"""_get_as_binary(DistanceRestraint self) -> PyObject *"""
6301  return _IMP_core.DistanceRestraint__get_as_binary(self)
6302 
6303  def _set_from_binary(self, p):
6304  r"""_set_from_binary(DistanceRestraint self, PyObject * p)"""
6305  return _IMP_core.DistanceRestraint__set_from_binary(self, p)
6306 
6307  def __getstate__(self):
6308  p = self._get_as_binary()
6309  if len(self.__dict__) > 1:
6310  d = self.__dict__.copy()
6311  del d['this']
6312  p = (d, p)
6313  return p
6314 
6315  def __setstate__(self, p):
6316  if not hasattr(self, 'this'):
6317  self.__init__()
6318  if isinstance(p, tuple):
6319  d, p = p
6320  self.__dict__.update(d)
6321  return self._set_from_binary(p)
6322 
6323 
6324  def _get_jax(self):
6325  import jax.numpy as jnp
6326  ps = self.get_score_object()
6327  indexes = jnp.array([self.get_index()])
6328  ji = ps._get_jax(self.get_model(), indexes)
6329  def score(jm):
6330  return jnp.sum(ji.score_func(jm))
6331  return self._wrap_jax(score)
6332 
6333 
6334 # Register DistanceRestraint in _IMP_core:
6335 _IMP_core.DistanceRestraint_swigregister(DistanceRestraint)
6336 class SphereDistanceToSingletonScore(IMP.SingletonScore):
6337  r"""Proxy of C++ IMP::core::SphereDistanceToSingletonScore class."""
6338 
6339  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
6340 
6341  def __init__(self, f, pt):
6342  r"""__init__(SphereDistanceToSingletonScore self, UnaryFunction f, Vector3D pt) -> SphereDistanceToSingletonScore"""
6343  _IMP_core.SphereDistanceToSingletonScore_swiginit(self, _IMP_core.new_SphereDistanceToSingletonScore(f, pt))
6344 
6345  def do_get_inputs(self, m, pis):
6346  r"""do_get_inputs(SphereDistanceToSingletonScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
6347  return _IMP_core.SphereDistanceToSingletonScore_do_get_inputs(self, m, pis)
6348 
6349  def evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked=False):
6350  r"""evaluate_indexes(SphereDistanceToSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
6351  return _IMP_core.SphereDistanceToSingletonScore_evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked)
6352 
6353  def evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked=False):
6354  r"""evaluate_indexes_scores(SphereDistanceToSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
6355  return _IMP_core.SphereDistanceToSingletonScore_evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked)
6356 
6357  def evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked=False):
6358  r"""evaluate_indexes_delta(SphereDistanceToSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, std::vector< unsigned int,std::allocator< unsigned int > > const & indexes, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
6359  return _IMP_core.SphereDistanceToSingletonScore_evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked)
6360 
6361  def evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked=False):
6362  r"""evaluate_if_good_indexes(SphereDistanceToSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, double max, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
6363  return _IMP_core.SphereDistanceToSingletonScore_evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked)
6364 
6365  def get_version_info(self):
6366  r"""get_version_info(SphereDistanceToSingletonScore self) -> VersionInfo"""
6367  return _IMP_core.SphereDistanceToSingletonScore_get_version_info(self)
6368  __swig_destroy__ = _IMP_core.delete_SphereDistanceToSingletonScore
6369 
6370  def __str__(self):
6371  r"""__str__(SphereDistanceToSingletonScore self) -> std::string"""
6372  return _IMP_core.SphereDistanceToSingletonScore___str__(self)
6373 
6374  def __repr__(self):
6375  r"""__repr__(SphereDistanceToSingletonScore self) -> std::string"""
6376  return _IMP_core.SphereDistanceToSingletonScore___repr__(self)
6377 
6378  @staticmethod
6379  def get_from(o):
6380  return _object_cast_to_SphereDistanceToSingletonScore(o)
6381 
6382 
6383 # Register SphereDistanceToSingletonScore in _IMP_core:
6384 _IMP_core.SphereDistanceToSingletonScore_swigregister(SphereDistanceToSingletonScore)
6385 class ExcludedVolumeRestraint(IMP.Restraint):
6386  r"""Proxy of C++ IMP::core::ExcludedVolumeRestraint class."""
6387 
6388  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
6389 
6390  def __init__(self, *args):
6391  r"""__init__(ExcludedVolumeRestraint self, _SingletonContainerAdaptor sc, double k=1, double slack=10, std::string name="ExcludedVolumeRestraint%1%") -> ExcludedVolumeRestraint"""
6392  _IMP_core.ExcludedVolumeRestraint_swiginit(self, _IMP_core.new_ExcludedVolumeRestraint(*args))
6393 
6394  def do_get_inputs(self):
6395  r"""do_get_inputs(ExcludedVolumeRestraint self) -> IMP::ModelObjectsTemp"""
6396  return _IMP_core.ExcludedVolumeRestraint_do_get_inputs(self)
6397 
6398  def get_version_info(self):
6399  r"""get_version_info(ExcludedVolumeRestraint self) -> VersionInfo"""
6400  return _IMP_core.ExcludedVolumeRestraint_get_version_info(self)
6401  __swig_destroy__ = _IMP_core.delete_ExcludedVolumeRestraint
6402 
6403  def do_create_decomposition(self):
6404  r"""do_create_decomposition(ExcludedVolumeRestraint self) -> IMP::Restraints"""
6405  return _IMP_core.ExcludedVolumeRestraint_do_create_decomposition(self)
6406 
6407  def do_create_current_decomposition(self):
6408  r"""do_create_current_decomposition(ExcludedVolumeRestraint self) -> IMP::Restraints"""
6409  return _IMP_core.ExcludedVolumeRestraint_do_create_current_decomposition(self)
6410 
6411  def get_indexes(self):
6412  r"""get_indexes(ExcludedVolumeRestraint self) -> IMP::ParticleIndexPairs const &"""
6413  return _IMP_core.ExcludedVolumeRestraint_get_indexes(self)
6414  def __get_pair_filters(self): return IMP._list_util.VarList(getdimfunc=self.get_number_of_pair_filters, getfunc=self.get_pair_filter, erasefunc=self.erase_pair_filter, appendfunc=self.add_pair_filter, extendfunc=self.add_pair_filters, clearfunc=self.clear_pair_filters, indexfunc=self._python_index_pair_filter)
6415  def __set_pair_filters(self, obj): IMP._list_util.set_varlist(self.pair_filters, obj)
6416  def __del_pair_filters(self): IMP._list_util.del_varlist(self.pair_filters)
6417  pair_filters = property(__get_pair_filters, __set_pair_filters, __del_pair_filters, doc="List of ##ucnames")
6418 
6419  def remove_pair_filter(self, d):
6420  r"""remove_pair_filter(ExcludedVolumeRestraint self, PairPredicate d)"""
6421  return _IMP_core.ExcludedVolumeRestraint_remove_pair_filter(self, d)
6422 
6423  def _python_index_pair_filter(self, d, start, stop):
6424  r"""_python_index_pair_filter(ExcludedVolumeRestraint self, PairPredicate d, unsigned int start, unsigned int stop) -> unsigned int"""
6425  return _IMP_core.ExcludedVolumeRestraint__python_index_pair_filter(self, d, start, stop)
6426 
6427  def remove_pair_filters(self, d):
6428  r"""remove_pair_filters(ExcludedVolumeRestraint self, IMP::PairPredicates const & d)"""
6429  return _IMP_core.ExcludedVolumeRestraint_remove_pair_filters(self, d)
6430 
6431  def set_pair_filters(self, ps):
6432  r"""set_pair_filters(ExcludedVolumeRestraint self, IMP::PairPredicates const & ps)"""
6433  return _IMP_core.ExcludedVolumeRestraint_set_pair_filters(self, ps)
6434 
6435  def set_pair_filters_order(self, objs):
6436  r"""set_pair_filters_order(ExcludedVolumeRestraint self, IMP::PairPredicates const & objs)"""
6437  return _IMP_core.ExcludedVolumeRestraint_set_pair_filters_order(self, objs)
6438 
6439  def add_pair_filter(self, obj):
6440  r"""add_pair_filter(ExcludedVolumeRestraint self, PairPredicate obj) -> unsigned int"""
6441  return _IMP_core.ExcludedVolumeRestraint_add_pair_filter(self, obj)
6442 
6443  def add_pair_filters(self, objs):
6444  r"""add_pair_filters(ExcludedVolumeRestraint self, IMP::PairPredicates const & objs)"""
6445  return _IMP_core.ExcludedVolumeRestraint_add_pair_filters(self, objs)
6446 
6447  def clear_pair_filters(self):
6448  r"""clear_pair_filters(ExcludedVolumeRestraint self)"""
6449  return _IMP_core.ExcludedVolumeRestraint_clear_pair_filters(self)
6450 
6451  def get_number_of_pair_filters(self):
6452  r"""get_number_of_pair_filters(ExcludedVolumeRestraint self) -> unsigned int"""
6453  return _IMP_core.ExcludedVolumeRestraint_get_number_of_pair_filters(self)
6454 
6455  def get_has_pair_filters(self):
6456  r"""get_has_pair_filters(ExcludedVolumeRestraint self) -> bool"""
6457  return _IMP_core.ExcludedVolumeRestraint_get_has_pair_filters(self)
6458 
6459  def get_pair_filter(self, i):
6460  r"""get_pair_filter(ExcludedVolumeRestraint self, unsigned int i) -> PairPredicate"""
6461  return _IMP_core.ExcludedVolumeRestraint_get_pair_filter(self, i)
6462 
6463  def get_pair_filters(self):
6464  r"""get_pair_filters(ExcludedVolumeRestraint self) -> IMP::PairPredicates"""
6465  return _IMP_core.ExcludedVolumeRestraint_get_pair_filters(self)
6466 
6467  def erase_pair_filter(self, i):
6468  r"""erase_pair_filter(ExcludedVolumeRestraint self, unsigned int i)"""
6469  return _IMP_core.ExcludedVolumeRestraint_erase_pair_filter(self, i)
6470 
6471  def reserve_pair_filters(self, sz):
6472  r"""reserve_pair_filters(ExcludedVolumeRestraint self, unsigned int sz)"""
6473  return _IMP_core.ExcludedVolumeRestraint_reserve_pair_filters(self, sz)
6474 
6475  def __str__(self):
6476  r"""__str__(ExcludedVolumeRestraint self) -> std::string"""
6477  return _IMP_core.ExcludedVolumeRestraint___str__(self)
6478 
6479  def __repr__(self):
6480  r"""__repr__(ExcludedVolumeRestraint self) -> std::string"""
6481  return _IMP_core.ExcludedVolumeRestraint___repr__(self)
6482 
6483  @staticmethod
6484  def get_from(o):
6485  return _object_cast_to_ExcludedVolumeRestraint(o)
6486 
6487 
6488 # Register ExcludedVolumeRestraint in _IMP_core:
6489 _IMP_core.ExcludedVolumeRestraint_swigregister(ExcludedVolumeRestraint)
6490 class FixedRefiner(IMP.Refiner):
6491  r"""Proxy of C++ IMP::core::FixedRefiner class."""
6492 
6493  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
6494 
6495  def __init__(self, *args):
6496  r"""
6497  __init__(FixedRefiner self, IMP::ParticlesTemp const & ps) -> FixedRefiner
6498  __init__(FixedRefiner self, Model m, IMP::ParticleIndexes const & pis) -> FixedRefiner
6499  __init__(FixedRefiner self) -> FixedRefiner
6500  """
6501  _IMP_core.FixedRefiner_swiginit(self, _IMP_core.new_FixedRefiner(*args))
6502 
6503  def do_get_inputs(self, m, pis):
6504  r"""do_get_inputs(FixedRefiner self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
6505  return _IMP_core.FixedRefiner_do_get_inputs(self, m, pis)
6506 
6507  def get_version_info(self):
6508  r"""get_version_info(FixedRefiner self) -> VersionInfo"""
6509  return _IMP_core.FixedRefiner_get_version_info(self)
6510  __swig_destroy__ = _IMP_core.delete_FixedRefiner
6511 
6512  def __str__(self):
6513  r"""__str__(FixedRefiner self) -> std::string"""
6514  return _IMP_core.FixedRefiner___str__(self)
6515 
6516  def __repr__(self):
6517  r"""__repr__(FixedRefiner self) -> std::string"""
6518  return _IMP_core.FixedRefiner___repr__(self)
6519 
6520  @staticmethod
6521  def get_from(o):
6522  return _object_cast_to_FixedRefiner(o)
6523 
6524 
6525  def _get_as_binary(self):
6526  r"""_get_as_binary(FixedRefiner self) -> PyObject *"""
6527  return _IMP_core.FixedRefiner__get_as_binary(self)
6528 
6529  def _set_from_binary(self, p):
6530  r"""_set_from_binary(FixedRefiner self, PyObject * p)"""
6531  return _IMP_core.FixedRefiner__set_from_binary(self, p)
6532 
6533  def __getstate__(self):
6534  p = self._get_as_binary()
6535  if len(self.__dict__) > 1:
6536  d = self.__dict__.copy()
6537  del d['this']
6538  p = (d, p)
6539  return p
6540 
6541  def __setstate__(self, p):
6542  if not hasattr(self, 'this'):
6543  self.__init__()
6544  if isinstance(p, tuple):
6545  d, p = p
6546  self.__dict__.update(d)
6547  return self._set_from_binary(p)
6548 
6549 
6550 # Register FixedRefiner in _IMP_core:
6551 _IMP_core.FixedRefiner_swigregister(FixedRefiner)
6552 class GridClosePairsFinder(ClosePairsFinder):
6553  r"""Proxy of C++ IMP::core::GridClosePairsFinder class."""
6554 
6555  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
6556 
6557  def __init__(self):
6558  r"""__init__(GridClosePairsFinder self) -> GridClosePairsFinder"""
6559  _IMP_core.GridClosePairsFinder_swiginit(self, _IMP_core.new_GridClosePairsFinder())
6560 
6561  def get_close_pairs(self, *args):
6562  r"""
6563  get_close_pairs(GridClosePairsFinder self, IMP::algebra::BoundingBox3Ds const & bbs) -> IMP::IntPairs
6564  get_close_pairs(GridClosePairsFinder self, IMP::algebra::BoundingBox3Ds const & bas, IMP::algebra::BoundingBox3Ds const & bbs) -> IMP::IntPairs
6565  get_close_pairs(GridClosePairsFinder self, Model m, IMP::ParticleIndexes const & pc) -> IMP::ParticleIndexPairs
6566  get_close_pairs(GridClosePairsFinder self, Model m, IMP::ParticleIndexes const & pca, IMP::ParticleIndexes const & pcb) -> IMP::ParticleIndexPairs
6567  """
6568  return _IMP_core.GridClosePairsFinder_get_close_pairs(self, *args)
6569 
6570  def do_get_inputs(self, m, pis):
6571  r"""do_get_inputs(GridClosePairsFinder self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
6572  return _IMP_core.GridClosePairsFinder_do_get_inputs(self, m, pis)
6573 
6574  def get_version_info(self):
6575  r"""get_version_info(GridClosePairsFinder self) -> VersionInfo"""
6576  return _IMP_core.GridClosePairsFinder_get_version_info(self)
6577  __swig_destroy__ = _IMP_core.delete_GridClosePairsFinder
6578 
6579  def __str__(self):
6580  r"""__str__(GridClosePairsFinder self) -> std::string"""
6581  return _IMP_core.GridClosePairsFinder___str__(self)
6582 
6583  def __repr__(self):
6584  r"""__repr__(GridClosePairsFinder self) -> std::string"""
6585  return _IMP_core.GridClosePairsFinder___repr__(self)
6586 
6587  @staticmethod
6588  def get_from(o):
6589  return _object_cast_to_GridClosePairsFinder(o)
6590 
6591 
6592  def _get_as_binary(self):
6593  r"""_get_as_binary(GridClosePairsFinder self) -> PyObject *"""
6594  return _IMP_core.GridClosePairsFinder__get_as_binary(self)
6595 
6596  def _set_from_binary(self, p):
6597  r"""_set_from_binary(GridClosePairsFinder self, PyObject * p)"""
6598  return _IMP_core.GridClosePairsFinder__set_from_binary(self, p)
6599 
6600  def __getstate__(self):
6601  p = self._get_as_binary()
6602  if len(self.__dict__) > 1:
6603  d = self.__dict__.copy()
6604  del d['this']
6605  p = (d, p)
6606  return p
6607 
6608  def __setstate__(self, p):
6609  if not hasattr(self, 'this'):
6610  self.__init__()
6611  if isinstance(p, tuple):
6612  d, p = p
6613  self.__dict__.update(d)
6614  return self._set_from_binary(p)
6615 
6616 
6617 # Register GridClosePairsFinder in _IMP_core:
6618 _IMP_core.GridClosePairsFinder_swigregister(GridClosePairsFinder)
6619 class Harmonic(IMP.UnaryFunction):
6620  r"""Proxy of C++ IMP::core::Harmonic class."""
6621 
6622  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
6623 
6624  def __init__(self, *args):
6625  r"""
6626  __init__(Harmonic self, IMP::Float mean, IMP::Float k) -> Harmonic
6627  __init__(Harmonic self) -> Harmonic
6628  """
6629  _IMP_core.Harmonic_swiginit(self, _IMP_core.new_Harmonic(*args))
6630 
6631  def get_version_info(self):
6632  r"""get_version_info(Harmonic self) -> VersionInfo"""
6633  return _IMP_core.Harmonic_get_version_info(self)
6634  __swig_destroy__ = _IMP_core.delete_Harmonic
6635 
6636  def get_mean(self):
6637  r"""get_mean(Harmonic self) -> IMP::Float"""
6638  return _IMP_core.Harmonic_get_mean(self)
6639 
6640  def get_k(self):
6641  r"""get_k(Harmonic self) -> IMP::Float"""
6642  return _IMP_core.Harmonic_get_k(self)
6643 
6644  def set_mean(self, mean):
6645  r"""set_mean(Harmonic self, IMP::Float mean)"""
6646  return _IMP_core.Harmonic_set_mean(self, mean)
6647 
6648  def set_k(self, k):
6649  r"""set_k(Harmonic self, IMP::Float k)"""
6650  return _IMP_core.Harmonic_set_k(self, k)
6651 
6652  @staticmethod
6653  def get_k_from_standard_deviation(sd, t=297.15):
6654  r"""get_k_from_standard_deviation(IMP::Float sd, IMP::Float t=297.15) -> IMP::Float"""
6655  return _IMP_core.Harmonic_get_k_from_standard_deviation(sd, t)
6656 
6657  def __str__(self):
6658  r"""__str__(Harmonic self) -> std::string"""
6659  return _IMP_core.Harmonic___str__(self)
6660 
6661  def __repr__(self):
6662  r"""__repr__(Harmonic self) -> std::string"""
6663  return _IMP_core.Harmonic___repr__(self)
6664 
6665  @staticmethod
6666  def get_from(o):
6667  return _object_cast_to_Harmonic(o)
6668 
6669 
6670  def _get_as_binary(self):
6671  r"""_get_as_binary(Harmonic self) -> PyObject *"""
6672  return _IMP_core.Harmonic__get_as_binary(self)
6673 
6674  def _set_from_binary(self, p):
6675  r"""_set_from_binary(Harmonic self, PyObject * p)"""
6676  return _IMP_core.Harmonic__set_from_binary(self, p)
6677 
6678  def __getstate__(self):
6679  p = self._get_as_binary()
6680  if len(self.__dict__) > 1:
6681  d = self.__dict__.copy()
6682  del d['this']
6683  p = (d, p)
6684  return p
6685 
6686  def __setstate__(self, p):
6687  if not hasattr(self, 'this'):
6688  self.__init__()
6689  if isinstance(p, tuple):
6690  d, p = p
6691  self.__dict__.update(d)
6692  return self._set_from_binary(p)
6693 
6694 
6695  def _get_jax(self):
6696  def score(val, mean, k):
6697  return 0.5 * k * (mean - val) ** 2
6698  return functools.partial(score, mean=self.get_mean(), k=self.get_k())
6699 
6700 
6701 # Register Harmonic in _IMP_core:
6702 _IMP_core.Harmonic_swigregister(Harmonic)
6703 class HarmonicWell(IMP.UnaryFunction):
6704  r"""Proxy of C++ IMP::core::HarmonicWell class."""
6705 
6706  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
6707 
6708  def __init__(self, well, k):
6709  r"""__init__(HarmonicWell self, IMP::FloatRange const & well, double k) -> HarmonicWell"""
6710  _IMP_core.HarmonicWell_swiginit(self, _IMP_core.new_HarmonicWell(well, k))
6711 
6712  def get_well(self):
6713  r"""get_well(HarmonicWell self) -> IMP::FloatRange"""
6714  return _IMP_core.HarmonicWell_get_well(self)
6715 
6716  def get_k(self):
6717  r"""get_k(HarmonicWell self) -> double"""
6718  return _IMP_core.HarmonicWell_get_k(self)
6719 
6720  def get_version_info(self):
6721  r"""get_version_info(HarmonicWell self) -> VersionInfo"""
6722  return _IMP_core.HarmonicWell_get_version_info(self)
6723  __swig_destroy__ = _IMP_core.delete_HarmonicWell
6724 
6725  def __str__(self):
6726  r"""__str__(HarmonicWell self) -> std::string"""
6727  return _IMP_core.HarmonicWell___str__(self)
6728 
6729  def __repr__(self):
6730  r"""__repr__(HarmonicWell self) -> std::string"""
6731  return _IMP_core.HarmonicWell___repr__(self)
6732 
6733  @staticmethod
6734  def get_from(o):
6735  return _object_cast_to_HarmonicWell(o)
6736 
6737 
6738  def _get_jax(self):
6739  import jax.numpy as jnp
6740  def score(val, lb, ub, k):
6741  return 0.5 * k * (val - jnp.clip(val, lb, ub)) ** 2
6742  well = self.get_well()
6743  return functools.partial(score, lb=well[0], ub=well[1], k=self.get_k())
6744 
6745 
6746 # Register HarmonicWell in _IMP_core:
6747 _IMP_core.HarmonicWell_swigregister(HarmonicWell)
6748 class HarmonicLowerBound(Harmonic):
6749  r"""Proxy of C++ IMP::core::HarmonicLowerBound class."""
6750 
6751  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
6752 
6753  def __init__(self, *args):
6754  r"""
6755  __init__(HarmonicLowerBound self, IMP::Float mean, IMP::Float k) -> HarmonicLowerBound
6756  __init__(HarmonicLowerBound self) -> HarmonicLowerBound
6757  """
6758  _IMP_core.HarmonicLowerBound_swiginit(self, _IMP_core.new_HarmonicLowerBound(*args))
6759  __swig_destroy__ = _IMP_core.delete_HarmonicLowerBound
6760 
6761  def __str__(self):
6762  r"""__str__(HarmonicLowerBound self) -> std::string"""
6763  return _IMP_core.HarmonicLowerBound___str__(self)
6764 
6765  def __repr__(self):
6766  r"""__repr__(HarmonicLowerBound self) -> std::string"""
6767  return _IMP_core.HarmonicLowerBound___repr__(self)
6768 
6769  @staticmethod
6770  def get_from(o):
6771  return _object_cast_to_HarmonicLowerBound(o)
6772 
6773 
6774  def _get_as_binary(self):
6775  r"""_get_as_binary(HarmonicLowerBound self) -> PyObject *"""
6776  return _IMP_core.HarmonicLowerBound__get_as_binary(self)
6777 
6778  def _set_from_binary(self, p):
6779  r"""_set_from_binary(HarmonicLowerBound self, PyObject * p)"""
6780  return _IMP_core.HarmonicLowerBound__set_from_binary(self, p)
6781 
6782  def __getstate__(self):
6783  p = self._get_as_binary()
6784  if len(self.__dict__) > 1:
6785  d = self.__dict__.copy()
6786  del d['this']
6787  p = (d, p)
6788  return p
6789 
6790  def __setstate__(self, p):
6791  if not hasattr(self, 'this'):
6792  self.__init__()
6793  if isinstance(p, tuple):
6794  d, p = p
6795  self.__dict__.update(d)
6796  return self._set_from_binary(p)
6797 
6798 
6799  def _get_jax(self):
6800  import jax.lax
6801  def score(val, mean, k):
6802  return 0.5 * k * jax.lax.max(mean - val, 0.0) ** 2
6803  return functools.partial(score, mean=self.get_mean(), k=self.get_k())
6804 
6805 
6806 # Register HarmonicLowerBound in _IMP_core:
6807 _IMP_core.HarmonicLowerBound_swigregister(HarmonicLowerBound)
6808 class HarmonicUpperBound(Harmonic):
6809  r"""Proxy of C++ IMP::core::HarmonicUpperBound class."""
6810 
6811  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
6812 
6813  def __init__(self, *args):
6814  r"""
6815  __init__(HarmonicUpperBound self, IMP::Float mean, IMP::Float k) -> HarmonicUpperBound
6816  __init__(HarmonicUpperBound self) -> HarmonicUpperBound
6817  """
6818  _IMP_core.HarmonicUpperBound_swiginit(self, _IMP_core.new_HarmonicUpperBound(*args))
6819  __swig_destroy__ = _IMP_core.delete_HarmonicUpperBound
6820 
6821  def __str__(self):
6822  r"""__str__(HarmonicUpperBound self) -> std::string"""
6823  return _IMP_core.HarmonicUpperBound___str__(self)
6824 
6825  def __repr__(self):
6826  r"""__repr__(HarmonicUpperBound self) -> std::string"""
6827  return _IMP_core.HarmonicUpperBound___repr__(self)
6828 
6829  @staticmethod
6830  def get_from(o):
6831  return _object_cast_to_HarmonicUpperBound(o)
6832 
6833 
6834  def _get_as_binary(self):
6835  r"""_get_as_binary(HarmonicUpperBound self) -> PyObject *"""
6836  return _IMP_core.HarmonicUpperBound__get_as_binary(self)
6837 
6838  def _set_from_binary(self, p):
6839  r"""_set_from_binary(HarmonicUpperBound self, PyObject * p)"""
6840  return _IMP_core.HarmonicUpperBound__set_from_binary(self, p)
6841 
6842  def __getstate__(self):
6843  p = self._get_as_binary()
6844  if len(self.__dict__) > 1:
6845  d = self.__dict__.copy()
6846  del d['this']
6847  p = (d, p)
6848  return p
6849 
6850  def __setstate__(self, p):
6851  if not hasattr(self, 'this'):
6852  self.__init__()
6853  if isinstance(p, tuple):
6854  d, p = p
6855  self.__dict__.update(d)
6856  return self._set_from_binary(p)
6857 
6858 
6859  def _get_jax(self):
6860  import jax.lax
6861  def score(val, mean, k):
6862  return 0.5 * k * jax.lax.min(mean - val, 0.0) ** 2
6863  return functools.partial(score, mean=self.get_mean(), k=self.get_k())
6864 
6865 
6866 # Register HarmonicUpperBound in _IMP_core:
6867 _IMP_core.HarmonicUpperBound_swigregister(HarmonicUpperBound)
6868 class WeightedSum(IMP.UnaryFunction):
6869  r"""Proxy of C++ IMP::core::WeightedSum class."""
6870 
6871  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
6872 
6873  def __init__(self, funcs, weights):
6874  r"""__init__(WeightedSum self, IMP::UnaryFunctions funcs, IMP::Floats weights) -> WeightedSum"""
6875  _IMP_core.WeightedSum_swiginit(self, _IMP_core.new_WeightedSum(funcs, weights))
6876 
6877  def get_function_number(self):
6878  r"""get_function_number(WeightedSum self) -> unsigned int"""
6879  return _IMP_core.WeightedSum_get_function_number(self)
6880 
6881  def set_weights(self, weights):
6882  r"""set_weights(WeightedSum self, IMP::Floats weights)"""
6883  return _IMP_core.WeightedSum_set_weights(self, weights)
6884 
6885  def get_weights(self):
6886  r"""get_weights(WeightedSum self) -> IMP::Floats"""
6887  return _IMP_core.WeightedSum_get_weights(self)
6888 
6889  def get_weight(self, i):
6890  r"""get_weight(WeightedSum self, unsigned int i) -> double"""
6891  return _IMP_core.WeightedSum_get_weight(self, i)
6892 
6893  def get_function(self, i):
6894  r"""get_function(WeightedSum self, unsigned int i) -> UnaryFunction"""
6895  return _IMP_core.WeightedSum_get_function(self, i)
6896 
6897  def get_version_info(self):
6898  r"""get_version_info(WeightedSum self) -> VersionInfo"""
6899  return _IMP_core.WeightedSum_get_version_info(self)
6900  __swig_destroy__ = _IMP_core.delete_WeightedSum
6901 
6902  def __str__(self):
6903  r"""__str__(WeightedSum self) -> std::string"""
6904  return _IMP_core.WeightedSum___str__(self)
6905 
6906  def __repr__(self):
6907  r"""__repr__(WeightedSum self) -> std::string"""
6908  return _IMP_core.WeightedSum___repr__(self)
6909 
6910  @staticmethod
6911  def get_from(o):
6912  return _object_cast_to_WeightedSum(o)
6913 
6914 
6915  def _get_jax(self):
6916  import jax.numpy as jnp
6917  def score(val, funcs, weights):
6918  return sum(f(val) * weight for (f, weight) in zip(funcs, weights))
6919  nfunc = self.get_function_number()
6920  funcs = [self.get_function(i).get_derived_object()._get_jax()
6921  for i in range(nfunc)]
6922  return functools.partial(score, funcs=funcs,
6923  weights=self.get_weights())
6924 
6925 
6926 # Register WeightedSum in _IMP_core:
6927 _IMP_core.WeightedSum_swigregister(WeightedSum)
6928 class WeightedSumOfExponential(IMP.UnaryFunction):
6929  r"""Proxy of C++ IMP::core::WeightedSumOfExponential class."""
6930 
6931  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
6932 
6933  def __init__(self, funcs, weights, denom=1.0):
6934  r"""__init__(WeightedSumOfExponential self, IMP::UnaryFunctions funcs, IMP::Floats weights, IMP::Float denom=1.0) -> WeightedSumOfExponential"""
6935  _IMP_core.WeightedSumOfExponential_swiginit(self, _IMP_core.new_WeightedSumOfExponential(funcs, weights, denom))
6936 
6937  def get_function_number(self):
6938  r"""get_function_number(WeightedSumOfExponential self) -> unsigned int"""
6939  return _IMP_core.WeightedSumOfExponential_get_function_number(self)
6940 
6941  def set_weights(self, weights):
6942  r"""set_weights(WeightedSumOfExponential self, IMP::Floats weights)"""
6943  return _IMP_core.WeightedSumOfExponential_set_weights(self, weights)
6944 
6945  def get_weights(self):
6946  r"""get_weights(WeightedSumOfExponential self) -> IMP::Floats"""
6947  return _IMP_core.WeightedSumOfExponential_get_weights(self)
6948 
6949  def get_weight(self, i):
6950  r"""get_weight(WeightedSumOfExponential self, unsigned int i) -> double"""
6951  return _IMP_core.WeightedSumOfExponential_get_weight(self, i)
6952 
6953  def get_function(self, i):
6954  r"""get_function(WeightedSumOfExponential self, unsigned int i) -> UnaryFunction"""
6955  return _IMP_core.WeightedSumOfExponential_get_function(self, i)
6956 
6957  def set_denominator(self, denom):
6958  r"""set_denominator(WeightedSumOfExponential self, double denom)"""
6959  return _IMP_core.WeightedSumOfExponential_set_denominator(self, denom)
6960 
6961  def get_denominator(self):
6962  r"""get_denominator(WeightedSumOfExponential self) -> double"""
6963  return _IMP_core.WeightedSumOfExponential_get_denominator(self)
6964 
6965  def get_version_info(self):
6966  r"""get_version_info(WeightedSumOfExponential self) -> VersionInfo"""
6967  return _IMP_core.WeightedSumOfExponential_get_version_info(self)
6968  __swig_destroy__ = _IMP_core.delete_WeightedSumOfExponential
6969 
6970  def __str__(self):
6971  r"""__str__(WeightedSumOfExponential self) -> std::string"""
6972  return _IMP_core.WeightedSumOfExponential___str__(self)
6973 
6974  def __repr__(self):
6975  r"""__repr__(WeightedSumOfExponential self) -> std::string"""
6976  return _IMP_core.WeightedSumOfExponential___repr__(self)
6977 
6978  @staticmethod
6979  def get_from(o):
6980  return _object_cast_to_WeightedSumOfExponential(o)
6981 
6982 
6983  def _get_jax(self):
6984  import jax.numpy as jnp
6985  def score(val, funcs, weights, denom):
6986  exp_sum = sum(weight * jnp.exp(-f(val) / denom)
6987  for (f, weight) in zip(funcs, weights))
6988  return -jnp.log(exp_sum) * denom
6989  nfunc = self.get_function_number()
6990  funcs = [self.get_function(i).get_derived_object()._get_jax()
6991  for i in range(nfunc)]
6992  return functools.partial(score, funcs=funcs,
6993  weights=self.get_weights(),
6994  denom=self.get_denominator())
6995 
6996 
6997 # Register WeightedSumOfExponential in _IMP_core:
6998 _IMP_core.WeightedSumOfExponential_swigregister(WeightedSumOfExponential)
6999 class MSConnectivityRestraint(IMP.Restraint):
7000  r"""Proxy of C++ IMP::core::MSConnectivityRestraint class."""
7001 
7002  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
7003 
7004  def __init__(self, m, ps, eps=0.1):
7005  r"""__init__(MSConnectivityRestraint self, Model m, PairScore ps, double eps=0.1) -> MSConnectivityRestraint"""
7006  _IMP_core.MSConnectivityRestraint_swiginit(self, _IMP_core.new_MSConnectivityRestraint(m, ps, eps))
7007 
7008  def add_type(self, ps):
7009  r"""add_type(MSConnectivityRestraint self, IMP::ParticlesTemp const & ps) -> unsigned int"""
7010  return _IMP_core.MSConnectivityRestraint_add_type(self, ps)
7011 
7012  def add_composite(self, *args):
7013  r"""
7014  add_composite(MSConnectivityRestraint self, IMP::Ints const & components) -> unsigned int
7015  add_composite(MSConnectivityRestraint self, IMP::Ints const & components, unsigned int parent) -> unsigned int
7016  """
7017  return _IMP_core.MSConnectivityRestraint_add_composite(self, *args)
7018 
7019  def get_connected_pairs(self):
7020  r"""get_connected_pairs(MSConnectivityRestraint self) -> IMP::ParticlePairsTemp"""
7021  return _IMP_core.MSConnectivityRestraint_get_connected_pairs(self)
7022 
7023  def get_pair_score(self):
7024  r"""get_pair_score(MSConnectivityRestraint self) -> PairScore"""
7025  return _IMP_core.MSConnectivityRestraint_get_pair_score(self)
7026 
7027  def do_create_current_decomposition(self):
7028  r"""do_create_current_decomposition(MSConnectivityRestraint self) -> IMP::Restraints"""
7029  return _IMP_core.MSConnectivityRestraint_do_create_current_decomposition(self)
7030 
7031  def do_get_inputs(self):
7032  r"""do_get_inputs(MSConnectivityRestraint self) -> IMP::ModelObjectsTemp"""
7033  return _IMP_core.MSConnectivityRestraint_do_get_inputs(self)
7034 
7035  def get_version_info(self):
7036  r"""get_version_info(MSConnectivityRestraint self) -> VersionInfo"""
7037  return _IMP_core.MSConnectivityRestraint_get_version_info(self)
7038  __swig_destroy__ = _IMP_core.delete_MSConnectivityRestraint
7039 
7040  def __str__(self):
7041  r"""__str__(MSConnectivityRestraint self) -> std::string"""
7042  return _IMP_core.MSConnectivityRestraint___str__(self)
7043 
7044  def __repr__(self):
7045  r"""__repr__(MSConnectivityRestraint self) -> std::string"""
7046  return _IMP_core.MSConnectivityRestraint___repr__(self)
7047 
7048  @staticmethod
7049  def get_from(o):
7050  return _object_cast_to_MSConnectivityRestraint(o)
7051 
7052 
7053 # Register MSConnectivityRestraint in _IMP_core:
7054 _IMP_core.MSConnectivityRestraint_swigregister(MSConnectivityRestraint)
7055 class HierarchyTraits(object):
7056  r"""Proxy of C++ IMP::core::HierarchyTraits class."""
7057 
7058  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
7059 
7060  def __init__(self, *args):
7061  r"""
7062  __init__(HierarchyTraits self) -> HierarchyTraits
7063  __init__(HierarchyTraits self, std::string name) -> HierarchyTraits
7064  """
7065  _IMP_core.HierarchyTraits_swiginit(self, _IMP_core.new_HierarchyTraits(*args))
7066 
7067  def get_children_key(self):
7068  r"""get_children_key(HierarchyTraits self) -> ParticleIndexesKey"""
7069  return _IMP_core.HierarchyTraits_get_children_key(self)
7070 
7071  def get_parent_key(self):
7072  r"""get_parent_key(HierarchyTraits self) -> ParticleIndexKey"""
7073  return _IMP_core.HierarchyTraits_get_parent_key(self)
7074 
7075  def __eq__(self, o):
7076  r"""__eq__(HierarchyTraits self, HierarchyTraits o) -> bool"""
7077  return _IMP_core.HierarchyTraits___eq__(self, o)
7078 
7079  def show(self, *args):
7080  r"""show(HierarchyTraits self, _ostream out=std::cout)"""
7081  return _IMP_core.HierarchyTraits_show(self, *args)
7082 
7083  def __str__(self):
7084  r"""__str__(HierarchyTraits self) -> std::string"""
7085  return _IMP_core.HierarchyTraits___str__(self)
7086 
7087  def __repr__(self):
7088  r"""__repr__(HierarchyTraits self) -> std::string"""
7089  return _IMP_core.HierarchyTraits___repr__(self)
7090  __swig_destroy__ = _IMP_core.delete_HierarchyTraits
7091 
7092 # Register HierarchyTraits in _IMP_core:
7093 _IMP_core.HierarchyTraits_swigregister(HierarchyTraits)
7094 class Hierarchy(IMP.Decorator):
7095  r"""Proxy of C++ IMP::core::Hierarchy class."""
7096 
7097  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
7098 
7099  def get_decorator_traits(self):
7100  r"""get_decorator_traits(Hierarchy self) -> HierarchyTraits"""
7101  return _IMP_core.Hierarchy_get_decorator_traits(self)
7102 
7103  @staticmethod
7104  def get_default_decorator_traits():
7105  r"""get_default_decorator_traits() -> HierarchyTraits"""
7106  return _IMP_core.Hierarchy_get_default_decorator_traits()
7107 
7108  def __init__(self, *args):
7109  r"""
7110  __init__(Hierarchy self) -> Hierarchy
7111  __init__(Hierarchy self, Model m, ParticleIndex id, HierarchyTraits tr=get_default_traits()) -> Hierarchy
7112  __init__(Hierarchy self, _ParticleAdaptor d, HierarchyTraits tr=get_default_traits()) -> Hierarchy
7113  """
7114  _IMP_core.Hierarchy_swiginit(self, _IMP_core.new_Hierarchy(*args))
7115 
7116  def show(self, *args):
7117  r"""show(Hierarchy self, _ostream out=std::cout)"""
7118  return _IMP_core.Hierarchy_show(self, *args)
7119 
7120  @staticmethod
7121  def setup_particle(*args):
7122  r"""
7123  setup_particle(Model m, ParticleIndex pi, HierarchyTraits tr=IMP::core::Hierarchy::get_default_decorator_traits()) -> Hierarchy
7124  setup_particle(_ParticleAdaptor d, HierarchyTraits tr=IMP::core::Hierarchy::get_default_decorator_traits()) -> Hierarchy
7125  setup_particle(Model m, ParticleIndex pi, IMP::ParticleIndexes children, HierarchyTraits tr=IMP::core::Hierarchy::get_default_decorator_traits()) -> Hierarchy
7126  setup_particle(_ParticleAdaptor d, IMP::ParticleIndexes children, HierarchyTraits tr=IMP::core::Hierarchy::get_default_decorator_traits()) -> Hierarchy
7127  setup_particle(Model m, ParticleIndex pi, IMP::ParticlesTemp children, HierarchyTraits tr=IMP::core::Hierarchy::get_default_decorator_traits()) -> Hierarchy
7128  setup_particle(_ParticleAdaptor d, IMP::ParticlesTemp children, HierarchyTraits tr=IMP::core::Hierarchy::get_default_decorator_traits()) -> Hierarchy
7129  """
7130  return _IMP_core.Hierarchy_setup_particle(*args)
7131 
7132  @staticmethod
7133  def get_is_setup(*args):
7134  r"""
7135  get_is_setup(_ParticleAdaptor p, HierarchyTraits tr=get_default_traits()) -> bool
7136  get_is_setup(Model arg1, ParticleIndex arg2, HierarchyTraits arg3=Hierarchy::get_default_traits()) -> bool
7137  """
7138  return _IMP_core.Hierarchy_get_is_setup(*args)
7139 
7140  @staticmethod
7141  def get_changed_key():
7142  r"""get_changed_key() -> TriggerKey"""
7143  return _IMP_core.Hierarchy_get_changed_key()
7144 
7145  def get_parent(self):
7146  r"""get_parent(Hierarchy self) -> Hierarchy"""
7147  return _IMP_core.Hierarchy_get_parent(self)
7148 
7149  def get_number_of_children(self):
7150  r"""get_number_of_children(Hierarchy self) -> unsigned int"""
7151  return _IMP_core.Hierarchy_get_number_of_children(self)
7152 
7153  def get_child(self, i):
7154  r"""get_child(Hierarchy self, unsigned int i) -> Hierarchy"""
7155  return _IMP_core.Hierarchy_get_child(self, i)
7156 
7157  def get_children_indexes(self):
7158  r"""get_children_indexes(Hierarchy self) -> IMP::ParticleIndexes"""
7159  return _IMP_core.Hierarchy_get_children_indexes(self)
7160 
7161  def get_children(self):
7162  r"""get_children(Hierarchy self) -> IMP::core::GenericHierarchies"""
7163  return _IMP_core.Hierarchy_get_children(self)
7164 
7165  def remove_child(self, *args):
7166  r"""
7167  remove_child(Hierarchy self, unsigned int i)
7168  remove_child(Hierarchy self, Hierarchy h)
7169  """
7170  return _IMP_core.Hierarchy_remove_child(self, *args)
7171 
7172  def clear_children(self):
7173  r"""clear_children(Hierarchy self)"""
7174  return _IMP_core.Hierarchy_clear_children(self)
7175 
7176  def add_child(self, h):
7177  r"""add_child(Hierarchy self, Hierarchy h)"""
7178  return _IMP_core.Hierarchy_add_child(self, h)
7179 
7180  def add_child_at(self, h, pos):
7181  r"""add_child_at(Hierarchy self, Hierarchy h, unsigned int pos)"""
7182  return _IMP_core.Hierarchy_add_child_at(self, h, pos)
7183 
7184  def get_child_index(self, *args):
7185  r"""
7186  get_child_index(Hierarchy self, unsigned int i) -> ParticleIndex
7187  get_child_index(Hierarchy self) -> int
7188  """
7189  return _IMP_core.Hierarchy_get_child_index(self, *args)
7190 
7191  @staticmethod
7192  def get_default_traits():
7193  r"""get_default_traits() -> HierarchyTraits"""
7194  return _IMP_core.Hierarchy_get_default_traits()
7195 
7196  def get_traits(self):
7197  r"""get_traits(Hierarchy self) -> HierarchyTraits"""
7198  return _IMP_core.Hierarchy_get_traits(self)
7199 
7200  def add_attribute(self, *args):
7201  r"""
7202  add_attribute(Hierarchy self, FloatKey k, IMP::Float v, bool opt)
7203  add_attribute(Hierarchy self, FloatKey a0, IMP::Float a1)
7204  add_attribute(Hierarchy self, IntKey a0, IMP::Int a1)
7205  add_attribute(Hierarchy self, FloatsKey a0, IMP::Floats a1)
7206  add_attribute(Hierarchy self, IntsKey a0, IMP::Ints a1)
7207  add_attribute(Hierarchy self, StringKey a0, IMP::String a1)
7208  add_attribute(Hierarchy self, ParticleIndexKey a0, Particle a1)
7209  add_attribute(Hierarchy self, ObjectKey a0, Object a1)
7210  add_attribute(Hierarchy self, SparseFloatKey a0, IMP::Float a1)
7211  add_attribute(Hierarchy self, SparseIntKey a0, IMP::Int a1)
7212  add_attribute(Hierarchy self, SparseStringKey a0, IMP::String a1)
7213  add_attribute(Hierarchy self, SparseParticleIndexKey a0, ParticleIndex a1)
7214  """
7215  return _IMP_core.Hierarchy_add_attribute(self, *args)
7216 
7217  def get_value(self, *args):
7218  r"""
7219  get_value(Hierarchy self, FloatKey a0) -> IMP::Float
7220  get_value(Hierarchy self, IntKey a0) -> IMP::Int
7221  get_value(Hierarchy self, FloatsKey a0) -> IMP::Floats
7222  get_value(Hierarchy self, IntsKey a0) -> IMP::Ints
7223  get_value(Hierarchy self, StringKey a0) -> IMP::String
7224  get_value(Hierarchy self, ParticleIndexKey a0) -> Particle
7225  get_value(Hierarchy self, ObjectKey a0) -> Object
7226  get_value(Hierarchy self, SparseFloatKey a0) -> IMP::Float
7227  get_value(Hierarchy self, SparseIntKey a0) -> IMP::Int
7228  get_value(Hierarchy self, SparseStringKey a0) -> IMP::String
7229  get_value(Hierarchy self, SparseParticleIndexKey a0) -> ParticleIndex
7230  """
7231  return _IMP_core.Hierarchy_get_value(self, *args)
7232 
7233  def set_value(self, *args):
7234  r"""
7235  set_value(Hierarchy self, FloatKey a0, IMP::Float a1)
7236  set_value(Hierarchy self, IntKey a0, IMP::Int a1)
7237  set_value(Hierarchy self, FloatsKey a0, IMP::Floats a1)
7238  set_value(Hierarchy self, IntsKey a0, IMP::Ints a1)
7239  set_value(Hierarchy self, StringKey a0, IMP::String a1)
7240  set_value(Hierarchy self, ParticleIndexKey a0, Particle a1)
7241  set_value(Hierarchy self, ObjectKey a0, Object a1)
7242  set_value(Hierarchy self, SparseFloatKey a0, IMP::Float a1)
7243  set_value(Hierarchy self, SparseIntKey a0, IMP::Int a1)
7244  set_value(Hierarchy self, SparseStringKey a0, IMP::String a1)
7245  set_value(Hierarchy self, SparseParticleIndexKey a0, ParticleIndex a1)
7246  """
7247  return _IMP_core.Hierarchy_set_value(self, *args)
7248 
7249  def remove_attribute(self, *args):
7250  r"""
7251  remove_attribute(Hierarchy self, FloatKey a0)
7252  remove_attribute(Hierarchy self, IntKey a0)
7253  remove_attribute(Hierarchy self, FloatsKey a0)
7254  remove_attribute(Hierarchy self, IntsKey a0)
7255  remove_attribute(Hierarchy self, StringKey a0)
7256  remove_attribute(Hierarchy self, ParticleIndexKey a0)
7257  remove_attribute(Hierarchy self, ObjectKey a0)
7258  remove_attribute(Hierarchy self, SparseFloatKey a0)
7259  remove_attribute(Hierarchy self, SparseIntKey a0)
7260  remove_attribute(Hierarchy self, SparseStringKey a0)
7261  remove_attribute(Hierarchy self, SparseParticleIndexKey a0)
7262  """
7263  return _IMP_core.Hierarchy_remove_attribute(self, *args)
7264 
7265  def has_attribute(self, *args):
7266  r"""
7267  has_attribute(Hierarchy self, FloatKey a0) -> bool
7268  has_attribute(Hierarchy self, IntKey a0) -> bool
7269  has_attribute(Hierarchy self, FloatsKey a0) -> bool
7270  has_attribute(Hierarchy self, IntsKey a0) -> bool
7271  has_attribute(Hierarchy self, StringKey a0) -> bool
7272  has_attribute(Hierarchy self, ParticleIndexKey a0) -> bool
7273  has_attribute(Hierarchy self, ObjectKey a0) -> bool
7274  has_attribute(Hierarchy self, SparseFloatKey a0) -> bool
7275  has_attribute(Hierarchy self, SparseIntKey a0) -> bool
7276  has_attribute(Hierarchy self, SparseStringKey a0) -> bool
7277  has_attribute(Hierarchy self, SparseParticleIndexKey a0) -> bool
7278  """
7279  return _IMP_core.Hierarchy_has_attribute(self, *args)
7280 
7281  def get_derivative(self, a0):
7282  r"""get_derivative(Hierarchy self, FloatKey a0) -> double"""
7283  return _IMP_core.Hierarchy_get_derivative(self, a0)
7284 
7285  def get_name(self):
7286  r"""get_name(Hierarchy self) -> std::string"""
7287  return _IMP_core.Hierarchy_get_name(self)
7288 
7289  def clear_caches(self):
7290  r"""clear_caches(Hierarchy self)"""
7291  return _IMP_core.Hierarchy_clear_caches(self)
7292 
7293  def set_name(self, a0):
7294  r"""set_name(Hierarchy self, std::string a0)"""
7295  return _IMP_core.Hierarchy_set_name(self, a0)
7296 
7297  def set_check_level(self, a0):
7298  r"""set_check_level(Hierarchy self, IMP::CheckLevel a0)"""
7299  return _IMP_core.Hierarchy_set_check_level(self, a0)
7300 
7301  def add_to_derivative(self, a0, a1, a2):
7302  r"""add_to_derivative(Hierarchy self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
7303  return _IMP_core.Hierarchy_add_to_derivative(self, a0, a1, a2)
7304 
7305  def set_is_optimized(self, a0, a1):
7306  r"""set_is_optimized(Hierarchy self, FloatKey a0, bool a1)"""
7307  return _IMP_core.Hierarchy_set_is_optimized(self, a0, a1)
7308 
7309  def get_is_optimized(self, a0):
7310  r"""get_is_optimized(Hierarchy self, FloatKey a0) -> bool"""
7311  return _IMP_core.Hierarchy_get_is_optimized(self, a0)
7312 
7313  def get_check_level(self):
7314  r"""get_check_level(Hierarchy self) -> IMP::CheckLevel"""
7315  return _IMP_core.Hierarchy_get_check_level(self)
7316 
7317  def __eq__(self, *args):
7318  r"""
7319  __eq__(Hierarchy self, Hierarchy o) -> bool
7320  __eq__(Hierarchy self, Particle d) -> bool
7321  """
7322  return _IMP_core.Hierarchy___eq__(self, *args)
7323 
7324  def __ne__(self, *args):
7325  r"""
7326  __ne__(Hierarchy self, Hierarchy o) -> bool
7327  __ne__(Hierarchy self, Particle d) -> bool
7328  """
7329  return _IMP_core.Hierarchy___ne__(self, *args)
7330 
7331  def __le__(self, *args):
7332  r"""
7333  __le__(Hierarchy self, Hierarchy o) -> bool
7334  __le__(Hierarchy self, Particle d) -> bool
7335  """
7336  return _IMP_core.Hierarchy___le__(self, *args)
7337 
7338  def __lt__(self, *args):
7339  r"""
7340  __lt__(Hierarchy self, Hierarchy o) -> bool
7341  __lt__(Hierarchy self, Particle d) -> bool
7342  """
7343  return _IMP_core.Hierarchy___lt__(self, *args)
7344 
7345  def __ge__(self, *args):
7346  r"""
7347  __ge__(Hierarchy self, Hierarchy o) -> bool
7348  __ge__(Hierarchy self, Particle d) -> bool
7349  """
7350  return _IMP_core.Hierarchy___ge__(self, *args)
7351 
7352  def __gt__(self, *args):
7353  r"""
7354  __gt__(Hierarchy self, Hierarchy o) -> bool
7355  __gt__(Hierarchy self, Particle d) -> bool
7356  """
7357  return _IMP_core.Hierarchy___gt__(self, *args)
7358 
7359  def __hash__(self):
7360  r"""__hash__(Hierarchy self) -> std::size_t"""
7361  return _IMP_core.Hierarchy___hash__(self)
7362 
7363  def __str__(self):
7364  r"""__str__(Hierarchy self) -> std::string"""
7365  return _IMP_core.Hierarchy___str__(self)
7366 
7367  def __repr__(self):
7368  r"""__repr__(Hierarchy self) -> std::string"""
7369  return _IMP_core.Hierarchy___repr__(self)
7370  __swig_destroy__ = _IMP_core.delete_Hierarchy
7371 
7372 # Register Hierarchy in _IMP_core:
7373 _IMP_core.Hierarchy_swigregister(Hierarchy)
7374 class HierarchyVisitor(object):
7375  r"""Proxy of C++ IMP::core::HierarchyVisitor class."""
7376 
7377  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
7378  __repr__ = _swig_repr
7379 
7380  def __init__(self):
7381  r"""__init__(HierarchyVisitor self) -> HierarchyVisitor"""
7382  if self.__class__ == HierarchyVisitor:
7383  _self = None
7384  else:
7385  _self = self
7386  _IMP_core.HierarchyVisitor_swiginit(self, _IMP_core.new_HierarchyVisitor(_self, ))
7387 
7388  if self.__class__ != HierarchyVisitor:
7389  _director_objects.register(self)
7390 
7391 
7392 
7393 
7394  def __call__(self, p):
7395  r"""__call__(HierarchyVisitor self, Hierarchy p) -> bool"""
7396  return _IMP_core.HierarchyVisitor___call__(self, p)
7397  __swig_destroy__ = _IMP_core.delete_HierarchyVisitor
7398  def __disown__(self):
7399  self.this.disown()
7400  _IMP_core.disown_HierarchyVisitor(self)
7401  return weakref.proxy(self)
7402 
7403 # Register HierarchyVisitor in _IMP_core:
7404 _IMP_core.HierarchyVisitor_swigregister(HierarchyVisitor)
7405 class ModifierVisitor(HierarchyVisitor):
7406  r"""Proxy of C++ IMP::core::ModifierVisitor class."""
7407 
7408  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
7409  __repr__ = _swig_repr
7410 
7411  def __init__(self, sm):
7412  r"""__init__(ModifierVisitor self, SingletonModifier sm) -> ModifierVisitor"""
7413  _IMP_core.ModifierVisitor_swiginit(self, _IMP_core.new_ModifierVisitor(sm))
7414  __swig_destroy__ = _IMP_core.delete_ModifierVisitor
7415 
7416 # Register ModifierVisitor in _IMP_core:
7417 _IMP_core.ModifierVisitor_swigregister(ModifierVisitor)
7418 class HierarchyCounter(HierarchyVisitor):
7419  r"""Proxy of C++ IMP::core::HierarchyCounter class."""
7420 
7421  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
7422 
7423  def __init__(self):
7424  r"""__init__(HierarchyCounter self) -> HierarchyCounter"""
7425  _IMP_core.HierarchyCounter_swiginit(self, _IMP_core.new_HierarchyCounter())
7426 
7427  def get_count(self):
7428  r"""get_count(HierarchyCounter self) -> unsigned int"""
7429  return _IMP_core.HierarchyCounter_get_count(self)
7430 
7431  def show(self, *args):
7432  r"""show(HierarchyCounter self, _ostream out=std::cout)"""
7433  return _IMP_core.HierarchyCounter_show(self, *args)
7434 
7435  def __str__(self):
7436  r"""__str__(HierarchyCounter self) -> std::string"""
7437  return _IMP_core.HierarchyCounter___str__(self)
7438 
7439  def __repr__(self):
7440  r"""__repr__(HierarchyCounter self) -> std::string"""
7441  return _IMP_core.HierarchyCounter___repr__(self)
7442 
7443  def _get_as_binary(self):
7444  r"""_get_as_binary(HierarchyCounter self) -> PyObject *"""
7445  return _IMP_core.HierarchyCounter__get_as_binary(self)
7446 
7447  def _set_from_binary(self, p):
7448  r"""_set_from_binary(HierarchyCounter self, PyObject * p)"""
7449  return _IMP_core.HierarchyCounter__set_from_binary(self, p)
7450 
7451  def __getstate__(self):
7452  p = self._get_as_binary()
7453  if len(self.__dict__) > 1:
7454  d = self.__dict__.copy()
7455  del d['this']
7456  p = (d, p)
7457  return p
7458 
7459  def __setstate__(self, p):
7460  if not hasattr(self, 'this'):
7461  self.__init__()
7462  if isinstance(p, tuple):
7463  d, p = p
7464  self.__dict__.update(d)
7465  return self._set_from_binary(p)
7466 
7467  __swig_destroy__ = _IMP_core.delete_HierarchyCounter
7468 
7469 # Register HierarchyCounter in _IMP_core:
7470 _IMP_core.HierarchyCounter_swigregister(HierarchyCounter)
7471 
7472 def get_leaves(mhd):
7473  r"""get_leaves(Hierarchy mhd) -> IMP::core::GenericHierarchies"""
7474  return _IMP_core.get_leaves(mhd)
7475 
7476 def get_internal(mhd):
7477  r"""get_internal(Hierarchy mhd) -> IMP::core::GenericHierarchies"""
7478  return _IMP_core.get_internal(mhd)
7479 
7480 def get_all_descendants(mhd):
7481  r"""get_all_descendants(Hierarchy mhd) -> IMP::core::GenericHierarchies"""
7482  return _IMP_core.get_all_descendants(mhd)
7483 
7484 def get_root(h):
7485  r"""get_root(Hierarchy h) -> Hierarchy"""
7486  return _IMP_core.get_root(h)
7487 
7488 def visit_breadth_first(d, f):
7489  r"""visit_breadth_first(Hierarchy d, HierarchyVisitor f)"""
7490  return _IMP_core.visit_breadth_first(d, f)
7491 
7492 def visit_depth_first(d, f):
7493  r"""visit_depth_first(Hierarchy d, HierarchyVisitor f)"""
7494  return _IMP_core.visit_depth_first(d, f)
7495 class LeavesRefiner(IMP.Refiner):
7496  r"""Proxy of C++ IMP::core::LeavesRefiner class."""
7497 
7498  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
7499 
7500  def __init__(self, tr):
7501  r"""__init__(LeavesRefiner self, HierarchyTraits tr) -> LeavesRefiner"""
7502  _IMP_core.LeavesRefiner_swiginit(self, _IMP_core.new_LeavesRefiner(tr))
7503 
7504  def do_get_inputs(self, m, pis):
7505  r"""do_get_inputs(LeavesRefiner self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
7506  return _IMP_core.LeavesRefiner_do_get_inputs(self, m, pis)
7507 
7508  def get_version_info(self):
7509  r"""get_version_info(LeavesRefiner self) -> VersionInfo"""
7510  return _IMP_core.LeavesRefiner_get_version_info(self)
7511  __swig_destroy__ = _IMP_core.delete_LeavesRefiner
7512 
7513  def __str__(self):
7514  r"""__str__(LeavesRefiner self) -> std::string"""
7515  return _IMP_core.LeavesRefiner___str__(self)
7516 
7517  def __repr__(self):
7518  r"""__repr__(LeavesRefiner self) -> std::string"""
7519  return _IMP_core.LeavesRefiner___repr__(self)
7520 
7521  @staticmethod
7522  def get_from(o):
7523  return _object_cast_to_LeavesRefiner(o)
7524 
7525 
7526 # Register LeavesRefiner in _IMP_core:
7527 _IMP_core.LeavesRefiner_swigregister(LeavesRefiner)
7528 class Linear(IMP.UnaryFunction):
7529  r"""Proxy of C++ IMP::core::Linear class."""
7530 
7531  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
7532 
7533  def __init__(self, *args):
7534  r"""
7535  __init__(Linear self, double offset, double slope) -> Linear
7536  __init__(Linear self) -> Linear
7537  """
7538  _IMP_core.Linear_swiginit(self, _IMP_core.new_Linear(*args))
7539 
7540  def set_slope(self, f):
7541  r"""set_slope(Linear self, double f)"""
7542  return _IMP_core.Linear_set_slope(self, f)
7543 
7544  def get_slope(self):
7545  r"""get_slope(Linear self) -> double"""
7546  return _IMP_core.Linear_get_slope(self)
7547 
7548  def set_offset(self, f):
7549  r"""set_offset(Linear self, double f)"""
7550  return _IMP_core.Linear_set_offset(self, f)
7551 
7552  def get_offset(self):
7553  r"""get_offset(Linear self) -> double"""
7554  return _IMP_core.Linear_get_offset(self)
7555 
7556  def get_version_info(self):
7557  r"""get_version_info(Linear self) -> VersionInfo"""
7558  return _IMP_core.Linear_get_version_info(self)
7559  __swig_destroy__ = _IMP_core.delete_Linear
7560 
7561  def __str__(self):
7562  r"""__str__(Linear self) -> std::string"""
7563  return _IMP_core.Linear___str__(self)
7564 
7565  def __repr__(self):
7566  r"""__repr__(Linear self) -> std::string"""
7567  return _IMP_core.Linear___repr__(self)
7568 
7569  @staticmethod
7570  def get_from(o):
7571  return _object_cast_to_Linear(o)
7572 
7573 
7574  def _get_as_binary(self):
7575  r"""_get_as_binary(Linear self) -> PyObject *"""
7576  return _IMP_core.Linear__get_as_binary(self)
7577 
7578  def _set_from_binary(self, p):
7579  r"""_set_from_binary(Linear self, PyObject * p)"""
7580  return _IMP_core.Linear__set_from_binary(self, p)
7581 
7582  def __getstate__(self):
7583  p = self._get_as_binary()
7584  if len(self.__dict__) > 1:
7585  d = self.__dict__.copy()
7586  del d['this']
7587  p = (d, p)
7588  return p
7589 
7590  def __setstate__(self, p):
7591  if not hasattr(self, 'this'):
7592  self.__init__()
7593  if isinstance(p, tuple):
7594  d, p = p
7595  self.__dict__.update(d)
7596  return self._set_from_binary(p)
7597 
7598 
7599  def _get_jax(self):
7600  def score(val, slope, offset):
7601  return (val - offset) * slope
7602  return functools.partial(score, slope=self.get_slope(),
7603  offset=self.get_offset())
7604 
7605 
7606 # Register Linear in _IMP_core:
7607 _IMP_core.Linear_swigregister(Linear)
7608 class LogNormalMover(MonteCarloMover):
7609  r"""Proxy of C++ IMP::core::LogNormalMover class."""
7610 
7611  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
7612 
7613  def __init__(self, *args):
7614  r"""
7615  __init__(LogNormalMover self, Model m, ParticleIndex pi, IMP::FloatKeys const & vars, double stddev) -> LogNormalMover
7616  __init__(LogNormalMover self, Model m, ParticleIndex pi, double stddev) -> LogNormalMover
7617  __init__(LogNormalMover self, IMP::ParticlesTemp const & sc, IMP::FloatKeys const & vars, IMP::Float sigma) -> LogNormalMover
7618  __init__(LogNormalMover self, IMP::ParticlesTemp const & sc, IMP::Float radius) -> LogNormalMover
7619  __init__(LogNormalMover self) -> LogNormalMover
7620  """
7621  _IMP_core.LogNormalMover_swiginit(self, _IMP_core.new_LogNormalMover(*args))
7622 
7623  def set_sigma(self, sigma):
7624  r"""set_sigma(LogNormalMover self, IMP::Float sigma)"""
7625  return _IMP_core.LogNormalMover_set_sigma(self, sigma)
7626 
7627  def get_sigma(self):
7628  r"""get_sigma(LogNormalMover self) -> IMP::Float"""
7629  return _IMP_core.LogNormalMover_get_sigma(self)
7630 
7631  def get_version_info(self):
7632  r"""get_version_info(LogNormalMover self) -> VersionInfo"""
7633  return _IMP_core.LogNormalMover_get_version_info(self)
7634  __swig_destroy__ = _IMP_core.delete_LogNormalMover
7635 
7636  def __str__(self):
7637  r"""__str__(LogNormalMover self) -> std::string"""
7638  return _IMP_core.LogNormalMover___str__(self)
7639 
7640  def __repr__(self):
7641  r"""__repr__(LogNormalMover self) -> std::string"""
7642  return _IMP_core.LogNormalMover___repr__(self)
7643 
7644  @staticmethod
7645  def get_from(o):
7646  return _object_cast_to_LogNormalMover(o)
7647 
7648 
7649  def _get_as_binary(self):
7650  r"""_get_as_binary(LogNormalMover self) -> PyObject *"""
7651  return _IMP_core.LogNormalMover__get_as_binary(self)
7652 
7653  def _set_from_binary(self, p):
7654  r"""_set_from_binary(LogNormalMover self, PyObject * p)"""
7655  return _IMP_core.LogNormalMover__set_from_binary(self, p)
7656 
7657  def __getstate__(self):
7658  p = self._get_as_binary()
7659  if len(self.__dict__) > 1:
7660  d = self.__dict__.copy()
7661  del d['this']
7662  p = (d, p)
7663  return p
7664 
7665  def __setstate__(self, p):
7666  if not hasattr(self, 'this'):
7667  self.__init__()
7668  if isinstance(p, tuple):
7669  d, p = p
7670  self.__dict__.update(d)
7671  return self._set_from_binary(p)
7672 
7673 
7674 # Register LogNormalMover in _IMP_core:
7675 _IMP_core.LogNormalMover_swigregister(LogNormalMover)
7676 IMP_CORE_HAS_MONTE_CARLO_MOVER = _IMP_core.IMP_CORE_HAS_MONTE_CARLO_MOVER
7677 
7678 class MonteCarlo(IMP.Optimizer):
7679  r"""Proxy of C++ IMP::core::MonteCarlo class."""
7680 
7681  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
7682 
7683  def __init__(self, *args):
7684  r"""
7685  __init__(MonteCarlo self, Model m) -> MonteCarlo
7686  __init__(MonteCarlo self) -> MonteCarlo
7687  """
7688  _IMP_core.MonteCarlo_swiginit(self, _IMP_core.new_MonteCarlo(*args))
7689 
7690  def get_version_info(self):
7691  r"""get_version_info(MonteCarlo self) -> VersionInfo"""
7692  return _IMP_core.MonteCarlo_get_version_info(self)
7693  __swig_destroy__ = _IMP_core.delete_MonteCarlo
7694 
7695  def set_return_best(self, tf):
7696  r"""set_return_best(MonteCarlo self, bool tf)"""
7697  return _IMP_core.MonteCarlo_set_return_best(self, tf)
7698 
7699  def get_return_best(self):
7700  r"""get_return_best(MonteCarlo self) -> bool"""
7701  return _IMP_core.MonteCarlo_get_return_best(self)
7702 
7703  def set_score_moved(self, mv):
7704  r"""set_score_moved(MonteCarlo self, bool mv)"""
7705  return _IMP_core.MonteCarlo_set_score_moved(self, mv)
7706 
7707  def set_kt(self, t):
7708  r"""set_kt(MonteCarlo self, IMP::Float t)"""
7709  return _IMP_core.MonteCarlo_set_kt(self, t)
7710 
7711  def get_kt(self):
7712  r"""get_kt(MonteCarlo self) -> IMP::Float"""
7713  return _IMP_core.MonteCarlo_get_kt(self)
7714 
7715  def get_last_accepted_energy(self):
7716  r"""get_last_accepted_energy(MonteCarlo self) -> double"""
7717  return _IMP_core.MonteCarlo_get_last_accepted_energy(self)
7718 
7719  def set_last_accepted_energy(self, energy):
7720  r"""set_last_accepted_energy(MonteCarlo self, double energy)"""
7721  return _IMP_core.MonteCarlo_set_last_accepted_energy(self, energy)
7722 
7723  def get_best_accepted_energy(self):
7724  r"""get_best_accepted_energy(MonteCarlo self) -> double"""
7725  return _IMP_core.MonteCarlo_get_best_accepted_energy(self)
7726 
7727  def set_best_accepted_energy(self, energy):
7728  r"""set_best_accepted_energy(MonteCarlo self, double energy)"""
7729  return _IMP_core.MonteCarlo_set_best_accepted_energy(self, energy)
7730 
7731  def get_number_of_downward_steps(self):
7732  r"""get_number_of_downward_steps(MonteCarlo self) -> unsigned int"""
7733  return _IMP_core.MonteCarlo_get_number_of_downward_steps(self)
7734 
7735  def get_number_of_upward_steps(self):
7736  r"""get_number_of_upward_steps(MonteCarlo self) -> unsigned int"""
7737  return _IMP_core.MonteCarlo_get_number_of_upward_steps(self)
7738 
7739  def get_number_of_proposed_steps(self):
7740  r"""get_number_of_proposed_steps(MonteCarlo self) -> unsigned int"""
7741  return _IMP_core.MonteCarlo_get_number_of_proposed_steps(self)
7742 
7743  def get_number_of_accepted_steps(self):
7744  r"""get_number_of_accepted_steps(MonteCarlo self) -> unsigned int"""
7745  return _IMP_core.MonteCarlo_get_number_of_accepted_steps(self)
7746 
7747  def set_number_of_downward_steps(self, nsteps):
7748  r"""set_number_of_downward_steps(MonteCarlo self, unsigned int nsteps)"""
7749  return _IMP_core.MonteCarlo_set_number_of_downward_steps(self, nsteps)
7750 
7751  def set_number_of_upward_steps(self, nsteps):
7752  r"""set_number_of_upward_steps(MonteCarlo self, unsigned int nsteps)"""
7753  return _IMP_core.MonteCarlo_set_number_of_upward_steps(self, nsteps)
7754 
7755  def set_number_of_rejected_steps(self, nsteps):
7756  r"""set_number_of_rejected_steps(MonteCarlo self, unsigned int nsteps)"""
7757  return _IMP_core.MonteCarlo_set_number_of_rejected_steps(self, nsteps)
7758 
7759  def reset_statistics(self):
7760  r"""reset_statistics(MonteCarlo self)"""
7761  return _IMP_core.MonteCarlo_reset_statistics(self)
7762 
7763  def set_score_threshold(self, s):
7764  r"""set_score_threshold(MonteCarlo self, double s)"""
7765  return _IMP_core.MonteCarlo_set_score_threshold(self, s)
7766 
7767  def get_score_threshold(self):
7768  r"""get_score_threshold(MonteCarlo self) -> double"""
7769  return _IMP_core.MonteCarlo_get_score_threshold(self)
7770 
7771  def set_maximum_difference(self, d):
7772  r"""set_maximum_difference(MonteCarlo self, double d)"""
7773  return _IMP_core.MonteCarlo_set_maximum_difference(self, d)
7774 
7775  def get_maximum_difference(self):
7776  r"""get_maximum_difference(MonteCarlo self) -> double"""
7777  return _IMP_core.MonteCarlo_get_maximum_difference(self)
7778  def __get_movers(self): return IMP._list_util.VarList(getdimfunc=self.get_number_of_movers, getfunc=self.get_mover, erasefunc=self.erase_mover, appendfunc=self.add_mover, extendfunc=self.add_movers, clearfunc=self.clear_movers, indexfunc=self._python_index_mover)
7779  def __set_movers(self, obj): IMP._list_util.set_varlist(self.movers, obj)
7780  def __del_movers(self): IMP._list_util.del_varlist(self.movers)
7781  movers = property(__get_movers, __set_movers, __del_movers, doc="List of ##ucnames")
7782 
7783  def remove_mover(self, d):
7784  r"""remove_mover(MonteCarlo self, MonteCarloMover d)"""
7785  return _IMP_core.MonteCarlo_remove_mover(self, d)
7786 
7787  def _python_index_mover(self, d, start, stop):
7788  r"""_python_index_mover(MonteCarlo self, MonteCarloMover d, unsigned int start, unsigned int stop) -> unsigned int"""
7789  return _IMP_core.MonteCarlo__python_index_mover(self, d, start, stop)
7790 
7791  def remove_movers(self, d):
7792  r"""remove_movers(MonteCarlo self, IMP::core::MonteCarloMovers const & d)"""
7793  return _IMP_core.MonteCarlo_remove_movers(self, d)
7794 
7795  def set_movers(self, ps):
7796  r"""set_movers(MonteCarlo self, IMP::core::MonteCarloMovers const & ps)"""
7797  return _IMP_core.MonteCarlo_set_movers(self, ps)
7798 
7799  def set_movers_order(self, objs):
7800  r"""set_movers_order(MonteCarlo self, IMP::core::MonteCarloMovers const & objs)"""
7801  return _IMP_core.MonteCarlo_set_movers_order(self, objs)
7802 
7803  def add_mover(self, obj):
7804  r"""add_mover(MonteCarlo self, MonteCarloMover obj) -> unsigned int"""
7805  return _IMP_core.MonteCarlo_add_mover(self, obj)
7806 
7807  def add_movers(self, objs):
7808  r"""add_movers(MonteCarlo self, IMP::core::MonteCarloMovers const & objs)"""
7809  return _IMP_core.MonteCarlo_add_movers(self, objs)
7810 
7811  def clear_movers(self):
7812  r"""clear_movers(MonteCarlo self)"""
7813  return _IMP_core.MonteCarlo_clear_movers(self)
7814 
7815  def get_number_of_movers(self):
7816  r"""get_number_of_movers(MonteCarlo self) -> unsigned int"""
7817  return _IMP_core.MonteCarlo_get_number_of_movers(self)
7818 
7819  def get_has_movers(self):
7820  r"""get_has_movers(MonteCarlo self) -> bool"""
7821  return _IMP_core.MonteCarlo_get_has_movers(self)
7822 
7823  def get_mover(self, i):
7824  r"""get_mover(MonteCarlo self, unsigned int i) -> MonteCarloMover"""
7825  return _IMP_core.MonteCarlo_get_mover(self, i)
7826 
7827  def get_movers(self):
7828  r"""get_movers(MonteCarlo self) -> IMP::core::MonteCarloMovers"""
7829  return _IMP_core.MonteCarlo_get_movers(self)
7830 
7831  def erase_mover(self, i):
7832  r"""erase_mover(MonteCarlo self, unsigned int i)"""
7833  return _IMP_core.MonteCarlo_erase_mover(self, i)
7834 
7835  def reserve_movers(self, sz):
7836  r"""reserve_movers(MonteCarlo self, unsigned int sz)"""
7837  return _IMP_core.MonteCarlo_reserve_movers(self, sz)
7838 
7839  def __str__(self):
7840  r"""__str__(MonteCarlo self) -> std::string"""
7841  return _IMP_core.MonteCarlo___str__(self)
7842 
7843  def __repr__(self):
7844  r"""__repr__(MonteCarlo self) -> std::string"""
7845  return _IMP_core.MonteCarlo___repr__(self)
7846 
7847  @staticmethod
7848  def get_from(o):
7849  return _object_cast_to_MonteCarlo(o)
7850 
7851 
7852  def _get_as_binary(self):
7853  r"""_get_as_binary(MonteCarlo self) -> PyObject *"""
7854  return _IMP_core.MonteCarlo__get_as_binary(self)
7855 
7856  def _set_from_binary(self, p):
7857  r"""_set_from_binary(MonteCarlo self, PyObject * p)"""
7858  return _IMP_core.MonteCarlo__set_from_binary(self, p)
7859 
7860  def __getstate__(self):
7861  p = self._get_as_binary()
7862  if len(self.__dict__) > 1:
7863  d = self.__dict__.copy()
7864  del d['this']
7865  p = (d, p)
7866  return p
7867 
7868  def __setstate__(self, p):
7869  if not hasattr(self, 'this'):
7870  self.__init__()
7871  if isinstance(p, tuple):
7872  d, p = p
7873  self.__dict__.update(d)
7874  return self._set_from_binary(p)
7875 
7876 
7877  def _get_jax(self):
7878  from IMP.core._jax_util import _MCJAXInfo
7879  return _MCJAXInfo(self)
7880 
7881  def _get_jax_optimizer(self, max_steps):
7882  import IMP.core._jax_util
7883  return IMP.core._jax_util._MCJAXOptimizer(self, max_steps)
7884 
7885  def _optimize_jax(self, max_steps):
7886  opt = self._get_jax_optimizer(max_steps)
7887  score, mc_state = opt.optimize(opt.get_initial_state())
7888  return score
7889 
7890 
7891 # Register MonteCarlo in _IMP_core:
7892 _IMP_core.MonteCarlo_swigregister(MonteCarlo)
7893 class MonteCarloWithLocalOptimization(MonteCarlo):
7894  r"""Proxy of C++ IMP::core::MonteCarloWithLocalOptimization class."""
7895 
7896  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
7897 
7898  def __init__(self, opt, steps):
7899  r"""__init__(MonteCarloWithLocalOptimization self, Optimizer opt, unsigned int steps) -> MonteCarloWithLocalOptimization"""
7900  _IMP_core.MonteCarloWithLocalOptimization_swiginit(self, _IMP_core.new_MonteCarloWithLocalOptimization(opt, steps))
7901 
7902  def get_number_of_steps(self):
7903  r"""get_number_of_steps(MonteCarloWithLocalOptimization self) -> unsigned int"""
7904  return _IMP_core.MonteCarloWithLocalOptimization_get_number_of_steps(self)
7905 
7906  def get_local_optimizer(self):
7907  r"""get_local_optimizer(MonteCarloWithLocalOptimization self) -> Optimizer"""
7908  return _IMP_core.MonteCarloWithLocalOptimization_get_local_optimizer(self)
7909  __swig_destroy__ = _IMP_core.delete_MonteCarloWithLocalOptimization
7910 
7911  def __str__(self):
7912  r"""__str__(MonteCarloWithLocalOptimization self) -> std::string"""
7913  return _IMP_core.MonteCarloWithLocalOptimization___str__(self)
7914 
7915  def __repr__(self):
7916  r"""__repr__(MonteCarloWithLocalOptimization self) -> std::string"""
7917  return _IMP_core.MonteCarloWithLocalOptimization___repr__(self)
7918 
7919  @staticmethod
7920  def get_from(o):
7921  return _object_cast_to_MonteCarloWithLocalOptimization(o)
7922 
7923 
7924 # Register MonteCarloWithLocalOptimization in _IMP_core:
7925 _IMP_core.MonteCarloWithLocalOptimization_swigregister(MonteCarloWithLocalOptimization)
7926 class MonteCarloWithBasinHopping(MonteCarloWithLocalOptimization):
7927  r"""Proxy of C++ IMP::core::MonteCarloWithBasinHopping class."""
7928 
7929  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
7930 
7931  def __init__(self, opt, ns):
7932  r"""__init__(MonteCarloWithBasinHopping self, Optimizer opt, unsigned int ns) -> MonteCarloWithBasinHopping"""
7933  _IMP_core.MonteCarloWithBasinHopping_swiginit(self, _IMP_core.new_MonteCarloWithBasinHopping(opt, ns))
7934  __swig_destroy__ = _IMP_core.delete_MonteCarloWithBasinHopping
7935 
7936  def __str__(self):
7937  r"""__str__(MonteCarloWithBasinHopping self) -> std::string"""
7938  return _IMP_core.MonteCarloWithBasinHopping___str__(self)
7939 
7940  def __repr__(self):
7941  r"""__repr__(MonteCarloWithBasinHopping self) -> std::string"""
7942  return _IMP_core.MonteCarloWithBasinHopping___repr__(self)
7943 
7944  @staticmethod
7945  def get_from(o):
7946  return _object_cast_to_MonteCarloWithBasinHopping(o)
7947 
7948 
7949 # Register MonteCarloWithBasinHopping in _IMP_core:
7950 _IMP_core.MonteCarloWithBasinHopping_swigregister(MonteCarloWithBasinHopping)
7951 class NeighborsTable(IMP.ScoreState):
7952  r"""Proxy of C++ IMP::core::NeighborsTable class."""
7953 
7954  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
7955 
7956  def __init__(self, *args):
7957  r"""__init__(NeighborsTable self, PairContainer input, std::string name="CloseNeighborsTable%1%") -> NeighborsTable"""
7958  _IMP_core.NeighborsTable_swiginit(self, _IMP_core.new_NeighborsTable(*args))
7959 
7960  def get_neighbors(self, pi):
7961  r"""get_neighbors(NeighborsTable self, ParticleIndex pi) -> IMP::ParticleIndexes const &"""
7962  return _IMP_core.NeighborsTable_get_neighbors(self, pi)
7963 
7964  def get_version_info(self):
7965  r"""get_version_info(NeighborsTable self) -> VersionInfo"""
7966  return _IMP_core.NeighborsTable_get_version_info(self)
7967  __swig_destroy__ = _IMP_core.delete_NeighborsTable
7968 
7969  def __str__(self):
7970  r"""__str__(NeighborsTable self) -> std::string"""
7971  return _IMP_core.NeighborsTable___str__(self)
7972 
7973  def __repr__(self):
7974  r"""__repr__(NeighborsTable self) -> std::string"""
7975  return _IMP_core.NeighborsTable___repr__(self)
7976 
7977  @staticmethod
7978  def get_from(o):
7979  return _object_cast_to_NeighborsTable(o)
7980 
7981 
7982 # Register NeighborsTable in _IMP_core:
7983 _IMP_core.NeighborsTable_swigregister(NeighborsTable)
7984 class NormalMover(MonteCarloMover):
7985  r"""Proxy of C++ IMP::core::NormalMover class."""
7986 
7987  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
7988 
7989  def __init__(self, *args):
7990  r"""
7991  __init__(NormalMover self, Model m, ParticleIndex pi, IMP::FloatKeys const & vars, double stddev) -> NormalMover
7992  __init__(NormalMover self, Model m, ParticleIndex pi, double stddev) -> NormalMover
7993  __init__(NormalMover self, IMP::ParticlesTemp const & sc, IMP::FloatKeys const & vars, IMP::Float sigma) -> NormalMover
7994  __init__(NormalMover self, IMP::ParticlesTemp const & sc, IMP::Float radius) -> NormalMover
7995  __init__(NormalMover self) -> NormalMover
7996  """
7997  _IMP_core.NormalMover_swiginit(self, _IMP_core.new_NormalMover(*args))
7998 
7999  def set_sigma(self, sigma):
8000  r"""set_sigma(NormalMover self, IMP::Float sigma)"""
8001  return _IMP_core.NormalMover_set_sigma(self, sigma)
8002 
8003  def get_sigma(self):
8004  r"""get_sigma(NormalMover self) -> IMP::Float"""
8005  return _IMP_core.NormalMover_get_sigma(self)
8006 
8007  def get_version_info(self):
8008  r"""get_version_info(NormalMover self) -> VersionInfo"""
8009  return _IMP_core.NormalMover_get_version_info(self)
8010  __swig_destroy__ = _IMP_core.delete_NormalMover
8011 
8012  def __str__(self):
8013  r"""__str__(NormalMover self) -> std::string"""
8014  return _IMP_core.NormalMover___str__(self)
8015 
8016  def __repr__(self):
8017  r"""__repr__(NormalMover self) -> std::string"""
8018  return _IMP_core.NormalMover___repr__(self)
8019 
8020  @staticmethod
8021  def get_from(o):
8022  return _object_cast_to_NormalMover(o)
8023 
8024 
8025  def _get_as_binary(self):
8026  r"""_get_as_binary(NormalMover self) -> PyObject *"""
8027  return _IMP_core.NormalMover__get_as_binary(self)
8028 
8029  def _set_from_binary(self, p):
8030  r"""_set_from_binary(NormalMover self, PyObject * p)"""
8031  return _IMP_core.NormalMover__set_from_binary(self, p)
8032 
8033  def __getstate__(self):
8034  p = self._get_as_binary()
8035  if len(self.__dict__) > 1:
8036  d = self.__dict__.copy()
8037  del d['this']
8038  p = (d, p)
8039  return p
8040 
8041  def __setstate__(self, p):
8042  if not hasattr(self, 'this'):
8043  self.__init__()
8044  if isinstance(p, tuple):
8045  d, p = p
8046  self.__dict__.update(d)
8047  return self._set_from_binary(p)
8048 
8049 
8050 # Register NormalMover in _IMP_core:
8051 _IMP_core.NormalMover_swigregister(NormalMover)
8052 class OpenCubicSpline(_OpenCubicSplineBase):
8053  r"""Proxy of C++ IMP::core::OpenCubicSpline class."""
8054 
8055  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
8056 
8057  def __init__(self, values, minrange, spacing, extend=False):
8058  r"""__init__(OpenCubicSpline self, IMP::Floats const & values, IMP::Float minrange, IMP::Float spacing, bool extend=False) -> OpenCubicSpline"""
8059  _IMP_core.OpenCubicSpline_swiginit(self, _IMP_core.new_OpenCubicSpline(values, minrange, spacing, extend))
8060 
8061  def get_minrange(self):
8062  r"""get_minrange(OpenCubicSpline self) -> IMP::Float"""
8063  return _IMP_core.OpenCubicSpline_get_minrange(self)
8064 
8065  def get_spacing(self):
8066  r"""get_spacing(OpenCubicSpline self) -> IMP::Float"""
8067  return _IMP_core.OpenCubicSpline_get_spacing(self)
8068 
8069  def get_values(self):
8070  r"""get_values(OpenCubicSpline self) -> IMP::Floats"""
8071  return _IMP_core.OpenCubicSpline_get_values(self)
8072 
8073  def get_extend(self):
8074  r"""get_extend(OpenCubicSpline self) -> bool"""
8075  return _IMP_core.OpenCubicSpline_get_extend(self)
8076 
8077  def get_second_derivatives(self):
8078  r"""get_second_derivatives(OpenCubicSpline self) -> IMP::Floats"""
8079  return _IMP_core.OpenCubicSpline_get_second_derivatives(self)
8080 
8081  def __str__(self):
8082  r"""__str__(OpenCubicSpline self) -> std::string"""
8083  return _IMP_core.OpenCubicSpline___str__(self)
8084 
8085  def __repr__(self):
8086  r"""__repr__(OpenCubicSpline self) -> std::string"""
8087  return _IMP_core.OpenCubicSpline___repr__(self)
8088 
8089  @staticmethod
8090  def get_from(o):
8091  return _object_cast_to_OpenCubicSpline(o)
8092 
8093 
8094  def _get_jax(self):
8095  import jax.numpy as jnp
8096  from IMP.core._jax_util import _spline
8097  def score(feature, minrange, maxrange, spacing, values, second_derivs):
8098  # clip feature to range (extend=True behavior)
8099  feature = jnp.clip(feature, minrange, maxrange)
8100  # determine bin index and thus the cubic fragment to use:
8101  lowbin = jnp.array((feature - minrange) / spacing, dtype=int)
8102  return _spline(feature, minrange, lowbin, lowbin + 1, spacing,
8103  values, second_derivs)
8104  spacing = self.get_spacing()
8105  minrange = self.get_minrange()
8106  values = jnp.asarray(self.get_values())
8107  maxrange = minrange + spacing * (len(values) - 1)
8108  return functools.partial(
8109  score, minrange=minrange, maxrange=maxrange,
8110  spacing=spacing, values=values,
8111  second_derivs=jnp.asarray(self.get_second_derivatives()))
8112 
8113  __swig_destroy__ = _IMP_core.delete_OpenCubicSpline
8114 
8115 # Register OpenCubicSpline in _IMP_core:
8116 _IMP_core.OpenCubicSpline_swigregister(OpenCubicSpline)
8117 class QuadraticClosePairsFinder(ClosePairsFinder):
8118  r"""Proxy of C++ IMP::core::QuadraticClosePairsFinder class."""
8119 
8120  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
8121 
8122  def __init__(self):
8123  r"""__init__(QuadraticClosePairsFinder self) -> QuadraticClosePairsFinder"""
8124  _IMP_core.QuadraticClosePairsFinder_swiginit(self, _IMP_core.new_QuadraticClosePairsFinder())
8125 
8126  def get_are_close_and_filtered(self, *args):
8127  r"""
8128  get_are_close_and_filtered(QuadraticClosePairsFinder self, Particle a, Particle b) -> bool
8129  get_are_close_and_filtered(QuadraticClosePairsFinder self, Model m, ParticleIndex a, ParticleIndex b) -> bool
8130  """
8131  return _IMP_core.QuadraticClosePairsFinder_get_are_close_and_filtered(self, *args)
8132 
8133  def get_close_pairs(self, *args):
8134  r"""
8135  get_close_pairs(QuadraticClosePairsFinder self, IMP::algebra::BoundingBox3Ds const & bbs) -> IMP::IntPairs
8136  get_close_pairs(QuadraticClosePairsFinder self, IMP::algebra::BoundingBox3Ds const & bas, IMP::algebra::BoundingBox3Ds const & bbs) -> IMP::IntPairs
8137  get_close_pairs(QuadraticClosePairsFinder self, Model m, IMP::ParticleIndexes const & pc) -> IMP::ParticleIndexPairs
8138  get_close_pairs(QuadraticClosePairsFinder self, Model m, IMP::ParticleIndexes const & pca, IMP::ParticleIndexes const & pcb) -> IMP::ParticleIndexPairs
8139  """
8140  return _IMP_core.QuadraticClosePairsFinder_get_close_pairs(self, *args)
8141 
8142  def do_get_inputs(self, m, pis):
8143  r"""do_get_inputs(QuadraticClosePairsFinder self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
8144  return _IMP_core.QuadraticClosePairsFinder_do_get_inputs(self, m, pis)
8145 
8146  def get_version_info(self):
8147  r"""get_version_info(QuadraticClosePairsFinder self) -> VersionInfo"""
8148  return _IMP_core.QuadraticClosePairsFinder_get_version_info(self)
8149  __swig_destroy__ = _IMP_core.delete_QuadraticClosePairsFinder
8150 
8151  def __str__(self):
8152  r"""__str__(QuadraticClosePairsFinder self) -> std::string"""
8153  return _IMP_core.QuadraticClosePairsFinder___str__(self)
8154 
8155  def __repr__(self):
8156  r"""__repr__(QuadraticClosePairsFinder self) -> std::string"""
8157  return _IMP_core.QuadraticClosePairsFinder___repr__(self)
8158 
8159  @staticmethod
8160  def get_from(o):
8161  return _object_cast_to_QuadraticClosePairsFinder(o)
8162 
8163 
8164 # Register QuadraticClosePairsFinder in _IMP_core:
8165 _IMP_core.QuadraticClosePairsFinder_swigregister(QuadraticClosePairsFinder)
8166 class RefinedPairsPairScore(IMP.PairScore):
8167  r"""Proxy of C++ IMP::core::RefinedPairsPairScore class."""
8168 
8169  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
8170 
8171  def __init__(self, r, f):
8172  r"""__init__(RefinedPairsPairScore self, Refiner r, PairScore f) -> RefinedPairsPairScore"""
8173  _IMP_core.RefinedPairsPairScore_swiginit(self, _IMP_core.new_RefinedPairsPairScore(r, f))
8174 
8175  def do_get_inputs(self, m, pis):
8176  r"""do_get_inputs(RefinedPairsPairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
8177  return _IMP_core.RefinedPairsPairScore_do_get_inputs(self, m, pis)
8178 
8179  def evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked=False):
8180  r"""evaluate_indexes(RefinedPairsPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
8181  return _IMP_core.RefinedPairsPairScore_evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked)
8182 
8183  def evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked=False):
8184  r"""evaluate_indexes_scores(RefinedPairsPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
8185  return _IMP_core.RefinedPairsPairScore_evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked)
8186 
8187  def evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked=False):
8188  r"""evaluate_indexes_delta(RefinedPairsPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, std::vector< unsigned int,std::allocator< unsigned int > > const & indexes, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
8189  return _IMP_core.RefinedPairsPairScore_evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked)
8190 
8191  def evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked=False):
8192  r"""evaluate_if_good_indexes(RefinedPairsPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, double max, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
8193  return _IMP_core.RefinedPairsPairScore_evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked)
8194 
8195  def get_version_info(self):
8196  r"""get_version_info(RefinedPairsPairScore self) -> VersionInfo"""
8197  return _IMP_core.RefinedPairsPairScore_get_version_info(self)
8198  __swig_destroy__ = _IMP_core.delete_RefinedPairsPairScore
8199 
8200  def __str__(self):
8201  r"""__str__(RefinedPairsPairScore self) -> std::string"""
8202  return _IMP_core.RefinedPairsPairScore___str__(self)
8203 
8204  def __repr__(self):
8205  r"""__repr__(RefinedPairsPairScore self) -> std::string"""
8206  return _IMP_core.RefinedPairsPairScore___repr__(self)
8207 
8208  @staticmethod
8209  def get_from(o):
8210  return _object_cast_to_RefinedPairsPairScore(o)
8211 
8212 
8213 # Register RefinedPairsPairScore in _IMP_core:
8214 _IMP_core.RefinedPairsPairScore_swigregister(RefinedPairsPairScore)
8215 class RigidBody(XYZ):
8216  r"""Proxy of C++ IMP::core::RigidBody class."""
8217 
8218  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
8219 
8220  def get_rigid_members(self):
8221  r"""get_rigid_members(RigidBody self) -> IMP::core::RigidMembers"""
8222  return _IMP_core.RigidBody_get_rigid_members(self)
8223 
8224  @staticmethod
8225  def get_rotation_key():
8226  r"""get_rotation_key() -> Vector4DDerivKey"""
8227  return _IMP_core.RigidBody_get_rotation_key()
8228 
8229  def get_member_particle_indexes(self):
8230  r"""get_member_particle_indexes(RigidBody self) -> IMP::ParticleIndexes const &"""
8231  return _IMP_core.RigidBody_get_member_particle_indexes(self)
8232 
8233  def get_body_member_particle_indexes(self):
8234  r"""get_body_member_particle_indexes(RigidBody self) -> IMP::ParticleIndexes const &"""
8235  return _IMP_core.RigidBody_get_body_member_particle_indexes(self)
8236 
8237  def get_member_indexes(self):
8238  r"""get_member_indexes(RigidBody self) -> IMP::ParticleIndexes"""
8239  return _IMP_core.RigidBody_get_member_indexes(self)
8240 
8241  def show(self, *args):
8242  r"""show(RigidBody self, _ostream out=std::cout)"""
8243  return _IMP_core.RigidBody_show(self, *args)
8244 
8245  @staticmethod
8246  def setup_particle(*args):
8247  r"""
8248  setup_particle(Model m, ParticleIndex pi, _ParticleIndexesAdaptor ps) -> RigidBody
8249  setup_particle(_ParticleAdaptor pa, _ParticleIndexesAdaptor ps) -> RigidBody
8250  setup_particle(Model m, ParticleIndex pi, ReferenceFrame3D rf) -> RigidBody
8251  setup_particle(_ParticleAdaptor pa, ReferenceFrame3D rf) -> RigidBody
8252  """
8253  return _IMP_core.RigidBody_setup_particle(*args)
8254 
8255  @staticmethod
8256  def teardown_particle(rb):
8257  r"""teardown_particle(RigidBody rb)"""
8258  return _IMP_core.RigidBody_teardown_particle(rb)
8259 
8260  def __init__(self, *args):
8261  r"""
8262  __init__(RigidBody self) -> RigidBody
8263  __init__(RigidBody self, Model m, ParticleIndex id) -> RigidBody
8264  __init__(RigidBody self, _ParticleAdaptor d) -> RigidBody
8265  __init__(RigidBody self, RigidBody arg2) -> RigidBody
8266  """
8267  _IMP_core.RigidBody_swiginit(self, _IMP_core.new_RigidBody(*args))
8268  __swig_destroy__ = _IMP_core.delete_RigidBody
8269 
8270  @staticmethod
8271  def get_is_setup(*args):
8272  r"""
8273  get_is_setup(_ParticleAdaptor p) -> bool
8274  get_is_setup(Model m, ParticleIndex pi) -> bool
8275  """
8276  return _IMP_core.RigidBody_get_is_setup(*args)
8277 
8278  def get_coordinates(self):
8279  r"""get_coordinates(RigidBody self) -> Vector3D"""
8280  return _IMP_core.RigidBody_get_coordinates(self)
8281 
8282  def get_rotation(self):
8283  r"""get_rotation(RigidBody self) -> Rotation3D"""
8284  return _IMP_core.RigidBody_get_rotation(self)
8285 
8286  def get_reference_frame(self):
8287  r"""get_reference_frame(RigidBody self) -> ReferenceFrame3D"""
8288  return _IMP_core.RigidBody_get_reference_frame(self)
8289 
8290  def set_reference_frame(self, tr):
8291  r"""set_reference_frame(RigidBody self, ReferenceFrame3D tr)"""
8292  return _IMP_core.RigidBody_set_reference_frame(self, tr)
8293 
8294  def set_reference_frame_lazy(self, tr):
8295  r"""set_reference_frame_lazy(RigidBody self, ReferenceFrame3D tr)"""
8296  return _IMP_core.RigidBody_set_reference_frame_lazy(self, tr)
8297 
8298  def set_reference_frame_from_members(self, members):
8299  r"""set_reference_frame_from_members(RigidBody self, IMP::ParticleIndexes const & members)"""
8300  return _IMP_core.RigidBody_set_reference_frame_from_members(self, members)
8301 
8302  def pull_back_members_adjoints(self, da):
8303  r"""pull_back_members_adjoints(RigidBody self, DerivativeAccumulator da)"""
8304  return _IMP_core.RigidBody_pull_back_members_adjoints(self, da)
8305 
8306  def pull_back_member_adjoints(self, pi, da):
8307  r"""pull_back_member_adjoints(RigidBody self, ParticleIndex pi, DerivativeAccumulator da)"""
8308  return _IMP_core.RigidBody_pull_back_member_adjoints(self, pi, da)
8309 
8310  def pull_back_body_member_adjoints(self, pi, da):
8311  r"""pull_back_body_member_adjoints(RigidBody self, ParticleIndex pi, DerivativeAccumulator da)"""
8312  return _IMP_core.RigidBody_pull_back_body_member_adjoints(self, pi, da)
8313 
8314  def add_to_rotational_derivatives(self, qderiv, da):
8315  r"""add_to_rotational_derivatives(RigidBody self, Vector4D qderiv, DerivativeAccumulator da)"""
8316  return _IMP_core.RigidBody_add_to_rotational_derivatives(self, qderiv, da)
8317 
8318  def add_to_torque(self, torque_local, da):
8319  r"""add_to_torque(RigidBody self, Vector3D torque_local, DerivativeAccumulator da)"""
8320  return _IMP_core.RigidBody_add_to_torque(self, torque_local, da)
8321 
8322  def get_torque(self):
8323  r"""get_torque(RigidBody self) -> Vector3D"""
8324  return _IMP_core.RigidBody_get_torque(self)
8325 
8326  def get_coordinates_are_optimized(self):
8327  r"""get_coordinates_are_optimized(RigidBody self) -> bool"""
8328  return _IMP_core.RigidBody_get_coordinates_are_optimized(self)
8329 
8330  def set_coordinates_are_optimized(self, tf):
8331  r"""set_coordinates_are_optimized(RigidBody self, bool tf)"""
8332  return _IMP_core.RigidBody_set_coordinates_are_optimized(self, tf)
8333 
8334  def normalize_rotation(self):
8335  r"""normalize_rotation(RigidBody self)"""
8336  return _IMP_core.RigidBody_normalize_rotation(self)
8337 
8338  def update_members(self):
8339  r"""update_members(RigidBody self)"""
8340  return _IMP_core.RigidBody_update_members(self)
8341 
8342  def get_rotational_derivatives(self):
8343  r"""get_rotational_derivatives(RigidBody self) -> Vector4D"""
8344  return _IMP_core.RigidBody_get_rotational_derivatives(self)
8345 
8346  def get_number_of_members(self):
8347  r"""get_number_of_members(RigidBody self) -> unsigned int"""
8348  return _IMP_core.RigidBody_get_number_of_members(self)
8349 
8350  def get_member(self, i):
8351  r"""get_member(RigidBody self, unsigned int i) -> RigidBodyMember"""
8352  return _IMP_core.RigidBody_get_member(self, i)
8353 
8354  def add_member(self, p):
8355  r"""add_member(RigidBody self, _ParticleIndexAdaptor p)"""
8356  return _IMP_core.RigidBody_add_member(self, p)
8357 
8358  def add_non_rigid_member(self, p):
8359  r"""add_non_rigid_member(RigidBody self, _ParticleIndexAdaptor p)"""
8360  return _IMP_core.RigidBody_add_non_rigid_member(self, p)
8361 
8362  def set_is_rigid_member(self, pi, tf):
8363  r"""set_is_rigid_member(RigidBody self, ParticleIndex pi, bool tf)"""
8364  return _IMP_core.RigidBody_set_is_rigid_member(self, pi, tf)
8365 
8366  def remove_member(self, p):
8367  r"""remove_member(RigidBody self, _ParticleIndexAdaptor p)"""
8368  return _IMP_core.RigidBody_remove_member(self, p)
8369 
8370  def add_attribute(self, *args):
8371  r"""
8372  add_attribute(RigidBody self, FloatKey k, IMP::Float v, bool opt)
8373  add_attribute(RigidBody self, FloatKey a0, IMP::Float a1)
8374  add_attribute(RigidBody self, IntKey a0, IMP::Int a1)
8375  add_attribute(RigidBody self, FloatsKey a0, IMP::Floats a1)
8376  add_attribute(RigidBody self, IntsKey a0, IMP::Ints a1)
8377  add_attribute(RigidBody self, StringKey a0, IMP::String a1)
8378  add_attribute(RigidBody self, ParticleIndexKey a0, Particle a1)
8379  add_attribute(RigidBody self, ObjectKey a0, Object a1)
8380  add_attribute(RigidBody self, SparseFloatKey a0, IMP::Float a1)
8381  add_attribute(RigidBody self, SparseIntKey a0, IMP::Int a1)
8382  add_attribute(RigidBody self, SparseStringKey a0, IMP::String a1)
8383  add_attribute(RigidBody self, SparseParticleIndexKey a0, ParticleIndex a1)
8384  """
8385  return _IMP_core.RigidBody_add_attribute(self, *args)
8386 
8387  def get_value(self, *args):
8388  r"""
8389  get_value(RigidBody self, FloatKey a0) -> IMP::Float
8390  get_value(RigidBody self, IntKey a0) -> IMP::Int
8391  get_value(RigidBody self, FloatsKey a0) -> IMP::Floats
8392  get_value(RigidBody self, IntsKey a0) -> IMP::Ints
8393  get_value(RigidBody self, StringKey a0) -> IMP::String
8394  get_value(RigidBody self, ParticleIndexKey a0) -> Particle
8395  get_value(RigidBody self, ObjectKey a0) -> Object
8396  get_value(RigidBody self, SparseFloatKey a0) -> IMP::Float
8397  get_value(RigidBody self, SparseIntKey a0) -> IMP::Int
8398  get_value(RigidBody self, SparseStringKey a0) -> IMP::String
8399  get_value(RigidBody self, SparseParticleIndexKey a0) -> ParticleIndex
8400  """
8401  return _IMP_core.RigidBody_get_value(self, *args)
8402 
8403  def set_value(self, *args):
8404  r"""
8405  set_value(RigidBody self, FloatKey a0, IMP::Float a1)
8406  set_value(RigidBody self, IntKey a0, IMP::Int a1)
8407  set_value(RigidBody self, FloatsKey a0, IMP::Floats a1)
8408  set_value(RigidBody self, IntsKey a0, IMP::Ints a1)
8409  set_value(RigidBody self, StringKey a0, IMP::String a1)
8410  set_value(RigidBody self, ParticleIndexKey a0, Particle a1)
8411  set_value(RigidBody self, ObjectKey a0, Object a1)
8412  set_value(RigidBody self, SparseFloatKey a0, IMP::Float a1)
8413  set_value(RigidBody self, SparseIntKey a0, IMP::Int a1)
8414  set_value(RigidBody self, SparseStringKey a0, IMP::String a1)
8415  set_value(RigidBody self, SparseParticleIndexKey a0, ParticleIndex a1)
8416  """
8417  return _IMP_core.RigidBody_set_value(self, *args)
8418 
8419  def remove_attribute(self, *args):
8420  r"""
8421  remove_attribute(RigidBody self, FloatKey a0)
8422  remove_attribute(RigidBody self, IntKey a0)
8423  remove_attribute(RigidBody self, FloatsKey a0)
8424  remove_attribute(RigidBody self, IntsKey a0)
8425  remove_attribute(RigidBody self, StringKey a0)
8426  remove_attribute(RigidBody self, ParticleIndexKey a0)
8427  remove_attribute(RigidBody self, ObjectKey a0)
8428  remove_attribute(RigidBody self, SparseFloatKey a0)
8429  remove_attribute(RigidBody self, SparseIntKey a0)
8430  remove_attribute(RigidBody self, SparseStringKey a0)
8431  remove_attribute(RigidBody self, SparseParticleIndexKey a0)
8432  """
8433  return _IMP_core.RigidBody_remove_attribute(self, *args)
8434 
8435  def has_attribute(self, *args):
8436  r"""
8437  has_attribute(RigidBody self, FloatKey a0) -> bool
8438  has_attribute(RigidBody self, IntKey a0) -> bool
8439  has_attribute(RigidBody self, FloatsKey a0) -> bool
8440  has_attribute(RigidBody self, IntsKey a0) -> bool
8441  has_attribute(RigidBody self, StringKey a0) -> bool
8442  has_attribute(RigidBody self, ParticleIndexKey a0) -> bool
8443  has_attribute(RigidBody self, ObjectKey a0) -> bool
8444  has_attribute(RigidBody self, SparseFloatKey a0) -> bool
8445  has_attribute(RigidBody self, SparseIntKey a0) -> bool
8446  has_attribute(RigidBody self, SparseStringKey a0) -> bool
8447  has_attribute(RigidBody self, SparseParticleIndexKey a0) -> bool
8448  """
8449  return _IMP_core.RigidBody_has_attribute(self, *args)
8450 
8451  def get_derivative(self, a0):
8452  r"""get_derivative(RigidBody self, FloatKey a0) -> double"""
8453  return _IMP_core.RigidBody_get_derivative(self, a0)
8454 
8455  def get_name(self):
8456  r"""get_name(RigidBody self) -> std::string"""
8457  return _IMP_core.RigidBody_get_name(self)
8458 
8459  def clear_caches(self):
8460  r"""clear_caches(RigidBody self)"""
8461  return _IMP_core.RigidBody_clear_caches(self)
8462 
8463  def set_name(self, a0):
8464  r"""set_name(RigidBody self, std::string a0)"""
8465  return _IMP_core.RigidBody_set_name(self, a0)
8466 
8467  def set_check_level(self, a0):
8468  r"""set_check_level(RigidBody self, IMP::CheckLevel a0)"""
8469  return _IMP_core.RigidBody_set_check_level(self, a0)
8470 
8471  def add_to_derivative(self, a0, a1, a2):
8472  r"""add_to_derivative(RigidBody self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
8473  return _IMP_core.RigidBody_add_to_derivative(self, a0, a1, a2)
8474 
8475  def set_is_optimized(self, a0, a1):
8476  r"""set_is_optimized(RigidBody self, FloatKey a0, bool a1)"""
8477  return _IMP_core.RigidBody_set_is_optimized(self, a0, a1)
8478 
8479  def get_is_optimized(self, a0):
8480  r"""get_is_optimized(RigidBody self, FloatKey a0) -> bool"""
8481  return _IMP_core.RigidBody_get_is_optimized(self, a0)
8482 
8483  def get_check_level(self):
8484  r"""get_check_level(RigidBody self) -> IMP::CheckLevel"""
8485  return _IMP_core.RigidBody_get_check_level(self)
8486 
8487  def __eq__(self, *args):
8488  r"""
8489  __eq__(RigidBody self, RigidBody o) -> bool
8490  __eq__(RigidBody self, Particle d) -> bool
8491  """
8492  return _IMP_core.RigidBody___eq__(self, *args)
8493 
8494  def __ne__(self, *args):
8495  r"""
8496  __ne__(RigidBody self, RigidBody o) -> bool
8497  __ne__(RigidBody self, Particle d) -> bool
8498  """
8499  return _IMP_core.RigidBody___ne__(self, *args)
8500 
8501  def __le__(self, *args):
8502  r"""
8503  __le__(RigidBody self, RigidBody o) -> bool
8504  __le__(RigidBody self, Particle d) -> bool
8505  """
8506  return _IMP_core.RigidBody___le__(self, *args)
8507 
8508  def __lt__(self, *args):
8509  r"""
8510  __lt__(RigidBody self, RigidBody o) -> bool
8511  __lt__(RigidBody self, Particle d) -> bool
8512  """
8513  return _IMP_core.RigidBody___lt__(self, *args)
8514 
8515  def __ge__(self, *args):
8516  r"""
8517  __ge__(RigidBody self, RigidBody o) -> bool
8518  __ge__(RigidBody self, Particle d) -> bool
8519  """
8520  return _IMP_core.RigidBody___ge__(self, *args)
8521 
8522  def __gt__(self, *args):
8523  r"""
8524  __gt__(RigidBody self, RigidBody o) -> bool
8525  __gt__(RigidBody self, Particle d) -> bool
8526  """
8527  return _IMP_core.RigidBody___gt__(self, *args)
8528 
8529  def __hash__(self):
8530  r"""__hash__(RigidBody self) -> std::size_t"""
8531  return _IMP_core.RigidBody___hash__(self)
8532 
8533  def __str__(self):
8534  r"""__str__(RigidBody self) -> std::string"""
8535  return _IMP_core.RigidBody___str__(self)
8536 
8537  def __repr__(self):
8538  r"""__repr__(RigidBody self) -> std::string"""
8539  return _IMP_core.RigidBody___repr__(self)
8540 
8541  def _get_as_binary(self):
8542  r"""_get_as_binary(RigidBody self) -> PyObject *"""
8543  return _IMP_core.RigidBody__get_as_binary(self)
8544 
8545  def _set_from_binary(self, p):
8546  r"""_set_from_binary(RigidBody self, PyObject * p)"""
8547  return _IMP_core.RigidBody__set_from_binary(self, p)
8548 
8549  def __getstate__(self):
8550  p = self._get_as_binary()
8551  if len(self.__dict__) > 1:
8552  d = self.__dict__.copy()
8553  del d['this']
8554  p = (d, p)
8555  return p
8556 
8557  def __setstate__(self, p):
8558  if not hasattr(self, 'this'):
8559  self.__init__()
8560  if isinstance(p, tuple):
8561  d, p = p
8562  self.__dict__.update(d)
8563  return self._set_from_binary(p)
8564 
8565 
8566 # Register RigidBody in _IMP_core:
8567 _IMP_core.RigidBody_swigregister(RigidBody)
8568 
8570  r"""add_rigid_body_cache_key(ObjectKey k)"""
8571  return _IMP_core.add_rigid_body_cache_key(k)
8572 class RigidBodyMember(XYZ):
8573  r"""Proxy of C++ IMP::core::RigidBodyMember class."""
8574 
8575  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
8576 
8577  def show(self, *args):
8578  r"""show(RigidBodyMember self, _ostream out=std::cout)"""
8579  return _IMP_core.RigidBodyMember_show(self, *args)
8580 
8581  def get_rigid_body(self):
8582  r"""get_rigid_body(RigidBodyMember self) -> RigidBody"""
8583  return _IMP_core.RigidBodyMember_get_rigid_body(self)
8584 
8585  def get_internal_coordinates(self):
8586  r"""get_internal_coordinates(RigidBodyMember self) -> Vector3D"""
8587  return _IMP_core.RigidBodyMember_get_internal_coordinates(self)
8588 
8589  def set_internal_coordinates(self, v):
8590  r"""set_internal_coordinates(RigidBodyMember self, Vector3D v)"""
8591  return _IMP_core.RigidBodyMember_set_internal_coordinates(self, v)
8592 
8593  def set_internal_transformation(self, v):
8594  r"""set_internal_transformation(RigidBodyMember self, Transformation3D v)"""
8595  return _IMP_core.RigidBodyMember_set_internal_transformation(self, v)
8596 
8597  def get_internal_transformation(self):
8598  r"""get_internal_transformation(RigidBodyMember self) -> Transformation3D"""
8599  return _IMP_core.RigidBodyMember_get_internal_transformation(self)
8600  __swig_destroy__ = _IMP_core.delete_RigidBodyMember
8601 
8602  def set_coordinates(self, *args):
8603  r"""
8604  set_coordinates(RigidBodyMember self, Vector3D center)
8605  set_coordinates(RigidBodyMember self, Transformation3D tr)
8606  """
8607  return _IMP_core.RigidBodyMember_set_coordinates(self, *args)
8608 
8609  def __init__(self, *args):
8610  r"""
8611  __init__(RigidBodyMember self) -> RigidBodyMember
8612  __init__(RigidBodyMember self, Model m, ParticleIndex id) -> RigidBodyMember
8613  __init__(RigidBodyMember self, _ParticleAdaptor d) -> RigidBodyMember
8614  __init__(RigidBodyMember self, RigidBodyMember arg2) -> RigidBodyMember
8615  """
8616  _IMP_core.RigidBodyMember_swiginit(self, _IMP_core.new_RigidBodyMember(*args))
8617 
8618  @staticmethod
8619  def get_is_setup(*args):
8620  r"""
8621  get_is_setup(_ParticleAdaptor p) -> bool
8622  get_is_setup(Model m, _ParticleIndexAdaptor p) -> bool
8623  """
8624  return _IMP_core.RigidBodyMember_get_is_setup(*args)
8625 
8626  @staticmethod
8627  def get_internal_coordinate_keys():
8628  r"""get_internal_coordinate_keys() -> IMP::FloatKeys"""
8629  return _IMP_core.RigidBodyMember_get_internal_coordinate_keys()
8630 
8631  @staticmethod
8632  def get_internal_rotation_key():
8633  r"""get_internal_rotation_key() -> Vector4DDerivKey"""
8634  return _IMP_core.RigidBodyMember_get_internal_rotation_key()
8635 
8636  def add_attribute(self, *args):
8637  r"""
8638  add_attribute(RigidBodyMember self, FloatKey k, IMP::Float v, bool opt)
8639  add_attribute(RigidBodyMember self, FloatKey a0, IMP::Float a1)
8640  add_attribute(RigidBodyMember self, IntKey a0, IMP::Int a1)
8641  add_attribute(RigidBodyMember self, FloatsKey a0, IMP::Floats a1)
8642  add_attribute(RigidBodyMember self, IntsKey a0, IMP::Ints a1)
8643  add_attribute(RigidBodyMember self, StringKey a0, IMP::String a1)
8644  add_attribute(RigidBodyMember self, ParticleIndexKey a0, Particle a1)
8645  add_attribute(RigidBodyMember self, ObjectKey a0, Object a1)
8646  add_attribute(RigidBodyMember self, SparseFloatKey a0, IMP::Float a1)
8647  add_attribute(RigidBodyMember self, SparseIntKey a0, IMP::Int a1)
8648  add_attribute(RigidBodyMember self, SparseStringKey a0, IMP::String a1)
8649  add_attribute(RigidBodyMember self, SparseParticleIndexKey a0, ParticleIndex a1)
8650  """
8651  return _IMP_core.RigidBodyMember_add_attribute(self, *args)
8652 
8653  def get_value(self, *args):
8654  r"""
8655  get_value(RigidBodyMember self, FloatKey a0) -> IMP::Float
8656  get_value(RigidBodyMember self, IntKey a0) -> IMP::Int
8657  get_value(RigidBodyMember self, FloatsKey a0) -> IMP::Floats
8658  get_value(RigidBodyMember self, IntsKey a0) -> IMP::Ints
8659  get_value(RigidBodyMember self, StringKey a0) -> IMP::String
8660  get_value(RigidBodyMember self, ParticleIndexKey a0) -> Particle
8661  get_value(RigidBodyMember self, ObjectKey a0) -> Object
8662  get_value(RigidBodyMember self, SparseFloatKey a0) -> IMP::Float
8663  get_value(RigidBodyMember self, SparseIntKey a0) -> IMP::Int
8664  get_value(RigidBodyMember self, SparseStringKey a0) -> IMP::String
8665  get_value(RigidBodyMember self, SparseParticleIndexKey a0) -> ParticleIndex
8666  """
8667  return _IMP_core.RigidBodyMember_get_value(self, *args)
8668 
8669  def set_value(self, *args):
8670  r"""
8671  set_value(RigidBodyMember self, FloatKey a0, IMP::Float a1)
8672  set_value(RigidBodyMember self, IntKey a0, IMP::Int a1)
8673  set_value(RigidBodyMember self, FloatsKey a0, IMP::Floats a1)
8674  set_value(RigidBodyMember self, IntsKey a0, IMP::Ints a1)
8675  set_value(RigidBodyMember self, StringKey a0, IMP::String a1)
8676  set_value(RigidBodyMember self, ParticleIndexKey a0, Particle a1)
8677  set_value(RigidBodyMember self, ObjectKey a0, Object a1)
8678  set_value(RigidBodyMember self, SparseFloatKey a0, IMP::Float a1)
8679  set_value(RigidBodyMember self, SparseIntKey a0, IMP::Int a1)
8680  set_value(RigidBodyMember self, SparseStringKey a0, IMP::String a1)
8681  set_value(RigidBodyMember self, SparseParticleIndexKey a0, ParticleIndex a1)
8682  """
8683  return _IMP_core.RigidBodyMember_set_value(self, *args)
8684 
8685  def remove_attribute(self, *args):
8686  r"""
8687  remove_attribute(RigidBodyMember self, FloatKey a0)
8688  remove_attribute(RigidBodyMember self, IntKey a0)
8689  remove_attribute(RigidBodyMember self, FloatsKey a0)
8690  remove_attribute(RigidBodyMember self, IntsKey a0)
8691  remove_attribute(RigidBodyMember self, StringKey a0)
8692  remove_attribute(RigidBodyMember self, ParticleIndexKey a0)
8693  remove_attribute(RigidBodyMember self, ObjectKey a0)
8694  remove_attribute(RigidBodyMember self, SparseFloatKey a0)
8695  remove_attribute(RigidBodyMember self, SparseIntKey a0)
8696  remove_attribute(RigidBodyMember self, SparseStringKey a0)
8697  remove_attribute(RigidBodyMember self, SparseParticleIndexKey a0)
8698  """
8699  return _IMP_core.RigidBodyMember_remove_attribute(self, *args)
8700 
8701  def has_attribute(self, *args):
8702  r"""
8703  has_attribute(RigidBodyMember self, FloatKey a0) -> bool
8704  has_attribute(RigidBodyMember self, IntKey a0) -> bool
8705  has_attribute(RigidBodyMember self, FloatsKey a0) -> bool
8706  has_attribute(RigidBodyMember self, IntsKey a0) -> bool
8707  has_attribute(RigidBodyMember self, StringKey a0) -> bool
8708  has_attribute(RigidBodyMember self, ParticleIndexKey a0) -> bool
8709  has_attribute(RigidBodyMember self, ObjectKey a0) -> bool
8710  has_attribute(RigidBodyMember self, SparseFloatKey a0) -> bool
8711  has_attribute(RigidBodyMember self, SparseIntKey a0) -> bool
8712  has_attribute(RigidBodyMember self, SparseStringKey a0) -> bool
8713  has_attribute(RigidBodyMember self, SparseParticleIndexKey a0) -> bool
8714  """
8715  return _IMP_core.RigidBodyMember_has_attribute(self, *args)
8716 
8717  def get_derivative(self, a0):
8718  r"""get_derivative(RigidBodyMember self, FloatKey a0) -> double"""
8719  return _IMP_core.RigidBodyMember_get_derivative(self, a0)
8720 
8721  def get_name(self):
8722  r"""get_name(RigidBodyMember self) -> std::string"""
8723  return _IMP_core.RigidBodyMember_get_name(self)
8724 
8725  def clear_caches(self):
8726  r"""clear_caches(RigidBodyMember self)"""
8727  return _IMP_core.RigidBodyMember_clear_caches(self)
8728 
8729  def set_name(self, a0):
8730  r"""set_name(RigidBodyMember self, std::string a0)"""
8731  return _IMP_core.RigidBodyMember_set_name(self, a0)
8732 
8733  def set_check_level(self, a0):
8734  r"""set_check_level(RigidBodyMember self, IMP::CheckLevel a0)"""
8735  return _IMP_core.RigidBodyMember_set_check_level(self, a0)
8736 
8737  def add_to_derivative(self, a0, a1, a2):
8738  r"""add_to_derivative(RigidBodyMember self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
8739  return _IMP_core.RigidBodyMember_add_to_derivative(self, a0, a1, a2)
8740 
8741  def set_is_optimized(self, a0, a1):
8742  r"""set_is_optimized(RigidBodyMember self, FloatKey a0, bool a1)"""
8743  return _IMP_core.RigidBodyMember_set_is_optimized(self, a0, a1)
8744 
8745  def get_is_optimized(self, a0):
8746  r"""get_is_optimized(RigidBodyMember self, FloatKey a0) -> bool"""
8747  return _IMP_core.RigidBodyMember_get_is_optimized(self, a0)
8748 
8749  def get_check_level(self):
8750  r"""get_check_level(RigidBodyMember self) -> IMP::CheckLevel"""
8751  return _IMP_core.RigidBodyMember_get_check_level(self)
8752 
8753  def __eq__(self, *args):
8754  r"""
8755  __eq__(RigidBodyMember self, RigidBodyMember o) -> bool
8756  __eq__(RigidBodyMember self, Particle d) -> bool
8757  """
8758  return _IMP_core.RigidBodyMember___eq__(self, *args)
8759 
8760  def __ne__(self, *args):
8761  r"""
8762  __ne__(RigidBodyMember self, RigidBodyMember o) -> bool
8763  __ne__(RigidBodyMember self, Particle d) -> bool
8764  """
8765  return _IMP_core.RigidBodyMember___ne__(self, *args)
8766 
8767  def __le__(self, *args):
8768  r"""
8769  __le__(RigidBodyMember self, RigidBodyMember o) -> bool
8770  __le__(RigidBodyMember self, Particle d) -> bool
8771  """
8772  return _IMP_core.RigidBodyMember___le__(self, *args)
8773 
8774  def __lt__(self, *args):
8775  r"""
8776  __lt__(RigidBodyMember self, RigidBodyMember o) -> bool
8777  __lt__(RigidBodyMember self, Particle d) -> bool
8778  """
8779  return _IMP_core.RigidBodyMember___lt__(self, *args)
8780 
8781  def __ge__(self, *args):
8782  r"""
8783  __ge__(RigidBodyMember self, RigidBodyMember o) -> bool
8784  __ge__(RigidBodyMember self, Particle d) -> bool
8785  """
8786  return _IMP_core.RigidBodyMember___ge__(self, *args)
8787 
8788  def __gt__(self, *args):
8789  r"""
8790  __gt__(RigidBodyMember self, RigidBodyMember o) -> bool
8791  __gt__(RigidBodyMember self, Particle d) -> bool
8792  """
8793  return _IMP_core.RigidBodyMember___gt__(self, *args)
8794 
8795  def __hash__(self):
8796  r"""__hash__(RigidBodyMember self) -> std::size_t"""
8797  return _IMP_core.RigidBodyMember___hash__(self)
8798 
8799  def __str__(self):
8800  r"""__str__(RigidBodyMember self) -> std::string"""
8801  return _IMP_core.RigidBodyMember___str__(self)
8802 
8803  def __repr__(self):
8804  r"""__repr__(RigidBodyMember self) -> std::string"""
8805  return _IMP_core.RigidBodyMember___repr__(self)
8806 
8807  def _get_as_binary(self):
8808  r"""_get_as_binary(RigidBodyMember self) -> PyObject *"""
8809  return _IMP_core.RigidBodyMember__get_as_binary(self)
8810 
8811  def _set_from_binary(self, p):
8812  r"""_set_from_binary(RigidBodyMember self, PyObject * p)"""
8813  return _IMP_core.RigidBodyMember__set_from_binary(self, p)
8814 
8815  def __getstate__(self):
8816  p = self._get_as_binary()
8817  if len(self.__dict__) > 1:
8818  d = self.__dict__.copy()
8819  del d['this']
8820  p = (d, p)
8821  return p
8822 
8823  def __setstate__(self, p):
8824  if not hasattr(self, 'this'):
8825  self.__init__()
8826  if isinstance(p, tuple):
8827  d, p = p
8828  self.__dict__.update(d)
8829  return self._set_from_binary(p)
8830 
8831 
8832 # Register RigidBodyMember in _IMP_core:
8833 _IMP_core.RigidBodyMember_swigregister(RigidBodyMember)
8834 class RigidMember(RigidBodyMember):
8835  r"""Proxy of C++ IMP::core::RigidMember class."""
8836 
8837  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
8838 
8839  def show(self, *args):
8840  r"""show(RigidMember self, _ostream out=std::cout)"""
8841  return _IMP_core.RigidMember_show(self, *args)
8842 
8843  def __init__(self, *args):
8844  r"""
8845  __init__(RigidMember self) -> RigidMember
8846  __init__(RigidMember self, Model m, ParticleIndex id) -> RigidMember
8847  __init__(RigidMember self, _ParticleAdaptor d) -> RigidMember
8848  __init__(RigidMember self, RigidMember arg2) -> RigidMember
8849  """
8850  _IMP_core.RigidMember_swiginit(self, _IMP_core.new_RigidMember(*args))
8851  __swig_destroy__ = _IMP_core.delete_RigidMember
8852 
8853  @staticmethod
8854  def get_is_setup(*args):
8855  r"""
8856  get_is_setup(_ParticleAdaptor p) -> bool
8857  get_is_setup(Model m, _ParticleIndexAdaptor p) -> bool
8858  """
8859  return _IMP_core.RigidMember_get_is_setup(*args)
8860 
8861  def add_attribute(self, *args):
8862  r"""
8863  add_attribute(RigidMember self, FloatKey k, IMP::Float v, bool opt)
8864  add_attribute(RigidMember self, FloatKey a0, IMP::Float a1)
8865  add_attribute(RigidMember self, IntKey a0, IMP::Int a1)
8866  add_attribute(RigidMember self, FloatsKey a0, IMP::Floats a1)
8867  add_attribute(RigidMember self, IntsKey a0, IMP::Ints a1)
8868  add_attribute(RigidMember self, StringKey a0, IMP::String a1)
8869  add_attribute(RigidMember self, ParticleIndexKey a0, Particle a1)
8870  add_attribute(RigidMember self, ObjectKey a0, Object a1)
8871  add_attribute(RigidMember self, SparseFloatKey a0, IMP::Float a1)
8872  add_attribute(RigidMember self, SparseIntKey a0, IMP::Int a1)
8873  add_attribute(RigidMember self, SparseStringKey a0, IMP::String a1)
8874  add_attribute(RigidMember self, SparseParticleIndexKey a0, ParticleIndex a1)
8875  """
8876  return _IMP_core.RigidMember_add_attribute(self, *args)
8877 
8878  def get_value(self, *args):
8879  r"""
8880  get_value(RigidMember self, FloatKey a0) -> IMP::Float
8881  get_value(RigidMember self, IntKey a0) -> IMP::Int
8882  get_value(RigidMember self, FloatsKey a0) -> IMP::Floats
8883  get_value(RigidMember self, IntsKey a0) -> IMP::Ints
8884  get_value(RigidMember self, StringKey a0) -> IMP::String
8885  get_value(RigidMember self, ParticleIndexKey a0) -> Particle
8886  get_value(RigidMember self, ObjectKey a0) -> Object
8887  get_value(RigidMember self, SparseFloatKey a0) -> IMP::Float
8888  get_value(RigidMember self, SparseIntKey a0) -> IMP::Int
8889  get_value(RigidMember self, SparseStringKey a0) -> IMP::String
8890  get_value(RigidMember self, SparseParticleIndexKey a0) -> ParticleIndex
8891  """
8892  return _IMP_core.RigidMember_get_value(self, *args)
8893 
8894  def set_value(self, *args):
8895  r"""
8896  set_value(RigidMember self, FloatKey a0, IMP::Float a1)
8897  set_value(RigidMember self, IntKey a0, IMP::Int a1)
8898  set_value(RigidMember self, FloatsKey a0, IMP::Floats a1)
8899  set_value(RigidMember self, IntsKey a0, IMP::Ints a1)
8900  set_value(RigidMember self, StringKey a0, IMP::String a1)
8901  set_value(RigidMember self, ParticleIndexKey a0, Particle a1)
8902  set_value(RigidMember self, ObjectKey a0, Object a1)
8903  set_value(RigidMember self, SparseFloatKey a0, IMP::Float a1)
8904  set_value(RigidMember self, SparseIntKey a0, IMP::Int a1)
8905  set_value(RigidMember self, SparseStringKey a0, IMP::String a1)
8906  set_value(RigidMember self, SparseParticleIndexKey a0, ParticleIndex a1)
8907  """
8908  return _IMP_core.RigidMember_set_value(self, *args)
8909 
8910  def remove_attribute(self, *args):
8911  r"""
8912  remove_attribute(RigidMember self, FloatKey a0)
8913  remove_attribute(RigidMember self, IntKey a0)
8914  remove_attribute(RigidMember self, FloatsKey a0)
8915  remove_attribute(RigidMember self, IntsKey a0)
8916  remove_attribute(RigidMember self, StringKey a0)
8917  remove_attribute(RigidMember self, ParticleIndexKey a0)
8918  remove_attribute(RigidMember self, ObjectKey a0)
8919  remove_attribute(RigidMember self, SparseFloatKey a0)
8920  remove_attribute(RigidMember self, SparseIntKey a0)
8921  remove_attribute(RigidMember self, SparseStringKey a0)
8922  remove_attribute(RigidMember self, SparseParticleIndexKey a0)
8923  """
8924  return _IMP_core.RigidMember_remove_attribute(self, *args)
8925 
8926  def has_attribute(self, *args):
8927  r"""
8928  has_attribute(RigidMember self, FloatKey a0) -> bool
8929  has_attribute(RigidMember self, IntKey a0) -> bool
8930  has_attribute(RigidMember self, FloatsKey a0) -> bool
8931  has_attribute(RigidMember self, IntsKey a0) -> bool
8932  has_attribute(RigidMember self, StringKey a0) -> bool
8933  has_attribute(RigidMember self, ParticleIndexKey a0) -> bool
8934  has_attribute(RigidMember self, ObjectKey a0) -> bool
8935  has_attribute(RigidMember self, SparseFloatKey a0) -> bool
8936  has_attribute(RigidMember self, SparseIntKey a0) -> bool
8937  has_attribute(RigidMember self, SparseStringKey a0) -> bool
8938  has_attribute(RigidMember self, SparseParticleIndexKey a0) -> bool
8939  """
8940  return _IMP_core.RigidMember_has_attribute(self, *args)
8941 
8942  def get_derivative(self, a0):
8943  r"""get_derivative(RigidMember self, FloatKey a0) -> double"""
8944  return _IMP_core.RigidMember_get_derivative(self, a0)
8945 
8946  def get_name(self):
8947  r"""get_name(RigidMember self) -> std::string"""
8948  return _IMP_core.RigidMember_get_name(self)
8949 
8950  def clear_caches(self):
8951  r"""clear_caches(RigidMember self)"""
8952  return _IMP_core.RigidMember_clear_caches(self)
8953 
8954  def set_name(self, a0):
8955  r"""set_name(RigidMember self, std::string a0)"""
8956  return _IMP_core.RigidMember_set_name(self, a0)
8957 
8958  def set_check_level(self, a0):
8959  r"""set_check_level(RigidMember self, IMP::CheckLevel a0)"""
8960  return _IMP_core.RigidMember_set_check_level(self, a0)
8961 
8962  def add_to_derivative(self, a0, a1, a2):
8963  r"""add_to_derivative(RigidMember self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
8964  return _IMP_core.RigidMember_add_to_derivative(self, a0, a1, a2)
8965 
8966  def set_is_optimized(self, a0, a1):
8967  r"""set_is_optimized(RigidMember self, FloatKey a0, bool a1)"""
8968  return _IMP_core.RigidMember_set_is_optimized(self, a0, a1)
8969 
8970  def get_is_optimized(self, a0):
8971  r"""get_is_optimized(RigidMember self, FloatKey a0) -> bool"""
8972  return _IMP_core.RigidMember_get_is_optimized(self, a0)
8973 
8974  def get_check_level(self):
8975  r"""get_check_level(RigidMember self) -> IMP::CheckLevel"""
8976  return _IMP_core.RigidMember_get_check_level(self)
8977 
8978  def __eq__(self, *args):
8979  r"""
8980  __eq__(RigidMember self, RigidMember o) -> bool
8981  __eq__(RigidMember self, Particle d) -> bool
8982  """
8983  return _IMP_core.RigidMember___eq__(self, *args)
8984 
8985  def __ne__(self, *args):
8986  r"""
8987  __ne__(RigidMember self, RigidMember o) -> bool
8988  __ne__(RigidMember self, Particle d) -> bool
8989  """
8990  return _IMP_core.RigidMember___ne__(self, *args)
8991 
8992  def __le__(self, *args):
8993  r"""
8994  __le__(RigidMember self, RigidMember o) -> bool
8995  __le__(RigidMember self, Particle d) -> bool
8996  """
8997  return _IMP_core.RigidMember___le__(self, *args)
8998 
8999  def __lt__(self, *args):
9000  r"""
9001  __lt__(RigidMember self, RigidMember o) -> bool
9002  __lt__(RigidMember self, Particle d) -> bool
9003  """
9004  return _IMP_core.RigidMember___lt__(self, *args)
9005 
9006  def __ge__(self, *args):
9007  r"""
9008  __ge__(RigidMember self, RigidMember o) -> bool
9009  __ge__(RigidMember self, Particle d) -> bool
9010  """
9011  return _IMP_core.RigidMember___ge__(self, *args)
9012 
9013  def __gt__(self, *args):
9014  r"""
9015  __gt__(RigidMember self, RigidMember o) -> bool
9016  __gt__(RigidMember self, Particle d) -> bool
9017  """
9018  return _IMP_core.RigidMember___gt__(self, *args)
9019 
9020  def __hash__(self):
9021  r"""__hash__(RigidMember self) -> std::size_t"""
9022  return _IMP_core.RigidMember___hash__(self)
9023 
9024  def __str__(self):
9025  r"""__str__(RigidMember self) -> std::string"""
9026  return _IMP_core.RigidMember___str__(self)
9027 
9028  def __repr__(self):
9029  r"""__repr__(RigidMember self) -> std::string"""
9030  return _IMP_core.RigidMember___repr__(self)
9031 
9032  def _get_as_binary(self):
9033  r"""_get_as_binary(RigidMember self) -> PyObject *"""
9034  return _IMP_core.RigidMember__get_as_binary(self)
9035 
9036  def _set_from_binary(self, p):
9037  r"""_set_from_binary(RigidMember self, PyObject * p)"""
9038  return _IMP_core.RigidMember__set_from_binary(self, p)
9039 
9040  def __getstate__(self):
9041  p = self._get_as_binary()
9042  if len(self.__dict__) > 1:
9043  d = self.__dict__.copy()
9044  del d['this']
9045  p = (d, p)
9046  return p
9047 
9048  def __setstate__(self, p):
9049  if not hasattr(self, 'this'):
9050  self.__init__()
9051  if isinstance(p, tuple):
9052  d, p = p
9053  self.__dict__.update(d)
9054  return self._set_from_binary(p)
9055 
9056 
9057 # Register RigidMember in _IMP_core:
9058 _IMP_core.RigidMember_swigregister(RigidMember)
9059 class NonRigidMember(RigidBodyMember):
9060  r"""Proxy of C++ IMP::core::NonRigidMember class."""
9061 
9062  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
9063 
9064  def show(self, *args):
9065  r"""show(NonRigidMember self, _ostream out=std::cout)"""
9066  return _IMP_core.NonRigidMember_show(self, *args)
9067 
9068  def __init__(self, *args):
9069  r"""
9070  __init__(NonRigidMember self) -> NonRigidMember
9071  __init__(NonRigidMember self, Model m, ParticleIndex id) -> NonRigidMember
9072  __init__(NonRigidMember self, _ParticleAdaptor d) -> NonRigidMember
9073  __init__(NonRigidMember self, NonRigidMember arg2) -> NonRigidMember
9074  """
9075  _IMP_core.NonRigidMember_swiginit(self, _IMP_core.new_NonRigidMember(*args))
9076  __swig_destroy__ = _IMP_core.delete_NonRigidMember
9077 
9078  @staticmethod
9079  def get_is_setup(*args):
9080  r"""
9081  get_is_setup(_ParticleAdaptor p) -> bool
9082  get_is_setup(Model m, ParticleIndex p) -> bool
9083  """
9084  return _IMP_core.NonRigidMember_get_is_setup(*args)
9085 
9086  def add_to_internal_derivatives(self, deriv_parent, da):
9087  r"""add_to_internal_derivatives(NonRigidMember self, Vector3D deriv_parent, DerivativeAccumulator da)"""
9088  return _IMP_core.NonRigidMember_add_to_internal_derivatives(self, deriv_parent, da)
9089 
9090  def add_to_internal_rotational_derivatives(self, qderiv, da):
9091  r"""add_to_internal_rotational_derivatives(NonRigidMember self, Vector4D qderiv, DerivativeAccumulator da)"""
9092  return _IMP_core.NonRigidMember_add_to_internal_rotational_derivatives(self, qderiv, da)
9093 
9094  def get_internal_derivatives(self):
9095  r"""get_internal_derivatives(NonRigidMember self) -> Vector3D"""
9096  return _IMP_core.NonRigidMember_get_internal_derivatives(self)
9097 
9098  def get_internal_rotational_derivatives(self):
9099  r"""get_internal_rotational_derivatives(NonRigidMember self) -> Vector4D"""
9100  return _IMP_core.NonRigidMember_get_internal_rotational_derivatives(self)
9101 
9102  def add_attribute(self, *args):
9103  r"""
9104  add_attribute(NonRigidMember self, FloatKey k, IMP::Float v, bool opt)
9105  add_attribute(NonRigidMember self, FloatKey a0, IMP::Float a1)
9106  add_attribute(NonRigidMember self, IntKey a0, IMP::Int a1)
9107  add_attribute(NonRigidMember self, FloatsKey a0, IMP::Floats a1)
9108  add_attribute(NonRigidMember self, IntsKey a0, IMP::Ints a1)
9109  add_attribute(NonRigidMember self, StringKey a0, IMP::String a1)
9110  add_attribute(NonRigidMember self, ParticleIndexKey a0, Particle a1)
9111  add_attribute(NonRigidMember self, ObjectKey a0, Object a1)
9112  add_attribute(NonRigidMember self, SparseFloatKey a0, IMP::Float a1)
9113  add_attribute(NonRigidMember self, SparseIntKey a0, IMP::Int a1)
9114  add_attribute(NonRigidMember self, SparseStringKey a0, IMP::String a1)
9115  add_attribute(NonRigidMember self, SparseParticleIndexKey a0, ParticleIndex a1)
9116  """
9117  return _IMP_core.NonRigidMember_add_attribute(self, *args)
9118 
9119  def get_value(self, *args):
9120  r"""
9121  get_value(NonRigidMember self, FloatKey a0) -> IMP::Float
9122  get_value(NonRigidMember self, IntKey a0) -> IMP::Int
9123  get_value(NonRigidMember self, FloatsKey a0) -> IMP::Floats
9124  get_value(NonRigidMember self, IntsKey a0) -> IMP::Ints
9125  get_value(NonRigidMember self, StringKey a0) -> IMP::String
9126  get_value(NonRigidMember self, ParticleIndexKey a0) -> Particle
9127  get_value(NonRigidMember self, ObjectKey a0) -> Object
9128  get_value(NonRigidMember self, SparseFloatKey a0) -> IMP::Float
9129  get_value(NonRigidMember self, SparseIntKey a0) -> IMP::Int
9130  get_value(NonRigidMember self, SparseStringKey a0) -> IMP::String
9131  get_value(NonRigidMember self, SparseParticleIndexKey a0) -> ParticleIndex
9132  """
9133  return _IMP_core.NonRigidMember_get_value(self, *args)
9134 
9135  def set_value(self, *args):
9136  r"""
9137  set_value(NonRigidMember self, FloatKey a0, IMP::Float a1)
9138  set_value(NonRigidMember self, IntKey a0, IMP::Int a1)
9139  set_value(NonRigidMember self, FloatsKey a0, IMP::Floats a1)
9140  set_value(NonRigidMember self, IntsKey a0, IMP::Ints a1)
9141  set_value(NonRigidMember self, StringKey a0, IMP::String a1)
9142  set_value(NonRigidMember self, ParticleIndexKey a0, Particle a1)
9143  set_value(NonRigidMember self, ObjectKey a0, Object a1)
9144  set_value(NonRigidMember self, SparseFloatKey a0, IMP::Float a1)
9145  set_value(NonRigidMember self, SparseIntKey a0, IMP::Int a1)
9146  set_value(NonRigidMember self, SparseStringKey a0, IMP::String a1)
9147  set_value(NonRigidMember self, SparseParticleIndexKey a0, ParticleIndex a1)
9148  """
9149  return _IMP_core.NonRigidMember_set_value(self, *args)
9150 
9151  def remove_attribute(self, *args):
9152  r"""
9153  remove_attribute(NonRigidMember self, FloatKey a0)
9154  remove_attribute(NonRigidMember self, IntKey a0)
9155  remove_attribute(NonRigidMember self, FloatsKey a0)
9156  remove_attribute(NonRigidMember self, IntsKey a0)
9157  remove_attribute(NonRigidMember self, StringKey a0)
9158  remove_attribute(NonRigidMember self, ParticleIndexKey a0)
9159  remove_attribute(NonRigidMember self, ObjectKey a0)
9160  remove_attribute(NonRigidMember self, SparseFloatKey a0)
9161  remove_attribute(NonRigidMember self, SparseIntKey a0)
9162  remove_attribute(NonRigidMember self, SparseStringKey a0)
9163  remove_attribute(NonRigidMember self, SparseParticleIndexKey a0)
9164  """
9165  return _IMP_core.NonRigidMember_remove_attribute(self, *args)
9166 
9167  def has_attribute(self, *args):
9168  r"""
9169  has_attribute(NonRigidMember self, FloatKey a0) -> bool
9170  has_attribute(NonRigidMember self, IntKey a0) -> bool
9171  has_attribute(NonRigidMember self, FloatsKey a0) -> bool
9172  has_attribute(NonRigidMember self, IntsKey a0) -> bool
9173  has_attribute(NonRigidMember self, StringKey a0) -> bool
9174  has_attribute(NonRigidMember self, ParticleIndexKey a0) -> bool
9175  has_attribute(NonRigidMember self, ObjectKey a0) -> bool
9176  has_attribute(NonRigidMember self, SparseFloatKey a0) -> bool
9177  has_attribute(NonRigidMember self, SparseIntKey a0) -> bool
9178  has_attribute(NonRigidMember self, SparseStringKey a0) -> bool
9179  has_attribute(NonRigidMember self, SparseParticleIndexKey a0) -> bool
9180  """
9181  return _IMP_core.NonRigidMember_has_attribute(self, *args)
9182 
9183  def get_derivative(self, a0):
9184  r"""get_derivative(NonRigidMember self, FloatKey a0) -> double"""
9185  return _IMP_core.NonRigidMember_get_derivative(self, a0)
9186 
9187  def get_name(self):
9188  r"""get_name(NonRigidMember self) -> std::string"""
9189  return _IMP_core.NonRigidMember_get_name(self)
9190 
9191  def clear_caches(self):
9192  r"""clear_caches(NonRigidMember self)"""
9193  return _IMP_core.NonRigidMember_clear_caches(self)
9194 
9195  def set_name(self, a0):
9196  r"""set_name(NonRigidMember self, std::string a0)"""
9197  return _IMP_core.NonRigidMember_set_name(self, a0)
9198 
9199  def set_check_level(self, a0):
9200  r"""set_check_level(NonRigidMember self, IMP::CheckLevel a0)"""
9201  return _IMP_core.NonRigidMember_set_check_level(self, a0)
9202 
9203  def add_to_derivative(self, a0, a1, a2):
9204  r"""add_to_derivative(NonRigidMember self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
9205  return _IMP_core.NonRigidMember_add_to_derivative(self, a0, a1, a2)
9206 
9207  def set_is_optimized(self, a0, a1):
9208  r"""set_is_optimized(NonRigidMember self, FloatKey a0, bool a1)"""
9209  return _IMP_core.NonRigidMember_set_is_optimized(self, a0, a1)
9210 
9211  def get_is_optimized(self, a0):
9212  r"""get_is_optimized(NonRigidMember self, FloatKey a0) -> bool"""
9213  return _IMP_core.NonRigidMember_get_is_optimized(self, a0)
9214 
9215  def get_check_level(self):
9216  r"""get_check_level(NonRigidMember self) -> IMP::CheckLevel"""
9217  return _IMP_core.NonRigidMember_get_check_level(self)
9218 
9219  def __eq__(self, *args):
9220  r"""
9221  __eq__(NonRigidMember self, NonRigidMember o) -> bool
9222  __eq__(NonRigidMember self, Particle d) -> bool
9223  """
9224  return _IMP_core.NonRigidMember___eq__(self, *args)
9225 
9226  def __ne__(self, *args):
9227  r"""
9228  __ne__(NonRigidMember self, NonRigidMember o) -> bool
9229  __ne__(NonRigidMember self, Particle d) -> bool
9230  """
9231  return _IMP_core.NonRigidMember___ne__(self, *args)
9232 
9233  def __le__(self, *args):
9234  r"""
9235  __le__(NonRigidMember self, NonRigidMember o) -> bool
9236  __le__(NonRigidMember self, Particle d) -> bool
9237  """
9238  return _IMP_core.NonRigidMember___le__(self, *args)
9239 
9240  def __lt__(self, *args):
9241  r"""
9242  __lt__(NonRigidMember self, NonRigidMember o) -> bool
9243  __lt__(NonRigidMember self, Particle d) -> bool
9244  """
9245  return _IMP_core.NonRigidMember___lt__(self, *args)
9246 
9247  def __ge__(self, *args):
9248  r"""
9249  __ge__(NonRigidMember self, NonRigidMember o) -> bool
9250  __ge__(NonRigidMember self, Particle d) -> bool
9251  """
9252  return _IMP_core.NonRigidMember___ge__(self, *args)
9253 
9254  def __gt__(self, *args):
9255  r"""
9256  __gt__(NonRigidMember self, NonRigidMember o) -> bool
9257  __gt__(NonRigidMember self, Particle d) -> bool
9258  """
9259  return _IMP_core.NonRigidMember___gt__(self, *args)
9260 
9261  def __hash__(self):
9262  r"""__hash__(NonRigidMember self) -> std::size_t"""
9263  return _IMP_core.NonRigidMember___hash__(self)
9264 
9265  def __str__(self):
9266  r"""__str__(NonRigidMember self) -> std::string"""
9267  return _IMP_core.NonRigidMember___str__(self)
9268 
9269  def __repr__(self):
9270  r"""__repr__(NonRigidMember self) -> std::string"""
9271  return _IMP_core.NonRigidMember___repr__(self)
9272 
9273  def _get_as_binary(self):
9274  r"""_get_as_binary(NonRigidMember self) -> PyObject *"""
9275  return _IMP_core.NonRigidMember__get_as_binary(self)
9276 
9277  def _set_from_binary(self, p):
9278  r"""_set_from_binary(NonRigidMember self, PyObject * p)"""
9279  return _IMP_core.NonRigidMember__set_from_binary(self, p)
9280 
9281  def __getstate__(self):
9282  p = self._get_as_binary()
9283  if len(self.__dict__) > 1:
9284  d = self.__dict__.copy()
9285  del d['this']
9286  p = (d, p)
9287  return p
9288 
9289  def __setstate__(self, p):
9290  if not hasattr(self, 'this'):
9291  self.__init__()
9292  if isinstance(p, tuple):
9293  d, p = p
9294  self.__dict__.update(d)
9295  return self._set_from_binary(p)
9296 
9297 
9298 # Register NonRigidMember in _IMP_core:
9299 _IMP_core.NonRigidMember_swigregister(NonRigidMember)
9300 class RigidMembersRefiner(IMP.Refiner):
9301  r"""Proxy of C++ IMP::core::RigidMembersRefiner class."""
9302 
9303  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
9304 
9305  def __init__(self, *args):
9306  r"""__init__(RigidMembersRefiner self, std::string name="RigidMembersRefiner%d") -> RigidMembersRefiner"""
9307  _IMP_core.RigidMembersRefiner_swiginit(self, _IMP_core.new_RigidMembersRefiner(*args))
9308 
9309  def do_get_inputs(self, m, pis):
9310  r"""do_get_inputs(RigidMembersRefiner self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
9311  return _IMP_core.RigidMembersRefiner_do_get_inputs(self, m, pis)
9312 
9313  def get_version_info(self):
9314  r"""get_version_info(RigidMembersRefiner self) -> VersionInfo"""
9315  return _IMP_core.RigidMembersRefiner_get_version_info(self)
9316  __swig_destroy__ = _IMP_core.delete_RigidMembersRefiner
9317 
9318  def __str__(self):
9319  r"""__str__(RigidMembersRefiner self) -> std::string"""
9320  return _IMP_core.RigidMembersRefiner___str__(self)
9321 
9322  def __repr__(self):
9323  r"""__repr__(RigidMembersRefiner self) -> std::string"""
9324  return _IMP_core.RigidMembersRefiner___repr__(self)
9325 
9326  @staticmethod
9327  def get_from(o):
9328  return _object_cast_to_RigidMembersRefiner(o)
9329 
9330 
9331 # Register RigidMembersRefiner in _IMP_core:
9332 _IMP_core.RigidMembersRefiner_swigregister(RigidMembersRefiner)
9333 
9334 def get_rigid_members_refiner():
9335  r"""get_rigid_members_refiner() -> RigidMembersRefiner"""
9336  return _IMP_core.get_rigid_members_refiner()
9337 
9338 def transform(*args):
9339  r"""
9340  transform(XYZ a, Transformation3D tr)
9341  transform(RigidBody a, Transformation3D tr)
9342  """
9343  return _IMP_core.transform(*args)
9344 
9345 def get_initial_reference_frame(*args):
9346  r"""
9347  get_initial_reference_frame(Model m, IMP::ParticleIndexes const & pis) -> ReferenceFrame3D
9348  get_initial_reference_frame(IMP::ParticlesTemp const & ps) -> ReferenceFrame3D
9349  """
9350  return _IMP_core.get_initial_reference_frame(*args)
9351 
9352 def create_rigid_bodies(m, n, no_members=False):
9353  r"""create_rigid_bodies(Model m, unsigned int n, bool no_members=False) -> IMP::ParticlesTemp"""
9354  return _IMP_core.create_rigid_bodies(m, n, no_members)
9355 
9356 def show_rigid_body_hierarchy(*args):
9357  r"""show_rigid_body_hierarchy(RigidBody rb, TextOutput out=IMP::TextOutput(std::cout))"""
9358  return _IMP_core.show_rigid_body_hierarchy(*args)
9359 
9360 def get_root_rigid_body(m):
9361  r"""get_root_rigid_body(RigidMember m) -> ParticleIndex"""
9362  return _IMP_core.get_root_rigid_body(m)
9363 class _UpdateRigidBodyMembers(IMP.SingletonModifier):
9364  r"""Proxy of C++ IMP::core::internal::_UpdateRigidBodyMembers class."""
9365 
9366  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
9367 
9368  def __init__(self, *args):
9369  r"""__init__(_UpdateRigidBodyMembers self, std::string name="UpdateRigidBodyMembers%1%") -> _UpdateRigidBodyMembers"""
9370  _IMP_core._UpdateRigidBodyMembers_swiginit(self, _IMP_core.new__UpdateRigidBodyMembers(*args))
9371 
9372  def do_get_inputs(self, m, pis):
9373  r"""do_get_inputs(_UpdateRigidBodyMembers self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
9374  return _IMP_core._UpdateRigidBodyMembers_do_get_inputs(self, m, pis)
9375 
9376  def do_get_outputs(self, m, pis):
9377  r"""do_get_outputs(_UpdateRigidBodyMembers self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
9378  return _IMP_core._UpdateRigidBodyMembers_do_get_outputs(self, m, pis)
9379 
9380  def get_version_info(self):
9381  r"""get_version_info(_UpdateRigidBodyMembers self) -> VersionInfo"""
9382  return _IMP_core._UpdateRigidBodyMembers_get_version_info(self)
9383  __swig_destroy__ = _IMP_core.delete__UpdateRigidBodyMembers
9384 
9385  def __str__(self):
9386  r"""__str__(_UpdateRigidBodyMembers self) -> std::string"""
9387  return _IMP_core._UpdateRigidBodyMembers___str__(self)
9388 
9389  def __repr__(self):
9390  r"""__repr__(_UpdateRigidBodyMembers self) -> std::string"""
9391  return _IMP_core._UpdateRigidBodyMembers___repr__(self)
9392 
9393  @staticmethod
9394  def get_from(o):
9395  return _object_cast_to__UpdateRigidBodyMembers(o)
9396 
9397 
9398 # Register _UpdateRigidBodyMembers in _IMP_core:
9399 _IMP_core._UpdateRigidBodyMembers_swigregister(_UpdateRigidBodyMembers)
9400 class _AccumulateRigidBodyDerivatives(IMP.SingletonModifier):
9401  r"""Proxy of C++ IMP::core::internal::_AccumulateRigidBodyDerivatives class."""
9402 
9403  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
9404 
9405  def __init__(self, *args):
9406  r"""__init__(_AccumulateRigidBodyDerivatives self, std::string name="AccumulateRigidBodyDerivatives%1%") -> _AccumulateRigidBodyDerivatives"""
9407  _IMP_core._AccumulateRigidBodyDerivatives_swiginit(self, _IMP_core.new__AccumulateRigidBodyDerivatives(*args))
9408 
9409  def do_get_inputs(self, m, pis):
9410  r"""do_get_inputs(_AccumulateRigidBodyDerivatives self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
9411  return _IMP_core._AccumulateRigidBodyDerivatives_do_get_inputs(self, m, pis)
9412 
9413  def do_get_outputs(self, m, pis):
9414  r"""do_get_outputs(_AccumulateRigidBodyDerivatives self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
9415  return _IMP_core._AccumulateRigidBodyDerivatives_do_get_outputs(self, m, pis)
9416 
9417  def get_version_info(self):
9418  r"""get_version_info(_AccumulateRigidBodyDerivatives self) -> VersionInfo"""
9419  return _IMP_core._AccumulateRigidBodyDerivatives_get_version_info(self)
9420  __swig_destroy__ = _IMP_core.delete__AccumulateRigidBodyDerivatives
9421 
9422  def __str__(self):
9423  r"""__str__(_AccumulateRigidBodyDerivatives self) -> std::string"""
9424  return _IMP_core._AccumulateRigidBodyDerivatives___str__(self)
9425 
9426  def __repr__(self):
9427  r"""__repr__(_AccumulateRigidBodyDerivatives self) -> std::string"""
9428  return _IMP_core._AccumulateRigidBodyDerivatives___repr__(self)
9429 
9430  @staticmethod
9431  def get_from(o):
9432  return _object_cast_to__AccumulateRigidBodyDerivatives(o)
9433 
9434 
9435 # Register _AccumulateRigidBodyDerivatives in _IMP_core:
9436 _IMP_core._AccumulateRigidBodyDerivatives_swigregister(_AccumulateRigidBodyDerivatives)
9437 class _NormalizeRotation(IMP.SingletonModifier):
9438  r"""Proxy of C++ IMP::core::internal::_NormalizeRotation class."""
9439 
9440  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
9441 
9442  def __init__(self, *args):
9443  r"""__init__(_NormalizeRotation self, std::string name="NormalizeRotation%1%") -> _NormalizeRotation"""
9444  _IMP_core._NormalizeRotation_swiginit(self, _IMP_core.new__NormalizeRotation(*args))
9445 
9446  def do_get_inputs(self, m, pis):
9447  r"""do_get_inputs(_NormalizeRotation self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
9448  return _IMP_core._NormalizeRotation_do_get_inputs(self, m, pis)
9449 
9450  def do_get_outputs(self, m, pis):
9451  r"""do_get_outputs(_NormalizeRotation self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
9452  return _IMP_core._NormalizeRotation_do_get_outputs(self, m, pis)
9453 
9454  def get_version_info(self):
9455  r"""get_version_info(_NormalizeRotation self) -> VersionInfo"""
9456  return _IMP_core._NormalizeRotation_get_version_info(self)
9457  __swig_destroy__ = _IMP_core.delete__NormalizeRotation
9458 
9459  def __str__(self):
9460  r"""__str__(_NormalizeRotation self) -> std::string"""
9461  return _IMP_core._NormalizeRotation___str__(self)
9462 
9463  def __repr__(self):
9464  r"""__repr__(_NormalizeRotation self) -> std::string"""
9465  return _IMP_core._NormalizeRotation___repr__(self)
9466 
9467  @staticmethod
9468  def get_from(o):
9469  return _object_cast_to__NormalizeRotation(o)
9470 
9471 
9472 # Register _NormalizeRotation in _IMP_core:
9473 _IMP_core._NormalizeRotation_swigregister(_NormalizeRotation)
9474 class _RigidBodyNormalizeConstraint(IMP.Constraint):
9475  r"""Proxy of C++ IMP::core::internal::_RigidBodyNormalizeConstraint class."""
9476 
9477  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
9478 
9479  def __init__(self, *args, **kwargs):
9480  raise AttributeError("No constructor defined - class is abstract")
9481 
9482  def get_before_modifier(self):
9483  r"""get_before_modifier(_RigidBodyNormalizeConstraint self) -> _NormalizeRotation"""
9484  return _IMP_core._RigidBodyNormalizeConstraint_get_before_modifier(self)
9485 
9486  def get_container(self):
9487  r"""get_container(_RigidBodyNormalizeConstraint self) -> Container"""
9488  return _IMP_core._RigidBodyNormalizeConstraint_get_container(self)
9489 
9490  def get_version_info(self):
9491  r"""get_version_info(_RigidBodyNormalizeConstraint self) -> VersionInfo"""
9492  return _IMP_core._RigidBodyNormalizeConstraint_get_version_info(self)
9493  __swig_destroy__ = _IMP_core.delete__RigidBodyNormalizeConstraint
9494 
9495  def __str__(self):
9496  r"""__str__(_RigidBodyNormalizeConstraint self) -> std::string"""
9497  return _IMP_core._RigidBodyNormalizeConstraint___str__(self)
9498 
9499  def __repr__(self):
9500  r"""__repr__(_RigidBodyNormalizeConstraint self) -> std::string"""
9501  return _IMP_core._RigidBodyNormalizeConstraint___repr__(self)
9502 
9503  @staticmethod
9504  def get_from(o):
9505  return _object_cast_to__RigidBodyNormalizeConstraint(o)
9506 
9507 
9508  def _get_jax(self):
9509  from IMP.algebra._jax_util import _quaternion_normalize
9510  import jax
9511  normalize_rotations = jax.vmap(_quaternion_normalize, in_axes=0)
9512  def apply_func(jm):
9513  # Assume that constraint acts on all rigid bodies
9514  allrbs = jm['rigid_bodies']
9515  allrbs.quaternion = normalize_rotations(allrbs.quaternion)
9516  return jm
9517  return self._wrap_jax(apply_func, keys=['rigid_bodies'])
9518 
9519 
9520 # Register _RigidBodyNormalizeConstraint in _IMP_core:
9521 _IMP_core._RigidBodyNormalizeConstraint_swigregister(_RigidBodyNormalizeConstraint)
9522 class _RigidBodyPositionConstraint(IMP.Constraint):
9523  r"""Proxy of C++ IMP::core::internal::_RigidBodyPositionConstraint class."""
9524 
9525  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
9526 
9527  def __init__(self, *args, **kwargs):
9528  raise AttributeError("No constructor defined - class is abstract")
9529 
9530  def get_version_info(self):
9531  r"""get_version_info(_RigidBodyPositionConstraint self) -> VersionInfo"""
9532  return _IMP_core._RigidBodyPositionConstraint_get_version_info(self)
9533  __swig_destroy__ = _IMP_core.delete__RigidBodyPositionConstraint
9534 
9535  def get_before_modifier(self):
9536  r"""get_before_modifier(_RigidBodyPositionConstraint self) -> _UpdateRigidBodyMembers"""
9537  return _IMP_core._RigidBodyPositionConstraint_get_before_modifier(self)
9538 
9539  def get_after_modifier(self):
9540  r"""get_after_modifier(_RigidBodyPositionConstraint self) -> _AccumulateRigidBodyDerivatives"""
9541  return _IMP_core._RigidBodyPositionConstraint_get_after_modifier(self)
9542 
9543  def get_index(self):
9544  r"""get_index(_RigidBodyPositionConstraint self) -> ParticleIndex"""
9545  return _IMP_core._RigidBodyPositionConstraint_get_index(self)
9546 
9547  def __str__(self):
9548  r"""__str__(_RigidBodyPositionConstraint self) -> std::string"""
9549  return _IMP_core._RigidBodyPositionConstraint___str__(self)
9550 
9551  def __repr__(self):
9552  r"""__repr__(_RigidBodyPositionConstraint self) -> std::string"""
9553  return _IMP_core._RigidBodyPositionConstraint___repr__(self)
9554 
9555  @staticmethod
9556  def get_from(o):
9557  return _object_cast_to__RigidBodyPositionConstraint(o)
9558 
9559 
9560  def _get_jax(self):
9561  import jax
9562  def apply_func(jm):
9563  # Assume that constraint acts on all rigid bodies
9564  bodies = jm['rigid_bodies'].bodies
9565  # todo: this could perhaps be better parallelized, as in most
9566  # cases (at least, without nested rigid bodies) the update of
9567  # one rigid body does not affect members of another body
9568  for body in bodies:
9569  jm = body.update_members(jm)
9570  return jm
9571  return self._wrap_jax(apply_func, keys=['rigid_bodies'])
9572 
9573 
9574 # Register _RigidBodyPositionConstraint in _IMP_core:
9575 _IMP_core._RigidBodyPositionConstraint_swigregister(_RigidBodyPositionConstraint)
9576 class RigidBodyHierarchyGeometry(IMP.display.SingletonGeometry):
9577  r"""Proxy of C++ IMP::core::RigidBodyHierarchyGeometry class."""
9578 
9579  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
9580 
9581  def __init__(self, rb, constituents):
9582  r"""__init__(RigidBodyHierarchyGeometry self, RigidBody rb, IMP::ParticlesTemp const & constituents) -> RigidBodyHierarchyGeometry"""
9583  _IMP_core.RigidBodyHierarchyGeometry_swiginit(self, _IMP_core.new_RigidBodyHierarchyGeometry(rb, constituents))
9584 
9585  def get_version_info(self):
9586  r"""get_version_info(RigidBodyHierarchyGeometry self) -> VersionInfo"""
9587  return _IMP_core.RigidBodyHierarchyGeometry_get_version_info(self)
9588  __swig_destroy__ = _IMP_core.delete_RigidBodyHierarchyGeometry
9589 
9590  def __str__(self):
9591  r"""__str__(RigidBodyHierarchyGeometry self) -> std::string"""
9592  return _IMP_core.RigidBodyHierarchyGeometry___str__(self)
9593 
9594  def __repr__(self):
9595  r"""__repr__(RigidBodyHierarchyGeometry self) -> std::string"""
9596  return _IMP_core.RigidBodyHierarchyGeometry___repr__(self)
9597 
9598  @staticmethod
9599  def get_from(o):
9600  return _object_cast_to_RigidBodyHierarchyGeometry(o)
9601 
9602 
9603 # Register RigidBodyHierarchyGeometry in _IMP_core:
9604 _IMP_core.RigidBodyHierarchyGeometry_swigregister(RigidBodyHierarchyGeometry)
9605 class RigidBodyDerivativeGeometry(IMP.display.SingletonGeometry):
9606  r"""Proxy of C++ IMP::core::RigidBodyDerivativeGeometry class."""
9607 
9608  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
9609 
9610  def __init__(self, *args):
9611  r"""
9612  __init__(RigidBodyDerivativeGeometry self, Particle p) -> RigidBodyDerivativeGeometry
9613  __init__(RigidBodyDerivativeGeometry self, RigidBody d) -> RigidBodyDerivativeGeometry
9614  """
9615  _IMP_core.RigidBodyDerivativeGeometry_swiginit(self, _IMP_core.new_RigidBodyDerivativeGeometry(*args))
9616 
9617  def get_version_info(self):
9618  r"""get_version_info(RigidBodyDerivativeGeometry self) -> VersionInfo"""
9619  return _IMP_core.RigidBodyDerivativeGeometry_get_version_info(self)
9620  __swig_destroy__ = _IMP_core.delete_RigidBodyDerivativeGeometry
9621 
9622  def __str__(self):
9623  r"""__str__(RigidBodyDerivativeGeometry self) -> std::string"""
9624  return _IMP_core.RigidBodyDerivativeGeometry___str__(self)
9625 
9626  def __repr__(self):
9627  r"""__repr__(RigidBodyDerivativeGeometry self) -> std::string"""
9628  return _IMP_core.RigidBodyDerivativeGeometry___repr__(self)
9629 
9630  @staticmethod
9631  def get_from(o):
9632  return _object_cast_to_RigidBodyDerivativeGeometry(o)
9633 
9634 
9635 # Register RigidBodyDerivativeGeometry in _IMP_core:
9636 _IMP_core.RigidBodyDerivativeGeometry_swigregister(RigidBodyDerivativeGeometry)
9637 class RigidBodyDerivativesGeometry(IMP.display.SingletonsGeometry):
9638  r"""Proxy of C++ IMP::core::RigidBodyDerivativesGeometry class."""
9639 
9640  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
9641 
9642  def __init__(self, sc):
9643  r"""__init__(RigidBodyDerivativesGeometry self, SingletonContainer sc) -> RigidBodyDerivativesGeometry"""
9644  _IMP_core.RigidBodyDerivativesGeometry_swiginit(self, _IMP_core.new_RigidBodyDerivativesGeometry(sc))
9645 
9646  def get_version_info(self):
9647  r"""get_version_info(RigidBodyDerivativesGeometry self) -> VersionInfo"""
9648  return _IMP_core.RigidBodyDerivativesGeometry_get_version_info(self)
9649  __swig_destroy__ = _IMP_core.delete_RigidBodyDerivativesGeometry
9650 
9651  def __str__(self):
9652  r"""__str__(RigidBodyDerivativesGeometry self) -> std::string"""
9653  return _IMP_core.RigidBodyDerivativesGeometry___str__(self)
9654 
9655  def __repr__(self):
9656  r"""__repr__(RigidBodyDerivativesGeometry self) -> std::string"""
9657  return _IMP_core.RigidBodyDerivativesGeometry___repr__(self)
9658 
9659  @staticmethod
9660  def get_from(o):
9661  return _object_cast_to_RigidBodyDerivativesGeometry(o)
9662 
9663 
9664 # Register RigidBodyDerivativesGeometry in _IMP_core:
9665 _IMP_core.RigidBodyDerivativesGeometry_swigregister(RigidBodyDerivativesGeometry)
9666 class RigidBodyFrameGeometry(IMP.display.SingletonGeometry):
9667  r"""Proxy of C++ IMP::core::RigidBodyFrameGeometry class."""
9668 
9669  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
9670 
9671  def __init__(self, *args):
9672  r"""
9673  __init__(RigidBodyFrameGeometry self, Particle p) -> RigidBodyFrameGeometry
9674  __init__(RigidBodyFrameGeometry self, RigidBody d) -> RigidBodyFrameGeometry
9675  """
9676  _IMP_core.RigidBodyFrameGeometry_swiginit(self, _IMP_core.new_RigidBodyFrameGeometry(*args))
9677 
9678  def get_version_info(self):
9679  r"""get_version_info(RigidBodyFrameGeometry self) -> VersionInfo"""
9680  return _IMP_core.RigidBodyFrameGeometry_get_version_info(self)
9681  __swig_destroy__ = _IMP_core.delete_RigidBodyFrameGeometry
9682 
9683  def __str__(self):
9684  r"""__str__(RigidBodyFrameGeometry self) -> std::string"""
9685  return _IMP_core.RigidBodyFrameGeometry___str__(self)
9686 
9687  def __repr__(self):
9688  r"""__repr__(RigidBodyFrameGeometry self) -> std::string"""
9689  return _IMP_core.RigidBodyFrameGeometry___repr__(self)
9690 
9691  @staticmethod
9692  def get_from(o):
9693  return _object_cast_to_RigidBodyFrameGeometry(o)
9694 
9695 
9696 # Register RigidBodyFrameGeometry in _IMP_core:
9697 _IMP_core.RigidBodyFrameGeometry_swigregister(RigidBodyFrameGeometry)
9698 class RigidBodyFramesGeometry(IMP.display.SingletonsGeometry):
9699  r"""Proxy of C++ IMP::core::RigidBodyFramesGeometry class."""
9700 
9701  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
9702 
9703  def __init__(self, sc):
9704  r"""__init__(RigidBodyFramesGeometry self, SingletonContainer sc) -> RigidBodyFramesGeometry"""
9705  _IMP_core.RigidBodyFramesGeometry_swiginit(self, _IMP_core.new_RigidBodyFramesGeometry(sc))
9706 
9707  def get_version_info(self):
9708  r"""get_version_info(RigidBodyFramesGeometry self) -> VersionInfo"""
9709  return _IMP_core.RigidBodyFramesGeometry_get_version_info(self)
9710  __swig_destroy__ = _IMP_core.delete_RigidBodyFramesGeometry
9711 
9712  def __str__(self):
9713  r"""__str__(RigidBodyFramesGeometry self) -> std::string"""
9714  return _IMP_core.RigidBodyFramesGeometry___str__(self)
9715 
9716  def __repr__(self):
9717  r"""__repr__(RigidBodyFramesGeometry self) -> std::string"""
9718  return _IMP_core.RigidBodyFramesGeometry___repr__(self)
9719 
9720  @staticmethod
9721  def get_from(o):
9722  return _object_cast_to_RigidBodyFramesGeometry(o)
9723 
9724 
9725 # Register RigidBodyFramesGeometry in _IMP_core:
9726 _IMP_core.RigidBodyFramesGeometry_swigregister(RigidBodyFramesGeometry)
9727 class RigidBodyTorque(IMP.display.SegmentGeometry):
9728  r"""Proxy of C++ IMP::core::RigidBodyTorque class."""
9729 
9730  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
9731 
9732  def __init__(self, p):
9733  r"""__init__(RigidBodyTorque self, Particle p) -> RigidBodyTorque"""
9734  _IMP_core.RigidBodyTorque_swiginit(self, _IMP_core.new_RigidBodyTorque(p))
9735 
9736  def __str__(self):
9737  r"""__str__(RigidBodyTorque self) -> std::string"""
9738  return _IMP_core.RigidBodyTorque___str__(self)
9739 
9740  def __repr__(self):
9741  r"""__repr__(RigidBodyTorque self) -> std::string"""
9742  return _IMP_core.RigidBodyTorque___repr__(self)
9743 
9744  @staticmethod
9745  def get_from(o):
9746  return _object_cast_to_RigidBodyTorque(o)
9747 
9748  __swig_destroy__ = _IMP_core.delete_RigidBodyTorque
9749 
9750 # Register RigidBodyTorque in _IMP_core:
9751 _IMP_core.RigidBodyTorque_swigregister(RigidBodyTorque)
9752 class NearestNeighborsClosePairsFinder(ClosePairsFinder):
9753  r"""Proxy of C++ IMP::core::NearestNeighborsClosePairsFinder class."""
9754 
9755  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
9756 
9757  def __init__(self):
9758  r"""__init__(NearestNeighborsClosePairsFinder self) -> NearestNeighborsClosePairsFinder"""
9759  _IMP_core.NearestNeighborsClosePairsFinder_swiginit(self, _IMP_core.new_NearestNeighborsClosePairsFinder())
9760 
9761  def get_close_pairs(self, *args):
9762  r"""
9763  get_close_pairs(NearestNeighborsClosePairsFinder self, IMP::algebra::BoundingBox3Ds const & bbs) -> IMP::IntPairs
9764  get_close_pairs(NearestNeighborsClosePairsFinder self, IMP::algebra::BoundingBox3Ds const & bas, IMP::algebra::BoundingBox3Ds const & bbs) -> IMP::IntPairs
9765  get_close_pairs(NearestNeighborsClosePairsFinder self, Model m, IMP::ParticleIndexes const & pc) -> IMP::ParticleIndexPairs
9766  get_close_pairs(NearestNeighborsClosePairsFinder self, Model m, IMP::ParticleIndexes const & pca, IMP::ParticleIndexes const & pcb) -> IMP::ParticleIndexPairs
9767  """
9768  return _IMP_core.NearestNeighborsClosePairsFinder_get_close_pairs(self, *args)
9769 
9770  def do_get_inputs(self, m, pis):
9771  r"""do_get_inputs(NearestNeighborsClosePairsFinder self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
9772  return _IMP_core.NearestNeighborsClosePairsFinder_do_get_inputs(self, m, pis)
9773 
9774  def get_version_info(self):
9775  r"""get_version_info(NearestNeighborsClosePairsFinder self) -> VersionInfo"""
9776  return _IMP_core.NearestNeighborsClosePairsFinder_get_version_info(self)
9777  __swig_destroy__ = _IMP_core.delete_NearestNeighborsClosePairsFinder
9778 
9779  def __str__(self):
9780  r"""__str__(NearestNeighborsClosePairsFinder self) -> std::string"""
9781  return _IMP_core.NearestNeighborsClosePairsFinder___str__(self)
9782 
9783  def __repr__(self):
9784  r"""__repr__(NearestNeighborsClosePairsFinder self) -> std::string"""
9785  return _IMP_core.NearestNeighborsClosePairsFinder___repr__(self)
9786 
9787  @staticmethod
9788  def get_from(o):
9789  return _object_cast_to_NearestNeighborsClosePairsFinder(o)
9790 
9791 
9792 # Register NearestNeighborsClosePairsFinder in _IMP_core:
9793 _IMP_core.NearestNeighborsClosePairsFinder_swigregister(NearestNeighborsClosePairsFinder)
9794 class RestraintsScoringFunction(IMP.ScoringFunction):
9795  r"""Proxy of C++ IMP::core::RestraintsScoringFunction class."""
9796 
9797  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
9798 
9799  def __init__(self, *args):
9800  r"""
9801  __init__(RestraintsScoringFunction self, _RestraintsAdaptor rs, double weight=1.0, double max=NO_MAX, std::string name="RestraintsScoringFunction%1%") -> RestraintsScoringFunction
9802  __init__(RestraintsScoringFunction self, _RestraintsAdaptor rs, std::string name) -> RestraintsScoringFunction
9803  __init__(RestraintsScoringFunction self) -> RestraintsScoringFunction
9804  """
9805  _IMP_core.RestraintsScoringFunction_swiginit(self, _IMP_core.new_RestraintsScoringFunction(*args))
9806 
9807  def do_add_score_and_derivatives(self, sa, ss):
9808  r"""do_add_score_and_derivatives(RestraintsScoringFunction self, ScoreAccumulator sa, IMP::ScoreStatesTemp const & ss)"""
9809  return _IMP_core.RestraintsScoringFunction_do_add_score_and_derivatives(self, sa, ss)
9810 
9811  def do_add_score_and_derivatives_moved(self, sa, moved_pis, reset_pis, ss):
9812  r"""do_add_score_and_derivatives_moved(RestraintsScoringFunction self, ScoreAccumulator sa, IMP::ParticleIndexes const & moved_pis, IMP::ParticleIndexes const & reset_pis, IMP::ScoreStatesTemp const & ss)"""
9813  return _IMP_core.RestraintsScoringFunction_do_add_score_and_derivatives_moved(self, sa, moved_pis, reset_pis, ss)
9814 
9815  def do_get_inputs(self):
9816  r"""do_get_inputs(RestraintsScoringFunction self) -> IMP::ModelObjectsTemp"""
9817  return _IMP_core.RestraintsScoringFunction_do_get_inputs(self)
9818 
9819  def get_restraints(self):
9820  r"""get_restraints(RestraintsScoringFunction self) -> IMP::Restraints"""
9821  return _IMP_core.RestraintsScoringFunction_get_restraints(self)
9822 
9823  def set_restraints(self, d):
9824  r"""set_restraints(RestraintsScoringFunction self, IMP::Restraints const & d)"""
9825  return _IMP_core.RestraintsScoringFunction_set_restraints(self, d)
9826 
9827  def get_number_of_restraints(self):
9828  r"""get_number_of_restraints(RestraintsScoringFunction self) -> unsigned int"""
9829  return _IMP_core.RestraintsScoringFunction_get_number_of_restraints(self)
9830 
9831  def clear_restraints(self):
9832  r"""clear_restraints(RestraintsScoringFunction self)"""
9833  return _IMP_core.RestraintsScoringFunction_clear_restraints(self)
9834 
9835  def get_restraint(self, i):
9836  r"""get_restraint(RestraintsScoringFunction self, unsigned int i) -> Restraint"""
9837  return _IMP_core.RestraintsScoringFunction_get_restraint(self, i)
9838 
9839  def erase_restraint(self, i):
9840  r"""erase_restraint(RestraintsScoringFunction self, unsigned int i)"""
9841  return _IMP_core.RestraintsScoringFunction_erase_restraint(self, i)
9842 
9843  def add_restraint(self, d):
9844  r"""add_restraint(RestraintsScoringFunction self, Restraint d) -> unsigned int"""
9845  return _IMP_core.RestraintsScoringFunction_add_restraint(self, d)
9846 
9847  def add_restraints(self, d):
9848  r"""add_restraints(RestraintsScoringFunction self, IMP::Restraints const & d)"""
9849  return _IMP_core.RestraintsScoringFunction_add_restraints(self, d)
9850 
9851  def _python_index_restraint(self, r, start, stop):
9852  r"""_python_index_restraint(RestraintsScoringFunction self, Restraint r, unsigned int start, unsigned int stop) -> unsigned int"""
9853  return _IMP_core.RestraintsScoringFunction__python_index_restraint(self, r, start, stop)
9854  def __get_restraints(self): return IMP._list_util.VarList(getdimfunc=self.get_number_of_restraints, getfunc=self.get_restraint, erasefunc=self.erase_restraint, appendfunc=self.add_restraint, extendfunc=self.add_restraints, clearfunc=self.clear_restraints, indexfunc=self._python_index_restraint)
9855  def __set_restraints(self, obj): IMP._list_util.set_varlist(self.restraints, obj)
9856  def __del_restraints(self): IMP._list_util.del_varlist(self.restraints)
9857  restraints = property(__get_restraints, __set_restraints, __del_restraints, doc="List of ##Restraints")
9858 
9859  def get_version_info(self):
9860  r"""get_version_info(RestraintsScoringFunction self) -> VersionInfo"""
9861  return _IMP_core.RestraintsScoringFunction_get_version_info(self)
9862  __swig_destroy__ = _IMP_core.delete_RestraintsScoringFunction
9863 
9864  def __str__(self):
9865  r"""__str__(RestraintsScoringFunction self) -> std::string"""
9866  return _IMP_core.RestraintsScoringFunction___str__(self)
9867 
9868  def __repr__(self):
9869  r"""__repr__(RestraintsScoringFunction self) -> std::string"""
9870  return _IMP_core.RestraintsScoringFunction___repr__(self)
9871 
9872  @staticmethod
9873  def get_from(o):
9874  return _object_cast_to_RestraintsScoringFunction(o)
9875 
9876 
9877  def _get_as_binary(self):
9878  r"""_get_as_binary(RestraintsScoringFunction self) -> PyObject *"""
9879  return _IMP_core.RestraintsScoringFunction__get_as_binary(self)
9880 
9881  def _set_from_binary(self, p):
9882  r"""_set_from_binary(RestraintsScoringFunction self, PyObject * p)"""
9883  return _IMP_core.RestraintsScoringFunction__set_from_binary(self, p)
9884 
9885  def __getstate__(self):
9886  p = self._get_as_binary()
9887  if len(self.__dict__) > 1:
9888  d = self.__dict__.copy()
9889  del d['this']
9890  p = (d, p)
9891  return p
9892 
9893  def __setstate__(self, p):
9894  if not hasattr(self, 'this'):
9895  self.__init__()
9896  if isinstance(p, tuple):
9897  d, p = p
9898  self.__dict__.update(d)
9899  return self._set_from_binary(p)
9900 
9901 
9902  def _get_jax(self):
9903  import IMP._jax_util
9904  jis = [r.get_derived_object()._get_jax() for r in self.restraints]
9905  funcs = [j.score_func for j in jis]
9906  keys = frozenset(x for j in jis for x in j._keys)
9907  def jax_sf(jm):
9908  return sum(f(jm) for f in funcs)
9909  return IMP._jax_util.JAXRestraintInfo(
9910  m=self.get_model(), score_func=jax_sf, weight=1.0, keys=keys)
9911 
9912 
9913 # Register RestraintsScoringFunction in _IMP_core:
9914 _IMP_core.RestraintsScoringFunction_swigregister(RestraintsScoringFunction)
9915 class RigidClosePairsFinder(ClosePairsFinder):
9916  r"""Proxy of C++ IMP::core::RigidClosePairsFinder class."""
9917 
9918  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
9919 
9920  def __init__(self, cpf=None):
9921  r"""__init__(RigidClosePairsFinder self, ClosePairsFinder cpf=None) -> RigidClosePairsFinder"""
9922  _IMP_core.RigidClosePairsFinder_swiginit(self, _IMP_core.new_RigidClosePairsFinder(cpf))
9923 
9924  def do_get_inputs(self, m, pis):
9925  r"""do_get_inputs(RigidClosePairsFinder self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
9926  return _IMP_core.RigidClosePairsFinder_do_get_inputs(self, m, pis)
9927 
9928  def get_close_pairs(self, *args):
9929  r"""
9930  get_close_pairs(RigidClosePairsFinder self, Model m, ParticleIndex a, ParticleIndex b, IMP::ParticleIndexes const & pa, IMP::ParticleIndexes const & pb) -> IMP::ParticleIndexPairs
9931  get_close_pairs(RigidClosePairsFinder self, IMP::algebra::BoundingBox3Ds const & bbs) -> IMP::IntPairs
9932  get_close_pairs(RigidClosePairsFinder self, IMP::algebra::BoundingBox3Ds const & bas, IMP::algebra::BoundingBox3Ds const & bbs) -> IMP::IntPairs
9933  get_close_pairs(RigidClosePairsFinder self, Model m, IMP::ParticleIndexes const & pc) -> IMP::ParticleIndexPairs
9934  get_close_pairs(RigidClosePairsFinder self, Model m, IMP::ParticleIndexes const & pca, IMP::ParticleIndexes const & pcb) -> IMP::ParticleIndexPairs
9935  """
9936  return _IMP_core.RigidClosePairsFinder_get_close_pairs(self, *args)
9937 
9938  def get_version_info(self):
9939  r"""get_version_info(RigidClosePairsFinder self) -> VersionInfo"""
9940  return _IMP_core.RigidClosePairsFinder_get_version_info(self)
9941  __swig_destroy__ = _IMP_core.delete_RigidClosePairsFinder
9942 
9943  def __str__(self):
9944  r"""__str__(RigidClosePairsFinder self) -> std::string"""
9945  return _IMP_core.RigidClosePairsFinder___str__(self)
9946 
9947  def __repr__(self):
9948  r"""__repr__(RigidClosePairsFinder self) -> std::string"""
9949  return _IMP_core.RigidClosePairsFinder___repr__(self)
9950 
9951  @staticmethod
9952  def get_from(o):
9953  return _object_cast_to_RigidClosePairsFinder(o)
9954 
9955 
9956  def _get_as_binary(self):
9957  r"""_get_as_binary(RigidClosePairsFinder self) -> PyObject *"""
9958  return _IMP_core.RigidClosePairsFinder__get_as_binary(self)
9959 
9960  def _set_from_binary(self, p):
9961  r"""_set_from_binary(RigidClosePairsFinder self, PyObject * p)"""
9962  return _IMP_core.RigidClosePairsFinder__set_from_binary(self, p)
9963 
9964  def __getstate__(self):
9965  p = self._get_as_binary()
9966  if len(self.__dict__) > 1:
9967  d = self.__dict__.copy()
9968  del d['this']
9969  p = (d, p)
9970  return p
9971 
9972  def __setstate__(self, p):
9973  if not hasattr(self, 'this'):
9974  self.__init__()
9975  if isinstance(p, tuple):
9976  d, p = p
9977  self.__dict__.update(d)
9978  return self._set_from_binary(p)
9979 
9980 
9981 # Register RigidClosePairsFinder in _IMP_core:
9982 _IMP_core.RigidClosePairsFinder_swigregister(RigidClosePairsFinder)
9983 class _SphereDistancePairScore(IMP.PairScore):
9984  r"""Proxy of C++ IMP::core::SphereDistancePairScore class."""
9985 
9986  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
9987  __repr__ = _swig_repr
9988 
9989  def __init__(self, *args):
9990  r"""
9991  SphereDistancePairScore(UnaryFunction uf, std::string name="SphereDistancePairScore%1%") -> _SphereDistancePairScore
9992  __init__(_SphereDistancePairScore self) -> _SphereDistancePairScore
9993  """
9994  _IMP_core._SphereDistancePairScore_swiginit(self, _IMP_core.new__SphereDistancePairScore(*args))
9995 
9996  def do_get_inputs(self, m, pis):
9997  r"""do_get_inputs(_SphereDistancePairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
9998  return _IMP_core._SphereDistancePairScore_do_get_inputs(self, m, pis)
9999 
10000  def get_score_functor(self, *args):
10001  r"""
10002  get_score_functor(_SphereDistancePairScore self) -> _SphereDistanceUF
10003  get_score_functor(_SphereDistancePairScore self) -> _SphereDistanceUF
10004  """
10005  return _IMP_core._SphereDistancePairScore_get_score_functor(self, *args)
10006 
10007  def get_version_info(self):
10008  r"""get_version_info(_SphereDistancePairScore self) -> VersionInfo"""
10009  return _IMP_core._SphereDistancePairScore_get_version_info(self)
10010  __swig_destroy__ = _IMP_core.delete__SphereDistancePairScore
10011 
10012  @staticmethod
10013  def get_from(o):
10014  return _object_cast_to__SphereDistancePairScore(o)
10015 
10016 
10017  def _get_as_binary(self):
10018  r"""_get_as_binary(_SphereDistancePairScore self) -> PyObject *"""
10019  return _IMP_core._SphereDistancePairScore__get_as_binary(self)
10020 
10021  def _set_from_binary(self, p):
10022  r"""_set_from_binary(_SphereDistancePairScore self, PyObject * p)"""
10023  return _IMP_core._SphereDistancePairScore__set_from_binary(self, p)
10024 
10025  def __getstate__(self):
10026  p = self._get_as_binary()
10027  if len(self.__dict__) > 1:
10028  d = self.__dict__.copy()
10029  del d['this']
10030  p = (d, p)
10031  return p
10032 
10033  def __setstate__(self, p):
10034  if not hasattr(self, 'this'):
10035  self.__init__()
10036  if isinstance(p, tuple):
10037  d, p = p
10038  self.__dict__.update(d)
10039  return self._set_from_binary(p)
10040 
10041 
10042  def _get_jax(self, m, indexes):
10043  import jax.numpy as jnp
10044  def jax_score(jm, uf):
10045  xyzs = jm['xyz'][indexes]
10046  rs = jm['r'][indexes]
10047  diff = xyzs[:,0] - xyzs[:,1]
10048  drs = jnp.linalg.norm(diff, axis=1) - rs.sum(axis=1)
10049  return uf(drs)
10050  sfnc = self.get_score_functor()
10051  uf = sfnc.get_unary_function().get_derived_object()
10052  f = functools.partial(jax_score, uf=uf._get_jax())
10053  return self._wrap_jax(m, f)
10054 
10055 
10056 # Register _SphereDistancePairScore in _IMP_core:
10057 _IMP_core._SphereDistancePairScore_swigregister(_SphereDistancePairScore)
10058 class HarmonicUpperBoundSphereDistancePairScore(IMP.PairScore):
10059  r"""Proxy of C++ IMP::core::HarmonicUpperBoundSphereDistancePairScore class."""
10060 
10061  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10062 
10063  def __init__(self, *args):
10064  r"""
10065  __init__(HarmonicUpperBoundSphereDistancePairScore self, double x0, double k, std::string name="HarmonicUpperBoundSphereDistancePairScore%1%") -> HarmonicUpperBoundSphereDistancePairScore
10066  __init__(HarmonicUpperBoundSphereDistancePairScore self) -> HarmonicUpperBoundSphereDistancePairScore
10067  """
10068  _IMP_core.HarmonicUpperBoundSphereDistancePairScore_swiginit(self, _IMP_core.new_HarmonicUpperBoundSphereDistancePairScore(*args))
10069 
10070  def do_get_inputs(self, m, pis):
10071  r"""do_get_inputs(HarmonicUpperBoundSphereDistancePairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
10072  return _IMP_core.HarmonicUpperBoundSphereDistancePairScore_do_get_inputs(self, m, pis)
10073 
10074  def get_score_functor(self, *args):
10075  r"""
10076  get_score_functor(HarmonicUpperBoundSphereDistancePairScore self) -> IMP::core::HarmonicUpperBoundSphereDistanceScore
10077  get_score_functor(HarmonicUpperBoundSphereDistancePairScore self) -> IMP::core::HarmonicUpperBoundSphereDistanceScore const &
10078  """
10079  return _IMP_core.HarmonicUpperBoundSphereDistancePairScore_get_score_functor(self, *args)
10080 
10081  def get_x0(self):
10082  r"""get_x0(HarmonicUpperBoundSphereDistancePairScore self) -> double"""
10083  return _IMP_core.HarmonicUpperBoundSphereDistancePairScore_get_x0(self)
10084 
10085  def get_k(self):
10086  r"""get_k(HarmonicUpperBoundSphereDistancePairScore self) -> double"""
10087  return _IMP_core.HarmonicUpperBoundSphereDistancePairScore_get_k(self)
10088 
10089  def get_version_info(self):
10090  r"""get_version_info(HarmonicUpperBoundSphereDistancePairScore self) -> VersionInfo"""
10091  return _IMP_core.HarmonicUpperBoundSphereDistancePairScore_get_version_info(self)
10092  __swig_destroy__ = _IMP_core.delete_HarmonicUpperBoundSphereDistancePairScore
10093 
10094  def __str__(self):
10095  r"""__str__(HarmonicUpperBoundSphereDistancePairScore self) -> std::string"""
10096  return _IMP_core.HarmonicUpperBoundSphereDistancePairScore___str__(self)
10097 
10098  def __repr__(self):
10099  r"""__repr__(HarmonicUpperBoundSphereDistancePairScore self) -> std::string"""
10100  return _IMP_core.HarmonicUpperBoundSphereDistancePairScore___repr__(self)
10101 
10102  @staticmethod
10103  def get_from(o):
10104  return _object_cast_to_HarmonicUpperBoundSphereDistancePairScore(o)
10105 
10106 
10107  def _get_as_binary(self):
10108  r"""_get_as_binary(HarmonicUpperBoundSphereDistancePairScore self) -> PyObject *"""
10109  return _IMP_core.HarmonicUpperBoundSphereDistancePairScore__get_as_binary(self)
10110 
10111  def _set_from_binary(self, p):
10112  r"""_set_from_binary(HarmonicUpperBoundSphereDistancePairScore self, PyObject * p)"""
10113  return _IMP_core.HarmonicUpperBoundSphereDistancePairScore__set_from_binary(self, p)
10114 
10115  def __getstate__(self):
10116  p = self._get_as_binary()
10117  if len(self.__dict__) > 1:
10118  d = self.__dict__.copy()
10119  del d['this']
10120  p = (d, p)
10121  return p
10122 
10123  def __setstate__(self, p):
10124  if not hasattr(self, 'this'):
10125  self.__init__()
10126  if isinstance(p, tuple):
10127  d, p = p
10128  self.__dict__.update(d)
10129  return self._set_from_binary(p)
10130 
10131 
10132  def _get_jax(self, m, indexes):
10133  import jax.numpy as jnp
10134  import jax.lax
10135  def jax_score(jm, d, k):
10136  xyzs = jm['xyz'][indexes]
10137  rs = jm['r'][indexes]
10138  diff = xyzs[:,0] - xyzs[:,1]
10139  drs = jnp.linalg.norm(diff, axis=1) - rs.sum(axis=1)
10140  return 0.5 * k * jax.lax.min(d - drs, 0.0) ** 2
10141  f = functools.partial(jax_score, d=self.get_x0(), k=self.get_k())
10142  return self._wrap_jax(m, f)
10143 
10144 
10145 # Register HarmonicUpperBoundSphereDistancePairScore in _IMP_core:
10146 _IMP_core.HarmonicUpperBoundSphereDistancePairScore_swigregister(HarmonicUpperBoundSphereDistancePairScore)
10147 class HarmonicUpperBoundSphereDiameterPairScore(IMP.PairScore):
10148  r"""Proxy of C++ IMP::core::HarmonicUpperBoundSphereDiameterPairScore class."""
10149 
10150  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10151 
10152  def __init__(self, d0, k):
10153  r"""__init__(HarmonicUpperBoundSphereDiameterPairScore self, double d0, double k) -> HarmonicUpperBoundSphereDiameterPairScore"""
10154  _IMP_core.HarmonicUpperBoundSphereDiameterPairScore_swiginit(self, _IMP_core.new_HarmonicUpperBoundSphereDiameterPairScore(d0, k))
10155 
10156  def get_rest_length(self):
10157  r"""get_rest_length(HarmonicUpperBoundSphereDiameterPairScore self) -> double"""
10158  return _IMP_core.HarmonicUpperBoundSphereDiameterPairScore_get_rest_length(self)
10159 
10160  def get_stiffness(self):
10161  r"""get_stiffness(HarmonicUpperBoundSphereDiameterPairScore self) -> double"""
10162  return _IMP_core.HarmonicUpperBoundSphereDiameterPairScore_get_stiffness(self)
10163 
10164  def do_get_inputs(self, m, pis):
10165  r"""do_get_inputs(HarmonicUpperBoundSphereDiameterPairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
10166  return _IMP_core.HarmonicUpperBoundSphereDiameterPairScore_do_get_inputs(self, m, pis)
10167 
10168  def evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked=False):
10169  r"""evaluate_indexes(HarmonicUpperBoundSphereDiameterPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
10170  return _IMP_core.HarmonicUpperBoundSphereDiameterPairScore_evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked)
10171 
10172  def evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked=False):
10173  r"""evaluate_indexes_scores(HarmonicUpperBoundSphereDiameterPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
10174  return _IMP_core.HarmonicUpperBoundSphereDiameterPairScore_evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked)
10175 
10176  def evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked=False):
10177  r"""evaluate_indexes_delta(HarmonicUpperBoundSphereDiameterPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, std::vector< unsigned int,std::allocator< unsigned int > > const & indexes, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
10178  return _IMP_core.HarmonicUpperBoundSphereDiameterPairScore_evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked)
10179 
10180  def evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked=False):
10181  r"""evaluate_if_good_indexes(HarmonicUpperBoundSphereDiameterPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, double max, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
10182  return _IMP_core.HarmonicUpperBoundSphereDiameterPairScore_evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked)
10183 
10184  def get_version_info(self):
10185  r"""get_version_info(HarmonicUpperBoundSphereDiameterPairScore self) -> VersionInfo"""
10186  return _IMP_core.HarmonicUpperBoundSphereDiameterPairScore_get_version_info(self)
10187  __swig_destroy__ = _IMP_core.delete_HarmonicUpperBoundSphereDiameterPairScore
10188 
10189  def __str__(self):
10190  r"""__str__(HarmonicUpperBoundSphereDiameterPairScore self) -> std::string"""
10191  return _IMP_core.HarmonicUpperBoundSphereDiameterPairScore___str__(self)
10192 
10193  def __repr__(self):
10194  r"""__repr__(HarmonicUpperBoundSphereDiameterPairScore self) -> std::string"""
10195  return _IMP_core.HarmonicUpperBoundSphereDiameterPairScore___repr__(self)
10196 
10197  @staticmethod
10198  def get_from(o):
10199  return _object_cast_to_HarmonicUpperBoundSphereDiameterPairScore(o)
10200 
10201 
10202 # Register HarmonicUpperBoundSphereDiameterPairScore in _IMP_core:
10203 _IMP_core.HarmonicUpperBoundSphereDiameterPairScore_swigregister(HarmonicUpperBoundSphereDiameterPairScore)
10204 class HarmonicSphereDistancePairScore(IMP.PairScore):
10205  r"""Proxy of C++ IMP::core::HarmonicSphereDistancePairScore class."""
10206 
10207  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10208 
10209  def __init__(self, *args):
10210  r"""
10211  __init__(HarmonicSphereDistancePairScore self, double x0, double k, std::string name="HarmonicSphereDistancePairScore%1%") -> HarmonicSphereDistancePairScore
10212  __init__(HarmonicSphereDistancePairScore self) -> HarmonicSphereDistancePairScore
10213  """
10214  _IMP_core.HarmonicSphereDistancePairScore_swiginit(self, _IMP_core.new_HarmonicSphereDistancePairScore(*args))
10215 
10216  def do_get_inputs(self, m, pis):
10217  r"""do_get_inputs(HarmonicSphereDistancePairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
10218  return _IMP_core.HarmonicSphereDistancePairScore_do_get_inputs(self, m, pis)
10219 
10220  def get_score_functor(self, *args):
10221  r"""
10222  get_score_functor(HarmonicSphereDistancePairScore self) -> IMP::core::HarmonicSphereDistanceScore
10223  get_score_functor(HarmonicSphereDistancePairScore self) -> IMP::core::HarmonicSphereDistanceScore const &
10224  """
10225  return _IMP_core.HarmonicSphereDistancePairScore_get_score_functor(self, *args)
10226 
10227  def get_x0(self):
10228  r"""get_x0(HarmonicSphereDistancePairScore self) -> double"""
10229  return _IMP_core.HarmonicSphereDistancePairScore_get_x0(self)
10230 
10231  def get_k(self):
10232  r"""get_k(HarmonicSphereDistancePairScore self) -> double"""
10233  return _IMP_core.HarmonicSphereDistancePairScore_get_k(self)
10234 
10235  def get_version_info(self):
10236  r"""get_version_info(HarmonicSphereDistancePairScore self) -> VersionInfo"""
10237  return _IMP_core.HarmonicSphereDistancePairScore_get_version_info(self)
10238  __swig_destroy__ = _IMP_core.delete_HarmonicSphereDistancePairScore
10239 
10240  def __str__(self):
10241  r"""__str__(HarmonicSphereDistancePairScore self) -> std::string"""
10242  return _IMP_core.HarmonicSphereDistancePairScore___str__(self)
10243 
10244  def __repr__(self):
10245  r"""__repr__(HarmonicSphereDistancePairScore self) -> std::string"""
10246  return _IMP_core.HarmonicSphereDistancePairScore___repr__(self)
10247 
10248  @staticmethod
10249  def get_from(o):
10250  return _object_cast_to_HarmonicSphereDistancePairScore(o)
10251 
10252 
10253  def _get_as_binary(self):
10254  r"""_get_as_binary(HarmonicSphereDistancePairScore self) -> PyObject *"""
10255  return _IMP_core.HarmonicSphereDistancePairScore__get_as_binary(self)
10256 
10257  def _set_from_binary(self, p):
10258  r"""_set_from_binary(HarmonicSphereDistancePairScore self, PyObject * p)"""
10259  return _IMP_core.HarmonicSphereDistancePairScore__set_from_binary(self, p)
10260 
10261  def __getstate__(self):
10262  p = self._get_as_binary()
10263  if len(self.__dict__) > 1:
10264  d = self.__dict__.copy()
10265  del d['this']
10266  p = (d, p)
10267  return p
10268 
10269  def __setstate__(self, p):
10270  if not hasattr(self, 'this'):
10271  self.__init__()
10272  if isinstance(p, tuple):
10273  d, p = p
10274  self.__dict__.update(d)
10275  return self._set_from_binary(p)
10276 
10277 
10278  def _get_jax(self, m, indexes):
10279  import jax.numpy as jnp
10280  def jax_score(jm, d, k):
10281  xyzs = jm['xyz'][indexes]
10282  rs = jm['r'][indexes]
10283  diff = xyzs[:,0] - xyzs[:,1]
10284  drs = jnp.linalg.norm(diff, axis=1) - rs.sum(axis=1)
10285  return 0.5 * k * (d - drs)**2
10286  f = functools.partial(jax_score, d=self.get_x0(), k=self.get_k())
10287  return self._wrap_jax(m, f)
10288 
10289 
10290 # Register HarmonicSphereDistancePairScore in _IMP_core:
10291 _IMP_core.HarmonicSphereDistancePairScore_swigregister(HarmonicSphereDistancePairScore)
10292 class NormalizedSphereDistancePairScore(IMP.PairScore):
10293  r"""Proxy of C++ IMP::core::NormalizedSphereDistancePairScore class."""
10294 
10295  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10296 
10297  def __init__(self, *args):
10298  r"""__init__(NormalizedSphereDistancePairScore self, UnaryFunction f, FloatKey radius=IMP::FloatKey("radius")) -> NormalizedSphereDistancePairScore"""
10299  _IMP_core.NormalizedSphereDistancePairScore_swiginit(self, _IMP_core.new_NormalizedSphereDistancePairScore(*args))
10300 
10301  def do_get_inputs(self, m, pis):
10302  r"""do_get_inputs(NormalizedSphereDistancePairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
10303  return _IMP_core.NormalizedSphereDistancePairScore_do_get_inputs(self, m, pis)
10304 
10305  def evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked=False):
10306  r"""evaluate_indexes(NormalizedSphereDistancePairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
10307  return _IMP_core.NormalizedSphereDistancePairScore_evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked)
10308 
10309  def evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked=False):
10310  r"""evaluate_indexes_scores(NormalizedSphereDistancePairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
10311  return _IMP_core.NormalizedSphereDistancePairScore_evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked)
10312 
10313  def evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked=False):
10314  r"""evaluate_indexes_delta(NormalizedSphereDistancePairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, std::vector< unsigned int,std::allocator< unsigned int > > const & indexes, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
10315  return _IMP_core.NormalizedSphereDistancePairScore_evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked)
10316 
10317  def evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked=False):
10318  r"""evaluate_if_good_indexes(NormalizedSphereDistancePairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, double max, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
10319  return _IMP_core.NormalizedSphereDistancePairScore_evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked)
10320 
10321  def get_version_info(self):
10322  r"""get_version_info(NormalizedSphereDistancePairScore self) -> VersionInfo"""
10323  return _IMP_core.NormalizedSphereDistancePairScore_get_version_info(self)
10324  __swig_destroy__ = _IMP_core.delete_NormalizedSphereDistancePairScore
10325 
10326  def __str__(self):
10327  r"""__str__(NormalizedSphereDistancePairScore self) -> std::string"""
10328  return _IMP_core.NormalizedSphereDistancePairScore___str__(self)
10329 
10330  def __repr__(self):
10331  r"""__repr__(NormalizedSphereDistancePairScore self) -> std::string"""
10332  return _IMP_core.NormalizedSphereDistancePairScore___repr__(self)
10333 
10334  @staticmethod
10335  def get_from(o):
10336  return _object_cast_to_NormalizedSphereDistancePairScore(o)
10337 
10338 
10339 # Register NormalizedSphereDistancePairScore in _IMP_core:
10340 _IMP_core.NormalizedSphereDistancePairScore_swigregister(NormalizedSphereDistancePairScore)
10341 class WeightedSphereDistancePairScore(IMP.PairScore):
10342  r"""Proxy of C++ IMP::core::WeightedSphereDistancePairScore class."""
10343 
10344  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10345 
10346  def __init__(self, *args):
10347  r"""__init__(WeightedSphereDistancePairScore self, UnaryFunction f, FloatKey weight, FloatKey radius=IMP::FloatKey("radius")) -> WeightedSphereDistancePairScore"""
10348  _IMP_core.WeightedSphereDistancePairScore_swiginit(self, _IMP_core.new_WeightedSphereDistancePairScore(*args))
10349 
10350  def do_get_inputs(self, m, pis):
10351  r"""do_get_inputs(WeightedSphereDistancePairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
10352  return _IMP_core.WeightedSphereDistancePairScore_do_get_inputs(self, m, pis)
10353 
10354  def evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked=False):
10355  r"""evaluate_indexes(WeightedSphereDistancePairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
10356  return _IMP_core.WeightedSphereDistancePairScore_evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked)
10357 
10358  def evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked=False):
10359  r"""evaluate_indexes_scores(WeightedSphereDistancePairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
10360  return _IMP_core.WeightedSphereDistancePairScore_evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked)
10361 
10362  def evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked=False):
10363  r"""evaluate_indexes_delta(WeightedSphereDistancePairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, std::vector< unsigned int,std::allocator< unsigned int > > const & indexes, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
10364  return _IMP_core.WeightedSphereDistancePairScore_evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked)
10365 
10366  def evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked=False):
10367  r"""evaluate_if_good_indexes(WeightedSphereDistancePairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, double max, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
10368  return _IMP_core.WeightedSphereDistancePairScore_evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked)
10369 
10370  def get_version_info(self):
10371  r"""get_version_info(WeightedSphereDistancePairScore self) -> VersionInfo"""
10372  return _IMP_core.WeightedSphereDistancePairScore_get_version_info(self)
10373  __swig_destroy__ = _IMP_core.delete_WeightedSphereDistancePairScore
10374 
10375  def __str__(self):
10376  r"""__str__(WeightedSphereDistancePairScore self) -> std::string"""
10377  return _IMP_core.WeightedSphereDistancePairScore___str__(self)
10378 
10379  def __repr__(self):
10380  r"""__repr__(WeightedSphereDistancePairScore self) -> std::string"""
10381  return _IMP_core.WeightedSphereDistancePairScore___repr__(self)
10382 
10383  @staticmethod
10384  def get_from(o):
10385  return _object_cast_to_WeightedSphereDistancePairScore(o)
10386 
10387 
10388 # Register WeightedSphereDistancePairScore in _IMP_core:
10389 _IMP_core.WeightedSphereDistancePairScore_swigregister(WeightedSphereDistancePairScore)
10390 class SoftSpherePairScore(IMP.PairScore):
10391  r"""Proxy of C++ IMP::core::SoftSpherePairScore class."""
10392 
10393  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10394 
10395  def __init__(self, *args):
10396  r"""
10397  __init__(SoftSpherePairScore self, double k, std::string name="SoftSpherePairScore%1%") -> SoftSpherePairScore
10398  __init__(SoftSpherePairScore self) -> SoftSpherePairScore
10399  """
10400  _IMP_core.SoftSpherePairScore_swiginit(self, _IMP_core.new_SoftSpherePairScore(*args))
10401 
10402  def do_get_inputs(self, m, pis):
10403  r"""do_get_inputs(SoftSpherePairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
10404  return _IMP_core.SoftSpherePairScore_do_get_inputs(self, m, pis)
10405 
10406  def get_score_functor(self, *args):
10407  r"""
10408  get_score_functor(SoftSpherePairScore self) -> IMP::core::SoftSphereDistanceScore
10409  get_score_functor(SoftSpherePairScore self) -> IMP::core::SoftSphereDistanceScore const &
10410  """
10411  return _IMP_core.SoftSpherePairScore_get_score_functor(self, *args)
10412 
10413  def get_k(self):
10414  r"""get_k(SoftSpherePairScore self) -> double"""
10415  return _IMP_core.SoftSpherePairScore_get_k(self)
10416 
10417  def get_version_info(self):
10418  r"""get_version_info(SoftSpherePairScore self) -> VersionInfo"""
10419  return _IMP_core.SoftSpherePairScore_get_version_info(self)
10420  __swig_destroy__ = _IMP_core.delete_SoftSpherePairScore
10421 
10422  def __str__(self):
10423  r"""__str__(SoftSpherePairScore self) -> std::string"""
10424  return _IMP_core.SoftSpherePairScore___str__(self)
10425 
10426  def __repr__(self):
10427  r"""__repr__(SoftSpherePairScore self) -> std::string"""
10428  return _IMP_core.SoftSpherePairScore___repr__(self)
10429 
10430  @staticmethod
10431  def get_from(o):
10432  return _object_cast_to_SoftSpherePairScore(o)
10433 
10434 
10435  def _get_as_binary(self):
10436  r"""_get_as_binary(SoftSpherePairScore self) -> PyObject *"""
10437  return _IMP_core.SoftSpherePairScore__get_as_binary(self)
10438 
10439  def _set_from_binary(self, p):
10440  r"""_set_from_binary(SoftSpherePairScore self, PyObject * p)"""
10441  return _IMP_core.SoftSpherePairScore__set_from_binary(self, p)
10442 
10443  def __getstate__(self):
10444  p = self._get_as_binary()
10445  if len(self.__dict__) > 1:
10446  d = self.__dict__.copy()
10447  del d['this']
10448  p = (d, p)
10449  return p
10450 
10451  def __setstate__(self, p):
10452  if not hasattr(self, 'this'):
10453  self.__init__()
10454  if isinstance(p, tuple):
10455  d, p = p
10456  self.__dict__.update(d)
10457  return self._set_from_binary(p)
10458 
10459 
10460  def _get_jax(self, m, indexes):
10461  import jax.numpy as jnp
10462  import jax.lax
10463  def jax_score(jm, k):
10464  xyzs = jm['xyz'][indexes]
10465  rs = jm['r'][indexes]
10466  diff = xyzs[:,0] - xyzs[:,1]
10467  drs = jnp.linalg.norm(diff, axis=1) - rs.sum(axis=1)
10468  return 0.5 * k * jax.lax.min(drs, 0.0) ** 2
10469  f = functools.partial(jax_score, k=self.get_k())
10470  return self._wrap_jax(m, f)
10471 
10472 
10473 # Register SoftSpherePairScore in _IMP_core:
10474 _IMP_core.SoftSpherePairScore_swigregister(SoftSpherePairScore)
10475 class SurfaceDistancePairScore(IMP.PairScore):
10476  r"""Proxy of C++ IMP::core::SurfaceDistancePairScore class."""
10477 
10478  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10479 
10480  def __init__(self, *args):
10481  r"""__init__(SurfaceDistancePairScore self, UnaryFunction uf, std::string name="SurfaceDistancePairScore%1%") -> SurfaceDistancePairScore"""
10482  _IMP_core.SurfaceDistancePairScore_swiginit(self, _IMP_core.new_SurfaceDistancePairScore(*args))
10483 
10484  def do_get_inputs(self, m, pis):
10485  r"""do_get_inputs(SurfaceDistancePairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
10486  return _IMP_core.SurfaceDistancePairScore_do_get_inputs(self, m, pis)
10487 
10488  def get_version_info(self):
10489  r"""get_version_info(SurfaceDistancePairScore self) -> VersionInfo"""
10490  return _IMP_core.SurfaceDistancePairScore_get_version_info(self)
10491  __swig_destroy__ = _IMP_core.delete_SurfaceDistancePairScore
10492 
10493  def __str__(self):
10494  r"""__str__(SurfaceDistancePairScore self) -> std::string"""
10495  return _IMP_core.SurfaceDistancePairScore___str__(self)
10496 
10497  def __repr__(self):
10498  r"""__repr__(SurfaceDistancePairScore self) -> std::string"""
10499  return _IMP_core.SurfaceDistancePairScore___repr__(self)
10500 
10501  @staticmethod
10502  def get_from(o):
10503  return _object_cast_to_SurfaceDistancePairScore(o)
10504 
10505 
10506 # Register SurfaceDistancePairScore in _IMP_core:
10507 _IMP_core.SurfaceDistancePairScore_swigregister(SurfaceDistancePairScore)
10508 class SurfaceHeightPairScore(IMP.PairScore):
10509  r"""Proxy of C++ IMP::core::SurfaceHeightPairScore class."""
10510 
10511  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10512 
10513  def __init__(self, *args):
10514  r"""__init__(SurfaceHeightPairScore self, UnaryFunction uf, std::string name="SurfaceHeightPairScore%1%") -> SurfaceHeightPairScore"""
10515  _IMP_core.SurfaceHeightPairScore_swiginit(self, _IMP_core.new_SurfaceHeightPairScore(*args))
10516 
10517  def do_get_inputs(self, m, pis):
10518  r"""do_get_inputs(SurfaceHeightPairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
10519  return _IMP_core.SurfaceHeightPairScore_do_get_inputs(self, m, pis)
10520 
10521  def get_version_info(self):
10522  r"""get_version_info(SurfaceHeightPairScore self) -> VersionInfo"""
10523  return _IMP_core.SurfaceHeightPairScore_get_version_info(self)
10524  __swig_destroy__ = _IMP_core.delete_SurfaceHeightPairScore
10525 
10526  def __str__(self):
10527  r"""__str__(SurfaceHeightPairScore self) -> std::string"""
10528  return _IMP_core.SurfaceHeightPairScore___str__(self)
10529 
10530  def __repr__(self):
10531  r"""__repr__(SurfaceHeightPairScore self) -> std::string"""
10532  return _IMP_core.SurfaceHeightPairScore___repr__(self)
10533 
10534  @staticmethod
10535  def get_from(o):
10536  return _object_cast_to_SurfaceHeightPairScore(o)
10537 
10538 
10539 # Register SurfaceHeightPairScore in _IMP_core:
10540 _IMP_core.SurfaceHeightPairScore_swigregister(SurfaceHeightPairScore)
10541 class SurfaceDepthPairScore(IMP.PairScore):
10542  r"""Proxy of C++ IMP::core::SurfaceDepthPairScore class."""
10543 
10544  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10545 
10546  def __init__(self, *args):
10547  r"""__init__(SurfaceDepthPairScore self, UnaryFunction uf, std::string name="SurfaceDepthPairScore%1%") -> SurfaceDepthPairScore"""
10548  _IMP_core.SurfaceDepthPairScore_swiginit(self, _IMP_core.new_SurfaceDepthPairScore(*args))
10549 
10550  def do_get_inputs(self, m, pis):
10551  r"""do_get_inputs(SurfaceDepthPairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
10552  return _IMP_core.SurfaceDepthPairScore_do_get_inputs(self, m, pis)
10553 
10554  def get_version_info(self):
10555  r"""get_version_info(SurfaceDepthPairScore self) -> VersionInfo"""
10556  return _IMP_core.SurfaceDepthPairScore_get_version_info(self)
10557  __swig_destroy__ = _IMP_core.delete_SurfaceDepthPairScore
10558 
10559  def __str__(self):
10560  r"""__str__(SurfaceDepthPairScore self) -> std::string"""
10561  return _IMP_core.SurfaceDepthPairScore___str__(self)
10562 
10563  def __repr__(self):
10564  r"""__repr__(SurfaceDepthPairScore self) -> std::string"""
10565  return _IMP_core.SurfaceDepthPairScore___repr__(self)
10566 
10567  @staticmethod
10568  def get_from(o):
10569  return _object_cast_to_SurfaceDepthPairScore(o)
10570 
10571 
10572 # Register SurfaceDepthPairScore in _IMP_core:
10573 _IMP_core.SurfaceDepthPairScore_swigregister(SurfaceDepthPairScore)
10574 class HarmonicSurfaceDistancePairScore(IMP.PairScore):
10575  r"""Proxy of C++ IMP::core::HarmonicSurfaceDistancePairScore class."""
10576 
10577  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10578 
10579  def __init__(self, *args):
10580  r"""__init__(HarmonicSurfaceDistancePairScore self, double x0, double k, std::string name="HarmonicSurfaceDistancePairScore%1%") -> HarmonicSurfaceDistancePairScore"""
10581  _IMP_core.HarmonicSurfaceDistancePairScore_swiginit(self, _IMP_core.new_HarmonicSurfaceDistancePairScore(*args))
10582 
10583  def do_get_inputs(self, m, pis):
10584  r"""do_get_inputs(HarmonicSurfaceDistancePairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
10585  return _IMP_core.HarmonicSurfaceDistancePairScore_do_get_inputs(self, m, pis)
10586 
10587  def get_version_info(self):
10588  r"""get_version_info(HarmonicSurfaceDistancePairScore self) -> VersionInfo"""
10589  return _IMP_core.HarmonicSurfaceDistancePairScore_get_version_info(self)
10590  __swig_destroy__ = _IMP_core.delete_HarmonicSurfaceDistancePairScore
10591 
10592  def __str__(self):
10593  r"""__str__(HarmonicSurfaceDistancePairScore self) -> std::string"""
10594  return _IMP_core.HarmonicSurfaceDistancePairScore___str__(self)
10595 
10596  def __repr__(self):
10597  r"""__repr__(HarmonicSurfaceDistancePairScore self) -> std::string"""
10598  return _IMP_core.HarmonicSurfaceDistancePairScore___repr__(self)
10599 
10600  @staticmethod
10601  def get_from(o):
10602  return _object_cast_to_HarmonicSurfaceDistancePairScore(o)
10603 
10604 
10605 # Register HarmonicSurfaceDistancePairScore in _IMP_core:
10606 _IMP_core.HarmonicSurfaceDistancePairScore_swigregister(HarmonicSurfaceDistancePairScore)
10607 class HarmonicSurfaceHeightPairScore(IMP.PairScore):
10608  r"""Proxy of C++ IMP::core::HarmonicSurfaceHeightPairScore class."""
10609 
10610  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10611 
10612  def __init__(self, *args):
10613  r"""__init__(HarmonicSurfaceHeightPairScore self, double x0, double k, std::string name="HarmonicSurfaceHeightPairScore%1%") -> HarmonicSurfaceHeightPairScore"""
10614  _IMP_core.HarmonicSurfaceHeightPairScore_swiginit(self, _IMP_core.new_HarmonicSurfaceHeightPairScore(*args))
10615 
10616  def do_get_inputs(self, m, pis):
10617  r"""do_get_inputs(HarmonicSurfaceHeightPairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
10618  return _IMP_core.HarmonicSurfaceHeightPairScore_do_get_inputs(self, m, pis)
10619 
10620  def get_version_info(self):
10621  r"""get_version_info(HarmonicSurfaceHeightPairScore self) -> VersionInfo"""
10622  return _IMP_core.HarmonicSurfaceHeightPairScore_get_version_info(self)
10623  __swig_destroy__ = _IMP_core.delete_HarmonicSurfaceHeightPairScore
10624 
10625  def __str__(self):
10626  r"""__str__(HarmonicSurfaceHeightPairScore self) -> std::string"""
10627  return _IMP_core.HarmonicSurfaceHeightPairScore___str__(self)
10628 
10629  def __repr__(self):
10630  r"""__repr__(HarmonicSurfaceHeightPairScore self) -> std::string"""
10631  return _IMP_core.HarmonicSurfaceHeightPairScore___repr__(self)
10632 
10633  @staticmethod
10634  def get_from(o):
10635  return _object_cast_to_HarmonicSurfaceHeightPairScore(o)
10636 
10637 
10638 # Register HarmonicSurfaceHeightPairScore in _IMP_core:
10639 _IMP_core.HarmonicSurfaceHeightPairScore_swigregister(HarmonicSurfaceHeightPairScore)
10640 class HarmonicSurfaceDepthPairScore(IMP.PairScore):
10641  r"""Proxy of C++ IMP::core::HarmonicSurfaceDepthPairScore class."""
10642 
10643  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10644 
10645  def __init__(self, *args):
10646  r"""__init__(HarmonicSurfaceDepthPairScore self, double x0, double k, std::string name="HarmonicSurfaceDepthPairScore%1%") -> HarmonicSurfaceDepthPairScore"""
10647  _IMP_core.HarmonicSurfaceDepthPairScore_swiginit(self, _IMP_core.new_HarmonicSurfaceDepthPairScore(*args))
10648 
10649  def do_get_inputs(self, m, pis):
10650  r"""do_get_inputs(HarmonicSurfaceDepthPairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
10651  return _IMP_core.HarmonicSurfaceDepthPairScore_do_get_inputs(self, m, pis)
10652 
10653  def get_version_info(self):
10654  r"""get_version_info(HarmonicSurfaceDepthPairScore self) -> VersionInfo"""
10655  return _IMP_core.HarmonicSurfaceDepthPairScore_get_version_info(self)
10656  __swig_destroy__ = _IMP_core.delete_HarmonicSurfaceDepthPairScore
10657 
10658  def __str__(self):
10659  r"""__str__(HarmonicSurfaceDepthPairScore self) -> std::string"""
10660  return _IMP_core.HarmonicSurfaceDepthPairScore___str__(self)
10661 
10662  def __repr__(self):
10663  r"""__repr__(HarmonicSurfaceDepthPairScore self) -> std::string"""
10664  return _IMP_core.HarmonicSurfaceDepthPairScore___repr__(self)
10665 
10666  @staticmethod
10667  def get_from(o):
10668  return _object_cast_to_HarmonicSurfaceDepthPairScore(o)
10669 
10670 
10671 # Register HarmonicSurfaceDepthPairScore in _IMP_core:
10672 _IMP_core.HarmonicSurfaceDepthPairScore_swigregister(HarmonicSurfaceDepthPairScore)
10673 class SoftSuperSurfacePairScore(IMP.PairScore):
10674  r"""Proxy of C++ IMP::core::SoftSuperSurfacePairScore class."""
10675 
10676  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10677 
10678  def __init__(self, *args):
10679  r"""__init__(SoftSuperSurfacePairScore self, double k, std::string name="SoftSuperSurfacePairScore%1%") -> SoftSuperSurfacePairScore"""
10680  _IMP_core.SoftSuperSurfacePairScore_swiginit(self, _IMP_core.new_SoftSuperSurfacePairScore(*args))
10681 
10682  def do_get_inputs(self, m, pis):
10683  r"""do_get_inputs(SoftSuperSurfacePairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
10684  return _IMP_core.SoftSuperSurfacePairScore_do_get_inputs(self, m, pis)
10685 
10686  def get_version_info(self):
10687  r"""get_version_info(SoftSuperSurfacePairScore self) -> VersionInfo"""
10688  return _IMP_core.SoftSuperSurfacePairScore_get_version_info(self)
10689  __swig_destroy__ = _IMP_core.delete_SoftSuperSurfacePairScore
10690 
10691  def __str__(self):
10692  r"""__str__(SoftSuperSurfacePairScore self) -> std::string"""
10693  return _IMP_core.SoftSuperSurfacePairScore___str__(self)
10694 
10695  def __repr__(self):
10696  r"""__repr__(SoftSuperSurfacePairScore self) -> std::string"""
10697  return _IMP_core.SoftSuperSurfacePairScore___repr__(self)
10698 
10699  @staticmethod
10700  def get_from(o):
10701  return _object_cast_to_SoftSuperSurfacePairScore(o)
10702 
10703 
10704 # Register SoftSuperSurfacePairScore in _IMP_core:
10705 _IMP_core.SoftSuperSurfacePairScore_swigregister(SoftSuperSurfacePairScore)
10706 class SoftSubSurfacePairScore(IMP.PairScore):
10707  r"""Proxy of C++ IMP::core::SoftSubSurfacePairScore class."""
10708 
10709  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10710 
10711  def __init__(self, *args):
10712  r"""__init__(SoftSubSurfacePairScore self, double k, std::string name="SoftSubSurfacePairScore%1%") -> SoftSubSurfacePairScore"""
10713  _IMP_core.SoftSubSurfacePairScore_swiginit(self, _IMP_core.new_SoftSubSurfacePairScore(*args))
10714 
10715  def do_get_inputs(self, m, pis):
10716  r"""do_get_inputs(SoftSubSurfacePairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
10717  return _IMP_core.SoftSubSurfacePairScore_do_get_inputs(self, m, pis)
10718 
10719  def get_version_info(self):
10720  r"""get_version_info(SoftSubSurfacePairScore self) -> VersionInfo"""
10721  return _IMP_core.SoftSubSurfacePairScore_get_version_info(self)
10722  __swig_destroy__ = _IMP_core.delete_SoftSubSurfacePairScore
10723 
10724  def __str__(self):
10725  r"""__str__(SoftSubSurfacePairScore self) -> std::string"""
10726  return _IMP_core.SoftSubSurfacePairScore___str__(self)
10727 
10728  def __repr__(self):
10729  r"""__repr__(SoftSubSurfacePairScore self) -> std::string"""
10730  return _IMP_core.SoftSubSurfacePairScore___repr__(self)
10731 
10732  @staticmethod
10733  def get_from(o):
10734  return _object_cast_to_SoftSubSurfacePairScore(o)
10735 
10736 
10737 # Register SoftSubSurfacePairScore in _IMP_core:
10738 _IMP_core.SoftSubSurfacePairScore_swigregister(SoftSubSurfacePairScore)
10739 class SurfaceTetheredChain(IMP.UnaryFunction):
10740  r"""Proxy of C++ IMP::core::SurfaceTetheredChain class."""
10741 
10742  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10743 
10744  def __init__(self, link_num, link_length):
10745  r"""__init__(SurfaceTetheredChain self, int link_num, double link_length) -> SurfaceTetheredChain"""
10746  _IMP_core.SurfaceTetheredChain_swiginit(self, _IMP_core.new_SurfaceTetheredChain(link_num, link_length))
10747 
10748  def get_version_info(self):
10749  r"""get_version_info(SurfaceTetheredChain self) -> VersionInfo"""
10750  return _IMP_core.SurfaceTetheredChain_get_version_info(self)
10751  __swig_destroy__ = _IMP_core.delete_SurfaceTetheredChain
10752 
10753  def get_link_number(self):
10754  r"""get_link_number(SurfaceTetheredChain self) -> int"""
10755  return _IMP_core.SurfaceTetheredChain_get_link_number(self)
10756 
10757  def get_link_length(self):
10758  r"""get_link_length(SurfaceTetheredChain self) -> double"""
10759  return _IMP_core.SurfaceTetheredChain_get_link_length(self)
10760 
10761  def set_link_number(self, N):
10762  r"""set_link_number(SurfaceTetheredChain self, int N)"""
10763  return _IMP_core.SurfaceTetheredChain_set_link_number(self, N)
10764 
10765  def set_link_length(self, b):
10766  r"""set_link_length(SurfaceTetheredChain self, double b)"""
10767  return _IMP_core.SurfaceTetheredChain_set_link_length(self, b)
10768 
10769  def get_distance_at_minimum(self):
10770  r"""get_distance_at_minimum(SurfaceTetheredChain self) -> double"""
10771  return _IMP_core.SurfaceTetheredChain_get_distance_at_minimum(self)
10772 
10773  def get_average_distance(self):
10774  r"""get_average_distance(SurfaceTetheredChain self) -> double"""
10775  return _IMP_core.SurfaceTetheredChain_get_average_distance(self)
10776 
10777  def __str__(self):
10778  r"""__str__(SurfaceTetheredChain self) -> std::string"""
10779  return _IMP_core.SurfaceTetheredChain___str__(self)
10780 
10781  def __repr__(self):
10782  r"""__repr__(SurfaceTetheredChain self) -> std::string"""
10783  return _IMP_core.SurfaceTetheredChain___repr__(self)
10784 
10785  @staticmethod
10786  def get_from(o):
10787  return _object_cast_to_SurfaceTetheredChain(o)
10788 
10789 
10790 # Register SurfaceTetheredChain in _IMP_core:
10791 _IMP_core.SurfaceTetheredChain_swigregister(SurfaceTetheredChain)
10792 class SurfaceSymmetryConstraint(IMP.Constraint):
10793  r"""Proxy of C++ IMP::core::SurfaceSymmetryConstraint class."""
10794 
10795  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10796 
10797  def __init__(self, m, ss, rbs):
10798  r"""__init__(SurfaceSymmetryConstraint self, Model m, IMP::ParticleIndexPair const & ss, IMP::ParticleIndexPair const & rbs) -> SurfaceSymmetryConstraint"""
10799  _IMP_core.SurfaceSymmetryConstraint_swiginit(self, _IMP_core.new_SurfaceSymmetryConstraint(m, ss, rbs))
10800 
10801  def do_get_inputs(self):
10802  r"""do_get_inputs(SurfaceSymmetryConstraint self) -> IMP::ModelObjectsTemp"""
10803  return _IMP_core.SurfaceSymmetryConstraint_do_get_inputs(self)
10804 
10805  def do_get_outputs(self):
10806  r"""do_get_outputs(SurfaceSymmetryConstraint self) -> IMP::ModelObjectsTemp"""
10807  return _IMP_core.SurfaceSymmetryConstraint_do_get_outputs(self)
10808 
10809  def get_version_info(self):
10810  r"""get_version_info(SurfaceSymmetryConstraint self) -> VersionInfo"""
10811  return _IMP_core.SurfaceSymmetryConstraint_get_version_info(self)
10812  __swig_destroy__ = _IMP_core.delete_SurfaceSymmetryConstraint
10813 
10814  def __str__(self):
10815  r"""__str__(SurfaceSymmetryConstraint self) -> std::string"""
10816  return _IMP_core.SurfaceSymmetryConstraint___str__(self)
10817 
10818  def __repr__(self):
10819  r"""__repr__(SurfaceSymmetryConstraint self) -> std::string"""
10820  return _IMP_core.SurfaceSymmetryConstraint___repr__(self)
10821 
10822  @staticmethod
10823  def get_from(o):
10824  return _object_cast_to_SurfaceSymmetryConstraint(o)
10825 
10826 
10827 # Register SurfaceSymmetryConstraint in _IMP_core:
10828 _IMP_core.SurfaceSymmetryConstraint_swigregister(SurfaceSymmetryConstraint)
10829 class SteepestDescent(IMP.AttributeOptimizer):
10830  r"""Proxy of C++ IMP::core::SteepestDescent class."""
10831 
10832  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10833 
10834  def __init__(self, *args):
10835  r"""__init__(SteepestDescent self, Model m, std::string name="SteepestDescent%1%") -> SteepestDescent"""
10836  _IMP_core.SteepestDescent_swiginit(self, _IMP_core.new_SteepestDescent(*args))
10837 
10838  def do_optimize(self, max_steps):
10839  r"""do_optimize(SteepestDescent self, unsigned int max_steps) -> IMP::Float"""
10840  return _IMP_core.SteepestDescent_do_optimize(self, max_steps)
10841 
10842  def get_version_info(self):
10843  r"""get_version_info(SteepestDescent self) -> VersionInfo"""
10844  return _IMP_core.SteepestDescent_get_version_info(self)
10845  __swig_destroy__ = _IMP_core.delete_SteepestDescent
10846 
10847  def set_threshold(self, t):
10848  r"""set_threshold(SteepestDescent self, IMP::Float t)"""
10849  return _IMP_core.SteepestDescent_set_threshold(self, t)
10850 
10851  def set_step_size(self, t):
10852  r"""set_step_size(SteepestDescent self, IMP::Float t)"""
10853  return _IMP_core.SteepestDescent_set_step_size(self, t)
10854 
10855  def set_maximum_step_size(self, t):
10856  r"""set_maximum_step_size(SteepestDescent self, IMP::Float t)"""
10857  return _IMP_core.SteepestDescent_set_maximum_step_size(self, t)
10858 
10859  def __str__(self):
10860  r"""__str__(SteepestDescent self) -> std::string"""
10861  return _IMP_core.SteepestDescent___str__(self)
10862 
10863  def __repr__(self):
10864  r"""__repr__(SteepestDescent self) -> std::string"""
10865  return _IMP_core.SteepestDescent___repr__(self)
10866 
10867  @staticmethod
10868  def get_from(o):
10869  return _object_cast_to_SteepestDescent(o)
10870 
10871 
10872 # Register SteepestDescent in _IMP_core:
10873 _IMP_core.SteepestDescent_swigregister(SteepestDescent)
10874 class TransformedDistancePairScore(IMP.PairScore):
10875  r"""Proxy of C++ IMP::core::TransformedDistancePairScore class."""
10876 
10877  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10878 
10879  def __init__(self, f, transformation):
10880  r"""__init__(TransformedDistancePairScore self, UnaryFunction f, Transformation3D transformation) -> TransformedDistancePairScore"""
10881  _IMP_core.TransformedDistancePairScore_swiginit(self, _IMP_core.new_TransformedDistancePairScore(f, transformation))
10882 
10883  def set_transformation(self, rot):
10884  r"""set_transformation(TransformedDistancePairScore self, Transformation3D rot)"""
10885  return _IMP_core.TransformedDistancePairScore_set_transformation(self, rot)
10886 
10887  def do_get_inputs(self, m, pis):
10888  r"""do_get_inputs(TransformedDistancePairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
10889  return _IMP_core.TransformedDistancePairScore_do_get_inputs(self, m, pis)
10890 
10891  def evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked=False):
10892  r"""evaluate_indexes(TransformedDistancePairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
10893  return _IMP_core.TransformedDistancePairScore_evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked)
10894 
10895  def evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked=False):
10896  r"""evaluate_indexes_scores(TransformedDistancePairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
10897  return _IMP_core.TransformedDistancePairScore_evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked)
10898 
10899  def evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked=False):
10900  r"""evaluate_indexes_delta(TransformedDistancePairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, std::vector< unsigned int,std::allocator< unsigned int > > const & indexes, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
10901  return _IMP_core.TransformedDistancePairScore_evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked)
10902 
10903  def evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked=False):
10904  r"""evaluate_if_good_indexes(TransformedDistancePairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, double max, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
10905  return _IMP_core.TransformedDistancePairScore_evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked)
10906 
10907  def get_version_info(self):
10908  r"""get_version_info(TransformedDistancePairScore self) -> VersionInfo"""
10909  return _IMP_core.TransformedDistancePairScore_get_version_info(self)
10910  __swig_destroy__ = _IMP_core.delete_TransformedDistancePairScore
10911 
10912  def __str__(self):
10913  r"""__str__(TransformedDistancePairScore self) -> std::string"""
10914  return _IMP_core.TransformedDistancePairScore___str__(self)
10915 
10916  def __repr__(self):
10917  r"""__repr__(TransformedDistancePairScore self) -> std::string"""
10918  return _IMP_core.TransformedDistancePairScore___repr__(self)
10919 
10920  @staticmethod
10921  def get_from(o):
10922  return _object_cast_to_TransformedDistancePairScore(o)
10923 
10924 
10925 # Register TransformedDistancePairScore in _IMP_core:
10926 _IMP_core.TransformedDistancePairScore_swigregister(TransformedDistancePairScore)
10927 class TypedPairScore(IMP.PairScore):
10928  r"""Proxy of C++ IMP::core::TypedPairScore class."""
10929 
10930  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10931 
10932  def __init__(self, typekey, allow_invalid_types=True):
10933  r"""__init__(TypedPairScore self, IntKey typekey, bool allow_invalid_types=True) -> TypedPairScore"""
10934  _IMP_core.TypedPairScore_swiginit(self, _IMP_core.new_TypedPairScore(typekey, allow_invalid_types))
10935 
10936  def set_particle_type(self, arg2):
10937  r"""set_particle_type(TypedPairScore self, Particle arg2)"""
10938  return _IMP_core.TypedPairScore_set_particle_type(self, arg2)
10939 
10940  def set_pair_score(self, ps, atype, btype):
10941  r"""set_pair_score(TypedPairScore self, PairScore ps, IMP::Int atype, IMP::Int btype)"""
10942  return _IMP_core.TypedPairScore_set_pair_score(self, ps, atype, btype)
10943 
10944  def do_get_inputs(self, m, pis):
10945  r"""do_get_inputs(TypedPairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
10946  return _IMP_core.TypedPairScore_do_get_inputs(self, m, pis)
10947 
10948  def evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked=False):
10949  r"""evaluate_indexes(TypedPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
10950  return _IMP_core.TypedPairScore_evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked)
10951 
10952  def evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked=False):
10953  r"""evaluate_indexes_scores(TypedPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
10954  return _IMP_core.TypedPairScore_evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked)
10955 
10956  def evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked=False):
10957  r"""evaluate_indexes_delta(TypedPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, std::vector< unsigned int,std::allocator< unsigned int > > const & indexes, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
10958  return _IMP_core.TypedPairScore_evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked)
10959 
10960  def evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked=False):
10961  r"""evaluate_if_good_indexes(TypedPairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, double max, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
10962  return _IMP_core.TypedPairScore_evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked)
10963 
10964  def get_version_info(self):
10965  r"""get_version_info(TypedPairScore self) -> VersionInfo"""
10966  return _IMP_core.TypedPairScore_get_version_info(self)
10967  __swig_destroy__ = _IMP_core.delete_TypedPairScore
10968 
10969  def __str__(self):
10970  r"""__str__(TypedPairScore self) -> std::string"""
10971  return _IMP_core.TypedPairScore___str__(self)
10972 
10973  def __repr__(self):
10974  r"""__repr__(TypedPairScore self) -> std::string"""
10975  return _IMP_core.TypedPairScore___repr__(self)
10976 
10977  @staticmethod
10978  def get_from(o):
10979  return _object_cast_to_TypedPairScore(o)
10980 
10981 
10982 # Register TypedPairScore in _IMP_core:
10983 _IMP_core.TypedPairScore_swigregister(TypedPairScore)
10984 class RigidBodyDistancePairScore(KClosePairsPairScore):
10985  r"""Proxy of C++ IMP::core::RigidBodyDistancePairScore class."""
10986 
10987  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
10988 
10989  def __init__(self, ps, r):
10990  r"""__init__(RigidBodyDistancePairScore self, PairScore ps, Refiner r) -> RigidBodyDistancePairScore"""
10991  _IMP_core.RigidBodyDistancePairScore_swiginit(self, _IMP_core.new_RigidBodyDistancePairScore(ps, r))
10992 
10993  def __str__(self):
10994  r"""__str__(RigidBodyDistancePairScore self) -> std::string"""
10995  return _IMP_core.RigidBodyDistancePairScore___str__(self)
10996 
10997  def __repr__(self):
10998  r"""__repr__(RigidBodyDistancePairScore self) -> std::string"""
10999  return _IMP_core.RigidBodyDistancePairScore___repr__(self)
11000 
11001  @staticmethod
11002  def get_from(o):
11003  return _object_cast_to_RigidBodyDistancePairScore(o)
11004 
11005  __swig_destroy__ = _IMP_core.delete_RigidBodyDistancePairScore
11006 
11007 # Register RigidBodyDistancePairScore in _IMP_core:
11008 _IMP_core.RigidBodyDistancePairScore_swigregister(RigidBodyDistancePairScore)
11009 class RigidBodyAnglePairScore(IMP.PairScore):
11010  r"""Proxy of C++ IMP::core::RigidBodyAnglePairScore class."""
11011 
11012  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
11013 
11014  def __init__(self, f):
11015  r"""__init__(RigidBodyAnglePairScore self, UnaryFunction f) -> RigidBodyAnglePairScore"""
11016  _IMP_core.RigidBodyAnglePairScore_swiginit(self, _IMP_core.new_RigidBodyAnglePairScore(f))
11017 
11018  def do_get_inputs(self, m, pis):
11019  r"""do_get_inputs(RigidBodyAnglePairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
11020  return _IMP_core.RigidBodyAnglePairScore_do_get_inputs(self, m, pis)
11021 
11022  def evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked=False):
11023  r"""evaluate_indexes(RigidBodyAnglePairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
11024  return _IMP_core.RigidBodyAnglePairScore_evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked)
11025 
11026  def evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked=False):
11027  r"""evaluate_indexes_scores(RigidBodyAnglePairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
11028  return _IMP_core.RigidBodyAnglePairScore_evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked)
11029 
11030  def evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked=False):
11031  r"""evaluate_indexes_delta(RigidBodyAnglePairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, std::vector< unsigned int,std::allocator< unsigned int > > const & indexes, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
11032  return _IMP_core.RigidBodyAnglePairScore_evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked)
11033 
11034  def evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked=False):
11035  r"""evaluate_if_good_indexes(RigidBodyAnglePairScore self, Model m, IMP::ParticleIndexPairs const & p, DerivativeAccumulator da, double max, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
11036  return _IMP_core.RigidBodyAnglePairScore_evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked)
11037 
11038  def get_version_info(self):
11039  r"""get_version_info(RigidBodyAnglePairScore self) -> VersionInfo"""
11040  return _IMP_core.RigidBodyAnglePairScore_get_version_info(self)
11041  __swig_destroy__ = _IMP_core.delete_RigidBodyAnglePairScore
11042 
11043  def __str__(self):
11044  r"""__str__(RigidBodyAnglePairScore self) -> std::string"""
11045  return _IMP_core.RigidBodyAnglePairScore___str__(self)
11046 
11047  def __repr__(self):
11048  r"""__repr__(RigidBodyAnglePairScore self) -> std::string"""
11049  return _IMP_core.RigidBodyAnglePairScore___repr__(self)
11050 
11051  @staticmethod
11052  def get_from(o):
11053  return _object_cast_to_RigidBodyAnglePairScore(o)
11054 
11055 
11056 # Register RigidBodyAnglePairScore in _IMP_core:
11057 _IMP_core.RigidBodyAnglePairScore_swigregister(RigidBodyAnglePairScore)
11058 class TableRefiner(IMP.Refiner):
11059  r"""Proxy of C++ IMP::core::TableRefiner class."""
11060 
11061  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
11062 
11063  def __init__(self):
11064  r"""__init__(TableRefiner self) -> TableRefiner"""
11065  _IMP_core.TableRefiner_swiginit(self, _IMP_core.new_TableRefiner())
11066 
11067  def add_particle(self, p, ps):
11068  r"""add_particle(TableRefiner self, Particle p, IMP::ParticlesTemp const & ps)"""
11069  return _IMP_core.TableRefiner_add_particle(self, p, ps)
11070 
11071  def remove_particle(self, p):
11072  r"""remove_particle(TableRefiner self, Particle p)"""
11073  return _IMP_core.TableRefiner_remove_particle(self, p)
11074 
11075  def set_particle(self, p, ps):
11076  r"""set_particle(TableRefiner self, Particle p, IMP::ParticlesTemp const & ps)"""
11077  return _IMP_core.TableRefiner_set_particle(self, p, ps)
11078 
11079  def do_get_inputs(self, m, pis):
11080  r"""do_get_inputs(TableRefiner self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
11081  return _IMP_core.TableRefiner_do_get_inputs(self, m, pis)
11082 
11083  def get_version_info(self):
11084  r"""get_version_info(TableRefiner self) -> VersionInfo"""
11085  return _IMP_core.TableRefiner_get_version_info(self)
11086  __swig_destroy__ = _IMP_core.delete_TableRefiner
11087 
11088  def __str__(self):
11089  r"""__str__(TableRefiner self) -> std::string"""
11090  return _IMP_core.TableRefiner___str__(self)
11091 
11092  def __repr__(self):
11093  r"""__repr__(TableRefiner self) -> std::string"""
11094  return _IMP_core.TableRefiner___repr__(self)
11095 
11096  @staticmethod
11097  def get_from(o):
11098  return _object_cast_to_TableRefiner(o)
11099 
11100 
11101 # Register TableRefiner in _IMP_core:
11102 _IMP_core.TableRefiner_swigregister(TableRefiner)
11103 LOWER = _IMP_core.LOWER
11104 
11105 BOTH = _IMP_core.BOTH
11106 
11107 UPPER = _IMP_core.UPPER
11108 
11109 class MCCGSampler(IMP.Sampler):
11110  r"""Proxy of C++ IMP::core::MCCGSampler class."""
11111 
11112  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
11113 
11114  def __init__(self, *args):
11115  r"""__init__(MCCGSampler self, Model m, std::string name="MCCG Sampler %1%") -> MCCGSampler"""
11116  _IMP_core.MCCGSampler_swiginit(self, _IMP_core.new_MCCGSampler(*args))
11117 
11118  def set_bounding_box(self, bb):
11119  r"""set_bounding_box(MCCGSampler self, BoundingBox3D bb)"""
11120  return _IMP_core.MCCGSampler_set_bounding_box(self, bb)
11121 
11122  def set_number_of_attempts(self, att):
11123  r"""set_number_of_attempts(MCCGSampler self, unsigned int att)"""
11124  return _IMP_core.MCCGSampler_set_number_of_attempts(self, att)
11125 
11126  def set_number_of_monte_carlo_steps(self, cg):
11127  r"""set_number_of_monte_carlo_steps(MCCGSampler self, unsigned int cg)"""
11128  return _IMP_core.MCCGSampler_set_number_of_monte_carlo_steps(self, cg)
11129 
11130  def set_number_of_conjugate_gradient_steps(self, cg):
11131  r"""set_number_of_conjugate_gradient_steps(MCCGSampler self, unsigned int cg)"""
11132  return _IMP_core.MCCGSampler_set_number_of_conjugate_gradient_steps(self, cg)
11133 
11134  def set_max_monte_carlo_step_size(self, *args):
11135  r"""
11136  set_max_monte_carlo_step_size(MCCGSampler self, double d)
11137  set_max_monte_carlo_step_size(MCCGSampler self, FloatKey k, double d)
11138  """
11139  return _IMP_core.MCCGSampler_set_max_monte_carlo_step_size(self, *args)
11140 
11141  def set_is_refining(self, tf):
11142  r"""set_is_refining(MCCGSampler self, bool tf)"""
11143  return _IMP_core.MCCGSampler_set_is_refining(self, tf)
11144 
11145  def set_local_optimizer(self, opt):
11146  r"""set_local_optimizer(MCCGSampler self, Optimizer opt)"""
11147  return _IMP_core.MCCGSampler_set_local_optimizer(self, opt)
11148 
11149  def set_save_rejected_configurations(self, tf):
11150  r"""set_save_rejected_configurations(MCCGSampler self, bool tf)"""
11151  return _IMP_core.MCCGSampler_set_save_rejected_configurations(self, tf)
11152 
11153  def get_rejected_configurations(self):
11154  r"""get_rejected_configurations(MCCGSampler self) -> ConfigurationSet"""
11155  return _IMP_core.MCCGSampler_get_rejected_configurations(self)
11156  def __get_optimizer_states(self): return IMP._list_util.VarList(getdimfunc=self.get_number_of_optimizer_states, getfunc=self.get_optimizer_state, erasefunc=self.erase_optimizer_state, appendfunc=self.add_optimizer_state, extendfunc=self.add_optimizer_states, clearfunc=self.clear_optimizer_states, indexfunc=self._python_index_optimizer_state)
11157  def __set_optimizer_states(self, obj): IMP._list_util.set_varlist(self.optimizer_states, obj)
11158  def __del_optimizer_states(self): IMP._list_util.del_varlist(self.optimizer_states)
11159  optimizer_states = property(__get_optimizer_states, __set_optimizer_states, __del_optimizer_states, doc="List of ##ucnames")
11160 
11161  def remove_optimizer_state(self, d):
11162  r"""remove_optimizer_state(MCCGSampler self, OptimizerState d)"""
11163  return _IMP_core.MCCGSampler_remove_optimizer_state(self, d)
11164 
11165  def _python_index_optimizer_state(self, d, start, stop):
11166  r"""_python_index_optimizer_state(MCCGSampler self, OptimizerState d, unsigned int start, unsigned int stop) -> unsigned int"""
11167  return _IMP_core.MCCGSampler__python_index_optimizer_state(self, d, start, stop)
11168 
11169  def remove_optimizer_states(self, d):
11170  r"""remove_optimizer_states(MCCGSampler self, IMP::OptimizerStates const & d)"""
11171  return _IMP_core.MCCGSampler_remove_optimizer_states(self, d)
11172 
11173  def set_optimizer_states(self, ps):
11174  r"""set_optimizer_states(MCCGSampler self, IMP::OptimizerStates const & ps)"""
11175  return _IMP_core.MCCGSampler_set_optimizer_states(self, ps)
11176 
11177  def set_optimizer_states_order(self, objs):
11178  r"""set_optimizer_states_order(MCCGSampler self, IMP::OptimizerStates const & objs)"""
11179  return _IMP_core.MCCGSampler_set_optimizer_states_order(self, objs)
11180 
11181  def add_optimizer_state(self, obj):
11182  r"""add_optimizer_state(MCCGSampler self, OptimizerState obj) -> unsigned int"""
11183  return _IMP_core.MCCGSampler_add_optimizer_state(self, obj)
11184 
11185  def add_optimizer_states(self, objs):
11186  r"""add_optimizer_states(MCCGSampler self, IMP::OptimizerStates const & objs)"""
11187  return _IMP_core.MCCGSampler_add_optimizer_states(self, objs)
11188 
11189  def clear_optimizer_states(self):
11190  r"""clear_optimizer_states(MCCGSampler self)"""
11191  return _IMP_core.MCCGSampler_clear_optimizer_states(self)
11192 
11193  def get_number_of_optimizer_states(self):
11194  r"""get_number_of_optimizer_states(MCCGSampler self) -> unsigned int"""
11195  return _IMP_core.MCCGSampler_get_number_of_optimizer_states(self)
11196 
11197  def get_has_optimizer_states(self):
11198  r"""get_has_optimizer_states(MCCGSampler self) -> bool"""
11199  return _IMP_core.MCCGSampler_get_has_optimizer_states(self)
11200 
11201  def get_optimizer_state(self, i):
11202  r"""get_optimizer_state(MCCGSampler self, unsigned int i) -> OptimizerState"""
11203  return _IMP_core.MCCGSampler_get_optimizer_state(self, i)
11204 
11205  def get_optimizer_states(self):
11206  r"""get_optimizer_states(MCCGSampler self) -> IMP::OptimizerStates"""
11207  return _IMP_core.MCCGSampler_get_optimizer_states(self)
11208 
11209  def erase_optimizer_state(self, i):
11210  r"""erase_optimizer_state(MCCGSampler self, unsigned int i)"""
11211  return _IMP_core.MCCGSampler_erase_optimizer_state(self, i)
11212 
11213  def reserve_optimizer_states(self, sz):
11214  r"""reserve_optimizer_states(MCCGSampler self, unsigned int sz)"""
11215  return _IMP_core.MCCGSampler_reserve_optimizer_states(self, sz)
11216 
11217  def do_sample(self):
11218  r"""do_sample(MCCGSampler self) -> ConfigurationSet"""
11219  return _IMP_core.MCCGSampler_do_sample(self)
11220 
11221  def get_version_info(self):
11222  r"""get_version_info(MCCGSampler self) -> VersionInfo"""
11223  return _IMP_core.MCCGSampler_get_version_info(self)
11224  __swig_destroy__ = _IMP_core.delete_MCCGSampler
11225 
11226  def __str__(self):
11227  r"""__str__(MCCGSampler self) -> std::string"""
11228  return _IMP_core.MCCGSampler___str__(self)
11229 
11230  def __repr__(self):
11231  r"""__repr__(MCCGSampler self) -> std::string"""
11232  return _IMP_core.MCCGSampler___repr__(self)
11233 
11234  @staticmethod
11235  def get_from(o):
11236  return _object_cast_to_MCCGSampler(o)
11237 
11238 
11239 # Register MCCGSampler in _IMP_core:
11240 _IMP_core.MCCGSampler_swigregister(MCCGSampler)
11241 class MinimumRestraint(IMP.Restraint):
11242  r"""Proxy of C++ IMP::core::MinimumRestraint class."""
11243 
11244  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
11245 
11246  def __init__(self, *args):
11247  r"""__init__(MinimumRestraint self, unsigned int num, IMP::Restraints const & rs=IMP::Restraints(), std::string name="MinimumRestraint %1%") -> MinimumRestraint"""
11248  _IMP_core.MinimumRestraint_swiginit(self, _IMP_core.new_MinimumRestraint(*args))
11249 
11250  def do_get_inputs(self):
11251  r"""do_get_inputs(MinimumRestraint self) -> IMP::ModelObjectsTemp"""
11252  return _IMP_core.MinimumRestraint_do_get_inputs(self)
11253 
11254  def get_version_info(self):
11255  r"""get_version_info(MinimumRestraint self) -> VersionInfo"""
11256  return _IMP_core.MinimumRestraint_get_version_info(self)
11257  __swig_destroy__ = _IMP_core.delete_MinimumRestraint
11258  def __get_restraints(self): return IMP._list_util.VarList(getdimfunc=self.get_number_of_restraints, getfunc=self.get_restraint, erasefunc=self.erase_restraint, appendfunc=self.add_restraint, extendfunc=self.add_restraints, clearfunc=self.clear_restraints, indexfunc=self._python_index_restraint)
11259  def __set_restraints(self, obj): IMP._list_util.set_varlist(self.restraints, obj)
11260  def __del_restraints(self): IMP._list_util.del_varlist(self.restraints)
11261  restraints = property(__get_restraints, __set_restraints, __del_restraints, doc="List of ##ucnames")
11262 
11263  def remove_restraint(self, d):
11264  r"""remove_restraint(MinimumRestraint self, Restraint d)"""
11265  return _IMP_core.MinimumRestraint_remove_restraint(self, d)
11266 
11267  def _python_index_restraint(self, d, start, stop):
11268  r"""_python_index_restraint(MinimumRestraint self, Restraint d, unsigned int start, unsigned int stop) -> unsigned int"""
11269  return _IMP_core.MinimumRestraint__python_index_restraint(self, d, start, stop)
11270 
11271  def remove_restraints(self, d):
11272  r"""remove_restraints(MinimumRestraint self, IMP::Restraints const & d)"""
11273  return _IMP_core.MinimumRestraint_remove_restraints(self, d)
11274 
11275  def set_restraints(self, ps):
11276  r"""set_restraints(MinimumRestraint self, IMP::Restraints const & ps)"""
11277  return _IMP_core.MinimumRestraint_set_restraints(self, ps)
11278 
11279  def set_restraints_order(self, objs):
11280  r"""set_restraints_order(MinimumRestraint self, IMP::Restraints const & objs)"""
11281  return _IMP_core.MinimumRestraint_set_restraints_order(self, objs)
11282 
11283  def add_restraint(self, obj):
11284  r"""add_restraint(MinimumRestraint self, Restraint obj) -> unsigned int"""
11285  return _IMP_core.MinimumRestraint_add_restraint(self, obj)
11286 
11287  def add_restraints(self, objs):
11288  r"""add_restraints(MinimumRestraint self, IMP::Restraints const & objs)"""
11289  return _IMP_core.MinimumRestraint_add_restraints(self, objs)
11290 
11291  def clear_restraints(self):
11292  r"""clear_restraints(MinimumRestraint self)"""
11293  return _IMP_core.MinimumRestraint_clear_restraints(self)
11294 
11295  def get_number_of_restraints(self):
11296  r"""get_number_of_restraints(MinimumRestraint self) -> unsigned int"""
11297  return _IMP_core.MinimumRestraint_get_number_of_restraints(self)
11298 
11299  def get_has_restraints(self):
11300  r"""get_has_restraints(MinimumRestraint self) -> bool"""
11301  return _IMP_core.MinimumRestraint_get_has_restraints(self)
11302 
11303  def get_restraint(self, i):
11304  r"""get_restraint(MinimumRestraint self, unsigned int i) -> Restraint"""
11305  return _IMP_core.MinimumRestraint_get_restraint(self, i)
11306 
11307  def get_restraints(self):
11308  r"""get_restraints(MinimumRestraint self) -> IMP::Restraints"""
11309  return _IMP_core.MinimumRestraint_get_restraints(self)
11310 
11311  def erase_restraint(self, i):
11312  r"""erase_restraint(MinimumRestraint self, unsigned int i)"""
11313  return _IMP_core.MinimumRestraint_erase_restraint(self, i)
11314 
11315  def reserve_restraints(self, sz):
11316  r"""reserve_restraints(MinimumRestraint self, unsigned int sz)"""
11317  return _IMP_core.MinimumRestraint_reserve_restraints(self, sz)
11318 
11319  def __str__(self):
11320  r"""__str__(MinimumRestraint self) -> std::string"""
11321  return _IMP_core.MinimumRestraint___str__(self)
11322 
11323  def __repr__(self):
11324  r"""__repr__(MinimumRestraint self) -> std::string"""
11325  return _IMP_core.MinimumRestraint___repr__(self)
11326 
11327  @staticmethod
11328  def get_from(o):
11329  return _object_cast_to_MinimumRestraint(o)
11330 
11331 
11332 # Register MinimumRestraint in _IMP_core:
11333 _IMP_core.MinimumRestraint_swigregister(MinimumRestraint)
11334 class Gaussian(RigidBody):
11335  r"""Proxy of C++ IMP::core::Gaussian class."""
11336 
11337  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
11338 
11339  def __init__(self, *args):
11340  r"""
11341  __init__(Gaussian self) -> Gaussian
11342  __init__(Gaussian self, Model m, ParticleIndex id) -> Gaussian
11343  __init__(Gaussian self, _ParticleAdaptor d) -> Gaussian
11344  """
11345  _IMP_core.Gaussian_swiginit(self, _IMP_core.new_Gaussian(*args))
11346 
11347  def show(self, *args):
11348  r"""show(Gaussian self, _ostream out=std::cout)"""
11349  return _IMP_core.Gaussian_show(self, *args)
11350 
11351  @staticmethod
11352  def setup_particle(*args):
11353  r"""
11354  setup_particle(Model m, ParticleIndex pi) -> Gaussian
11355  setup_particle(_ParticleAdaptor pa) -> Gaussian
11356  setup_particle(Model m, ParticleIndex pi, Gaussian3D g) -> Gaussian
11357  setup_particle(_ParticleAdaptor pa, Gaussian3D g) -> Gaussian
11358  """
11359  return _IMP_core.Gaussian_setup_particle(*args)
11360 
11361  @staticmethod
11362  def get_local_covariance_key():
11363  r"""get_local_covariance_key() -> ObjectKey"""
11364  return _IMP_core.Gaussian_get_local_covariance_key()
11365 
11366  @staticmethod
11367  def get_global_covariance_key():
11368  r"""get_global_covariance_key() -> ObjectKey"""
11369  return _IMP_core.Gaussian_get_global_covariance_key()
11370 
11371  @staticmethod
11372  def get_is_setup(*args):
11373  r"""
11374  get_is_setup(_ParticleAdaptor p) -> bool
11375  get_is_setup(Model m, ParticleIndex pi) -> bool
11376  """
11377  return _IMP_core.Gaussian_get_is_setup(*args)
11378 
11379  def get_local_covariance(self):
11380  r"""get_local_covariance(Gaussian self) -> Eigen::Matrix3d"""
11381  return _IMP_core.Gaussian_get_local_covariance(self)
11382 
11383  def get_variances(self):
11384  r"""get_variances(Gaussian self) -> Vector3D"""
11385  return _IMP_core.Gaussian_get_variances(self)
11386 
11387  def get_global_covariance(self):
11388  r"""get_global_covariance(Gaussian self) -> Eigen::Matrix3d"""
11389  return _IMP_core.Gaussian_get_global_covariance(self)
11390 
11391  def get_gaussian(self):
11392  r"""get_gaussian(Gaussian self) -> Gaussian3D"""
11393  return _IMP_core.Gaussian_get_gaussian(self)
11394 
11395  def set_gaussian(self, g):
11396  r"""set_gaussian(Gaussian self, Gaussian3D g)"""
11397  return _IMP_core.Gaussian_set_gaussian(self, g)
11398 
11399  def set_local_covariance(self, covar):
11400  r"""set_local_covariance(Gaussian self, Eigen::Vector3d const covar)"""
11401  return _IMP_core.Gaussian_set_local_covariance(self, covar)
11402 
11403  def set_variances(self, v):
11404  r"""set_variances(Gaussian self, Vector3D v)"""
11405  return _IMP_core.Gaussian_set_variances(self, v)
11406 
11407  def set_global_covariance(self, covar):
11408  r"""set_global_covariance(Gaussian self, Eigen::Matrix3d covar)"""
11409  return _IMP_core.Gaussian_set_global_covariance(self, covar)
11410 
11411  def update_global_covariance(self):
11412  r"""update_global_covariance(Gaussian self)"""
11413  return _IMP_core.Gaussian_update_global_covariance(self)
11414 
11415  def add_attribute(self, *args):
11416  r"""
11417  add_attribute(Gaussian self, FloatKey k, IMP::Float v, bool opt)
11418  add_attribute(Gaussian self, FloatKey a0, IMP::Float a1)
11419  add_attribute(Gaussian self, IntKey a0, IMP::Int a1)
11420  add_attribute(Gaussian self, FloatsKey a0, IMP::Floats a1)
11421  add_attribute(Gaussian self, IntsKey a0, IMP::Ints a1)
11422  add_attribute(Gaussian self, StringKey a0, IMP::String a1)
11423  add_attribute(Gaussian self, ParticleIndexKey a0, Particle a1)
11424  add_attribute(Gaussian self, ObjectKey a0, Object a1)
11425  add_attribute(Gaussian self, SparseFloatKey a0, IMP::Float a1)
11426  add_attribute(Gaussian self, SparseIntKey a0, IMP::Int a1)
11427  add_attribute(Gaussian self, SparseStringKey a0, IMP::String a1)
11428  add_attribute(Gaussian self, SparseParticleIndexKey a0, ParticleIndex a1)
11429  """
11430  return _IMP_core.Gaussian_add_attribute(self, *args)
11431 
11432  def get_value(self, *args):
11433  r"""
11434  get_value(Gaussian self, FloatKey a0) -> IMP::Float
11435  get_value(Gaussian self, IntKey a0) -> IMP::Int
11436  get_value(Gaussian self, FloatsKey a0) -> IMP::Floats
11437  get_value(Gaussian self, IntsKey a0) -> IMP::Ints
11438  get_value(Gaussian self, StringKey a0) -> IMP::String
11439  get_value(Gaussian self, ParticleIndexKey a0) -> Particle
11440  get_value(Gaussian self, ObjectKey a0) -> Object
11441  get_value(Gaussian self, SparseFloatKey a0) -> IMP::Float
11442  get_value(Gaussian self, SparseIntKey a0) -> IMP::Int
11443  get_value(Gaussian self, SparseStringKey a0) -> IMP::String
11444  get_value(Gaussian self, SparseParticleIndexKey a0) -> ParticleIndex
11445  """
11446  return _IMP_core.Gaussian_get_value(self, *args)
11447 
11448  def set_value(self, *args):
11449  r"""
11450  set_value(Gaussian self, FloatKey a0, IMP::Float a1)
11451  set_value(Gaussian self, IntKey a0, IMP::Int a1)
11452  set_value(Gaussian self, FloatsKey a0, IMP::Floats a1)
11453  set_value(Gaussian self, IntsKey a0, IMP::Ints a1)
11454  set_value(Gaussian self, StringKey a0, IMP::String a1)
11455  set_value(Gaussian self, ParticleIndexKey a0, Particle a1)
11456  set_value(Gaussian self, ObjectKey a0, Object a1)
11457  set_value(Gaussian self, SparseFloatKey a0, IMP::Float a1)
11458  set_value(Gaussian self, SparseIntKey a0, IMP::Int a1)
11459  set_value(Gaussian self, SparseStringKey a0, IMP::String a1)
11460  set_value(Gaussian self, SparseParticleIndexKey a0, ParticleIndex a1)
11461  """
11462  return _IMP_core.Gaussian_set_value(self, *args)
11463 
11464  def remove_attribute(self, *args):
11465  r"""
11466  remove_attribute(Gaussian self, FloatKey a0)
11467  remove_attribute(Gaussian self, IntKey a0)
11468  remove_attribute(Gaussian self, FloatsKey a0)
11469  remove_attribute(Gaussian self, IntsKey a0)
11470  remove_attribute(Gaussian self, StringKey a0)
11471  remove_attribute(Gaussian self, ParticleIndexKey a0)
11472  remove_attribute(Gaussian self, ObjectKey a0)
11473  remove_attribute(Gaussian self, SparseFloatKey a0)
11474  remove_attribute(Gaussian self, SparseIntKey a0)
11475  remove_attribute(Gaussian self, SparseStringKey a0)
11476  remove_attribute(Gaussian self, SparseParticleIndexKey a0)
11477  """
11478  return _IMP_core.Gaussian_remove_attribute(self, *args)
11479 
11480  def has_attribute(self, *args):
11481  r"""
11482  has_attribute(Gaussian self, FloatKey a0) -> bool
11483  has_attribute(Gaussian self, IntKey a0) -> bool
11484  has_attribute(Gaussian self, FloatsKey a0) -> bool
11485  has_attribute(Gaussian self, IntsKey a0) -> bool
11486  has_attribute(Gaussian self, StringKey a0) -> bool
11487  has_attribute(Gaussian self, ParticleIndexKey a0) -> bool
11488  has_attribute(Gaussian self, ObjectKey a0) -> bool
11489  has_attribute(Gaussian self, SparseFloatKey a0) -> bool
11490  has_attribute(Gaussian self, SparseIntKey a0) -> bool
11491  has_attribute(Gaussian self, SparseStringKey a0) -> bool
11492  has_attribute(Gaussian self, SparseParticleIndexKey a0) -> bool
11493  """
11494  return _IMP_core.Gaussian_has_attribute(self, *args)
11495 
11496  def get_derivative(self, a0):
11497  r"""get_derivative(Gaussian self, FloatKey a0) -> double"""
11498  return _IMP_core.Gaussian_get_derivative(self, a0)
11499 
11500  def get_name(self):
11501  r"""get_name(Gaussian self) -> std::string"""
11502  return _IMP_core.Gaussian_get_name(self)
11503 
11504  def clear_caches(self):
11505  r"""clear_caches(Gaussian self)"""
11506  return _IMP_core.Gaussian_clear_caches(self)
11507 
11508  def set_name(self, a0):
11509  r"""set_name(Gaussian self, std::string a0)"""
11510  return _IMP_core.Gaussian_set_name(self, a0)
11511 
11512  def set_check_level(self, a0):
11513  r"""set_check_level(Gaussian self, IMP::CheckLevel a0)"""
11514  return _IMP_core.Gaussian_set_check_level(self, a0)
11515 
11516  def add_to_derivative(self, a0, a1, a2):
11517  r"""add_to_derivative(Gaussian self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
11518  return _IMP_core.Gaussian_add_to_derivative(self, a0, a1, a2)
11519 
11520  def set_is_optimized(self, a0, a1):
11521  r"""set_is_optimized(Gaussian self, FloatKey a0, bool a1)"""
11522  return _IMP_core.Gaussian_set_is_optimized(self, a0, a1)
11523 
11524  def get_is_optimized(self, a0):
11525  r"""get_is_optimized(Gaussian self, FloatKey a0) -> bool"""
11526  return _IMP_core.Gaussian_get_is_optimized(self, a0)
11527 
11528  def get_check_level(self):
11529  r"""get_check_level(Gaussian self) -> IMP::CheckLevel"""
11530  return _IMP_core.Gaussian_get_check_level(self)
11531 
11532  def __eq__(self, *args):
11533  r"""
11534  __eq__(Gaussian self, Gaussian o) -> bool
11535  __eq__(Gaussian self, Particle d) -> bool
11536  """
11537  return _IMP_core.Gaussian___eq__(self, *args)
11538 
11539  def __ne__(self, *args):
11540  r"""
11541  __ne__(Gaussian self, Gaussian o) -> bool
11542  __ne__(Gaussian self, Particle d) -> bool
11543  """
11544  return _IMP_core.Gaussian___ne__(self, *args)
11545 
11546  def __le__(self, *args):
11547  r"""
11548  __le__(Gaussian self, Gaussian o) -> bool
11549  __le__(Gaussian self, Particle d) -> bool
11550  """
11551  return _IMP_core.Gaussian___le__(self, *args)
11552 
11553  def __lt__(self, *args):
11554  r"""
11555  __lt__(Gaussian self, Gaussian o) -> bool
11556  __lt__(Gaussian self, Particle d) -> bool
11557  """
11558  return _IMP_core.Gaussian___lt__(self, *args)
11559 
11560  def __ge__(self, *args):
11561  r"""
11562  __ge__(Gaussian self, Gaussian o) -> bool
11563  __ge__(Gaussian self, Particle d) -> bool
11564  """
11565  return _IMP_core.Gaussian___ge__(self, *args)
11566 
11567  def __gt__(self, *args):
11568  r"""
11569  __gt__(Gaussian self, Gaussian o) -> bool
11570  __gt__(Gaussian self, Particle d) -> bool
11571  """
11572  return _IMP_core.Gaussian___gt__(self, *args)
11573 
11574  def __hash__(self):
11575  r"""__hash__(Gaussian self) -> std::size_t"""
11576  return _IMP_core.Gaussian___hash__(self)
11577 
11578  def __str__(self):
11579  r"""__str__(Gaussian self) -> std::string"""
11580  return _IMP_core.Gaussian___str__(self)
11581 
11582  def __repr__(self):
11583  r"""__repr__(Gaussian self) -> std::string"""
11584  return _IMP_core.Gaussian___repr__(self)
11585 
11586  def _get_as_binary(self):
11587  r"""_get_as_binary(Gaussian self) -> PyObject *"""
11588  return _IMP_core.Gaussian__get_as_binary(self)
11589 
11590  def _set_from_binary(self, p):
11591  r"""_set_from_binary(Gaussian self, PyObject * p)"""
11592  return _IMP_core.Gaussian__set_from_binary(self, p)
11593 
11594  def __getstate__(self):
11595  p = self._get_as_binary()
11596  if len(self.__dict__) > 1:
11597  d = self.__dict__.copy()
11598  del d['this']
11599  p = (d, p)
11600  return p
11601 
11602  def __setstate__(self, p):
11603  if not hasattr(self, 'this'):
11604  self.__init__()
11605  if isinstance(p, tuple):
11606  d, p = p
11607  self.__dict__.update(d)
11608  return self._set_from_binary(p)
11609 
11610  __swig_destroy__ = _IMP_core.delete_Gaussian
11611 
11612 # Register Gaussian in _IMP_core:
11613 _IMP_core.Gaussian_swigregister(Gaussian)
11614 class PairRestraint(IMP.Restraint):
11615  r"""Proxy of C++ IMP::core::PairRestraint class."""
11616 
11617  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
11618 
11619  def __init__(self, *args):
11620  r"""
11621  __init__(PairRestraint self, Model m, PairScore ss, IMP::ParticleIndexPair const & vt, std::string name="PairRestraint %1%") -> PairRestraint
11622  __init__(PairRestraint self) -> PairRestraint
11623  """
11624  _IMP_core.PairRestraint_swiginit(self, _IMP_core.new_PairRestraint(*args))
11625 
11626  def get_score_object(self):
11627  r"""get_score_object(PairRestraint self) -> PairScore"""
11628  return _IMP_core.PairRestraint_get_score_object(self)
11629 
11630  def get_index(self):
11631  r"""get_index(PairRestraint self) -> IMP::PairScore::IndexArgument"""
11632  return _IMP_core.PairRestraint_get_index(self)
11633 
11634  def get_version_info(self):
11635  r"""get_version_info(PairRestraint self) -> VersionInfo"""
11636  return _IMP_core.PairRestraint_get_version_info(self)
11637  __swig_destroy__ = _IMP_core.delete_PairRestraint
11638 
11639  def __str__(self):
11640  r"""__str__(PairRestraint self) -> std::string"""
11641  return _IMP_core.PairRestraint___str__(self)
11642 
11643  def __repr__(self):
11644  r"""__repr__(PairRestraint self) -> std::string"""
11645  return _IMP_core.PairRestraint___repr__(self)
11646 
11647  @staticmethod
11648  def get_from(o):
11649  return _object_cast_to_PairRestraint(o)
11650 
11651 
11652  def _get_as_binary(self):
11653  r"""_get_as_binary(PairRestraint self) -> PyObject *"""
11654  return _IMP_core.PairRestraint__get_as_binary(self)
11655 
11656  def _set_from_binary(self, p):
11657  r"""_set_from_binary(PairRestraint self, PyObject * p)"""
11658  return _IMP_core.PairRestraint__set_from_binary(self, p)
11659 
11660  def __getstate__(self):
11661  p = self._get_as_binary()
11662  if len(self.__dict__) > 1:
11663  d = self.__dict__.copy()
11664  del d['this']
11665  p = (d, p)
11666  return p
11667 
11668  def __setstate__(self, p):
11669  if not hasattr(self, 'this'):
11670  self.__init__()
11671  if isinstance(p, tuple):
11672  d, p = p
11673  self.__dict__.update(d)
11674  return self._set_from_binary(p)
11675 
11676 
11677  def _get_jax(self):
11678  from . import _jax_util
11679  return _jax_util._get_jax_restraint(self)
11680 
11681 
11682 # Register PairRestraint in _IMP_core:
11683 _IMP_core.PairRestraint_swigregister(PairRestraint)
11684 class SingletonRestraint(IMP.Restraint):
11685  r"""Proxy of C++ IMP::core::SingletonRestraint class."""
11686 
11687  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
11688 
11689  def __init__(self, *args):
11690  r"""
11691  __init__(SingletonRestraint self, Model m, SingletonScore ss, ParticleIndex vt, std::string name="SingletonRestraint %1%") -> SingletonRestraint
11692  __init__(SingletonRestraint self) -> SingletonRestraint
11693  """
11694  _IMP_core.SingletonRestraint_swiginit(self, _IMP_core.new_SingletonRestraint(*args))
11695 
11696  def get_score_object(self):
11697  r"""get_score_object(SingletonRestraint self) -> SingletonScore"""
11698  return _IMP_core.SingletonRestraint_get_score_object(self)
11699 
11700  def get_index(self):
11701  r"""get_index(SingletonRestraint self) -> ParticleIndex"""
11702  return _IMP_core.SingletonRestraint_get_index(self)
11703 
11704  def get_version_info(self):
11705  r"""get_version_info(SingletonRestraint self) -> VersionInfo"""
11706  return _IMP_core.SingletonRestraint_get_version_info(self)
11707  __swig_destroy__ = _IMP_core.delete_SingletonRestraint
11708 
11709  def __str__(self):
11710  r"""__str__(SingletonRestraint self) -> std::string"""
11711  return _IMP_core.SingletonRestraint___str__(self)
11712 
11713  def __repr__(self):
11714  r"""__repr__(SingletonRestraint self) -> std::string"""
11715  return _IMP_core.SingletonRestraint___repr__(self)
11716 
11717  @staticmethod
11718  def get_from(o):
11719  return _object_cast_to_SingletonRestraint(o)
11720 
11721 
11722  def _get_as_binary(self):
11723  r"""_get_as_binary(SingletonRestraint self) -> PyObject *"""
11724  return _IMP_core.SingletonRestraint__get_as_binary(self)
11725 
11726  def _set_from_binary(self, p):
11727  r"""_set_from_binary(SingletonRestraint self, PyObject * p)"""
11728  return _IMP_core.SingletonRestraint__set_from_binary(self, p)
11729 
11730  def __getstate__(self):
11731  p = self._get_as_binary()
11732  if len(self.__dict__) > 1:
11733  d = self.__dict__.copy()
11734  del d['this']
11735  p = (d, p)
11736  return p
11737 
11738  def __setstate__(self, p):
11739  if not hasattr(self, 'this'):
11740  self.__init__()
11741  if isinstance(p, tuple):
11742  d, p = p
11743  self.__dict__.update(d)
11744  return self._set_from_binary(p)
11745 
11746 
11747  def _get_jax(self):
11748  from . import _jax_util
11749  return _jax_util._get_jax_restraint(self)
11750 
11751 
11752 # Register SingletonRestraint in _IMP_core:
11753 _IMP_core.SingletonRestraint_swigregister(SingletonRestraint)
11754 class TripletRestraint(IMP.Restraint):
11755  r"""Proxy of C++ IMP::core::TripletRestraint class."""
11756 
11757  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
11758 
11759  def __init__(self, *args):
11760  r"""
11761  __init__(TripletRestraint self, Model m, TripletScore ss, IMP::ParticleIndexTriplet const & vt, std::string name="TripletRestraint %1%") -> TripletRestraint
11762  __init__(TripletRestraint self) -> TripletRestraint
11763  """
11764  _IMP_core.TripletRestraint_swiginit(self, _IMP_core.new_TripletRestraint(*args))
11765 
11766  def get_score_object(self):
11767  r"""get_score_object(TripletRestraint self) -> TripletScore"""
11768  return _IMP_core.TripletRestraint_get_score_object(self)
11769 
11770  def get_index(self):
11771  r"""get_index(TripletRestraint self) -> IMP::TripletScore::IndexArgument"""
11772  return _IMP_core.TripletRestraint_get_index(self)
11773 
11774  def get_version_info(self):
11775  r"""get_version_info(TripletRestraint self) -> VersionInfo"""
11776  return _IMP_core.TripletRestraint_get_version_info(self)
11777  __swig_destroy__ = _IMP_core.delete_TripletRestraint
11778 
11779  def __str__(self):
11780  r"""__str__(TripletRestraint self) -> std::string"""
11781  return _IMP_core.TripletRestraint___str__(self)
11782 
11783  def __repr__(self):
11784  r"""__repr__(TripletRestraint self) -> std::string"""
11785  return _IMP_core.TripletRestraint___repr__(self)
11786 
11787  @staticmethod
11788  def get_from(o):
11789  return _object_cast_to_TripletRestraint(o)
11790 
11791 
11792  def _get_as_binary(self):
11793  r"""_get_as_binary(TripletRestraint self) -> PyObject *"""
11794  return _IMP_core.TripletRestraint__get_as_binary(self)
11795 
11796  def _set_from_binary(self, p):
11797  r"""_set_from_binary(TripletRestraint self, PyObject * p)"""
11798  return _IMP_core.TripletRestraint__set_from_binary(self, p)
11799 
11800  def __getstate__(self):
11801  p = self._get_as_binary()
11802  if len(self.__dict__) > 1:
11803  d = self.__dict__.copy()
11804  del d['this']
11805  p = (d, p)
11806  return p
11807 
11808  def __setstate__(self, p):
11809  if not hasattr(self, 'this'):
11810  self.__init__()
11811  if isinstance(p, tuple):
11812  d, p = p
11813  self.__dict__.update(d)
11814  return self._set_from_binary(p)
11815 
11816 
11817 # Register TripletRestraint in _IMP_core:
11818 _IMP_core.TripletRestraint_swigregister(TripletRestraint)
11819 class QuadRestraint(IMP.Restraint):
11820  r"""Proxy of C++ IMP::core::QuadRestraint class."""
11821 
11822  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
11823 
11824  def __init__(self, *args):
11825  r"""
11826  __init__(QuadRestraint self, Model m, QuadScore ss, IMP::ParticleIndexQuad const & vt, std::string name="QuadRestraint %1%") -> QuadRestraint
11827  __init__(QuadRestraint self) -> QuadRestraint
11828  """
11829  _IMP_core.QuadRestraint_swiginit(self, _IMP_core.new_QuadRestraint(*args))
11830 
11831  def get_score_object(self):
11832  r"""get_score_object(QuadRestraint self) -> QuadScore"""
11833  return _IMP_core.QuadRestraint_get_score_object(self)
11834 
11835  def get_index(self):
11836  r"""get_index(QuadRestraint self) -> IMP::QuadScore::IndexArgument"""
11837  return _IMP_core.QuadRestraint_get_index(self)
11838 
11839  def get_version_info(self):
11840  r"""get_version_info(QuadRestraint self) -> VersionInfo"""
11841  return _IMP_core.QuadRestraint_get_version_info(self)
11842  __swig_destroy__ = _IMP_core.delete_QuadRestraint
11843 
11844  def __str__(self):
11845  r"""__str__(QuadRestraint self) -> std::string"""
11846  return _IMP_core.QuadRestraint___str__(self)
11847 
11848  def __repr__(self):
11849  r"""__repr__(QuadRestraint self) -> std::string"""
11850  return _IMP_core.QuadRestraint___repr__(self)
11851 
11852  @staticmethod
11853  def get_from(o):
11854  return _object_cast_to_QuadRestraint(o)
11855 
11856 
11857  def _get_as_binary(self):
11858  r"""_get_as_binary(QuadRestraint self) -> PyObject *"""
11859  return _IMP_core.QuadRestraint__get_as_binary(self)
11860 
11861  def _set_from_binary(self, p):
11862  r"""_set_from_binary(QuadRestraint self, PyObject * p)"""
11863  return _IMP_core.QuadRestraint__set_from_binary(self, p)
11864 
11865  def __getstate__(self):
11866  p = self._get_as_binary()
11867  if len(self.__dict__) > 1:
11868  d = self.__dict__.copy()
11869  del d['this']
11870  p = (d, p)
11871  return p
11872 
11873  def __setstate__(self, p):
11874  if not hasattr(self, 'this'):
11875  self.__init__()
11876  if isinstance(p, tuple):
11877  d, p = p
11878  self.__dict__.update(d)
11879  return self._set_from_binary(p)
11880 
11881 
11882 # Register QuadRestraint in _IMP_core:
11883 _IMP_core.QuadRestraint_swigregister(QuadRestraint)
11884 class SingletonConstraint(IMP.Constraint):
11885  r"""Proxy of C++ IMP::core::SingletonConstraint class."""
11886 
11887  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
11888 
11889  def __init__(self, *args):
11890  r"""
11891  __init__(SingletonConstraint self, SingletonModifier before, SingletonModifier after, Model m, ParticleIndex vt, std::string name="SingletonConstraint %1%", bool can_skip=False) -> SingletonConstraint
11892  __init__(SingletonConstraint self) -> SingletonConstraint
11893  """
11894  _IMP_core.SingletonConstraint_swiginit(self, _IMP_core.new_SingletonConstraint(*args))
11895 
11896  def get_before_modifier(self):
11897  r"""get_before_modifier(SingletonConstraint self) -> SingletonModifier"""
11898  return _IMP_core.SingletonConstraint_get_before_modifier(self)
11899 
11900  def get_index(self):
11901  r"""get_index(SingletonConstraint self) -> ParticleIndex"""
11902  return _IMP_core.SingletonConstraint_get_index(self)
11903 
11904  def get_version_info(self):
11905  r"""get_version_info(SingletonConstraint self) -> VersionInfo"""
11906  return _IMP_core.SingletonConstraint_get_version_info(self)
11907  __swig_destroy__ = _IMP_core.delete_SingletonConstraint
11908 
11909  def __str__(self):
11910  r"""__str__(SingletonConstraint self) -> std::string"""
11911  return _IMP_core.SingletonConstraint___str__(self)
11912 
11913  def __repr__(self):
11914  r"""__repr__(SingletonConstraint self) -> std::string"""
11915  return _IMP_core.SingletonConstraint___repr__(self)
11916 
11917  @staticmethod
11918  def get_from(o):
11919  return _object_cast_to_SingletonConstraint(o)
11920 
11921 
11922  def _get_as_binary(self):
11923  r"""_get_as_binary(SingletonConstraint self) -> PyObject *"""
11924  return _IMP_core.SingletonConstraint__get_as_binary(self)
11925 
11926  def _set_from_binary(self, p):
11927  r"""_set_from_binary(SingletonConstraint self, PyObject * p)"""
11928  return _IMP_core.SingletonConstraint__set_from_binary(self, p)
11929 
11930  def __getstate__(self):
11931  p = self._get_as_binary()
11932  if len(self.__dict__) > 1:
11933  d = self.__dict__.copy()
11934  del d['this']
11935  p = (d, p)
11936  return p
11937 
11938  def __setstate__(self, p):
11939  if not hasattr(self, 'this'):
11940  self.__init__()
11941  if isinstance(p, tuple):
11942  d, p = p
11943  self.__dict__.update(d)
11944  return self._set_from_binary(p)
11945 
11946 
11947  def _get_jax(self):
11948  import jax.numpy as jnp
11949  indexes = jnp.array([self.get_index()])
11950  mod = self.get_before_modifier().get_derived_object()
11951  ji = mod._get_jax(self.get_model(), indexes)
11952  return self._wrap_jax(ji.apply_func, keys=ji._keys)
11953 
11954 
11955 # Register SingletonConstraint in _IMP_core:
11956 _IMP_core.SingletonConstraint_swigregister(SingletonConstraint)
11957 class PairConstraint(IMP.Constraint):
11958  r"""Proxy of C++ IMP::core::PairConstraint class."""
11959 
11960  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
11961 
11962  def __init__(self, *args):
11963  r"""
11964  __init__(PairConstraint self, PairModifier before, PairModifier after, Model m, IMP::ParticleIndexPair const & vt, std::string name="PairConstraint %1%", bool can_skip=False) -> PairConstraint
11965  __init__(PairConstraint self) -> PairConstraint
11966  """
11967  _IMP_core.PairConstraint_swiginit(self, _IMP_core.new_PairConstraint(*args))
11968 
11969  def get_before_modifier(self):
11970  r"""get_before_modifier(PairConstraint self) -> PairModifier"""
11971  return _IMP_core.PairConstraint_get_before_modifier(self)
11972 
11973  def get_index(self):
11974  r"""get_index(PairConstraint self) -> IMP::PairModifier::IndexArgument"""
11975  return _IMP_core.PairConstraint_get_index(self)
11976 
11977  def get_version_info(self):
11978  r"""get_version_info(PairConstraint self) -> VersionInfo"""
11979  return _IMP_core.PairConstraint_get_version_info(self)
11980  __swig_destroy__ = _IMP_core.delete_PairConstraint
11981 
11982  def __str__(self):
11983  r"""__str__(PairConstraint self) -> std::string"""
11984  return _IMP_core.PairConstraint___str__(self)
11985 
11986  def __repr__(self):
11987  r"""__repr__(PairConstraint self) -> std::string"""
11988  return _IMP_core.PairConstraint___repr__(self)
11989 
11990  @staticmethod
11991  def get_from(o):
11992  return _object_cast_to_PairConstraint(o)
11993 
11994 
11995  def _get_as_binary(self):
11996  r"""_get_as_binary(PairConstraint self) -> PyObject *"""
11997  return _IMP_core.PairConstraint__get_as_binary(self)
11998 
11999  def _set_from_binary(self, p):
12000  r"""_set_from_binary(PairConstraint self, PyObject * p)"""
12001  return _IMP_core.PairConstraint__set_from_binary(self, p)
12002 
12003  def __getstate__(self):
12004  p = self._get_as_binary()
12005  if len(self.__dict__) > 1:
12006  d = self.__dict__.copy()
12007  del d['this']
12008  p = (d, p)
12009  return p
12010 
12011  def __setstate__(self, p):
12012  if not hasattr(self, 'this'):
12013  self.__init__()
12014  if isinstance(p, tuple):
12015  d, p = p
12016  self.__dict__.update(d)
12017  return self._set_from_binary(p)
12018 
12019 
12020 # Register PairConstraint in _IMP_core:
12021 _IMP_core.PairConstraint_swigregister(PairConstraint)
12022 class TripletConstraint(IMP.Constraint):
12023  r"""Proxy of C++ IMP::core::TripletConstraint class."""
12024 
12025  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
12026 
12027  def __init__(self, *args):
12028  r"""
12029  __init__(TripletConstraint self, TripletModifier before, TripletModifier after, Model m, IMP::ParticleIndexTriplet const & vt, std::string name="TripletConstraint %1%", bool can_skip=False) -> TripletConstraint
12030  __init__(TripletConstraint self) -> TripletConstraint
12031  """
12032  _IMP_core.TripletConstraint_swiginit(self, _IMP_core.new_TripletConstraint(*args))
12033 
12034  def get_before_modifier(self):
12035  r"""get_before_modifier(TripletConstraint self) -> TripletModifier"""
12036  return _IMP_core.TripletConstraint_get_before_modifier(self)
12037 
12038  def get_index(self):
12039  r"""get_index(TripletConstraint self) -> IMP::TripletModifier::IndexArgument"""
12040  return _IMP_core.TripletConstraint_get_index(self)
12041 
12042  def get_version_info(self):
12043  r"""get_version_info(TripletConstraint self) -> VersionInfo"""
12044  return _IMP_core.TripletConstraint_get_version_info(self)
12045  __swig_destroy__ = _IMP_core.delete_TripletConstraint
12046 
12047  def __str__(self):
12048  r"""__str__(TripletConstraint self) -> std::string"""
12049  return _IMP_core.TripletConstraint___str__(self)
12050 
12051  def __repr__(self):
12052  r"""__repr__(TripletConstraint self) -> std::string"""
12053  return _IMP_core.TripletConstraint___repr__(self)
12054 
12055  @staticmethod
12056  def get_from(o):
12057  return _object_cast_to_TripletConstraint(o)
12058 
12059 
12060  def _get_as_binary(self):
12061  r"""_get_as_binary(TripletConstraint self) -> PyObject *"""
12062  return _IMP_core.TripletConstraint__get_as_binary(self)
12063 
12064  def _set_from_binary(self, p):
12065  r"""_set_from_binary(TripletConstraint self, PyObject * p)"""
12066  return _IMP_core.TripletConstraint__set_from_binary(self, p)
12067 
12068  def __getstate__(self):
12069  p = self._get_as_binary()
12070  if len(self.__dict__) > 1:
12071  d = self.__dict__.copy()
12072  del d['this']
12073  p = (d, p)
12074  return p
12075 
12076  def __setstate__(self, p):
12077  if not hasattr(self, 'this'):
12078  self.__init__()
12079  if isinstance(p, tuple):
12080  d, p = p
12081  self.__dict__.update(d)
12082  return self._set_from_binary(p)
12083 
12084 
12085 # Register TripletConstraint in _IMP_core:
12086 _IMP_core.TripletConstraint_swigregister(TripletConstraint)
12087 class QuadConstraint(IMP.Constraint):
12088  r"""Proxy of C++ IMP::core::QuadConstraint class."""
12089 
12090  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
12091 
12092  def __init__(self, *args):
12093  r"""
12094  __init__(QuadConstraint self, QuadModifier before, QuadModifier after, Model m, IMP::ParticleIndexQuad const & vt, std::string name="QuadConstraint %1%", bool can_skip=False) -> QuadConstraint
12095  __init__(QuadConstraint self) -> QuadConstraint
12096  """
12097  _IMP_core.QuadConstraint_swiginit(self, _IMP_core.new_QuadConstraint(*args))
12098 
12099  def get_before_modifier(self):
12100  r"""get_before_modifier(QuadConstraint self) -> QuadModifier"""
12101  return _IMP_core.QuadConstraint_get_before_modifier(self)
12102 
12103  def get_index(self):
12104  r"""get_index(QuadConstraint self) -> IMP::QuadModifier::IndexArgument"""
12105  return _IMP_core.QuadConstraint_get_index(self)
12106 
12107  def get_version_info(self):
12108  r"""get_version_info(QuadConstraint self) -> VersionInfo"""
12109  return _IMP_core.QuadConstraint_get_version_info(self)
12110  __swig_destroy__ = _IMP_core.delete_QuadConstraint
12111 
12112  def __str__(self):
12113  r"""__str__(QuadConstraint self) -> std::string"""
12114  return _IMP_core.QuadConstraint___str__(self)
12115 
12116  def __repr__(self):
12117  r"""__repr__(QuadConstraint self) -> std::string"""
12118  return _IMP_core.QuadConstraint___repr__(self)
12119 
12120  @staticmethod
12121  def get_from(o):
12122  return _object_cast_to_QuadConstraint(o)
12123 
12124 
12125  def _get_as_binary(self):
12126  r"""_get_as_binary(QuadConstraint self) -> PyObject *"""
12127  return _IMP_core.QuadConstraint__get_as_binary(self)
12128 
12129  def _set_from_binary(self, p):
12130  r"""_set_from_binary(QuadConstraint self, PyObject * p)"""
12131  return _IMP_core.QuadConstraint__set_from_binary(self, p)
12132 
12133  def __getstate__(self):
12134  p = self._get_as_binary()
12135  if len(self.__dict__) > 1:
12136  d = self.__dict__.copy()
12137  del d['this']
12138  p = (d, p)
12139  return p
12140 
12141  def __setstate__(self, p):
12142  if not hasattr(self, 'this'):
12143  self.__init__()
12144  if isinstance(p, tuple):
12145  d, p = p
12146  self.__dict__.update(d)
12147  return self._set_from_binary(p)
12148 
12149 
12150 # Register QuadConstraint in _IMP_core:
12151 _IMP_core.QuadConstraint_swigregister(QuadConstraint)
12152 class ConstantSingletonPredicate(IMP.SingletonPredicate):
12153  r"""Proxy of C++ IMP::core::ConstantSingletonPredicate class."""
12154 
12155  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
12156 
12157  def __init__(self, *args):
12158  r"""
12159  __init__(ConstantSingletonPredicate self, int v, std::string name="ConstSingletonPredicate%1%") -> ConstantSingletonPredicate
12160  __init__(ConstantSingletonPredicate self) -> ConstantSingletonPredicate
12161  """
12162  _IMP_core.ConstantSingletonPredicate_swiginit(self, _IMP_core.new_ConstantSingletonPredicate(*args))
12163 
12164  def do_get_inputs(self, arg2, arg3):
12165  r"""do_get_inputs(ConstantSingletonPredicate self, Model arg2, IMP::ParticleIndexes const & arg3) -> IMP::ModelObjectsTemp"""
12166  return _IMP_core.ConstantSingletonPredicate_do_get_inputs(self, arg2, arg3)
12167 
12168  def get_value(self, *args):
12169  r"""
12170  get_value(ConstantSingletonPredicate self, Particle a) -> int
12171  get_value(ConstantSingletonPredicate self, IMP::ParticlesTemp const & o) -> IMP::Ints
12172  """
12173  return _IMP_core.ConstantSingletonPredicate_get_value(self, *args)
12174 
12175  def get_value_index(self, *args):
12176  r"""
12177  get_value_index(ConstantSingletonPredicate self, Model arg2, ParticleIndex arg3) -> int
12178  get_value_index(ConstantSingletonPredicate self, Model m, IMP::ParticleIndexes const & o) -> IMP::Ints
12179  """
12180  return _IMP_core.ConstantSingletonPredicate_get_value_index(self, *args)
12181 
12182  def get_version_info(self):
12183  r"""get_version_info(ConstantSingletonPredicate self) -> VersionInfo"""
12184  return _IMP_core.ConstantSingletonPredicate_get_version_info(self)
12185  __swig_destroy__ = _IMP_core.delete_ConstantSingletonPredicate
12186 
12187  def __str__(self):
12188  r"""__str__(ConstantSingletonPredicate self) -> std::string"""
12189  return _IMP_core.ConstantSingletonPredicate___str__(self)
12190 
12191  def __repr__(self):
12192  r"""__repr__(ConstantSingletonPredicate self) -> std::string"""
12193  return _IMP_core.ConstantSingletonPredicate___repr__(self)
12194 
12195  @staticmethod
12196  def get_from(o):
12197  return _object_cast_to_ConstantSingletonPredicate(o)
12198 
12199 
12200  def _get_as_binary(self):
12201  r"""_get_as_binary(ConstantSingletonPredicate self) -> PyObject *"""
12202  return _IMP_core.ConstantSingletonPredicate__get_as_binary(self)
12203 
12204  def _set_from_binary(self, p):
12205  r"""_set_from_binary(ConstantSingletonPredicate self, PyObject * p)"""
12206  return _IMP_core.ConstantSingletonPredicate__set_from_binary(self, p)
12207 
12208  def __getstate__(self):
12209  p = self._get_as_binary()
12210  if len(self.__dict__) > 1:
12211  d = self.__dict__.copy()
12212  del d['this']
12213  p = (d, p)
12214  return p
12215 
12216  def __setstate__(self, p):
12217  if not hasattr(self, 'this'):
12218  self.__init__()
12219  if isinstance(p, tuple):
12220  d, p = p
12221  self.__dict__.update(d)
12222  return self._set_from_binary(p)
12223 
12224 
12225 # Register ConstantSingletonPredicate in _IMP_core:
12226 _IMP_core.ConstantSingletonPredicate_swigregister(ConstantSingletonPredicate)
12227 class UnorderedTypeSingletonPredicate(IMP.SingletonPredicate):
12228  r"""Proxy of C++ IMP::core::UnorderedTypeSingletonPredicate class."""
12229 
12230  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
12231 
12232  def __init__(self, *args):
12233  r"""__init__(UnorderedTypeSingletonPredicate self, std::string name="UnorderedTypeSingletonPredicate%1%") -> UnorderedTypeSingletonPredicate"""
12234  _IMP_core.UnorderedTypeSingletonPredicate_swiginit(self, _IMP_core.new_UnorderedTypeSingletonPredicate(*args))
12235 
12236  def do_get_inputs(self, m, pis):
12237  r"""do_get_inputs(UnorderedTypeSingletonPredicate self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
12238  return _IMP_core.UnorderedTypeSingletonPredicate_do_get_inputs(self, m, pis)
12239 
12240  def get_value(self, *args):
12241  r"""
12242  get_value(UnorderedTypeSingletonPredicate self, Particle a) -> int
12243  get_value(UnorderedTypeSingletonPredicate self, IMP::ParticlesTemp const & o) -> IMP::Ints
12244  """
12245  return _IMP_core.UnorderedTypeSingletonPredicate_get_value(self, *args)
12246 
12247  def get_value_index(self, *args):
12248  r"""
12249  get_value_index(UnorderedTypeSingletonPredicate self, Model m, ParticleIndex pi) -> int
12250  get_value_index(UnorderedTypeSingletonPredicate self, Model m, IMP::ParticleIndexes const & o) -> IMP::Ints
12251  """
12252  return _IMP_core.UnorderedTypeSingletonPredicate_get_value_index(self, *args)
12253 
12254  def get_version_info(self):
12255  r"""get_version_info(UnorderedTypeSingletonPredicate self) -> VersionInfo"""
12256  return _IMP_core.UnorderedTypeSingletonPredicate_get_version_info(self)
12257  __swig_destroy__ = _IMP_core.delete_UnorderedTypeSingletonPredicate
12258 
12259  def __str__(self):
12260  r"""__str__(UnorderedTypeSingletonPredicate self) -> std::string"""
12261  return _IMP_core.UnorderedTypeSingletonPredicate___str__(self)
12262 
12263  def __repr__(self):
12264  r"""__repr__(UnorderedTypeSingletonPredicate self) -> std::string"""
12265  return _IMP_core.UnorderedTypeSingletonPredicate___repr__(self)
12266 
12267  @staticmethod
12268  def get_from(o):
12269  return _object_cast_to_UnorderedTypeSingletonPredicate(o)
12270 
12271 
12272  def _get_as_binary(self):
12273  r"""_get_as_binary(UnorderedTypeSingletonPredicate self) -> PyObject *"""
12274  return _IMP_core.UnorderedTypeSingletonPredicate__get_as_binary(self)
12275 
12276  def _set_from_binary(self, p):
12277  r"""_set_from_binary(UnorderedTypeSingletonPredicate self, PyObject * p)"""
12278  return _IMP_core.UnorderedTypeSingletonPredicate__set_from_binary(self, p)
12279 
12280  def __getstate__(self):
12281  p = self._get_as_binary()
12282  if len(self.__dict__) > 1:
12283  d = self.__dict__.copy()
12284  del d['this']
12285  p = (d, p)
12286  return p
12287 
12288  def __setstate__(self, p):
12289  if not hasattr(self, 'this'):
12290  self.__init__()
12291  if isinstance(p, tuple):
12292  d, p = p
12293  self.__dict__.update(d)
12294  return self._set_from_binary(p)
12295 
12296 
12297 # Register UnorderedTypeSingletonPredicate in _IMP_core:
12298 _IMP_core.UnorderedTypeSingletonPredicate_swigregister(UnorderedTypeSingletonPredicate)
12299 class OrderedTypeSingletonPredicate(IMP.SingletonPredicate):
12300  r"""Proxy of C++ IMP::core::OrderedTypeSingletonPredicate class."""
12301 
12302  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
12303 
12304  def __init__(self, *args):
12305  r"""__init__(OrderedTypeSingletonPredicate self, std::string name="OrderedTypeSingletonPredicate%1%") -> OrderedTypeSingletonPredicate"""
12306  _IMP_core.OrderedTypeSingletonPredicate_swiginit(self, _IMP_core.new_OrderedTypeSingletonPredicate(*args))
12307 
12308  def do_get_inputs(self, m, pis):
12309  r"""do_get_inputs(OrderedTypeSingletonPredicate self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
12310  return _IMP_core.OrderedTypeSingletonPredicate_do_get_inputs(self, m, pis)
12311 
12312  def get_value(self, *args):
12313  r"""
12314  get_value(OrderedTypeSingletonPredicate self, IMP::core::ParticleTypes const & types) -> int
12315  get_value(OrderedTypeSingletonPredicate self, Particle a) -> int
12316  get_value(OrderedTypeSingletonPredicate self, IMP::ParticlesTemp const & o) -> IMP::Ints
12317  """
12318  return _IMP_core.OrderedTypeSingletonPredicate_get_value(self, *args)
12319 
12320  def get_value_index(self, *args):
12321  r"""
12322  get_value_index(OrderedTypeSingletonPredicate self, Model m, ParticleIndex pi) -> int
12323  get_value_index(OrderedTypeSingletonPredicate self, Model m, IMP::ParticleIndexes const & o) -> IMP::Ints
12324  """
12325  return _IMP_core.OrderedTypeSingletonPredicate_get_value_index(self, *args)
12326 
12327  def get_version_info(self):
12328  r"""get_version_info(OrderedTypeSingletonPredicate self) -> VersionInfo"""
12329  return _IMP_core.OrderedTypeSingletonPredicate_get_version_info(self)
12330  __swig_destroy__ = _IMP_core.delete_OrderedTypeSingletonPredicate
12331 
12332  def __str__(self):
12333  r"""__str__(OrderedTypeSingletonPredicate self) -> std::string"""
12334  return _IMP_core.OrderedTypeSingletonPredicate___str__(self)
12335 
12336  def __repr__(self):
12337  r"""__repr__(OrderedTypeSingletonPredicate self) -> std::string"""
12338  return _IMP_core.OrderedTypeSingletonPredicate___repr__(self)
12339 
12340  @staticmethod
12341  def get_from(o):
12342  return _object_cast_to_OrderedTypeSingletonPredicate(o)
12343 
12344 
12345 # Register OrderedTypeSingletonPredicate in _IMP_core:
12346 _IMP_core.OrderedTypeSingletonPredicate_swigregister(OrderedTypeSingletonPredicate)
12347 class AllSameSingletonPredicate(IMP.SingletonPredicate):
12348  r"""Proxy of C++ IMP::core::AllSameSingletonPredicate class."""
12349 
12350  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
12351 
12352  def __init__(self, *args):
12353  r"""__init__(AllSameSingletonPredicate self, std::string name="AllSameSingletonPredicate%1%") -> AllSameSingletonPredicate"""
12354  _IMP_core.AllSameSingletonPredicate_swiginit(self, _IMP_core.new_AllSameSingletonPredicate(*args))
12355 
12356  def do_get_inputs(self, arg2, arg3):
12357  r"""do_get_inputs(AllSameSingletonPredicate self, Model arg2, IMP::ParticleIndexes const & arg3) -> IMP::ModelObjectsTemp"""
12358  return _IMP_core.AllSameSingletonPredicate_do_get_inputs(self, arg2, arg3)
12359 
12360  def get_value(self, *args):
12361  r"""
12362  get_value(AllSameSingletonPredicate self, Particle a) -> int
12363  get_value(AllSameSingletonPredicate self, IMP::ParticlesTemp const & o) -> IMP::Ints
12364  """
12365  return _IMP_core.AllSameSingletonPredicate_get_value(self, *args)
12366 
12367  def get_value_index(self, *args):
12368  r"""
12369  get_value_index(AllSameSingletonPredicate self, Model m, ParticleIndex pi) -> int
12370  get_value_index(AllSameSingletonPredicate self, Model m, IMP::ParticleIndexes const & o) -> IMP::Ints
12371  """
12372  return _IMP_core.AllSameSingletonPredicate_get_value_index(self, *args)
12373 
12374  def get_version_info(self):
12375  r"""get_version_info(AllSameSingletonPredicate self) -> VersionInfo"""
12376  return _IMP_core.AllSameSingletonPredicate_get_version_info(self)
12377  __swig_destroy__ = _IMP_core.delete_AllSameSingletonPredicate
12378 
12379  def __str__(self):
12380  r"""__str__(AllSameSingletonPredicate self) -> std::string"""
12381  return _IMP_core.AllSameSingletonPredicate___str__(self)
12382 
12383  def __repr__(self):
12384  r"""__repr__(AllSameSingletonPredicate self) -> std::string"""
12385  return _IMP_core.AllSameSingletonPredicate___repr__(self)
12386 
12387  @staticmethod
12388  def get_from(o):
12389  return _object_cast_to_AllSameSingletonPredicate(o)
12390 
12391 
12392  def _get_as_binary(self):
12393  r"""_get_as_binary(AllSameSingletonPredicate self) -> PyObject *"""
12394  return _IMP_core.AllSameSingletonPredicate__get_as_binary(self)
12395 
12396  def _set_from_binary(self, p):
12397  r"""_set_from_binary(AllSameSingletonPredicate self, PyObject * p)"""
12398  return _IMP_core.AllSameSingletonPredicate__set_from_binary(self, p)
12399 
12400  def __getstate__(self):
12401  p = self._get_as_binary()
12402  if len(self.__dict__) > 1:
12403  d = self.__dict__.copy()
12404  del d['this']
12405  p = (d, p)
12406  return p
12407 
12408  def __setstate__(self, p):
12409  if not hasattr(self, 'this'):
12410  self.__init__()
12411  if isinstance(p, tuple):
12412  d, p = p
12413  self.__dict__.update(d)
12414  return self._set_from_binary(p)
12415 
12416 
12417 # Register AllSameSingletonPredicate in _IMP_core:
12418 _IMP_core.AllSameSingletonPredicate_swigregister(AllSameSingletonPredicate)
12419 class CoinFlipSingletonPredicate(IMP.SingletonPredicate):
12420  r"""Proxy of C++ IMP::core::CoinFlipSingletonPredicate class."""
12421 
12422  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
12423 
12424  def __init__(self, *args):
12425  r"""__init__(CoinFlipSingletonPredicate self, double p, std::string name="CoinFlipSingletonPredicate%1%") -> CoinFlipSingletonPredicate"""
12426  _IMP_core.CoinFlipSingletonPredicate_swiginit(self, _IMP_core.new_CoinFlipSingletonPredicate(*args))
12427 
12428  def do_get_inputs(self, arg2, arg3):
12429  r"""do_get_inputs(CoinFlipSingletonPredicate self, Model arg2, IMP::ParticleIndexes const & arg3) -> IMP::ModelObjectsTemp"""
12430  return _IMP_core.CoinFlipSingletonPredicate_do_get_inputs(self, arg2, arg3)
12431 
12432  def get_value(self, *args):
12433  r"""
12434  get_value(CoinFlipSingletonPredicate self, Particle a) -> int
12435  get_value(CoinFlipSingletonPredicate self, IMP::ParticlesTemp const & o) -> IMP::Ints
12436  """
12437  return _IMP_core.CoinFlipSingletonPredicate_get_value(self, *args)
12438 
12439  def get_value_index(self, *args):
12440  r"""
12441  get_value_index(CoinFlipSingletonPredicate self, Model arg2, ParticleIndex arg3) -> int
12442  get_value_index(CoinFlipSingletonPredicate self, Model m, IMP::ParticleIndexes const & o) -> IMP::Ints
12443  """
12444  return _IMP_core.CoinFlipSingletonPredicate_get_value_index(self, *args)
12445 
12446  def get_version_info(self):
12447  r"""get_version_info(CoinFlipSingletonPredicate self) -> VersionInfo"""
12448  return _IMP_core.CoinFlipSingletonPredicate_get_version_info(self)
12449  __swig_destroy__ = _IMP_core.delete_CoinFlipSingletonPredicate
12450 
12451  def __str__(self):
12452  r"""__str__(CoinFlipSingletonPredicate self) -> std::string"""
12453  return _IMP_core.CoinFlipSingletonPredicate___str__(self)
12454 
12455  def __repr__(self):
12456  r"""__repr__(CoinFlipSingletonPredicate self) -> std::string"""
12457  return _IMP_core.CoinFlipSingletonPredicate___repr__(self)
12458 
12459  @staticmethod
12460  def get_from(o):
12461  return _object_cast_to_CoinFlipSingletonPredicate(o)
12462 
12463 
12464 # Register CoinFlipSingletonPredicate in _IMP_core:
12465 _IMP_core.CoinFlipSingletonPredicate_swigregister(CoinFlipSingletonPredicate)
12466 class ConstantPairPredicate(IMP.PairPredicate):
12467  r"""Proxy of C++ IMP::core::ConstantPairPredicate class."""
12468 
12469  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
12470 
12471  def __init__(self, *args):
12472  r"""
12473  __init__(ConstantPairPredicate self, int v, std::string name="ConstPairPredicate%1%") -> ConstantPairPredicate
12474  __init__(ConstantPairPredicate self) -> ConstantPairPredicate
12475  """
12476  _IMP_core.ConstantPairPredicate_swiginit(self, _IMP_core.new_ConstantPairPredicate(*args))
12477 
12478  def do_get_inputs(self, arg2, arg3):
12479  r"""do_get_inputs(ConstantPairPredicate self, Model arg2, IMP::ParticleIndexes const & arg3) -> IMP::ModelObjectsTemp"""
12480  return _IMP_core.ConstantPairPredicate_do_get_inputs(self, arg2, arg3)
12481 
12482  def get_value(self, *args):
12483  r"""
12484  get_value(ConstantPairPredicate self, IMP::ParticlePair const & a) -> int
12485  get_value(ConstantPairPredicate self, IMP::ParticlePairsTemp const & o) -> IMP::Ints
12486  """
12487  return _IMP_core.ConstantPairPredicate_get_value(self, *args)
12488 
12489  def get_value_index(self, *args):
12490  r"""
12491  get_value_index(ConstantPairPredicate self, Model arg2, IMP::ParticleIndexPair const & arg3) -> int
12492  get_value_index(ConstantPairPredicate self, Model m, IMP::ParticleIndexPairs const & o) -> IMP::Ints
12493  """
12494  return _IMP_core.ConstantPairPredicate_get_value_index(self, *args)
12495 
12496  def get_version_info(self):
12497  r"""get_version_info(ConstantPairPredicate self) -> VersionInfo"""
12498  return _IMP_core.ConstantPairPredicate_get_version_info(self)
12499  __swig_destroy__ = _IMP_core.delete_ConstantPairPredicate
12500 
12501  def __str__(self):
12502  r"""__str__(ConstantPairPredicate self) -> std::string"""
12503  return _IMP_core.ConstantPairPredicate___str__(self)
12504 
12505  def __repr__(self):
12506  r"""__repr__(ConstantPairPredicate self) -> std::string"""
12507  return _IMP_core.ConstantPairPredicate___repr__(self)
12508 
12509  @staticmethod
12510  def get_from(o):
12511  return _object_cast_to_ConstantPairPredicate(o)
12512 
12513 
12514  def _get_as_binary(self):
12515  r"""_get_as_binary(ConstantPairPredicate self) -> PyObject *"""
12516  return _IMP_core.ConstantPairPredicate__get_as_binary(self)
12517 
12518  def _set_from_binary(self, p):
12519  r"""_set_from_binary(ConstantPairPredicate self, PyObject * p)"""
12520  return _IMP_core.ConstantPairPredicate__set_from_binary(self, p)
12521 
12522  def __getstate__(self):
12523  p = self._get_as_binary()
12524  if len(self.__dict__) > 1:
12525  d = self.__dict__.copy()
12526  del d['this']
12527  p = (d, p)
12528  return p
12529 
12530  def __setstate__(self, p):
12531  if not hasattr(self, 'this'):
12532  self.__init__()
12533  if isinstance(p, tuple):
12534  d, p = p
12535  self.__dict__.update(d)
12536  return self._set_from_binary(p)
12537 
12538 
12539 # Register ConstantPairPredicate in _IMP_core:
12540 _IMP_core.ConstantPairPredicate_swigregister(ConstantPairPredicate)
12541 class UnorderedTypePairPredicate(IMP.PairPredicate):
12542  r"""Proxy of C++ IMP::core::UnorderedTypePairPredicate class."""
12543 
12544  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
12545 
12546  def __init__(self, *args):
12547  r"""__init__(UnorderedTypePairPredicate self, std::string name="UnorderedTypePairPredicate%1%") -> UnorderedTypePairPredicate"""
12548  _IMP_core.UnorderedTypePairPredicate_swiginit(self, _IMP_core.new_UnorderedTypePairPredicate(*args))
12549 
12550  def do_get_inputs(self, m, pis):
12551  r"""do_get_inputs(UnorderedTypePairPredicate self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
12552  return _IMP_core.UnorderedTypePairPredicate_do_get_inputs(self, m, pis)
12553 
12554  def get_value(self, *args):
12555  r"""
12556  get_value(UnorderedTypePairPredicate self, IMP::ParticlePair const & a) -> int
12557  get_value(UnorderedTypePairPredicate self, IMP::ParticlePairsTemp const & o) -> IMP::Ints
12558  """
12559  return _IMP_core.UnorderedTypePairPredicate_get_value(self, *args)
12560 
12561  def get_value_index(self, *args):
12562  r"""
12563  get_value_index(UnorderedTypePairPredicate self, Model m, IMP::ParticleIndexPair const & pi) -> int
12564  get_value_index(UnorderedTypePairPredicate self, Model m, IMP::ParticleIndexPairs const & o) -> IMP::Ints
12565  """
12566  return _IMP_core.UnorderedTypePairPredicate_get_value_index(self, *args)
12567 
12568  def get_version_info(self):
12569  r"""get_version_info(UnorderedTypePairPredicate self) -> VersionInfo"""
12570  return _IMP_core.UnorderedTypePairPredicate_get_version_info(self)
12571  __swig_destroy__ = _IMP_core.delete_UnorderedTypePairPredicate
12572 
12573  def __str__(self):
12574  r"""__str__(UnorderedTypePairPredicate self) -> std::string"""
12575  return _IMP_core.UnorderedTypePairPredicate___str__(self)
12576 
12577  def __repr__(self):
12578  r"""__repr__(UnorderedTypePairPredicate self) -> std::string"""
12579  return _IMP_core.UnorderedTypePairPredicate___repr__(self)
12580 
12581  @staticmethod
12582  def get_from(o):
12583  return _object_cast_to_UnorderedTypePairPredicate(o)
12584 
12585 
12586  def _get_as_binary(self):
12587  r"""_get_as_binary(UnorderedTypePairPredicate self) -> PyObject *"""
12588  return _IMP_core.UnorderedTypePairPredicate__get_as_binary(self)
12589 
12590  def _set_from_binary(self, p):
12591  r"""_set_from_binary(UnorderedTypePairPredicate self, PyObject * p)"""
12592  return _IMP_core.UnorderedTypePairPredicate__set_from_binary(self, p)
12593 
12594  def __getstate__(self):
12595  p = self._get_as_binary()
12596  if len(self.__dict__) > 1:
12597  d = self.__dict__.copy()
12598  del d['this']
12599  p = (d, p)
12600  return p
12601 
12602  def __setstate__(self, p):
12603  if not hasattr(self, 'this'):
12604  self.__init__()
12605  if isinstance(p, tuple):
12606  d, p = p
12607  self.__dict__.update(d)
12608  return self._set_from_binary(p)
12609 
12610 
12611 # Register UnorderedTypePairPredicate in _IMP_core:
12612 _IMP_core.UnorderedTypePairPredicate_swigregister(UnorderedTypePairPredicate)
12613 class OrderedTypePairPredicate(IMP.PairPredicate):
12614  r"""Proxy of C++ IMP::core::OrderedTypePairPredicate class."""
12615 
12616  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
12617 
12618  def __init__(self, *args):
12619  r"""__init__(OrderedTypePairPredicate self, std::string name="OrderedTypePairPredicate%1%") -> OrderedTypePairPredicate"""
12620  _IMP_core.OrderedTypePairPredicate_swiginit(self, _IMP_core.new_OrderedTypePairPredicate(*args))
12621 
12622  def do_get_inputs(self, m, pis):
12623  r"""do_get_inputs(OrderedTypePairPredicate self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
12624  return _IMP_core.OrderedTypePairPredicate_do_get_inputs(self, m, pis)
12625 
12626  def get_value(self, *args):
12627  r"""
12628  get_value(OrderedTypePairPredicate self, IMP::core::ParticleTypes const & types) -> int
12629  get_value(OrderedTypePairPredicate self, IMP::ParticlePair const & a) -> int
12630  get_value(OrderedTypePairPredicate self, IMP::ParticlePairsTemp const & o) -> IMP::Ints
12631  """
12632  return _IMP_core.OrderedTypePairPredicate_get_value(self, *args)
12633 
12634  def get_value_index(self, *args):
12635  r"""
12636  get_value_index(OrderedTypePairPredicate self, Model m, IMP::ParticleIndexPair const & pi) -> int
12637  get_value_index(OrderedTypePairPredicate self, Model m, IMP::ParticleIndexPairs const & o) -> IMP::Ints
12638  """
12639  return _IMP_core.OrderedTypePairPredicate_get_value_index(self, *args)
12640 
12641  def get_version_info(self):
12642  r"""get_version_info(OrderedTypePairPredicate self) -> VersionInfo"""
12643  return _IMP_core.OrderedTypePairPredicate_get_version_info(self)
12644  __swig_destroy__ = _IMP_core.delete_OrderedTypePairPredicate
12645 
12646  def __str__(self):
12647  r"""__str__(OrderedTypePairPredicate self) -> std::string"""
12648  return _IMP_core.OrderedTypePairPredicate___str__(self)
12649 
12650  def __repr__(self):
12651  r"""__repr__(OrderedTypePairPredicate self) -> std::string"""
12652  return _IMP_core.OrderedTypePairPredicate___repr__(self)
12653 
12654  @staticmethod
12655  def get_from(o):
12656  return _object_cast_to_OrderedTypePairPredicate(o)
12657 
12658 
12659 # Register OrderedTypePairPredicate in _IMP_core:
12660 _IMP_core.OrderedTypePairPredicate_swigregister(OrderedTypePairPredicate)
12661 class AllSamePairPredicate(IMP.PairPredicate):
12662  r"""Proxy of C++ IMP::core::AllSamePairPredicate class."""
12663 
12664  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
12665 
12666  def __init__(self, *args):
12667  r"""__init__(AllSamePairPredicate self, std::string name="AllSamePairPredicate%1%") -> AllSamePairPredicate"""
12668  _IMP_core.AllSamePairPredicate_swiginit(self, _IMP_core.new_AllSamePairPredicate(*args))
12669 
12670  def do_get_inputs(self, arg2, arg3):
12671  r"""do_get_inputs(AllSamePairPredicate self, Model arg2, IMP::ParticleIndexes const & arg3) -> IMP::ModelObjectsTemp"""
12672  return _IMP_core.AllSamePairPredicate_do_get_inputs(self, arg2, arg3)
12673 
12674  def get_value(self, *args):
12675  r"""
12676  get_value(AllSamePairPredicate self, IMP::ParticlePair const & a) -> int
12677  get_value(AllSamePairPredicate self, IMP::ParticlePairsTemp const & o) -> IMP::Ints
12678  """
12679  return _IMP_core.AllSamePairPredicate_get_value(self, *args)
12680 
12681  def get_value_index(self, *args):
12682  r"""
12683  get_value_index(AllSamePairPredicate self, Model m, IMP::ParticleIndexPair const & pi) -> int
12684  get_value_index(AllSamePairPredicate self, Model m, IMP::ParticleIndexPairs const & o) -> IMP::Ints
12685  """
12686  return _IMP_core.AllSamePairPredicate_get_value_index(self, *args)
12687 
12688  def get_version_info(self):
12689  r"""get_version_info(AllSamePairPredicate self) -> VersionInfo"""
12690  return _IMP_core.AllSamePairPredicate_get_version_info(self)
12691  __swig_destroy__ = _IMP_core.delete_AllSamePairPredicate
12692 
12693  def __str__(self):
12694  r"""__str__(AllSamePairPredicate self) -> std::string"""
12695  return _IMP_core.AllSamePairPredicate___str__(self)
12696 
12697  def __repr__(self):
12698  r"""__repr__(AllSamePairPredicate self) -> std::string"""
12699  return _IMP_core.AllSamePairPredicate___repr__(self)
12700 
12701  @staticmethod
12702  def get_from(o):
12703  return _object_cast_to_AllSamePairPredicate(o)
12704 
12705 
12706  def _get_as_binary(self):
12707  r"""_get_as_binary(AllSamePairPredicate self) -> PyObject *"""
12708  return _IMP_core.AllSamePairPredicate__get_as_binary(self)
12709 
12710  def _set_from_binary(self, p):
12711  r"""_set_from_binary(AllSamePairPredicate self, PyObject * p)"""
12712  return _IMP_core.AllSamePairPredicate__set_from_binary(self, p)
12713 
12714  def __getstate__(self):
12715  p = self._get_as_binary()
12716  if len(self.__dict__) > 1:
12717  d = self.__dict__.copy()
12718  del d['this']
12719  p = (d, p)
12720  return p
12721 
12722  def __setstate__(self, p):
12723  if not hasattr(self, 'this'):
12724  self.__init__()
12725  if isinstance(p, tuple):
12726  d, p = p
12727  self.__dict__.update(d)
12728  return self._set_from_binary(p)
12729 
12730 
12731 # Register AllSamePairPredicate in _IMP_core:
12732 _IMP_core.AllSamePairPredicate_swigregister(AllSamePairPredicate)
12733 class CoinFlipPairPredicate(IMP.PairPredicate):
12734  r"""Proxy of C++ IMP::core::CoinFlipPairPredicate class."""
12735 
12736  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
12737 
12738  def __init__(self, *args):
12739  r"""__init__(CoinFlipPairPredicate self, double p, std::string name="CoinFlipPairPredicate%1%") -> CoinFlipPairPredicate"""
12740  _IMP_core.CoinFlipPairPredicate_swiginit(self, _IMP_core.new_CoinFlipPairPredicate(*args))
12741 
12742  def do_get_inputs(self, arg2, arg3):
12743  r"""do_get_inputs(CoinFlipPairPredicate self, Model arg2, IMP::ParticleIndexes const & arg3) -> IMP::ModelObjectsTemp"""
12744  return _IMP_core.CoinFlipPairPredicate_do_get_inputs(self, arg2, arg3)
12745 
12746  def get_value(self, *args):
12747  r"""
12748  get_value(CoinFlipPairPredicate self, IMP::ParticlePair const & a) -> int
12749  get_value(CoinFlipPairPredicate self, IMP::ParticlePairsTemp const & o) -> IMP::Ints
12750  """
12751  return _IMP_core.CoinFlipPairPredicate_get_value(self, *args)
12752 
12753  def get_value_index(self, *args):
12754  r"""
12755  get_value_index(CoinFlipPairPredicate self, Model arg2, IMP::ParticleIndexPair const & arg3) -> int
12756  get_value_index(CoinFlipPairPredicate self, Model m, IMP::ParticleIndexPairs const & o) -> IMP::Ints
12757  """
12758  return _IMP_core.CoinFlipPairPredicate_get_value_index(self, *args)
12759 
12760  def get_version_info(self):
12761  r"""get_version_info(CoinFlipPairPredicate self) -> VersionInfo"""
12762  return _IMP_core.CoinFlipPairPredicate_get_version_info(self)
12763  __swig_destroy__ = _IMP_core.delete_CoinFlipPairPredicate
12764 
12765  def __str__(self):
12766  r"""__str__(CoinFlipPairPredicate self) -> std::string"""
12767  return _IMP_core.CoinFlipPairPredicate___str__(self)
12768 
12769  def __repr__(self):
12770  r"""__repr__(CoinFlipPairPredicate self) -> std::string"""
12771  return _IMP_core.CoinFlipPairPredicate___repr__(self)
12772 
12773  @staticmethod
12774  def get_from(o):
12775  return _object_cast_to_CoinFlipPairPredicate(o)
12776 
12777 
12778 # Register CoinFlipPairPredicate in _IMP_core:
12779 _IMP_core.CoinFlipPairPredicate_swigregister(CoinFlipPairPredicate)
12780 class ConstantTripletPredicate(IMP.TripletPredicate):
12781  r"""Proxy of C++ IMP::core::ConstantTripletPredicate class."""
12782 
12783  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
12784 
12785  def __init__(self, *args):
12786  r"""
12787  __init__(ConstantTripletPredicate self, int v, std::string name="ConstTripletPredicate%1%") -> ConstantTripletPredicate
12788  __init__(ConstantTripletPredicate self) -> ConstantTripletPredicate
12789  """
12790  _IMP_core.ConstantTripletPredicate_swiginit(self, _IMP_core.new_ConstantTripletPredicate(*args))
12791 
12792  def do_get_inputs(self, arg2, arg3):
12793  r"""do_get_inputs(ConstantTripletPredicate self, Model arg2, IMP::ParticleIndexes const & arg3) -> IMP::ModelObjectsTemp"""
12794  return _IMP_core.ConstantTripletPredicate_do_get_inputs(self, arg2, arg3)
12795 
12796  def get_value(self, *args):
12797  r"""
12798  get_value(ConstantTripletPredicate self, IMP::ParticleTriplet const & a) -> int
12799  get_value(ConstantTripletPredicate self, IMP::ParticleTripletsTemp const & o) -> IMP::Ints
12800  """
12801  return _IMP_core.ConstantTripletPredicate_get_value(self, *args)
12802 
12803  def get_value_index(self, *args):
12804  r"""
12805  get_value_index(ConstantTripletPredicate self, Model arg2, IMP::ParticleIndexTriplet const & arg3) -> int
12806  get_value_index(ConstantTripletPredicate self, Model m, IMP::ParticleIndexTriplets const & o) -> IMP::Ints
12807  """
12808  return _IMP_core.ConstantTripletPredicate_get_value_index(self, *args)
12809 
12810  def get_version_info(self):
12811  r"""get_version_info(ConstantTripletPredicate self) -> VersionInfo"""
12812  return _IMP_core.ConstantTripletPredicate_get_version_info(self)
12813  __swig_destroy__ = _IMP_core.delete_ConstantTripletPredicate
12814 
12815  def __str__(self):
12816  r"""__str__(ConstantTripletPredicate self) -> std::string"""
12817  return _IMP_core.ConstantTripletPredicate___str__(self)
12818 
12819  def __repr__(self):
12820  r"""__repr__(ConstantTripletPredicate self) -> std::string"""
12821  return _IMP_core.ConstantTripletPredicate___repr__(self)
12822 
12823  @staticmethod
12824  def get_from(o):
12825  return _object_cast_to_ConstantTripletPredicate(o)
12826 
12827 
12828  def _get_as_binary(self):
12829  r"""_get_as_binary(ConstantTripletPredicate self) -> PyObject *"""
12830  return _IMP_core.ConstantTripletPredicate__get_as_binary(self)
12831 
12832  def _set_from_binary(self, p):
12833  r"""_set_from_binary(ConstantTripletPredicate self, PyObject * p)"""
12834  return _IMP_core.ConstantTripletPredicate__set_from_binary(self, p)
12835 
12836  def __getstate__(self):
12837  p = self._get_as_binary()
12838  if len(self.__dict__) > 1:
12839  d = self.__dict__.copy()
12840  del d['this']
12841  p = (d, p)
12842  return p
12843 
12844  def __setstate__(self, p):
12845  if not hasattr(self, 'this'):
12846  self.__init__()
12847  if isinstance(p, tuple):
12848  d, p = p
12849  self.__dict__.update(d)
12850  return self._set_from_binary(p)
12851 
12852 
12853 # Register ConstantTripletPredicate in _IMP_core:
12854 _IMP_core.ConstantTripletPredicate_swigregister(ConstantTripletPredicate)
12855 class UnorderedTypeTripletPredicate(IMP.TripletPredicate):
12856  r"""Proxy of C++ IMP::core::UnorderedTypeTripletPredicate class."""
12857 
12858  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
12859 
12860  def __init__(self, *args):
12861  r"""__init__(UnorderedTypeTripletPredicate self, std::string name="UnorderedTypeTripletPredicate%1%") -> UnorderedTypeTripletPredicate"""
12862  _IMP_core.UnorderedTypeTripletPredicate_swiginit(self, _IMP_core.new_UnorderedTypeTripletPredicate(*args))
12863 
12864  def do_get_inputs(self, m, pis):
12865  r"""do_get_inputs(UnorderedTypeTripletPredicate self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
12866  return _IMP_core.UnorderedTypeTripletPredicate_do_get_inputs(self, m, pis)
12867 
12868  def get_value(self, *args):
12869  r"""
12870  get_value(UnorderedTypeTripletPredicate self, IMP::ParticleTriplet const & a) -> int
12871  get_value(UnorderedTypeTripletPredicate self, IMP::ParticleTripletsTemp const & o) -> IMP::Ints
12872  """
12873  return _IMP_core.UnorderedTypeTripletPredicate_get_value(self, *args)
12874 
12875  def get_value_index(self, *args):
12876  r"""
12877  get_value_index(UnorderedTypeTripletPredicate self, Model m, IMP::ParticleIndexTriplet const & pi) -> int
12878  get_value_index(UnorderedTypeTripletPredicate self, Model m, IMP::ParticleIndexTriplets const & o) -> IMP::Ints
12879  """
12880  return _IMP_core.UnorderedTypeTripletPredicate_get_value_index(self, *args)
12881 
12882  def get_version_info(self):
12883  r"""get_version_info(UnorderedTypeTripletPredicate self) -> VersionInfo"""
12884  return _IMP_core.UnorderedTypeTripletPredicate_get_version_info(self)
12885  __swig_destroy__ = _IMP_core.delete_UnorderedTypeTripletPredicate
12886 
12887  def __str__(self):
12888  r"""__str__(UnorderedTypeTripletPredicate self) -> std::string"""
12889  return _IMP_core.UnorderedTypeTripletPredicate___str__(self)
12890 
12891  def __repr__(self):
12892  r"""__repr__(UnorderedTypeTripletPredicate self) -> std::string"""
12893  return _IMP_core.UnorderedTypeTripletPredicate___repr__(self)
12894 
12895  @staticmethod
12896  def get_from(o):
12897  return _object_cast_to_UnorderedTypeTripletPredicate(o)
12898 
12899 
12900  def _get_as_binary(self):
12901  r"""_get_as_binary(UnorderedTypeTripletPredicate self) -> PyObject *"""
12902  return _IMP_core.UnorderedTypeTripletPredicate__get_as_binary(self)
12903 
12904  def _set_from_binary(self, p):
12905  r"""_set_from_binary(UnorderedTypeTripletPredicate self, PyObject * p)"""
12906  return _IMP_core.UnorderedTypeTripletPredicate__set_from_binary(self, p)
12907 
12908  def __getstate__(self):
12909  p = self._get_as_binary()
12910  if len(self.__dict__) > 1:
12911  d = self.__dict__.copy()
12912  del d['this']
12913  p = (d, p)
12914  return p
12915 
12916  def __setstate__(self, p):
12917  if not hasattr(self, 'this'):
12918  self.__init__()
12919  if isinstance(p, tuple):
12920  d, p = p
12921  self.__dict__.update(d)
12922  return self._set_from_binary(p)
12923 
12924 
12925 # Register UnorderedTypeTripletPredicate in _IMP_core:
12926 _IMP_core.UnorderedTypeTripletPredicate_swigregister(UnorderedTypeTripletPredicate)
12927 class OrderedTypeTripletPredicate(IMP.TripletPredicate):
12928  r"""Proxy of C++ IMP::core::OrderedTypeTripletPredicate class."""
12929 
12930  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
12931 
12932  def __init__(self, *args):
12933  r"""__init__(OrderedTypeTripletPredicate self, std::string name="OrderedTypeTripletPredicate%1%") -> OrderedTypeTripletPredicate"""
12934  _IMP_core.OrderedTypeTripletPredicate_swiginit(self, _IMP_core.new_OrderedTypeTripletPredicate(*args))
12935 
12936  def do_get_inputs(self, m, pis):
12937  r"""do_get_inputs(OrderedTypeTripletPredicate self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
12938  return _IMP_core.OrderedTypeTripletPredicate_do_get_inputs(self, m, pis)
12939 
12940  def get_value(self, *args):
12941  r"""
12942  get_value(OrderedTypeTripletPredicate self, IMP::core::ParticleTypes const & types) -> int
12943  get_value(OrderedTypeTripletPredicate self, IMP::ParticleTriplet const & a) -> int
12944  get_value(OrderedTypeTripletPredicate self, IMP::ParticleTripletsTemp const & o) -> IMP::Ints
12945  """
12946  return _IMP_core.OrderedTypeTripletPredicate_get_value(self, *args)
12947 
12948  def get_value_index(self, *args):
12949  r"""
12950  get_value_index(OrderedTypeTripletPredicate self, Model m, IMP::ParticleIndexTriplet const & pi) -> int
12951  get_value_index(OrderedTypeTripletPredicate self, Model m, IMP::ParticleIndexTriplets const & o) -> IMP::Ints
12952  """
12953  return _IMP_core.OrderedTypeTripletPredicate_get_value_index(self, *args)
12954 
12955  def get_version_info(self):
12956  r"""get_version_info(OrderedTypeTripletPredicate self) -> VersionInfo"""
12957  return _IMP_core.OrderedTypeTripletPredicate_get_version_info(self)
12958  __swig_destroy__ = _IMP_core.delete_OrderedTypeTripletPredicate
12959 
12960  def __str__(self):
12961  r"""__str__(OrderedTypeTripletPredicate self) -> std::string"""
12962  return _IMP_core.OrderedTypeTripletPredicate___str__(self)
12963 
12964  def __repr__(self):
12965  r"""__repr__(OrderedTypeTripletPredicate self) -> std::string"""
12966  return _IMP_core.OrderedTypeTripletPredicate___repr__(self)
12967 
12968  @staticmethod
12969  def get_from(o):
12970  return _object_cast_to_OrderedTypeTripletPredicate(o)
12971 
12972 
12973 # Register OrderedTypeTripletPredicate in _IMP_core:
12974 _IMP_core.OrderedTypeTripletPredicate_swigregister(OrderedTypeTripletPredicate)
12975 class AllSameTripletPredicate(IMP.TripletPredicate):
12976  r"""Proxy of C++ IMP::core::AllSameTripletPredicate class."""
12977 
12978  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
12979 
12980  def __init__(self, *args):
12981  r"""__init__(AllSameTripletPredicate self, std::string name="AllSameTripletPredicate%1%") -> AllSameTripletPredicate"""
12982  _IMP_core.AllSameTripletPredicate_swiginit(self, _IMP_core.new_AllSameTripletPredicate(*args))
12983 
12984  def do_get_inputs(self, arg2, arg3):
12985  r"""do_get_inputs(AllSameTripletPredicate self, Model arg2, IMP::ParticleIndexes const & arg3) -> IMP::ModelObjectsTemp"""
12986  return _IMP_core.AllSameTripletPredicate_do_get_inputs(self, arg2, arg3)
12987 
12988  def get_value(self, *args):
12989  r"""
12990  get_value(AllSameTripletPredicate self, IMP::ParticleTriplet const & a) -> int
12991  get_value(AllSameTripletPredicate self, IMP::ParticleTripletsTemp const & o) -> IMP::Ints
12992  """
12993  return _IMP_core.AllSameTripletPredicate_get_value(self, *args)
12994 
12995  def get_value_index(self, *args):
12996  r"""
12997  get_value_index(AllSameTripletPredicate self, Model m, IMP::ParticleIndexTriplet const & pi) -> int
12998  get_value_index(AllSameTripletPredicate self, Model m, IMP::ParticleIndexTriplets const & o) -> IMP::Ints
12999  """
13000  return _IMP_core.AllSameTripletPredicate_get_value_index(self, *args)
13001 
13002  def get_version_info(self):
13003  r"""get_version_info(AllSameTripletPredicate self) -> VersionInfo"""
13004  return _IMP_core.AllSameTripletPredicate_get_version_info(self)
13005  __swig_destroy__ = _IMP_core.delete_AllSameTripletPredicate
13006 
13007  def __str__(self):
13008  r"""__str__(AllSameTripletPredicate self) -> std::string"""
13009  return _IMP_core.AllSameTripletPredicate___str__(self)
13010 
13011  def __repr__(self):
13012  r"""__repr__(AllSameTripletPredicate self) -> std::string"""
13013  return _IMP_core.AllSameTripletPredicate___repr__(self)
13014 
13015  @staticmethod
13016  def get_from(o):
13017  return _object_cast_to_AllSameTripletPredicate(o)
13018 
13019 
13020  def _get_as_binary(self):
13021  r"""_get_as_binary(AllSameTripletPredicate self) -> PyObject *"""
13022  return _IMP_core.AllSameTripletPredicate__get_as_binary(self)
13023 
13024  def _set_from_binary(self, p):
13025  r"""_set_from_binary(AllSameTripletPredicate self, PyObject * p)"""
13026  return _IMP_core.AllSameTripletPredicate__set_from_binary(self, p)
13027 
13028  def __getstate__(self):
13029  p = self._get_as_binary()
13030  if len(self.__dict__) > 1:
13031  d = self.__dict__.copy()
13032  del d['this']
13033  p = (d, p)
13034  return p
13035 
13036  def __setstate__(self, p):
13037  if not hasattr(self, 'this'):
13038  self.__init__()
13039  if isinstance(p, tuple):
13040  d, p = p
13041  self.__dict__.update(d)
13042  return self._set_from_binary(p)
13043 
13044 
13045 # Register AllSameTripletPredicate in _IMP_core:
13046 _IMP_core.AllSameTripletPredicate_swigregister(AllSameTripletPredicate)
13047 class CoinFlipTripletPredicate(IMP.TripletPredicate):
13048  r"""Proxy of C++ IMP::core::CoinFlipTripletPredicate class."""
13049 
13050  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
13051 
13052  def __init__(self, *args):
13053  r"""__init__(CoinFlipTripletPredicate self, double p, std::string name="CoinFlipTripletPredicate%1%") -> CoinFlipTripletPredicate"""
13054  _IMP_core.CoinFlipTripletPredicate_swiginit(self, _IMP_core.new_CoinFlipTripletPredicate(*args))
13055 
13056  def do_get_inputs(self, arg2, arg3):
13057  r"""do_get_inputs(CoinFlipTripletPredicate self, Model arg2, IMP::ParticleIndexes const & arg3) -> IMP::ModelObjectsTemp"""
13058  return _IMP_core.CoinFlipTripletPredicate_do_get_inputs(self, arg2, arg3)
13059 
13060  def get_value(self, *args):
13061  r"""
13062  get_value(CoinFlipTripletPredicate self, IMP::ParticleTriplet const & a) -> int
13063  get_value(CoinFlipTripletPredicate self, IMP::ParticleTripletsTemp const & o) -> IMP::Ints
13064  """
13065  return _IMP_core.CoinFlipTripletPredicate_get_value(self, *args)
13066 
13067  def get_value_index(self, *args):
13068  r"""
13069  get_value_index(CoinFlipTripletPredicate self, Model arg2, IMP::ParticleIndexTriplet const & arg3) -> int
13070  get_value_index(CoinFlipTripletPredicate self, Model m, IMP::ParticleIndexTriplets const & o) -> IMP::Ints
13071  """
13072  return _IMP_core.CoinFlipTripletPredicate_get_value_index(self, *args)
13073 
13074  def get_version_info(self):
13075  r"""get_version_info(CoinFlipTripletPredicate self) -> VersionInfo"""
13076  return _IMP_core.CoinFlipTripletPredicate_get_version_info(self)
13077  __swig_destroy__ = _IMP_core.delete_CoinFlipTripletPredicate
13078 
13079  def __str__(self):
13080  r"""__str__(CoinFlipTripletPredicate self) -> std::string"""
13081  return _IMP_core.CoinFlipTripletPredicate___str__(self)
13082 
13083  def __repr__(self):
13084  r"""__repr__(CoinFlipTripletPredicate self) -> std::string"""
13085  return _IMP_core.CoinFlipTripletPredicate___repr__(self)
13086 
13087  @staticmethod
13088  def get_from(o):
13089  return _object_cast_to_CoinFlipTripletPredicate(o)
13090 
13091 
13092 # Register CoinFlipTripletPredicate in _IMP_core:
13093 _IMP_core.CoinFlipTripletPredicate_swigregister(CoinFlipTripletPredicate)
13094 class ConstantQuadPredicate(IMP.QuadPredicate):
13095  r"""Proxy of C++ IMP::core::ConstantQuadPredicate class."""
13096 
13097  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
13098 
13099  def __init__(self, *args):
13100  r"""
13101  __init__(ConstantQuadPredicate self, int v, std::string name="ConstQuadPredicate%1%") -> ConstantQuadPredicate
13102  __init__(ConstantQuadPredicate self) -> ConstantQuadPredicate
13103  """
13104  _IMP_core.ConstantQuadPredicate_swiginit(self, _IMP_core.new_ConstantQuadPredicate(*args))
13105 
13106  def do_get_inputs(self, arg2, arg3):
13107  r"""do_get_inputs(ConstantQuadPredicate self, Model arg2, IMP::ParticleIndexes const & arg3) -> IMP::ModelObjectsTemp"""
13108  return _IMP_core.ConstantQuadPredicate_do_get_inputs(self, arg2, arg3)
13109 
13110  def get_value(self, *args):
13111  r"""
13112  get_value(ConstantQuadPredicate self, IMP::ParticleQuad const & a) -> int
13113  get_value(ConstantQuadPredicate self, IMP::ParticleQuadsTemp const & o) -> IMP::Ints
13114  """
13115  return _IMP_core.ConstantQuadPredicate_get_value(self, *args)
13116 
13117  def get_value_index(self, *args):
13118  r"""
13119  get_value_index(ConstantQuadPredicate self, Model arg2, IMP::ParticleIndexQuad const & arg3) -> int
13120  get_value_index(ConstantQuadPredicate self, Model m, IMP::ParticleIndexQuads const & o) -> IMP::Ints
13121  """
13122  return _IMP_core.ConstantQuadPredicate_get_value_index(self, *args)
13123 
13124  def get_version_info(self):
13125  r"""get_version_info(ConstantQuadPredicate self) -> VersionInfo"""
13126  return _IMP_core.ConstantQuadPredicate_get_version_info(self)
13127  __swig_destroy__ = _IMP_core.delete_ConstantQuadPredicate
13128 
13129  def __str__(self):
13130  r"""__str__(ConstantQuadPredicate self) -> std::string"""
13131  return _IMP_core.ConstantQuadPredicate___str__(self)
13132 
13133  def __repr__(self):
13134  r"""__repr__(ConstantQuadPredicate self) -> std::string"""
13135  return _IMP_core.ConstantQuadPredicate___repr__(self)
13136 
13137  @staticmethod
13138  def get_from(o):
13139  return _object_cast_to_ConstantQuadPredicate(o)
13140 
13141 
13142  def _get_as_binary(self):
13143  r"""_get_as_binary(ConstantQuadPredicate self) -> PyObject *"""
13144  return _IMP_core.ConstantQuadPredicate__get_as_binary(self)
13145 
13146  def _set_from_binary(self, p):
13147  r"""_set_from_binary(ConstantQuadPredicate self, PyObject * p)"""
13148  return _IMP_core.ConstantQuadPredicate__set_from_binary(self, p)
13149 
13150  def __getstate__(self):
13151  p = self._get_as_binary()
13152  if len(self.__dict__) > 1:
13153  d = self.__dict__.copy()
13154  del d['this']
13155  p = (d, p)
13156  return p
13157 
13158  def __setstate__(self, p):
13159  if not hasattr(self, 'this'):
13160  self.__init__()
13161  if isinstance(p, tuple):
13162  d, p = p
13163  self.__dict__.update(d)
13164  return self._set_from_binary(p)
13165 
13166 
13167 # Register ConstantQuadPredicate in _IMP_core:
13168 _IMP_core.ConstantQuadPredicate_swigregister(ConstantQuadPredicate)
13169 class UnorderedTypeQuadPredicate(IMP.QuadPredicate):
13170  r"""Proxy of C++ IMP::core::UnorderedTypeQuadPredicate class."""
13171 
13172  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
13173 
13174  def __init__(self, *args):
13175  r"""__init__(UnorderedTypeQuadPredicate self, std::string name="UnorderedTypeQuadPredicate%1%") -> UnorderedTypeQuadPredicate"""
13176  _IMP_core.UnorderedTypeQuadPredicate_swiginit(self, _IMP_core.new_UnorderedTypeQuadPredicate(*args))
13177 
13178  def do_get_inputs(self, m, pis):
13179  r"""do_get_inputs(UnorderedTypeQuadPredicate self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
13180  return _IMP_core.UnorderedTypeQuadPredicate_do_get_inputs(self, m, pis)
13181 
13182  def get_value(self, *args):
13183  r"""
13184  get_value(UnorderedTypeQuadPredicate self, IMP::ParticleQuad const & a) -> int
13185  get_value(UnorderedTypeQuadPredicate self, IMP::ParticleQuadsTemp const & o) -> IMP::Ints
13186  """
13187  return _IMP_core.UnorderedTypeQuadPredicate_get_value(self, *args)
13188 
13189  def get_value_index(self, *args):
13190  r"""
13191  get_value_index(UnorderedTypeQuadPredicate self, Model m, IMP::ParticleIndexQuad const & pi) -> int
13192  get_value_index(UnorderedTypeQuadPredicate self, Model m, IMP::ParticleIndexQuads const & o) -> IMP::Ints
13193  """
13194  return _IMP_core.UnorderedTypeQuadPredicate_get_value_index(self, *args)
13195 
13196  def get_version_info(self):
13197  r"""get_version_info(UnorderedTypeQuadPredicate self) -> VersionInfo"""
13198  return _IMP_core.UnorderedTypeQuadPredicate_get_version_info(self)
13199  __swig_destroy__ = _IMP_core.delete_UnorderedTypeQuadPredicate
13200 
13201  def __str__(self):
13202  r"""__str__(UnorderedTypeQuadPredicate self) -> std::string"""
13203  return _IMP_core.UnorderedTypeQuadPredicate___str__(self)
13204 
13205  def __repr__(self):
13206  r"""__repr__(UnorderedTypeQuadPredicate self) -> std::string"""
13207  return _IMP_core.UnorderedTypeQuadPredicate___repr__(self)
13208 
13209  @staticmethod
13210  def get_from(o):
13211  return _object_cast_to_UnorderedTypeQuadPredicate(o)
13212 
13213 
13214  def _get_as_binary(self):
13215  r"""_get_as_binary(UnorderedTypeQuadPredicate self) -> PyObject *"""
13216  return _IMP_core.UnorderedTypeQuadPredicate__get_as_binary(self)
13217 
13218  def _set_from_binary(self, p):
13219  r"""_set_from_binary(UnorderedTypeQuadPredicate self, PyObject * p)"""
13220  return _IMP_core.UnorderedTypeQuadPredicate__set_from_binary(self, p)
13221 
13222  def __getstate__(self):
13223  p = self._get_as_binary()
13224  if len(self.__dict__) > 1:
13225  d = self.__dict__.copy()
13226  del d['this']
13227  p = (d, p)
13228  return p
13229 
13230  def __setstate__(self, p):
13231  if not hasattr(self, 'this'):
13232  self.__init__()
13233  if isinstance(p, tuple):
13234  d, p = p
13235  self.__dict__.update(d)
13236  return self._set_from_binary(p)
13237 
13238 
13239 # Register UnorderedTypeQuadPredicate in _IMP_core:
13240 _IMP_core.UnorderedTypeQuadPredicate_swigregister(UnorderedTypeQuadPredicate)
13241 class OrderedTypeQuadPredicate(IMP.QuadPredicate):
13242  r"""Proxy of C++ IMP::core::OrderedTypeQuadPredicate class."""
13243 
13244  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
13245 
13246  def __init__(self, *args):
13247  r"""__init__(OrderedTypeQuadPredicate self, std::string name="OrderedTypeQuadPredicate%1%") -> OrderedTypeQuadPredicate"""
13248  _IMP_core.OrderedTypeQuadPredicate_swiginit(self, _IMP_core.new_OrderedTypeQuadPredicate(*args))
13249 
13250  def do_get_inputs(self, m, pis):
13251  r"""do_get_inputs(OrderedTypeQuadPredicate self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
13252  return _IMP_core.OrderedTypeQuadPredicate_do_get_inputs(self, m, pis)
13253 
13254  def get_value(self, *args):
13255  r"""
13256  get_value(OrderedTypeQuadPredicate self, IMP::core::ParticleTypes const & types) -> int
13257  get_value(OrderedTypeQuadPredicate self, IMP::ParticleQuad const & a) -> int
13258  get_value(OrderedTypeQuadPredicate self, IMP::ParticleQuadsTemp const & o) -> IMP::Ints
13259  """
13260  return _IMP_core.OrderedTypeQuadPredicate_get_value(self, *args)
13261 
13262  def get_value_index(self, *args):
13263  r"""
13264  get_value_index(OrderedTypeQuadPredicate self, Model m, IMP::ParticleIndexQuad const & pi) -> int
13265  get_value_index(OrderedTypeQuadPredicate self, Model m, IMP::ParticleIndexQuads const & o) -> IMP::Ints
13266  """
13267  return _IMP_core.OrderedTypeQuadPredicate_get_value_index(self, *args)
13268 
13269  def get_version_info(self):
13270  r"""get_version_info(OrderedTypeQuadPredicate self) -> VersionInfo"""
13271  return _IMP_core.OrderedTypeQuadPredicate_get_version_info(self)
13272  __swig_destroy__ = _IMP_core.delete_OrderedTypeQuadPredicate
13273 
13274  def __str__(self):
13275  r"""__str__(OrderedTypeQuadPredicate self) -> std::string"""
13276  return _IMP_core.OrderedTypeQuadPredicate___str__(self)
13277 
13278  def __repr__(self):
13279  r"""__repr__(OrderedTypeQuadPredicate self) -> std::string"""
13280  return _IMP_core.OrderedTypeQuadPredicate___repr__(self)
13281 
13282  @staticmethod
13283  def get_from(o):
13284  return _object_cast_to_OrderedTypeQuadPredicate(o)
13285 
13286 
13287 # Register OrderedTypeQuadPredicate in _IMP_core:
13288 _IMP_core.OrderedTypeQuadPredicate_swigregister(OrderedTypeQuadPredicate)
13289 class AllSameQuadPredicate(IMP.QuadPredicate):
13290  r"""Proxy of C++ IMP::core::AllSameQuadPredicate class."""
13291 
13292  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
13293 
13294  def __init__(self, *args):
13295  r"""__init__(AllSameQuadPredicate self, std::string name="AllSameQuadPredicate%1%") -> AllSameQuadPredicate"""
13296  _IMP_core.AllSameQuadPredicate_swiginit(self, _IMP_core.new_AllSameQuadPredicate(*args))
13297 
13298  def do_get_inputs(self, arg2, arg3):
13299  r"""do_get_inputs(AllSameQuadPredicate self, Model arg2, IMP::ParticleIndexes const & arg3) -> IMP::ModelObjectsTemp"""
13300  return _IMP_core.AllSameQuadPredicate_do_get_inputs(self, arg2, arg3)
13301 
13302  def get_value(self, *args):
13303  r"""
13304  get_value(AllSameQuadPredicate self, IMP::ParticleQuad const & a) -> int
13305  get_value(AllSameQuadPredicate self, IMP::ParticleQuadsTemp const & o) -> IMP::Ints
13306  """
13307  return _IMP_core.AllSameQuadPredicate_get_value(self, *args)
13308 
13309  def get_value_index(self, *args):
13310  r"""
13311  get_value_index(AllSameQuadPredicate self, Model m, IMP::ParticleIndexQuad const & pi) -> int
13312  get_value_index(AllSameQuadPredicate self, Model m, IMP::ParticleIndexQuads const & o) -> IMP::Ints
13313  """
13314  return _IMP_core.AllSameQuadPredicate_get_value_index(self, *args)
13315 
13316  def get_version_info(self):
13317  r"""get_version_info(AllSameQuadPredicate self) -> VersionInfo"""
13318  return _IMP_core.AllSameQuadPredicate_get_version_info(self)
13319  __swig_destroy__ = _IMP_core.delete_AllSameQuadPredicate
13320 
13321  def __str__(self):
13322  r"""__str__(AllSameQuadPredicate self) -> std::string"""
13323  return _IMP_core.AllSameQuadPredicate___str__(self)
13324 
13325  def __repr__(self):
13326  r"""__repr__(AllSameQuadPredicate self) -> std::string"""
13327  return _IMP_core.AllSameQuadPredicate___repr__(self)
13328 
13329  @staticmethod
13330  def get_from(o):
13331  return _object_cast_to_AllSameQuadPredicate(o)
13332 
13333 
13334  def _get_as_binary(self):
13335  r"""_get_as_binary(AllSameQuadPredicate self) -> PyObject *"""
13336  return _IMP_core.AllSameQuadPredicate__get_as_binary(self)
13337 
13338  def _set_from_binary(self, p):
13339  r"""_set_from_binary(AllSameQuadPredicate self, PyObject * p)"""
13340  return _IMP_core.AllSameQuadPredicate__set_from_binary(self, p)
13341 
13342  def __getstate__(self):
13343  p = self._get_as_binary()
13344  if len(self.__dict__) > 1:
13345  d = self.__dict__.copy()
13346  del d['this']
13347  p = (d, p)
13348  return p
13349 
13350  def __setstate__(self, p):
13351  if not hasattr(self, 'this'):
13352  self.__init__()
13353  if isinstance(p, tuple):
13354  d, p = p
13355  self.__dict__.update(d)
13356  return self._set_from_binary(p)
13357 
13358 
13359 # Register AllSameQuadPredicate in _IMP_core:
13360 _IMP_core.AllSameQuadPredicate_swigregister(AllSameQuadPredicate)
13361 class CoinFlipQuadPredicate(IMP.QuadPredicate):
13362  r"""Proxy of C++ IMP::core::CoinFlipQuadPredicate class."""
13363 
13364  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
13365 
13366  def __init__(self, *args):
13367  r"""__init__(CoinFlipQuadPredicate self, double p, std::string name="CoinFlipQuadPredicate%1%") -> CoinFlipQuadPredicate"""
13368  _IMP_core.CoinFlipQuadPredicate_swiginit(self, _IMP_core.new_CoinFlipQuadPredicate(*args))
13369 
13370  def do_get_inputs(self, arg2, arg3):
13371  r"""do_get_inputs(CoinFlipQuadPredicate self, Model arg2, IMP::ParticleIndexes const & arg3) -> IMP::ModelObjectsTemp"""
13372  return _IMP_core.CoinFlipQuadPredicate_do_get_inputs(self, arg2, arg3)
13373 
13374  def get_value(self, *args):
13375  r"""
13376  get_value(CoinFlipQuadPredicate self, IMP::ParticleQuad const & a) -> int
13377  get_value(CoinFlipQuadPredicate self, IMP::ParticleQuadsTemp const & o) -> IMP::Ints
13378  """
13379  return _IMP_core.CoinFlipQuadPredicate_get_value(self, *args)
13380 
13381  def get_value_index(self, *args):
13382  r"""
13383  get_value_index(CoinFlipQuadPredicate self, Model arg2, IMP::ParticleIndexQuad const & arg3) -> int
13384  get_value_index(CoinFlipQuadPredicate self, Model m, IMP::ParticleIndexQuads const & o) -> IMP::Ints
13385  """
13386  return _IMP_core.CoinFlipQuadPredicate_get_value_index(self, *args)
13387 
13388  def get_version_info(self):
13389  r"""get_version_info(CoinFlipQuadPredicate self) -> VersionInfo"""
13390  return _IMP_core.CoinFlipQuadPredicate_get_version_info(self)
13391  __swig_destroy__ = _IMP_core.delete_CoinFlipQuadPredicate
13392 
13393  def __str__(self):
13394  r"""__str__(CoinFlipQuadPredicate self) -> std::string"""
13395  return _IMP_core.CoinFlipQuadPredicate___str__(self)
13396 
13397  def __repr__(self):
13398  r"""__repr__(CoinFlipQuadPredicate self) -> std::string"""
13399  return _IMP_core.CoinFlipQuadPredicate___repr__(self)
13400 
13401  @staticmethod
13402  def get_from(o):
13403  return _object_cast_to_CoinFlipQuadPredicate(o)
13404 
13405 
13406 # Register CoinFlipQuadPredicate in _IMP_core:
13407 _IMP_core.CoinFlipQuadPredicate_swigregister(CoinFlipQuadPredicate)
13408 class InBoundingBox3DSingletonPredicate(IMP.SingletonPredicate):
13409  r"""Proxy of C++ IMP::core::InBoundingBox3DSingletonPredicate class."""
13410 
13411  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
13412 
13413  def __init__(self, *args):
13414  r"""__init__(InBoundingBox3DSingletonPredicate self, BoundingBox3D bb, std::string name="InBoundingBox3DSingletonPredicate%1%") -> InBoundingBox3DSingletonPredicate"""
13415  _IMP_core.InBoundingBox3DSingletonPredicate_swiginit(self, _IMP_core.new_InBoundingBox3DSingletonPredicate(*args))
13416 
13417  def do_get_inputs(self, m, pi):
13418  r"""do_get_inputs(InBoundingBox3DSingletonPredicate self, Model m, IMP::ParticleIndexes const & pi) -> IMP::ModelObjectsTemp"""
13419  return _IMP_core.InBoundingBox3DSingletonPredicate_do_get_inputs(self, m, pi)
13420 
13421  def get_value(self, *args):
13422  r"""
13423  get_value(InBoundingBox3DSingletonPredicate self, Particle a) -> int
13424  get_value(InBoundingBox3DSingletonPredicate self, IMP::ParticlesTemp const & o) -> IMP::Ints
13425  """
13426  return _IMP_core.InBoundingBox3DSingletonPredicate_get_value(self, *args)
13427 
13428  def get_value_index(self, *args):
13429  r"""
13430  get_value_index(InBoundingBox3DSingletonPredicate self, Model m, ParticleIndex pi) -> int
13431  get_value_index(InBoundingBox3DSingletonPredicate self, Model m, IMP::ParticleIndexes const & o) -> IMP::Ints
13432  """
13433  return _IMP_core.InBoundingBox3DSingletonPredicate_get_value_index(self, *args)
13434 
13435  def get_version_info(self):
13436  r"""get_version_info(InBoundingBox3DSingletonPredicate self) -> VersionInfo"""
13437  return _IMP_core.InBoundingBox3DSingletonPredicate_get_version_info(self)
13438  __swig_destroy__ = _IMP_core.delete_InBoundingBox3DSingletonPredicate
13439 
13440  def __str__(self):
13441  r"""__str__(InBoundingBox3DSingletonPredicate self) -> std::string"""
13442  return _IMP_core.InBoundingBox3DSingletonPredicate___str__(self)
13443 
13444  def __repr__(self):
13445  r"""__repr__(InBoundingBox3DSingletonPredicate self) -> std::string"""
13446  return _IMP_core.InBoundingBox3DSingletonPredicate___repr__(self)
13447 
13448  @staticmethod
13449  def get_from(o):
13450  return _object_cast_to_InBoundingBox3DSingletonPredicate(o)
13451 
13452 
13453 # Register InBoundingBox3DSingletonPredicate in _IMP_core:
13454 _IMP_core.InBoundingBox3DSingletonPredicate_swigregister(InBoundingBox3DSingletonPredicate)
13455 class AttributeSingletonPredicate(IMP.SingletonPredicate):
13456  r"""Proxy of C++ IMP::core::AttributeSingletonPredicate class."""
13457 
13458  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
13459 
13460  def __init__(self, *args):
13461  r"""__init__(AttributeSingletonPredicate self, IntKey bb, std::string name="AttributeSingletonPredicate%1%") -> AttributeSingletonPredicate"""
13462  _IMP_core.AttributeSingletonPredicate_swiginit(self, _IMP_core.new_AttributeSingletonPredicate(*args))
13463 
13464  def do_get_inputs(self, m, pi):
13465  r"""do_get_inputs(AttributeSingletonPredicate self, Model m, IMP::ParticleIndexes const & pi) -> IMP::ModelObjectsTemp"""
13466  return _IMP_core.AttributeSingletonPredicate_do_get_inputs(self, m, pi)
13467 
13468  def get_value(self, *args):
13469  r"""
13470  get_value(AttributeSingletonPredicate self, Particle a) -> int
13471  get_value(AttributeSingletonPredicate self, IMP::ParticlesTemp const & o) -> IMP::Ints
13472  """
13473  return _IMP_core.AttributeSingletonPredicate_get_value(self, *args)
13474 
13475  def get_value_index(self, *args):
13476  r"""
13477  get_value_index(AttributeSingletonPredicate self, Model m, ParticleIndex pi) -> int
13478  get_value_index(AttributeSingletonPredicate self, Model m, IMP::ParticleIndexes const & o) -> IMP::Ints
13479  """
13480  return _IMP_core.AttributeSingletonPredicate_get_value_index(self, *args)
13481 
13482  def get_version_info(self):
13483  r"""get_version_info(AttributeSingletonPredicate self) -> VersionInfo"""
13484  return _IMP_core.AttributeSingletonPredicate_get_version_info(self)
13485  __swig_destroy__ = _IMP_core.delete_AttributeSingletonPredicate
13486 
13487  def __str__(self):
13488  r"""__str__(AttributeSingletonPredicate self) -> std::string"""
13489  return _IMP_core.AttributeSingletonPredicate___str__(self)
13490 
13491  def __repr__(self):
13492  r"""__repr__(AttributeSingletonPredicate self) -> std::string"""
13493  return _IMP_core.AttributeSingletonPredicate___repr__(self)
13494 
13495  @staticmethod
13496  def get_from(o):
13497  return _object_cast_to_AttributeSingletonPredicate(o)
13498 
13499 
13500 # Register AttributeSingletonPredicate in _IMP_core:
13501 _IMP_core.AttributeSingletonPredicate_swigregister(AttributeSingletonPredicate)
13502 class IsCollisionPairPredicate(IMP.PairPredicate):
13503  r"""Proxy of C++ IMP::core::IsCollisionPairPredicate class."""
13504 
13505  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
13506 
13507  def __init__(self, *args):
13508  r"""__init__(IsCollisionPairPredicate self, std::string name="CollisionPairPredicate%1%") -> IsCollisionPairPredicate"""
13509  _IMP_core.IsCollisionPairPredicate_swiginit(self, _IMP_core.new_IsCollisionPairPredicate(*args))
13510 
13511  def do_get_inputs(self, m, pi):
13512  r"""do_get_inputs(IsCollisionPairPredicate self, Model m, IMP::ParticleIndexes const & pi) -> IMP::ModelObjectsTemp"""
13513  return _IMP_core.IsCollisionPairPredicate_do_get_inputs(self, m, pi)
13514 
13515  def get_value(self, *args):
13516  r"""
13517  get_value(IsCollisionPairPredicate self, IMP::ParticlePair const & a) -> int
13518  get_value(IsCollisionPairPredicate self, IMP::ParticlePairsTemp const & o) -> IMP::Ints
13519  """
13520  return _IMP_core.IsCollisionPairPredicate_get_value(self, *args)
13521 
13522  def get_value_index(self, *args):
13523  r"""
13524  get_value_index(IsCollisionPairPredicate self, Model m, IMP::ParticleIndexPair const & pi) -> int
13525  get_value_index(IsCollisionPairPredicate self, Model m, IMP::ParticleIndexPairs const & o) -> IMP::Ints
13526  """
13527  return _IMP_core.IsCollisionPairPredicate_get_value_index(self, *args)
13528 
13529  def get_version_info(self):
13530  r"""get_version_info(IsCollisionPairPredicate self) -> VersionInfo"""
13531  return _IMP_core.IsCollisionPairPredicate_get_version_info(self)
13532  __swig_destroy__ = _IMP_core.delete_IsCollisionPairPredicate
13533 
13534  def __str__(self):
13535  r"""__str__(IsCollisionPairPredicate self) -> std::string"""
13536  return _IMP_core.IsCollisionPairPredicate___str__(self)
13537 
13538  def __repr__(self):
13539  r"""__repr__(IsCollisionPairPredicate self) -> std::string"""
13540  return _IMP_core.IsCollisionPairPredicate___repr__(self)
13541 
13542  @staticmethod
13543  def get_from(o):
13544  return _object_cast_to_IsCollisionPairPredicate(o)
13545 
13546 
13547 # Register IsCollisionPairPredicate in _IMP_core:
13548 _IMP_core.IsCollisionPairPredicate_swigregister(IsCollisionPairPredicate)
13549 class AngleRestraint(TripletRestraint):
13550  r"""Proxy of C++ IMP::core::AngleRestraint class."""
13551 
13552  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
13553 
13554  def __init__(self, *args):
13555  r"""
13556  __init__(AngleRestraint self, Model m, UnaryFunction score_func, _ParticleIndexAdaptor p1, _ParticleIndexAdaptor p2, _ParticleIndexAdaptor p3) -> AngleRestraint
13557  __init__(AngleRestraint self) -> AngleRestraint
13558  """
13559  _IMP_core.AngleRestraint_swiginit(self, _IMP_core.new_AngleRestraint(*args))
13560  __swig_destroy__ = _IMP_core.delete_AngleRestraint
13561 
13562  def __str__(self):
13563  r"""__str__(AngleRestraint self) -> std::string"""
13564  return _IMP_core.AngleRestraint___str__(self)
13565 
13566  def __repr__(self):
13567  r"""__repr__(AngleRestraint self) -> std::string"""
13568  return _IMP_core.AngleRestraint___repr__(self)
13569 
13570  @staticmethod
13571  def get_from(o):
13572  return _object_cast_to_AngleRestraint(o)
13573 
13574 
13575  def _get_as_binary(self):
13576  r"""_get_as_binary(AngleRestraint self) -> PyObject *"""
13577  return _IMP_core.AngleRestraint__get_as_binary(self)
13578 
13579  def _set_from_binary(self, p):
13580  r"""_set_from_binary(AngleRestraint self, PyObject * p)"""
13581  return _IMP_core.AngleRestraint__set_from_binary(self, p)
13582 
13583  def __getstate__(self):
13584  p = self._get_as_binary()
13585  if len(self.__dict__) > 1:
13586  d = self.__dict__.copy()
13587  del d['this']
13588  p = (d, p)
13589  return p
13590 
13591  def __setstate__(self, p):
13592  if not hasattr(self, 'this'):
13593  self.__init__()
13594  if isinstance(p, tuple):
13595  d, p = p
13596  self.__dict__.update(d)
13597  return self._set_from_binary(p)
13598 
13599 
13600 # Register AngleRestraint in _IMP_core:
13601 _IMP_core.AngleRestraint_swigregister(AngleRestraint)
13602 class RigidBodyMover(MonteCarloMover):
13603  r"""Proxy of C++ IMP::core::RigidBodyMover class."""
13604 
13605  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
13606 
13607  def __init__(self, *args):
13608  r"""
13609  __init__(RigidBodyMover self, Model m, ParticleIndex pi, IMP::Float max_translation, IMP::Float max_rotation) -> RigidBodyMover
13610  __init__(RigidBodyMover self) -> RigidBodyMover
13611  """
13612  _IMP_core.RigidBodyMover_swiginit(self, _IMP_core.new_RigidBodyMover(*args))
13613 
13614  def set_maximum_translation(self, mt):
13615  r"""set_maximum_translation(RigidBodyMover self, IMP::Float mt)"""
13616  return _IMP_core.RigidBodyMover_set_maximum_translation(self, mt)
13617 
13618  def set_maximum_rotation(self, mr):
13619  r"""set_maximum_rotation(RigidBodyMover self, IMP::Float mr)"""
13620  return _IMP_core.RigidBodyMover_set_maximum_rotation(self, mr)
13621 
13622  def get_maximum_translation(self):
13623  r"""get_maximum_translation(RigidBodyMover self) -> IMP::Float"""
13624  return _IMP_core.RigidBodyMover_get_maximum_translation(self)
13625 
13626  def get_maximum_rotation(self):
13627  r"""get_maximum_rotation(RigidBodyMover self) -> IMP::Float"""
13628  return _IMP_core.RigidBodyMover_get_maximum_rotation(self)
13629 
13630  def get_index(self):
13631  r"""get_index(RigidBodyMover self) -> ParticleIndex"""
13632  return _IMP_core.RigidBodyMover_get_index(self)
13633 
13634  def get_version_info(self):
13635  r"""get_version_info(RigidBodyMover self) -> VersionInfo"""
13636  return _IMP_core.RigidBodyMover_get_version_info(self)
13637  __swig_destroy__ = _IMP_core.delete_RigidBodyMover
13638 
13639  def __str__(self):
13640  r"""__str__(RigidBodyMover self) -> std::string"""
13641  return _IMP_core.RigidBodyMover___str__(self)
13642 
13643  def __repr__(self):
13644  r"""__repr__(RigidBodyMover self) -> std::string"""
13645  return _IMP_core.RigidBodyMover___repr__(self)
13646 
13647  @staticmethod
13648  def get_from(o):
13649  return _object_cast_to_RigidBodyMover(o)
13650 
13651 
13652  def _get_as_binary(self):
13653  r"""_get_as_binary(RigidBodyMover self) -> PyObject *"""
13654  return _IMP_core.RigidBodyMover__get_as_binary(self)
13655 
13656  def _set_from_binary(self, p):
13657  r"""_set_from_binary(RigidBodyMover self, PyObject * p)"""
13658  return _IMP_core.RigidBodyMover__set_from_binary(self, p)
13659 
13660  def __getstate__(self):
13661  p = self._get_as_binary()
13662  if len(self.__dict__) > 1:
13663  d = self.__dict__.copy()
13664  del d['this']
13665  p = (d, p)
13666  return p
13667 
13668  def __setstate__(self, p):
13669  if not hasattr(self, 'this'):
13670  self.__init__()
13671  if isinstance(p, tuple):
13672  d, p = p
13673  self.__dict__.update(d)
13674  return self._set_from_binary(p)
13675 
13676 
13677  def _get_jax(self):
13678  import jax.random
13679  import IMP.core._jax_rigid
13680  from IMP.algebra._jax_util import (get_random_vector_on_3d_sphere,
13681  get_random_vector_in_3d_sphere,
13682  get_rotation_about_normalized_axis,
13683  _quaternion_multiply)
13684  max_angle = self.get_maximum_rotation()
13685  max_translation = self.get_maximum_translation()
13686  particle_index = self.get_index()
13687  body_index = IMP.core._jax_rigid._get_rigid_body_index(
13688  self.get_model(), self.get_index())
13689 
13690  def init_func(key):
13691  return key
13692 
13693  def propose_func(jm, key):
13694  body = jm['rigid_bodies'].bodies[body_index]
13695  tf = body.get_transformation(jm)
13696 
13697  if max_translation > 0:
13698  key, subkey = jax.random.split(key)
13699  tf.translation += get_random_vector_in_3d_sphere(
13700  subkey, max_translation)[0]
13701  if max_angle > 0:
13702  key, subkey1, subkey2 = jax.random.split(key, 3)
13703  axis_norm = get_random_vector_on_3d_sphere(subkey1, 1.0)[0]
13704  angle = jax.random.uniform(
13705  subkey2, minval=-max_angle, maxval=max_angle)
13706  rotation = get_rotation_about_normalized_axis(axis_norm, angle)
13707  tf.rotation = _quaternion_multiply(rotation, tf.rotation)
13708  jm = body.set_transformation_lazy(tf, jm)
13709  return jm, key, 1.0
13710 
13711  return self._wrap_jax(init_func, propose_func, keys=['rigid_bodies'])
13712 
13713 
13714 # Register RigidBodyMover in _IMP_core:
13715 _IMP_core.RigidBodyMover_swigregister(RigidBodyMover)
13716 class RigidBodyTunneler(MonteCarloMover):
13717  r"""Proxy of C++ IMP::core::RigidBodyTunneler class."""
13718 
13719  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
13720 
13721  def __init__(self, m, pis, ref, k, move_probability=1.):
13722  r"""__init__(RigidBodyTunneler self, Model m, IMP::ParticleIndexes pis, ParticleIndex ref, double k, double move_probability=1.) -> RigidBodyTunneler"""
13723  _IMP_core.RigidBodyTunneler_swiginit(self, _IMP_core.new_RigidBodyTunneler(m, pis, ref, k, move_probability))
13724 
13725  def add_entry_point(self, fl):
13726  r"""add_entry_point(RigidBodyTunneler self, IMP::Floats fl)"""
13727  return _IMP_core.RigidBodyTunneler_add_entry_point(self, fl)
13728 
13729  def reset_stats(self):
13730  r"""reset_stats(RigidBodyTunneler self)"""
13731  return _IMP_core.RigidBodyTunneler_reset_stats(self)
13732 
13733  def get_number_of_rejected_moves(self):
13734  r"""get_number_of_rejected_moves(RigidBodyTunneler self) -> unsigned int"""
13735  return _IMP_core.RigidBodyTunneler_get_number_of_rejected_moves(self)
13736 
13737  def get_number_of_proposed_moves(self):
13738  r"""get_number_of_proposed_moves(RigidBodyTunneler self) -> unsigned int"""
13739  return _IMP_core.RigidBodyTunneler_get_number_of_proposed_moves(self)
13740 
13741  def get_number_of_impossible_moves(self):
13742  r"""get_number_of_impossible_moves(RigidBodyTunneler self) -> unsigned int"""
13743  return _IMP_core.RigidBodyTunneler_get_number_of_impossible_moves(self)
13744 
13745  def get_number_of_calls(self):
13746  r"""get_number_of_calls(RigidBodyTunneler self) -> unsigned int"""
13747  return _IMP_core.RigidBodyTunneler_get_number_of_calls(self)
13748 
13749  @staticmethod
13750  def get_reduced_coordinates(*args):
13751  r"""
13752  get_reduced_coordinates(Model m, ParticleIndex target, ParticleIndex ref) -> IMP::Floats
13753  get_reduced_coordinates(Model m, ParticleIndex pi) -> IMP::Floats
13754  """
13755  return _IMP_core.RigidBodyTunneler_get_reduced_coordinates(*args)
13756 
13757  @staticmethod
13758  def set_reduced_coordinates(m, target, ref, coords):
13759  r"""set_reduced_coordinates(Model m, ParticleIndex target, ParticleIndex ref, IMP::Floats coords)"""
13760  return _IMP_core.RigidBodyTunneler_set_reduced_coordinates(m, target, ref, coords)
13761 
13762  def get_version_info(self):
13763  r"""get_version_info(RigidBodyTunneler self) -> VersionInfo"""
13764  return _IMP_core.RigidBodyTunneler_get_version_info(self)
13765  __swig_destroy__ = _IMP_core.delete_RigidBodyTunneler
13766 
13767  def __str__(self):
13768  r"""__str__(RigidBodyTunneler self) -> std::string"""
13769  return _IMP_core.RigidBodyTunneler___str__(self)
13770 
13771  def __repr__(self):
13772  r"""__repr__(RigidBodyTunneler self) -> std::string"""
13773  return _IMP_core.RigidBodyTunneler___repr__(self)
13774 
13775  @staticmethod
13776  def get_from(o):
13777  return _object_cast_to_RigidBodyTunneler(o)
13778 
13779 
13780 # Register RigidBodyTunneler in _IMP_core:
13781 _IMP_core.RigidBodyTunneler_swigregister(RigidBodyTunneler)
13782 class RigidBodyUmbrella(IMP.Restraint):
13783  r"""Proxy of C++ IMP::core::RigidBodyUmbrella class."""
13784 
13785  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
13786 
13787  def __init__(self, *args):
13788  r"""
13789  __init__(RigidBodyUmbrella self, Model m, ParticleIndex pi, ParticleIndex ref, IMP::Floats x0, double alpha, double k, std::string name="RigidBodyUmbrella %1%") -> RigidBodyUmbrella
13790  __init__(RigidBodyUmbrella self, Model m, ParticleIndex pi, ParticleIndex ref, double _lambda, IMP::Floats x1, IMP::Floats x2, double alpha, double k, std::string name="RigidBodyUmbrella %1%") -> RigidBodyUmbrella
13791  """
13792  _IMP_core.RigidBodyUmbrella_swiginit(self, _IMP_core.new_RigidBodyUmbrella(*args))
13793 
13794  def set_x0(self, *args):
13795  r"""
13796  set_x0(RigidBodyUmbrella self, IMP::Floats x0)
13797  set_x0(RigidBodyUmbrella self, double _lambda, IMP::Floats x1, IMP::Floats x2)
13798  """
13799  return _IMP_core.RigidBodyUmbrella_set_x0(self, *args)
13800 
13801  def get_x0(self):
13802  r"""get_x0(RigidBodyUmbrella self) -> IMP::Floats"""
13803  return _IMP_core.RigidBodyUmbrella_get_x0(self)
13804 
13805  def get_x(self):
13806  r"""get_x(RigidBodyUmbrella self) -> IMP::Floats"""
13807  return _IMP_core.RigidBodyUmbrella_get_x(self)
13808 
13809  def set_alpha(self, alpha):
13810  r"""set_alpha(RigidBodyUmbrella self, double alpha)"""
13811  return _IMP_core.RigidBodyUmbrella_set_alpha(self, alpha)
13812 
13813  def set_k(self, k):
13814  r"""set_k(RigidBodyUmbrella self, double k)"""
13815  return _IMP_core.RigidBodyUmbrella_set_k(self, k)
13816 
13817  def get_version_info(self):
13818  r"""get_version_info(RigidBodyUmbrella self) -> VersionInfo"""
13819  return _IMP_core.RigidBodyUmbrella_get_version_info(self)
13820  __swig_destroy__ = _IMP_core.delete_RigidBodyUmbrella
13821 
13822  def __str__(self):
13823  r"""__str__(RigidBodyUmbrella self) -> std::string"""
13824  return _IMP_core.RigidBodyUmbrella___str__(self)
13825 
13826  def __repr__(self):
13827  r"""__repr__(RigidBodyUmbrella self) -> std::string"""
13828  return _IMP_core.RigidBodyUmbrella___repr__(self)
13829 
13830  @staticmethod
13831  def get_from(o):
13832  return _object_cast_to_RigidBodyUmbrella(o)
13833 
13834 
13835 # Register RigidBodyUmbrella in _IMP_core:
13836 _IMP_core.RigidBodyUmbrella_swigregister(RigidBodyUmbrella)
13837 class VolumeRestraint(IMP.Restraint):
13838  r"""Proxy of C++ IMP::core::VolumeRestraint class."""
13839 
13840  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
13841 
13842  def __init__(self, f, sc, volume):
13843  r"""__init__(VolumeRestraint self, UnaryFunction f, SingletonContainer sc, double volume) -> VolumeRestraint"""
13844  _IMP_core.VolumeRestraint_swiginit(self, _IMP_core.new_VolumeRestraint(f, sc, volume))
13845 
13846  def do_get_inputs(self):
13847  r"""do_get_inputs(VolumeRestraint self) -> IMP::ModelObjectsTemp"""
13848  return _IMP_core.VolumeRestraint_do_get_inputs(self)
13849 
13850  def get_version_info(self):
13851  r"""get_version_info(VolumeRestraint self) -> VersionInfo"""
13852  return _IMP_core.VolumeRestraint_get_version_info(self)
13853  __swig_destroy__ = _IMP_core.delete_VolumeRestraint
13854 
13855  def __str__(self):
13856  r"""__str__(VolumeRestraint self) -> std::string"""
13857  return _IMP_core.VolumeRestraint___str__(self)
13858 
13859  def __repr__(self):
13860  r"""__repr__(VolumeRestraint self) -> std::string"""
13861  return _IMP_core.VolumeRestraint___repr__(self)
13862 
13863  @staticmethod
13864  def get_from(o):
13865  return _object_cast_to_VolumeRestraint(o)
13866 
13867 
13868 # Register VolumeRestraint in _IMP_core:
13869 _IMP_core.VolumeRestraint_swigregister(VolumeRestraint)
13870 
13871 def get_centroid(ps):
13872  r"""get_centroid(IMP::core::XYZs const & ps) -> Vector3D"""
13873  return _IMP_core.get_centroid(ps)
13874 
13875 def get_bounding_box(ps):
13876  r"""get_bounding_box(IMP::core::XYZRs const & ps) -> BoundingBox3D"""
13877  return _IMP_core.get_bounding_box(ps)
13878 class MoveStatisticsScoreState(IMP.ScoreState):
13879  r"""Proxy of C++ IMP::core::MoveStatisticsScoreState class."""
13880 
13881  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
13882 
13883  def __init__(self, ps):
13884  r"""__init__(MoveStatisticsScoreState self, IMP::ParticlesTemp const & ps) -> MoveStatisticsScoreState"""
13885  _IMP_core.MoveStatisticsScoreState_swiginit(self, _IMP_core.new_MoveStatisticsScoreState(ps))
13886 
13887  def show_statistics(self, *args):
13888  r"""show_statistics(MoveStatisticsScoreState self, _ostream out=std::cout)"""
13889  return _IMP_core.MoveStatisticsScoreState_show_statistics(self, *args)
13890 
13891  def reset(self):
13892  r"""reset(MoveStatisticsScoreState self)"""
13893  return _IMP_core.MoveStatisticsScoreState_reset(self)
13894 
13895  def do_before_evaluate(self):
13896  r"""do_before_evaluate(MoveStatisticsScoreState self)"""
13897  return _IMP_core.MoveStatisticsScoreState_do_before_evaluate(self)
13898 
13899  def do_after_evaluate(self, da):
13900  r"""do_after_evaluate(MoveStatisticsScoreState self, DerivativeAccumulator da)"""
13901  return _IMP_core.MoveStatisticsScoreState_do_after_evaluate(self, da)
13902 
13903  def do_get_inputs(self):
13904  r"""do_get_inputs(MoveStatisticsScoreState self) -> IMP::ModelObjectsTemp"""
13905  return _IMP_core.MoveStatisticsScoreState_do_get_inputs(self)
13906 
13907  def do_get_outputs(self):
13908  r"""do_get_outputs(MoveStatisticsScoreState self) -> IMP::ModelObjectsTemp"""
13909  return _IMP_core.MoveStatisticsScoreState_do_get_outputs(self)
13910 
13911  def get_version_info(self):
13912  r"""get_version_info(MoveStatisticsScoreState self) -> VersionInfo"""
13913  return _IMP_core.MoveStatisticsScoreState_get_version_info(self)
13914  __swig_destroy__ = _IMP_core.delete_MoveStatisticsScoreState
13915 
13916  def __str__(self):
13917  r"""__str__(MoveStatisticsScoreState self) -> std::string"""
13918  return _IMP_core.MoveStatisticsScoreState___str__(self)
13919 
13920  def __repr__(self):
13921  r"""__repr__(MoveStatisticsScoreState self) -> std::string"""
13922  return _IMP_core.MoveStatisticsScoreState___repr__(self)
13923 
13924  @staticmethod
13925  def get_from(o):
13926  return _object_cast_to_MoveStatisticsScoreState(o)
13927 
13928 
13929 # Register MoveStatisticsScoreState in _IMP_core:
13930 _IMP_core.MoveStatisticsScoreState_swigregister(MoveStatisticsScoreState)
13931 IMP_PARTICLE_TYPE_INDEX = _IMP_core.IMP_PARTICLE_TYPE_INDEX
13932 
13933 class Typed(IMP.Decorator):
13934  r"""Proxy of C++ IMP::core::Typed class."""
13935 
13936  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
13937 
13938  @staticmethod
13939  def get_type_key():
13940  r"""get_type_key() -> IntKey"""
13941  return _IMP_core.Typed_get_type_key()
13942 
13943  def __init__(self, *args):
13944  r"""
13945  __init__(Typed self) -> Typed
13946  __init__(Typed self, Model m, ParticleIndex id) -> Typed
13947  __init__(Typed self, _ParticleAdaptor d) -> Typed
13948  """
13949  _IMP_core.Typed_swiginit(self, _IMP_core.new_Typed(*args))
13950 
13951  def show(self, *args):
13952  r"""show(Typed self, _ostream out=std::cout)"""
13953  return _IMP_core.Typed_show(self, *args)
13954 
13955  @staticmethod
13956  def setup_particle(*args):
13957  r"""
13958  setup_particle(Model m, ParticleIndex pi, ParticleType t) -> Typed
13959  setup_particle(_ParticleAdaptor pa, ParticleType t) -> Typed
13960  """
13961  return _IMP_core.Typed_setup_particle(*args)
13962 
13963  @staticmethod
13964  def get_is_setup(*args):
13965  r"""
13966  get_is_setup(_ParticleAdaptor p) -> bool
13967  get_is_setup(Model m, ParticleIndex pi) -> bool
13968  """
13969  return _IMP_core.Typed_get_is_setup(*args)
13970 
13971  def get_type(self):
13972  r"""get_type(Typed self) -> ParticleType"""
13973  return _IMP_core.Typed_get_type(self)
13974 
13975  def set_type(self, pt):
13976  r"""set_type(Typed self, ParticleType pt)"""
13977  return _IMP_core.Typed_set_type(self, pt)
13978 
13979  def add_attribute(self, *args):
13980  r"""
13981  add_attribute(Typed self, FloatKey k, IMP::Float v, bool opt)
13982  add_attribute(Typed self, FloatKey a0, IMP::Float a1)
13983  add_attribute(Typed self, IntKey a0, IMP::Int a1)
13984  add_attribute(Typed self, FloatsKey a0, IMP::Floats a1)
13985  add_attribute(Typed self, IntsKey a0, IMP::Ints a1)
13986  add_attribute(Typed self, StringKey a0, IMP::String a1)
13987  add_attribute(Typed self, ParticleIndexKey a0, Particle a1)
13988  add_attribute(Typed self, ObjectKey a0, Object a1)
13989  add_attribute(Typed self, SparseFloatKey a0, IMP::Float a1)
13990  add_attribute(Typed self, SparseIntKey a0, IMP::Int a1)
13991  add_attribute(Typed self, SparseStringKey a0, IMP::String a1)
13992  add_attribute(Typed self, SparseParticleIndexKey a0, ParticleIndex a1)
13993  """
13994  return _IMP_core.Typed_add_attribute(self, *args)
13995 
13996  def get_value(self, *args):
13997  r"""
13998  get_value(Typed self, FloatKey a0) -> IMP::Float
13999  get_value(Typed self, IntKey a0) -> IMP::Int
14000  get_value(Typed self, FloatsKey a0) -> IMP::Floats
14001  get_value(Typed self, IntsKey a0) -> IMP::Ints
14002  get_value(Typed self, StringKey a0) -> IMP::String
14003  get_value(Typed self, ParticleIndexKey a0) -> Particle
14004  get_value(Typed self, ObjectKey a0) -> Object
14005  get_value(Typed self, SparseFloatKey a0) -> IMP::Float
14006  get_value(Typed self, SparseIntKey a0) -> IMP::Int
14007  get_value(Typed self, SparseStringKey a0) -> IMP::String
14008  get_value(Typed self, SparseParticleIndexKey a0) -> ParticleIndex
14009  """
14010  return _IMP_core.Typed_get_value(self, *args)
14011 
14012  def set_value(self, *args):
14013  r"""
14014  set_value(Typed self, FloatKey a0, IMP::Float a1)
14015  set_value(Typed self, IntKey a0, IMP::Int a1)
14016  set_value(Typed self, FloatsKey a0, IMP::Floats a1)
14017  set_value(Typed self, IntsKey a0, IMP::Ints a1)
14018  set_value(Typed self, StringKey a0, IMP::String a1)
14019  set_value(Typed self, ParticleIndexKey a0, Particle a1)
14020  set_value(Typed self, ObjectKey a0, Object a1)
14021  set_value(Typed self, SparseFloatKey a0, IMP::Float a1)
14022  set_value(Typed self, SparseIntKey a0, IMP::Int a1)
14023  set_value(Typed self, SparseStringKey a0, IMP::String a1)
14024  set_value(Typed self, SparseParticleIndexKey a0, ParticleIndex a1)
14025  """
14026  return _IMP_core.Typed_set_value(self, *args)
14027 
14028  def remove_attribute(self, *args):
14029  r"""
14030  remove_attribute(Typed self, FloatKey a0)
14031  remove_attribute(Typed self, IntKey a0)
14032  remove_attribute(Typed self, FloatsKey a0)
14033  remove_attribute(Typed self, IntsKey a0)
14034  remove_attribute(Typed self, StringKey a0)
14035  remove_attribute(Typed self, ParticleIndexKey a0)
14036  remove_attribute(Typed self, ObjectKey a0)
14037  remove_attribute(Typed self, SparseFloatKey a0)
14038  remove_attribute(Typed self, SparseIntKey a0)
14039  remove_attribute(Typed self, SparseStringKey a0)
14040  remove_attribute(Typed self, SparseParticleIndexKey a0)
14041  """
14042  return _IMP_core.Typed_remove_attribute(self, *args)
14043 
14044  def has_attribute(self, *args):
14045  r"""
14046  has_attribute(Typed self, FloatKey a0) -> bool
14047  has_attribute(Typed self, IntKey a0) -> bool
14048  has_attribute(Typed self, FloatsKey a0) -> bool
14049  has_attribute(Typed self, IntsKey a0) -> bool
14050  has_attribute(Typed self, StringKey a0) -> bool
14051  has_attribute(Typed self, ParticleIndexKey a0) -> bool
14052  has_attribute(Typed self, ObjectKey a0) -> bool
14053  has_attribute(Typed self, SparseFloatKey a0) -> bool
14054  has_attribute(Typed self, SparseIntKey a0) -> bool
14055  has_attribute(Typed self, SparseStringKey a0) -> bool
14056  has_attribute(Typed self, SparseParticleIndexKey a0) -> bool
14057  """
14058  return _IMP_core.Typed_has_attribute(self, *args)
14059 
14060  def get_derivative(self, a0):
14061  r"""get_derivative(Typed self, FloatKey a0) -> double"""
14062  return _IMP_core.Typed_get_derivative(self, a0)
14063 
14064  def get_name(self):
14065  r"""get_name(Typed self) -> std::string"""
14066  return _IMP_core.Typed_get_name(self)
14067 
14068  def clear_caches(self):
14069  r"""clear_caches(Typed self)"""
14070  return _IMP_core.Typed_clear_caches(self)
14071 
14072  def set_name(self, a0):
14073  r"""set_name(Typed self, std::string a0)"""
14074  return _IMP_core.Typed_set_name(self, a0)
14075 
14076  def set_check_level(self, a0):
14077  r"""set_check_level(Typed self, IMP::CheckLevel a0)"""
14078  return _IMP_core.Typed_set_check_level(self, a0)
14079 
14080  def add_to_derivative(self, a0, a1, a2):
14081  r"""add_to_derivative(Typed self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
14082  return _IMP_core.Typed_add_to_derivative(self, a0, a1, a2)
14083 
14084  def set_is_optimized(self, a0, a1):
14085  r"""set_is_optimized(Typed self, FloatKey a0, bool a1)"""
14086  return _IMP_core.Typed_set_is_optimized(self, a0, a1)
14087 
14088  def get_is_optimized(self, a0):
14089  r"""get_is_optimized(Typed self, FloatKey a0) -> bool"""
14090  return _IMP_core.Typed_get_is_optimized(self, a0)
14091 
14092  def get_check_level(self):
14093  r"""get_check_level(Typed self) -> IMP::CheckLevel"""
14094  return _IMP_core.Typed_get_check_level(self)
14095 
14096  def __eq__(self, *args):
14097  r"""
14098  __eq__(Typed self, Typed o) -> bool
14099  __eq__(Typed self, Particle d) -> bool
14100  """
14101  return _IMP_core.Typed___eq__(self, *args)
14102 
14103  def __ne__(self, *args):
14104  r"""
14105  __ne__(Typed self, Typed o) -> bool
14106  __ne__(Typed self, Particle d) -> bool
14107  """
14108  return _IMP_core.Typed___ne__(self, *args)
14109 
14110  def __le__(self, *args):
14111  r"""
14112  __le__(Typed self, Typed o) -> bool
14113  __le__(Typed self, Particle d) -> bool
14114  """
14115  return _IMP_core.Typed___le__(self, *args)
14116 
14117  def __lt__(self, *args):
14118  r"""
14119  __lt__(Typed self, Typed o) -> bool
14120  __lt__(Typed self, Particle d) -> bool
14121  """
14122  return _IMP_core.Typed___lt__(self, *args)
14123 
14124  def __ge__(self, *args):
14125  r"""
14126  __ge__(Typed self, Typed o) -> bool
14127  __ge__(Typed self, Particle d) -> bool
14128  """
14129  return _IMP_core.Typed___ge__(self, *args)
14130 
14131  def __gt__(self, *args):
14132  r"""
14133  __gt__(Typed self, Typed o) -> bool
14134  __gt__(Typed self, Particle d) -> bool
14135  """
14136  return _IMP_core.Typed___gt__(self, *args)
14137 
14138  def __hash__(self):
14139  r"""__hash__(Typed self) -> std::size_t"""
14140  return _IMP_core.Typed___hash__(self)
14141 
14142  def __str__(self):
14143  r"""__str__(Typed self) -> std::string"""
14144  return _IMP_core.Typed___str__(self)
14145 
14146  def __repr__(self):
14147  r"""__repr__(Typed self) -> std::string"""
14148  return _IMP_core.Typed___repr__(self)
14149 
14150  def _get_as_binary(self):
14151  r"""_get_as_binary(Typed self) -> PyObject *"""
14152  return _IMP_core.Typed__get_as_binary(self)
14153 
14154  def _set_from_binary(self, p):
14155  r"""_set_from_binary(Typed self, PyObject * p)"""
14156  return _IMP_core.Typed__set_from_binary(self, p)
14157 
14158  def __getstate__(self):
14159  p = self._get_as_binary()
14160  if len(self.__dict__) > 1:
14161  d = self.__dict__.copy()
14162  del d['this']
14163  p = (d, p)
14164  return p
14165 
14166  def __setstate__(self, p):
14167  if not hasattr(self, 'this'):
14168  self.__init__()
14169  if isinstance(p, tuple):
14170  d, p = p
14171  self.__dict__.update(d)
14172  return self._set_from_binary(p)
14173 
14174  __swig_destroy__ = _IMP_core.delete_Typed
14175 
14176 # Register Typed in _IMP_core:
14177 _IMP_core.Typed_swigregister(Typed)
14178 
14179 def __lshift__(*args):
14180  r"""
14181  __lshift__(_ostream out, XYZ n) -> _ostream
14182  __lshift__(_ostream out, XYZR n) -> _ostream
14183  __lshift__(_ostream out, Direction n) -> _ostream
14184  __lshift__(_ostream out, DirectionAngle n) -> _ostream
14185  __lshift__(_ostream out, Surface n) -> _ostream
14186  __lshift__(_ostream out, Centroid n) -> _ostream
14187  __lshift__(_ostream out, Cover n) -> _ostream
14188  __lshift__(_ostream out, Reference n) -> _ostream
14189  __lshift__(_ostream out, RigidMember n) -> _ostream
14190  __lshift__(_ostream out, RigidBody n) -> _ostream
14191  __lshift__(_ostream out, Gaussian n) -> _ostream
14192  __lshift__(_ostream out, Typed n) -> _ostream
14193  """
14194  return _IMP_core.__lshift__(*args)
14195 class WriteRestraintScoresOptimizerState(IMP.OptimizerState):
14196  r"""Proxy of C++ IMP::core::WriteRestraintScoresOptimizerState class."""
14197 
14198  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
14199 
14200  def __init__(self, rs, out):
14201  r"""__init__(WriteRestraintScoresOptimizerState self, IMP::Restraints const & rs, TextOutput out) -> WriteRestraintScoresOptimizerState"""
14202  _IMP_core.WriteRestraintScoresOptimizerState_swiginit(self, _IMP_core.new_WriteRestraintScoresOptimizerState(rs, out))
14203 
14204  def get_version_info(self):
14205  r"""get_version_info(WriteRestraintScoresOptimizerState self) -> VersionInfo"""
14206  return _IMP_core.WriteRestraintScoresOptimizerState_get_version_info(self)
14207  __swig_destroy__ = _IMP_core.delete_WriteRestraintScoresOptimizerState
14208 
14209  def __str__(self):
14210  r"""__str__(WriteRestraintScoresOptimizerState self) -> std::string"""
14211  return _IMP_core.WriteRestraintScoresOptimizerState___str__(self)
14212 
14213  def __repr__(self):
14214  r"""__repr__(WriteRestraintScoresOptimizerState self) -> std::string"""
14215  return _IMP_core.WriteRestraintScoresOptimizerState___repr__(self)
14216 
14217  @staticmethod
14218  def get_from(o):
14219  return _object_cast_to_WriteRestraintScoresOptimizerState(o)
14220 
14221 
14222 # Register WriteRestraintScoresOptimizerState in _IMP_core:
14223 _IMP_core.WriteRestraintScoresOptimizerState_swigregister(WriteRestraintScoresOptimizerState)
14224 
14225 def assign_blame(rs, ps, attribute):
14226  r"""assign_blame(IMP::RestraintsTemp const & rs, IMP::ParticlesTemp const & ps, FloatKey attribute)"""
14227  return _IMP_core.assign_blame(rs, ps, attribute)
14228 
14229 def create_blame_geometries(*args):
14230  r"""create_blame_geometries(IMP::RestraintsTemp const & rs, IMP::ParticlesTemp const & ps, double max=NO_MAX, std::string name=std::string()) -> IMP::display::Geometries"""
14231  return _IMP_core.create_blame_geometries(*args)
14232 class MultipleBinormalRestraint(IMP.Restraint):
14233  r"""Proxy of C++ IMP::core::MultipleBinormalRestraint class."""
14234 
14235  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
14236 
14237  def __init__(self, m, q1, q2):
14238  r"""__init__(MultipleBinormalRestraint self, Model m, IMP::ParticleIndexQuad const & q1, IMP::ParticleIndexQuad const & q2) -> MultipleBinormalRestraint"""
14239  _IMP_core.MultipleBinormalRestraint_swiginit(self, _IMP_core.new_MultipleBinormalRestraint(m, q1, q2))
14240 
14241  def add_term(self, term):
14242  r"""add_term(MultipleBinormalRestraint self, BinormalTerm term)"""
14243  return _IMP_core.MultipleBinormalRestraint_add_term(self, term)
14244 
14245  def do_get_inputs(self):
14246  r"""do_get_inputs(MultipleBinormalRestraint self) -> IMP::ModelObjectsTemp"""
14247  return _IMP_core.MultipleBinormalRestraint_do_get_inputs(self)
14248 
14249  def get_version_info(self):
14250  r"""get_version_info(MultipleBinormalRestraint self) -> VersionInfo"""
14251  return _IMP_core.MultipleBinormalRestraint_get_version_info(self)
14252  __swig_destroy__ = _IMP_core.delete_MultipleBinormalRestraint
14253 
14254  def __str__(self):
14255  r"""__str__(MultipleBinormalRestraint self) -> std::string"""
14256  return _IMP_core.MultipleBinormalRestraint___str__(self)
14257 
14258  def __repr__(self):
14259  r"""__repr__(MultipleBinormalRestraint self) -> std::string"""
14260  return _IMP_core.MultipleBinormalRestraint___repr__(self)
14261 
14262  @staticmethod
14263  def get_from(o):
14264  return _object_cast_to_MultipleBinormalRestraint(o)
14265 
14266 
14267 # Register MultipleBinormalRestraint in _IMP_core:
14268 _IMP_core.MultipleBinormalRestraint_swigregister(MultipleBinormalRestraint)
14269 class BinormalTerm(object):
14270  r"""Proxy of C++ IMP::core::BinormalTerm class."""
14271 
14272  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
14273 
14274  def __init__(self):
14275  r"""__init__(BinormalTerm self) -> BinormalTerm"""
14276  _IMP_core.BinormalTerm_swiginit(self, _IMP_core.new_BinormalTerm())
14277 
14278  def set_correlation(self, correlation):
14279  r"""set_correlation(BinormalTerm self, double correlation)"""
14280  return _IMP_core.BinormalTerm_set_correlation(self, correlation)
14281 
14282  def set_weight(self, weight):
14283  r"""set_weight(BinormalTerm self, double weight)"""
14284  return _IMP_core.BinormalTerm_set_weight(self, weight)
14285 
14286  def set_means(self, means):
14287  r"""set_means(BinormalTerm self, IMP::FloatPair means)"""
14288  return _IMP_core.BinormalTerm_set_means(self, means)
14289 
14290  def set_standard_deviations(self, stdevs):
14291  r"""set_standard_deviations(BinormalTerm self, IMP::FloatPair stdevs)"""
14292  return _IMP_core.BinormalTerm_set_standard_deviations(self, stdevs)
14293 
14294  def show(self, *args):
14295  r"""show(BinormalTerm self, _ostream out=std::cout)"""
14296  return _IMP_core.BinormalTerm_show(self, *args)
14297 
14298  def __str__(self):
14299  r"""__str__(BinormalTerm self) -> std::string"""
14300  return _IMP_core.BinormalTerm___str__(self)
14301 
14302  def __repr__(self):
14303  r"""__repr__(BinormalTerm self) -> std::string"""
14304  return _IMP_core.BinormalTerm___repr__(self)
14305 
14306  def _get_as_binary(self):
14307  r"""_get_as_binary(BinormalTerm self) -> PyObject *"""
14308  return _IMP_core.BinormalTerm__get_as_binary(self)
14309 
14310  def _set_from_binary(self, p):
14311  r"""_set_from_binary(BinormalTerm self, PyObject * p)"""
14312  return _IMP_core.BinormalTerm__set_from_binary(self, p)
14313 
14314  def __getstate__(self):
14315  p = self._get_as_binary()
14316  if len(self.__dict__) > 1:
14317  d = self.__dict__.copy()
14318  del d['this']
14319  p = (d, p)
14320  return p
14321 
14322  def __setstate__(self, p):
14323  if not hasattr(self, 'this'):
14324  self.__init__()
14325  if isinstance(p, tuple):
14326  d, p = p
14327  self.__dict__.update(d)
14328  return self._set_from_binary(p)
14329 
14330  __swig_destroy__ = _IMP_core.delete_BinormalTerm
14331 
14332 # Register BinormalTerm in _IMP_core:
14333 _IMP_core.BinormalTerm_swigregister(BinormalTerm)
14334 class Provenance(IMP.Decorator):
14335  r"""Proxy of C++ IMP::core::Provenance class."""
14336 
14337  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
14338 
14339  def get_previous(self):
14340  r"""get_previous(Provenance self) -> Provenance"""
14341  return _IMP_core.Provenance_get_previous(self)
14342 
14343  def set_previous(self, p):
14344  r"""set_previous(Provenance self, Provenance p)"""
14345  return _IMP_core.Provenance_set_previous(self, p)
14346 
14347  def __init__(self, *args):
14348  r"""
14349  __init__(Provenance self) -> Provenance
14350  __init__(Provenance self, Model m, ParticleIndex id) -> Provenance
14351  __init__(Provenance self, _ParticleAdaptor d) -> Provenance
14352  """
14353  _IMP_core.Provenance_swiginit(self, _IMP_core.new_Provenance(*args))
14354 
14355  @staticmethod
14356  def get_is_setup(*args):
14357  r"""
14358  get_is_setup(Model m, ParticleIndex pi) -> bool
14359  get_is_setup(_ParticleAdaptor p) -> bool
14360  """
14361  return _IMP_core.Provenance_get_is_setup(*args)
14362 
14363  def show(self, *args):
14364  r"""show(Provenance self, _ostream out=std::cout)"""
14365  return _IMP_core.Provenance_show(self, *args)
14366 
14367  @staticmethod
14368  def setup_particle(*args):
14369  r"""
14370  setup_particle(Model m, ParticleIndex pi) -> Provenance
14371  setup_particle(_ParticleAdaptor pa) -> Provenance
14372  """
14373  return _IMP_core.Provenance_setup_particle(*args)
14374 
14375  def add_attribute(self, *args):
14376  r"""
14377  add_attribute(Provenance self, FloatKey k, IMP::Float v, bool opt)
14378  add_attribute(Provenance self, FloatKey a0, IMP::Float a1)
14379  add_attribute(Provenance self, IntKey a0, IMP::Int a1)
14380  add_attribute(Provenance self, FloatsKey a0, IMP::Floats a1)
14381  add_attribute(Provenance self, IntsKey a0, IMP::Ints a1)
14382  add_attribute(Provenance self, StringKey a0, IMP::String a1)
14383  add_attribute(Provenance self, ParticleIndexKey a0, Particle a1)
14384  add_attribute(Provenance self, ObjectKey a0, Object a1)
14385  add_attribute(Provenance self, SparseFloatKey a0, IMP::Float a1)
14386  add_attribute(Provenance self, SparseIntKey a0, IMP::Int a1)
14387  add_attribute(Provenance self, SparseStringKey a0, IMP::String a1)
14388  add_attribute(Provenance self, SparseParticleIndexKey a0, ParticleIndex a1)
14389  """
14390  return _IMP_core.Provenance_add_attribute(self, *args)
14391 
14392  def get_value(self, *args):
14393  r"""
14394  get_value(Provenance self, FloatKey a0) -> IMP::Float
14395  get_value(Provenance self, IntKey a0) -> IMP::Int
14396  get_value(Provenance self, FloatsKey a0) -> IMP::Floats
14397  get_value(Provenance self, IntsKey a0) -> IMP::Ints
14398  get_value(Provenance self, StringKey a0) -> IMP::String
14399  get_value(Provenance self, ParticleIndexKey a0) -> Particle
14400  get_value(Provenance self, ObjectKey a0) -> Object
14401  get_value(Provenance self, SparseFloatKey a0) -> IMP::Float
14402  get_value(Provenance self, SparseIntKey a0) -> IMP::Int
14403  get_value(Provenance self, SparseStringKey a0) -> IMP::String
14404  get_value(Provenance self, SparseParticleIndexKey a0) -> ParticleIndex
14405  """
14406  return _IMP_core.Provenance_get_value(self, *args)
14407 
14408  def set_value(self, *args):
14409  r"""
14410  set_value(Provenance self, FloatKey a0, IMP::Float a1)
14411  set_value(Provenance self, IntKey a0, IMP::Int a1)
14412  set_value(Provenance self, FloatsKey a0, IMP::Floats a1)
14413  set_value(Provenance self, IntsKey a0, IMP::Ints a1)
14414  set_value(Provenance self, StringKey a0, IMP::String a1)
14415  set_value(Provenance self, ParticleIndexKey a0, Particle a1)
14416  set_value(Provenance self, ObjectKey a0, Object a1)
14417  set_value(Provenance self, SparseFloatKey a0, IMP::Float a1)
14418  set_value(Provenance self, SparseIntKey a0, IMP::Int a1)
14419  set_value(Provenance self, SparseStringKey a0, IMP::String a1)
14420  set_value(Provenance self, SparseParticleIndexKey a0, ParticleIndex a1)
14421  """
14422  return _IMP_core.Provenance_set_value(self, *args)
14423 
14424  def remove_attribute(self, *args):
14425  r"""
14426  remove_attribute(Provenance self, FloatKey a0)
14427  remove_attribute(Provenance self, IntKey a0)
14428  remove_attribute(Provenance self, FloatsKey a0)
14429  remove_attribute(Provenance self, IntsKey a0)
14430  remove_attribute(Provenance self, StringKey a0)
14431  remove_attribute(Provenance self, ParticleIndexKey a0)
14432  remove_attribute(Provenance self, ObjectKey a0)
14433  remove_attribute(Provenance self, SparseFloatKey a0)
14434  remove_attribute(Provenance self, SparseIntKey a0)
14435  remove_attribute(Provenance self, SparseStringKey a0)
14436  remove_attribute(Provenance self, SparseParticleIndexKey a0)
14437  """
14438  return _IMP_core.Provenance_remove_attribute(self, *args)
14439 
14440  def has_attribute(self, *args):
14441  r"""
14442  has_attribute(Provenance self, FloatKey a0) -> bool
14443  has_attribute(Provenance self, IntKey a0) -> bool
14444  has_attribute(Provenance self, FloatsKey a0) -> bool
14445  has_attribute(Provenance self, IntsKey a0) -> bool
14446  has_attribute(Provenance self, StringKey a0) -> bool
14447  has_attribute(Provenance self, ParticleIndexKey a0) -> bool
14448  has_attribute(Provenance self, ObjectKey a0) -> bool
14449  has_attribute(Provenance self, SparseFloatKey a0) -> bool
14450  has_attribute(Provenance self, SparseIntKey a0) -> bool
14451  has_attribute(Provenance self, SparseStringKey a0) -> bool
14452  has_attribute(Provenance self, SparseParticleIndexKey a0) -> bool
14453  """
14454  return _IMP_core.Provenance_has_attribute(self, *args)
14455 
14456  def get_derivative(self, a0):
14457  r"""get_derivative(Provenance self, FloatKey a0) -> double"""
14458  return _IMP_core.Provenance_get_derivative(self, a0)
14459 
14460  def get_name(self):
14461  r"""get_name(Provenance self) -> std::string"""
14462  return _IMP_core.Provenance_get_name(self)
14463 
14464  def clear_caches(self):
14465  r"""clear_caches(Provenance self)"""
14466  return _IMP_core.Provenance_clear_caches(self)
14467 
14468  def set_name(self, a0):
14469  r"""set_name(Provenance self, std::string a0)"""
14470  return _IMP_core.Provenance_set_name(self, a0)
14471 
14472  def set_check_level(self, a0):
14473  r"""set_check_level(Provenance self, IMP::CheckLevel a0)"""
14474  return _IMP_core.Provenance_set_check_level(self, a0)
14475 
14476  def add_to_derivative(self, a0, a1, a2):
14477  r"""add_to_derivative(Provenance self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
14478  return _IMP_core.Provenance_add_to_derivative(self, a0, a1, a2)
14479 
14480  def set_is_optimized(self, a0, a1):
14481  r"""set_is_optimized(Provenance self, FloatKey a0, bool a1)"""
14482  return _IMP_core.Provenance_set_is_optimized(self, a0, a1)
14483 
14484  def get_is_optimized(self, a0):
14485  r"""get_is_optimized(Provenance self, FloatKey a0) -> bool"""
14486  return _IMP_core.Provenance_get_is_optimized(self, a0)
14487 
14488  def get_check_level(self):
14489  r"""get_check_level(Provenance self) -> IMP::CheckLevel"""
14490  return _IMP_core.Provenance_get_check_level(self)
14491 
14492  def __eq__(self, *args):
14493  r"""
14494  __eq__(Provenance self, Provenance o) -> bool
14495  __eq__(Provenance self, Particle d) -> bool
14496  """
14497  return _IMP_core.Provenance___eq__(self, *args)
14498 
14499  def __ne__(self, *args):
14500  r"""
14501  __ne__(Provenance self, Provenance o) -> bool
14502  __ne__(Provenance self, Particle d) -> bool
14503  """
14504  return _IMP_core.Provenance___ne__(self, *args)
14505 
14506  def __le__(self, *args):
14507  r"""
14508  __le__(Provenance self, Provenance o) -> bool
14509  __le__(Provenance self, Particle d) -> bool
14510  """
14511  return _IMP_core.Provenance___le__(self, *args)
14512 
14513  def __lt__(self, *args):
14514  r"""
14515  __lt__(Provenance self, Provenance o) -> bool
14516  __lt__(Provenance self, Particle d) -> bool
14517  """
14518  return _IMP_core.Provenance___lt__(self, *args)
14519 
14520  def __ge__(self, *args):
14521  r"""
14522  __ge__(Provenance self, Provenance o) -> bool
14523  __ge__(Provenance self, Particle d) -> bool
14524  """
14525  return _IMP_core.Provenance___ge__(self, *args)
14526 
14527  def __gt__(self, *args):
14528  r"""
14529  __gt__(Provenance self, Provenance o) -> bool
14530  __gt__(Provenance self, Particle d) -> bool
14531  """
14532  return _IMP_core.Provenance___gt__(self, *args)
14533 
14534  def __hash__(self):
14535  r"""__hash__(Provenance self) -> std::size_t"""
14536  return _IMP_core.Provenance___hash__(self)
14537 
14538  def __str__(self):
14539  r"""__str__(Provenance self) -> std::string"""
14540  return _IMP_core.Provenance___str__(self)
14541 
14542  def __repr__(self):
14543  r"""__repr__(Provenance self) -> std::string"""
14544  return _IMP_core.Provenance___repr__(self)
14545 
14546  def _get_as_binary(self):
14547  r"""_get_as_binary(Provenance self) -> PyObject *"""
14548  return _IMP_core.Provenance__get_as_binary(self)
14549 
14550  def _set_from_binary(self, p):
14551  r"""_set_from_binary(Provenance self, PyObject * p)"""
14552  return _IMP_core.Provenance__set_from_binary(self, p)
14553 
14554  def __getstate__(self):
14555  p = self._get_as_binary()
14556  if len(self.__dict__) > 1:
14557  d = self.__dict__.copy()
14558  del d['this']
14559  p = (d, p)
14560  return p
14561 
14562  def __setstate__(self, p):
14563  if not hasattr(self, 'this'):
14564  self.__init__()
14565  if isinstance(p, tuple):
14566  d, p = p
14567  self.__dict__.update(d)
14568  return self._set_from_binary(p)
14569 
14570  __swig_destroy__ = _IMP_core.delete_Provenance
14571 
14572 # Register Provenance in _IMP_core:
14573 _IMP_core.Provenance_swigregister(Provenance)
14574 class StructureProvenance(Provenance):
14575  r"""Proxy of C++ IMP::core::StructureProvenance class."""
14576 
14577  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
14578 
14579  def set_filename(self, filename):
14580  r"""set_filename(StructureProvenance self, std::string filename)"""
14581  return _IMP_core.StructureProvenance_set_filename(self, filename)
14582 
14583  def get_filename(self):
14584  r"""get_filename(StructureProvenance self) -> std::string"""
14585  return _IMP_core.StructureProvenance_get_filename(self)
14586 
14587  def set_chain_id(self, chain_id):
14588  r"""set_chain_id(StructureProvenance self, std::string chain_id)"""
14589  return _IMP_core.StructureProvenance_set_chain_id(self, chain_id)
14590 
14591  def get_chain_id(self):
14592  r"""get_chain_id(StructureProvenance self) -> std::string"""
14593  return _IMP_core.StructureProvenance_get_chain_id(self)
14594 
14595  def set_residue_offset(self, residue_offset):
14596  r"""set_residue_offset(StructureProvenance self, int residue_offset)"""
14597  return _IMP_core.StructureProvenance_set_residue_offset(self, residue_offset)
14598 
14599  def get_residue_offset(self):
14600  r"""get_residue_offset(StructureProvenance self) -> int"""
14601  return _IMP_core.StructureProvenance_get_residue_offset(self)
14602 
14603  def __init__(self, *args):
14604  r"""
14605  __init__(StructureProvenance self) -> StructureProvenance
14606  __init__(StructureProvenance self, Model m, ParticleIndex id) -> StructureProvenance
14607  __init__(StructureProvenance self, _ParticleAdaptor d) -> StructureProvenance
14608  """
14609  _IMP_core.StructureProvenance_swiginit(self, _IMP_core.new_StructureProvenance(*args))
14610 
14611  @staticmethod
14612  def get_is_setup(*args):
14613  r"""
14614  get_is_setup(Model m, ParticleIndex pi) -> bool
14615  get_is_setup(_ParticleAdaptor p) -> bool
14616  """
14617  return _IMP_core.StructureProvenance_get_is_setup(*args)
14618 
14619  def show(self, *args):
14620  r"""show(StructureProvenance self, _ostream out=std::cout)"""
14621  return _IMP_core.StructureProvenance_show(self, *args)
14622 
14623  @staticmethod
14624  def setup_particle(*args):
14625  r"""
14626  setup_particle(Model m, ParticleIndex pi, std::string filename, std::string chain_id, int residue_offset) -> StructureProvenance
14627  setup_particle(_ParticleAdaptor pa, std::string filename, std::string chain_id, int residue_offset) -> StructureProvenance
14628  setup_particle(Model m, ParticleIndex pi, std::string filename, std::string chain_id) -> StructureProvenance
14629  setup_particle(_ParticleAdaptor pa, std::string filename, std::string chain_id) -> StructureProvenance
14630  setup_particle(Model m, ParticleIndex pi, StructureProvenance o) -> StructureProvenance
14631  setup_particle(_ParticleAdaptor pa, StructureProvenance o) -> StructureProvenance
14632  """
14633  return _IMP_core.StructureProvenance_setup_particle(*args)
14634 
14635  def add_attribute(self, *args):
14636  r"""
14637  add_attribute(StructureProvenance self, FloatKey k, IMP::Float v, bool opt)
14638  add_attribute(StructureProvenance self, FloatKey a0, IMP::Float a1)
14639  add_attribute(StructureProvenance self, IntKey a0, IMP::Int a1)
14640  add_attribute(StructureProvenance self, FloatsKey a0, IMP::Floats a1)
14641  add_attribute(StructureProvenance self, IntsKey a0, IMP::Ints a1)
14642  add_attribute(StructureProvenance self, StringKey a0, IMP::String a1)
14643  add_attribute(StructureProvenance self, ParticleIndexKey a0, Particle a1)
14644  add_attribute(StructureProvenance self, ObjectKey a0, Object a1)
14645  add_attribute(StructureProvenance self, SparseFloatKey a0, IMP::Float a1)
14646  add_attribute(StructureProvenance self, SparseIntKey a0, IMP::Int a1)
14647  add_attribute(StructureProvenance self, SparseStringKey a0, IMP::String a1)
14648  add_attribute(StructureProvenance self, SparseParticleIndexKey a0, ParticleIndex a1)
14649  """
14650  return _IMP_core.StructureProvenance_add_attribute(self, *args)
14651 
14652  def get_value(self, *args):
14653  r"""
14654  get_value(StructureProvenance self, FloatKey a0) -> IMP::Float
14655  get_value(StructureProvenance self, IntKey a0) -> IMP::Int
14656  get_value(StructureProvenance self, FloatsKey a0) -> IMP::Floats
14657  get_value(StructureProvenance self, IntsKey a0) -> IMP::Ints
14658  get_value(StructureProvenance self, StringKey a0) -> IMP::String
14659  get_value(StructureProvenance self, ParticleIndexKey a0) -> Particle
14660  get_value(StructureProvenance self, ObjectKey a0) -> Object
14661  get_value(StructureProvenance self, SparseFloatKey a0) -> IMP::Float
14662  get_value(StructureProvenance self, SparseIntKey a0) -> IMP::Int
14663  get_value(StructureProvenance self, SparseStringKey a0) -> IMP::String
14664  get_value(StructureProvenance self, SparseParticleIndexKey a0) -> ParticleIndex
14665  """
14666  return _IMP_core.StructureProvenance_get_value(self, *args)
14667 
14668  def set_value(self, *args):
14669  r"""
14670  set_value(StructureProvenance self, FloatKey a0, IMP::Float a1)
14671  set_value(StructureProvenance self, IntKey a0, IMP::Int a1)
14672  set_value(StructureProvenance self, FloatsKey a0, IMP::Floats a1)
14673  set_value(StructureProvenance self, IntsKey a0, IMP::Ints a1)
14674  set_value(StructureProvenance self, StringKey a0, IMP::String a1)
14675  set_value(StructureProvenance self, ParticleIndexKey a0, Particle a1)
14676  set_value(StructureProvenance self, ObjectKey a0, Object a1)
14677  set_value(StructureProvenance self, SparseFloatKey a0, IMP::Float a1)
14678  set_value(StructureProvenance self, SparseIntKey a0, IMP::Int a1)
14679  set_value(StructureProvenance self, SparseStringKey a0, IMP::String a1)
14680  set_value(StructureProvenance self, SparseParticleIndexKey a0, ParticleIndex a1)
14681  """
14682  return _IMP_core.StructureProvenance_set_value(self, *args)
14683 
14684  def remove_attribute(self, *args):
14685  r"""
14686  remove_attribute(StructureProvenance self, FloatKey a0)
14687  remove_attribute(StructureProvenance self, IntKey a0)
14688  remove_attribute(StructureProvenance self, FloatsKey a0)
14689  remove_attribute(StructureProvenance self, IntsKey a0)
14690  remove_attribute(StructureProvenance self, StringKey a0)
14691  remove_attribute(StructureProvenance self, ParticleIndexKey a0)
14692  remove_attribute(StructureProvenance self, ObjectKey a0)
14693  remove_attribute(StructureProvenance self, SparseFloatKey a0)
14694  remove_attribute(StructureProvenance self, SparseIntKey a0)
14695  remove_attribute(StructureProvenance self, SparseStringKey a0)
14696  remove_attribute(StructureProvenance self, SparseParticleIndexKey a0)
14697  """
14698  return _IMP_core.StructureProvenance_remove_attribute(self, *args)
14699 
14700  def has_attribute(self, *args):
14701  r"""
14702  has_attribute(StructureProvenance self, FloatKey a0) -> bool
14703  has_attribute(StructureProvenance self, IntKey a0) -> bool
14704  has_attribute(StructureProvenance self, FloatsKey a0) -> bool
14705  has_attribute(StructureProvenance self, IntsKey a0) -> bool
14706  has_attribute(StructureProvenance self, StringKey a0) -> bool
14707  has_attribute(StructureProvenance self, ParticleIndexKey a0) -> bool
14708  has_attribute(StructureProvenance self, ObjectKey a0) -> bool
14709  has_attribute(StructureProvenance self, SparseFloatKey a0) -> bool
14710  has_attribute(StructureProvenance self, SparseIntKey a0) -> bool
14711  has_attribute(StructureProvenance self, SparseStringKey a0) -> bool
14712  has_attribute(StructureProvenance self, SparseParticleIndexKey a0) -> bool
14713  """
14714  return _IMP_core.StructureProvenance_has_attribute(self, *args)
14715 
14716  def get_derivative(self, a0):
14717  r"""get_derivative(StructureProvenance self, FloatKey a0) -> double"""
14718  return _IMP_core.StructureProvenance_get_derivative(self, a0)
14719 
14720  def get_name(self):
14721  r"""get_name(StructureProvenance self) -> std::string"""
14722  return _IMP_core.StructureProvenance_get_name(self)
14723 
14724  def clear_caches(self):
14725  r"""clear_caches(StructureProvenance self)"""
14726  return _IMP_core.StructureProvenance_clear_caches(self)
14727 
14728  def set_name(self, a0):
14729  r"""set_name(StructureProvenance self, std::string a0)"""
14730  return _IMP_core.StructureProvenance_set_name(self, a0)
14731 
14732  def set_check_level(self, a0):
14733  r"""set_check_level(StructureProvenance self, IMP::CheckLevel a0)"""
14734  return _IMP_core.StructureProvenance_set_check_level(self, a0)
14735 
14736  def add_to_derivative(self, a0, a1, a2):
14737  r"""add_to_derivative(StructureProvenance self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
14738  return _IMP_core.StructureProvenance_add_to_derivative(self, a0, a1, a2)
14739 
14740  def set_is_optimized(self, a0, a1):
14741  r"""set_is_optimized(StructureProvenance self, FloatKey a0, bool a1)"""
14742  return _IMP_core.StructureProvenance_set_is_optimized(self, a0, a1)
14743 
14744  def get_is_optimized(self, a0):
14745  r"""get_is_optimized(StructureProvenance self, FloatKey a0) -> bool"""
14746  return _IMP_core.StructureProvenance_get_is_optimized(self, a0)
14747 
14748  def get_check_level(self):
14749  r"""get_check_level(StructureProvenance self) -> IMP::CheckLevel"""
14750  return _IMP_core.StructureProvenance_get_check_level(self)
14751 
14752  def __eq__(self, *args):
14753  r"""
14754  __eq__(StructureProvenance self, StructureProvenance o) -> bool
14755  __eq__(StructureProvenance self, Particle d) -> bool
14756  """
14757  return _IMP_core.StructureProvenance___eq__(self, *args)
14758 
14759  def __ne__(self, *args):
14760  r"""
14761  __ne__(StructureProvenance self, StructureProvenance o) -> bool
14762  __ne__(StructureProvenance self, Particle d) -> bool
14763  """
14764  return _IMP_core.StructureProvenance___ne__(self, *args)
14765 
14766  def __le__(self, *args):
14767  r"""
14768  __le__(StructureProvenance self, StructureProvenance o) -> bool
14769  __le__(StructureProvenance self, Particle d) -> bool
14770  """
14771  return _IMP_core.StructureProvenance___le__(self, *args)
14772 
14773  def __lt__(self, *args):
14774  r"""
14775  __lt__(StructureProvenance self, StructureProvenance o) -> bool
14776  __lt__(StructureProvenance self, Particle d) -> bool
14777  """
14778  return _IMP_core.StructureProvenance___lt__(self, *args)
14779 
14780  def __ge__(self, *args):
14781  r"""
14782  __ge__(StructureProvenance self, StructureProvenance o) -> bool
14783  __ge__(StructureProvenance self, Particle d) -> bool
14784  """
14785  return _IMP_core.StructureProvenance___ge__(self, *args)
14786 
14787  def __gt__(self, *args):
14788  r"""
14789  __gt__(StructureProvenance self, StructureProvenance o) -> bool
14790  __gt__(StructureProvenance self, Particle d) -> bool
14791  """
14792  return _IMP_core.StructureProvenance___gt__(self, *args)
14793 
14794  def __hash__(self):
14795  r"""__hash__(StructureProvenance self) -> std::size_t"""
14796  return _IMP_core.StructureProvenance___hash__(self)
14797 
14798  def __str__(self):
14799  r"""__str__(StructureProvenance self) -> std::string"""
14800  return _IMP_core.StructureProvenance___str__(self)
14801 
14802  def __repr__(self):
14803  r"""__repr__(StructureProvenance self) -> std::string"""
14804  return _IMP_core.StructureProvenance___repr__(self)
14805 
14806  def _get_as_binary(self):
14807  r"""_get_as_binary(StructureProvenance self) -> PyObject *"""
14808  return _IMP_core.StructureProvenance__get_as_binary(self)
14809 
14810  def _set_from_binary(self, p):
14811  r"""_set_from_binary(StructureProvenance self, PyObject * p)"""
14812  return _IMP_core.StructureProvenance__set_from_binary(self, p)
14813 
14814  def __getstate__(self):
14815  p = self._get_as_binary()
14816  if len(self.__dict__) > 1:
14817  d = self.__dict__.copy()
14818  del d['this']
14819  p = (d, p)
14820  return p
14821 
14822  def __setstate__(self, p):
14823  if not hasattr(self, 'this'):
14824  self.__init__()
14825  if isinstance(p, tuple):
14826  d, p = p
14827  self.__dict__.update(d)
14828  return self._set_from_binary(p)
14829 
14830  __swig_destroy__ = _IMP_core.delete_StructureProvenance
14831 
14832 # Register StructureProvenance in _IMP_core:
14833 _IMP_core.StructureProvenance_swigregister(StructureProvenance)
14834 class SampleProvenance(Provenance):
14835  r"""Proxy of C++ IMP::core::SampleProvenance class."""
14836 
14837  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
14838 
14839  def set_method(self, method):
14840  r"""set_method(SampleProvenance self, std::string method)"""
14841  return _IMP_core.SampleProvenance_set_method(self, method)
14842 
14843  def get_method(self):
14844  r"""get_method(SampleProvenance self) -> std::string"""
14845  return _IMP_core.SampleProvenance_get_method(self)
14846 
14847  def set_number_of_frames(self, frames):
14848  r"""set_number_of_frames(SampleProvenance self, int frames)"""
14849  return _IMP_core.SampleProvenance_set_number_of_frames(self, frames)
14850 
14851  def get_number_of_frames(self):
14852  r"""get_number_of_frames(SampleProvenance self) -> int"""
14853  return _IMP_core.SampleProvenance_get_number_of_frames(self)
14854 
14855  def set_number_of_iterations(self, iterations):
14856  r"""set_number_of_iterations(SampleProvenance self, int iterations)"""
14857  return _IMP_core.SampleProvenance_set_number_of_iterations(self, iterations)
14858 
14859  def get_number_of_iterations(self):
14860  r"""get_number_of_iterations(SampleProvenance self) -> int"""
14861  return _IMP_core.SampleProvenance_get_number_of_iterations(self)
14862 
14863  def set_number_of_replicas(self, replicas):
14864  r"""set_number_of_replicas(SampleProvenance self, int replicas)"""
14865  return _IMP_core.SampleProvenance_set_number_of_replicas(self, replicas)
14866 
14867  def get_number_of_replicas(self):
14868  r"""get_number_of_replicas(SampleProvenance self) -> int"""
14869  return _IMP_core.SampleProvenance_get_number_of_replicas(self)
14870 
14871  def __init__(self, *args):
14872  r"""
14873  __init__(SampleProvenance self) -> SampleProvenance
14874  __init__(SampleProvenance self, Model m, ParticleIndex id) -> SampleProvenance
14875  __init__(SampleProvenance self, _ParticleAdaptor d) -> SampleProvenance
14876  """
14877  _IMP_core.SampleProvenance_swiginit(self, _IMP_core.new_SampleProvenance(*args))
14878 
14879  @staticmethod
14880  def get_is_setup(*args):
14881  r"""
14882  get_is_setup(Model m, ParticleIndex pi) -> bool
14883  get_is_setup(_ParticleAdaptor p) -> bool
14884  """
14885  return _IMP_core.SampleProvenance_get_is_setup(*args)
14886 
14887  def show(self, *args):
14888  r"""show(SampleProvenance self, _ostream out=std::cout)"""
14889  return _IMP_core.SampleProvenance_show(self, *args)
14890 
14891  @staticmethod
14892  def setup_particle(*args):
14893  r"""
14894  setup_particle(Model m, ParticleIndex pi, std::string method, int frames, int iterations, int replicas) -> SampleProvenance
14895  setup_particle(_ParticleAdaptor pa, std::string method, int frames, int iterations, int replicas) -> SampleProvenance
14896  setup_particle(Model m, ParticleIndex pi, std::string method, int frames, int iterations) -> SampleProvenance
14897  setup_particle(_ParticleAdaptor pa, std::string method, int frames, int iterations) -> SampleProvenance
14898  setup_particle(Model m, ParticleIndex pi, SampleProvenance o) -> SampleProvenance
14899  setup_particle(_ParticleAdaptor pa, SampleProvenance o) -> SampleProvenance
14900  """
14901  return _IMP_core.SampleProvenance_setup_particle(*args)
14902 
14903  def add_attribute(self, *args):
14904  r"""
14905  add_attribute(SampleProvenance self, FloatKey k, IMP::Float v, bool opt)
14906  add_attribute(SampleProvenance self, FloatKey a0, IMP::Float a1)
14907  add_attribute(SampleProvenance self, IntKey a0, IMP::Int a1)
14908  add_attribute(SampleProvenance self, FloatsKey a0, IMP::Floats a1)
14909  add_attribute(SampleProvenance self, IntsKey a0, IMP::Ints a1)
14910  add_attribute(SampleProvenance self, StringKey a0, IMP::String a1)
14911  add_attribute(SampleProvenance self, ParticleIndexKey a0, Particle a1)
14912  add_attribute(SampleProvenance self, ObjectKey a0, Object a1)
14913  add_attribute(SampleProvenance self, SparseFloatKey a0, IMP::Float a1)
14914  add_attribute(SampleProvenance self, SparseIntKey a0, IMP::Int a1)
14915  add_attribute(SampleProvenance self, SparseStringKey a0, IMP::String a1)
14916  add_attribute(SampleProvenance self, SparseParticleIndexKey a0, ParticleIndex a1)
14917  """
14918  return _IMP_core.SampleProvenance_add_attribute(self, *args)
14919 
14920  def get_value(self, *args):
14921  r"""
14922  get_value(SampleProvenance self, FloatKey a0) -> IMP::Float
14923  get_value(SampleProvenance self, IntKey a0) -> IMP::Int
14924  get_value(SampleProvenance self, FloatsKey a0) -> IMP::Floats
14925  get_value(SampleProvenance self, IntsKey a0) -> IMP::Ints
14926  get_value(SampleProvenance self, StringKey a0) -> IMP::String
14927  get_value(SampleProvenance self, ParticleIndexKey a0) -> Particle
14928  get_value(SampleProvenance self, ObjectKey a0) -> Object
14929  get_value(SampleProvenance self, SparseFloatKey a0) -> IMP::Float
14930  get_value(SampleProvenance self, SparseIntKey a0) -> IMP::Int
14931  get_value(SampleProvenance self, SparseStringKey a0) -> IMP::String
14932  get_value(SampleProvenance self, SparseParticleIndexKey a0) -> ParticleIndex
14933  """
14934  return _IMP_core.SampleProvenance_get_value(self, *args)
14935 
14936  def set_value(self, *args):
14937  r"""
14938  set_value(SampleProvenance self, FloatKey a0, IMP::Float a1)
14939  set_value(SampleProvenance self, IntKey a0, IMP::Int a1)
14940  set_value(SampleProvenance self, FloatsKey a0, IMP::Floats a1)
14941  set_value(SampleProvenance self, IntsKey a0, IMP::Ints a1)
14942  set_value(SampleProvenance self, StringKey a0, IMP::String a1)
14943  set_value(SampleProvenance self, ParticleIndexKey a0, Particle a1)
14944  set_value(SampleProvenance self, ObjectKey a0, Object a1)
14945  set_value(SampleProvenance self, SparseFloatKey a0, IMP::Float a1)
14946  set_value(SampleProvenance self, SparseIntKey a0, IMP::Int a1)
14947  set_value(SampleProvenance self, SparseStringKey a0, IMP::String a1)
14948  set_value(SampleProvenance self, SparseParticleIndexKey a0, ParticleIndex a1)
14949  """
14950  return _IMP_core.SampleProvenance_set_value(self, *args)
14951 
14952  def remove_attribute(self, *args):
14953  r"""
14954  remove_attribute(SampleProvenance self, FloatKey a0)
14955  remove_attribute(SampleProvenance self, IntKey a0)
14956  remove_attribute(SampleProvenance self, FloatsKey a0)
14957  remove_attribute(SampleProvenance self, IntsKey a0)
14958  remove_attribute(SampleProvenance self, StringKey a0)
14959  remove_attribute(SampleProvenance self, ParticleIndexKey a0)
14960  remove_attribute(SampleProvenance self, ObjectKey a0)
14961  remove_attribute(SampleProvenance self, SparseFloatKey a0)
14962  remove_attribute(SampleProvenance self, SparseIntKey a0)
14963  remove_attribute(SampleProvenance self, SparseStringKey a0)
14964  remove_attribute(SampleProvenance self, SparseParticleIndexKey a0)
14965  """
14966  return _IMP_core.SampleProvenance_remove_attribute(self, *args)
14967 
14968  def has_attribute(self, *args):
14969  r"""
14970  has_attribute(SampleProvenance self, FloatKey a0) -> bool
14971  has_attribute(SampleProvenance self, IntKey a0) -> bool
14972  has_attribute(SampleProvenance self, FloatsKey a0) -> bool
14973  has_attribute(SampleProvenance self, IntsKey a0) -> bool
14974  has_attribute(SampleProvenance self, StringKey a0) -> bool
14975  has_attribute(SampleProvenance self, ParticleIndexKey a0) -> bool
14976  has_attribute(SampleProvenance self, ObjectKey a0) -> bool
14977  has_attribute(SampleProvenance self, SparseFloatKey a0) -> bool
14978  has_attribute(SampleProvenance self, SparseIntKey a0) -> bool
14979  has_attribute(SampleProvenance self, SparseStringKey a0) -> bool
14980  has_attribute(SampleProvenance self, SparseParticleIndexKey a0) -> bool
14981  """
14982  return _IMP_core.SampleProvenance_has_attribute(self, *args)
14983 
14984  def get_derivative(self, a0):
14985  r"""get_derivative(SampleProvenance self, FloatKey a0) -> double"""
14986  return _IMP_core.SampleProvenance_get_derivative(self, a0)
14987 
14988  def get_name(self):
14989  r"""get_name(SampleProvenance self) -> std::string"""
14990  return _IMP_core.SampleProvenance_get_name(self)
14991 
14992  def clear_caches(self):
14993  r"""clear_caches(SampleProvenance self)"""
14994  return _IMP_core.SampleProvenance_clear_caches(self)
14995 
14996  def set_name(self, a0):
14997  r"""set_name(SampleProvenance self, std::string a0)"""
14998  return _IMP_core.SampleProvenance_set_name(self, a0)
14999 
15000  def set_check_level(self, a0):
15001  r"""set_check_level(SampleProvenance self, IMP::CheckLevel a0)"""
15002  return _IMP_core.SampleProvenance_set_check_level(self, a0)
15003 
15004  def add_to_derivative(self, a0, a1, a2):
15005  r"""add_to_derivative(SampleProvenance self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
15006  return _IMP_core.SampleProvenance_add_to_derivative(self, a0, a1, a2)
15007 
15008  def set_is_optimized(self, a0, a1):
15009  r"""set_is_optimized(SampleProvenance self, FloatKey a0, bool a1)"""
15010  return _IMP_core.SampleProvenance_set_is_optimized(self, a0, a1)
15011 
15012  def get_is_optimized(self, a0):
15013  r"""get_is_optimized(SampleProvenance self, FloatKey a0) -> bool"""
15014  return _IMP_core.SampleProvenance_get_is_optimized(self, a0)
15015 
15016  def get_check_level(self):
15017  r"""get_check_level(SampleProvenance self) -> IMP::CheckLevel"""
15018  return _IMP_core.SampleProvenance_get_check_level(self)
15019 
15020  def __eq__(self, *args):
15021  r"""
15022  __eq__(SampleProvenance self, SampleProvenance o) -> bool
15023  __eq__(SampleProvenance self, Particle d) -> bool
15024  """
15025  return _IMP_core.SampleProvenance___eq__(self, *args)
15026 
15027  def __ne__(self, *args):
15028  r"""
15029  __ne__(SampleProvenance self, SampleProvenance o) -> bool
15030  __ne__(SampleProvenance self, Particle d) -> bool
15031  """
15032  return _IMP_core.SampleProvenance___ne__(self, *args)
15033 
15034  def __le__(self, *args):
15035  r"""
15036  __le__(SampleProvenance self, SampleProvenance o) -> bool
15037  __le__(SampleProvenance self, Particle d) -> bool
15038  """
15039  return _IMP_core.SampleProvenance___le__(self, *args)
15040 
15041  def __lt__(self, *args):
15042  r"""
15043  __lt__(SampleProvenance self, SampleProvenance o) -> bool
15044  __lt__(SampleProvenance self, Particle d) -> bool
15045  """
15046  return _IMP_core.SampleProvenance___lt__(self, *args)
15047 
15048  def __ge__(self, *args):
15049  r"""
15050  __ge__(SampleProvenance self, SampleProvenance o) -> bool
15051  __ge__(SampleProvenance self, Particle d) -> bool
15052  """
15053  return _IMP_core.SampleProvenance___ge__(self, *args)
15054 
15055  def __gt__(self, *args):
15056  r"""
15057  __gt__(SampleProvenance self, SampleProvenance o) -> bool
15058  __gt__(SampleProvenance self, Particle d) -> bool
15059  """
15060  return _IMP_core.SampleProvenance___gt__(self, *args)
15061 
15062  def __hash__(self):
15063  r"""__hash__(SampleProvenance self) -> std::size_t"""
15064  return _IMP_core.SampleProvenance___hash__(self)
15065 
15066  def __str__(self):
15067  r"""__str__(SampleProvenance self) -> std::string"""
15068  return _IMP_core.SampleProvenance___str__(self)
15069 
15070  def __repr__(self):
15071  r"""__repr__(SampleProvenance self) -> std::string"""
15072  return _IMP_core.SampleProvenance___repr__(self)
15073 
15074  def _get_as_binary(self):
15075  r"""_get_as_binary(SampleProvenance self) -> PyObject *"""
15076  return _IMP_core.SampleProvenance__get_as_binary(self)
15077 
15078  def _set_from_binary(self, p):
15079  r"""_set_from_binary(SampleProvenance self, PyObject * p)"""
15080  return _IMP_core.SampleProvenance__set_from_binary(self, p)
15081 
15082  def __getstate__(self):
15083  p = self._get_as_binary()
15084  if len(self.__dict__) > 1:
15085  d = self.__dict__.copy()
15086  del d['this']
15087  p = (d, p)
15088  return p
15089 
15090  def __setstate__(self, p):
15091  if not hasattr(self, 'this'):
15092  self.__init__()
15093  if isinstance(p, tuple):
15094  d, p = p
15095  self.__dict__.update(d)
15096  return self._set_from_binary(p)
15097 
15098  __swig_destroy__ = _IMP_core.delete_SampleProvenance
15099 
15100 # Register SampleProvenance in _IMP_core:
15101 _IMP_core.SampleProvenance_swigregister(SampleProvenance)
15102 class CombineProvenance(Provenance):
15103  r"""Proxy of C++ IMP::core::CombineProvenance class."""
15104 
15105  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
15106 
15107  def set_number_of_frames(self, frames):
15108  r"""set_number_of_frames(CombineProvenance self, int frames)"""
15109  return _IMP_core.CombineProvenance_set_number_of_frames(self, frames)
15110 
15111  def get_number_of_frames(self):
15112  r"""get_number_of_frames(CombineProvenance self) -> int"""
15113  return _IMP_core.CombineProvenance_get_number_of_frames(self)
15114 
15115  def set_number_of_runs(self, runs):
15116  r"""set_number_of_runs(CombineProvenance self, int runs)"""
15117  return _IMP_core.CombineProvenance_set_number_of_runs(self, runs)
15118 
15119  def get_number_of_runs(self):
15120  r"""get_number_of_runs(CombineProvenance self) -> int"""
15121  return _IMP_core.CombineProvenance_get_number_of_runs(self)
15122 
15123  def __init__(self, *args):
15124  r"""
15125  __init__(CombineProvenance self) -> CombineProvenance
15126  __init__(CombineProvenance self, Model m, ParticleIndex id) -> CombineProvenance
15127  __init__(CombineProvenance self, _ParticleAdaptor d) -> CombineProvenance
15128  """
15129  _IMP_core.CombineProvenance_swiginit(self, _IMP_core.new_CombineProvenance(*args))
15130 
15131  @staticmethod
15132  def get_is_setup(*args):
15133  r"""
15134  get_is_setup(Model m, ParticleIndex pi) -> bool
15135  get_is_setup(_ParticleAdaptor p) -> bool
15136  """
15137  return _IMP_core.CombineProvenance_get_is_setup(*args)
15138 
15139  def show(self, *args):
15140  r"""show(CombineProvenance self, _ostream out=std::cout)"""
15141  return _IMP_core.CombineProvenance_show(self, *args)
15142 
15143  @staticmethod
15144  def setup_particle(*args):
15145  r"""
15146  setup_particle(Model m, ParticleIndex pi, int runs, int frames) -> CombineProvenance
15147  setup_particle(_ParticleAdaptor pa, int runs, int frames) -> CombineProvenance
15148  setup_particle(Model m, ParticleIndex pi, CombineProvenance o) -> CombineProvenance
15149  setup_particle(_ParticleAdaptor pa, CombineProvenance o) -> CombineProvenance
15150  """
15151  return _IMP_core.CombineProvenance_setup_particle(*args)
15152 
15153  def add_attribute(self, *args):
15154  r"""
15155  add_attribute(CombineProvenance self, FloatKey k, IMP::Float v, bool opt)
15156  add_attribute(CombineProvenance self, FloatKey a0, IMP::Float a1)
15157  add_attribute(CombineProvenance self, IntKey a0, IMP::Int a1)
15158  add_attribute(CombineProvenance self, FloatsKey a0, IMP::Floats a1)
15159  add_attribute(CombineProvenance self, IntsKey a0, IMP::Ints a1)
15160  add_attribute(CombineProvenance self, StringKey a0, IMP::String a1)
15161  add_attribute(CombineProvenance self, ParticleIndexKey a0, Particle a1)
15162  add_attribute(CombineProvenance self, ObjectKey a0, Object a1)
15163  add_attribute(CombineProvenance self, SparseFloatKey a0, IMP::Float a1)
15164  add_attribute(CombineProvenance self, SparseIntKey a0, IMP::Int a1)
15165  add_attribute(CombineProvenance self, SparseStringKey a0, IMP::String a1)
15166  add_attribute(CombineProvenance self, SparseParticleIndexKey a0, ParticleIndex a1)
15167  """
15168  return _IMP_core.CombineProvenance_add_attribute(self, *args)
15169 
15170  def get_value(self, *args):
15171  r"""
15172  get_value(CombineProvenance self, FloatKey a0) -> IMP::Float
15173  get_value(CombineProvenance self, IntKey a0) -> IMP::Int
15174  get_value(CombineProvenance self, FloatsKey a0) -> IMP::Floats
15175  get_value(CombineProvenance self, IntsKey a0) -> IMP::Ints
15176  get_value(CombineProvenance self, StringKey a0) -> IMP::String
15177  get_value(CombineProvenance self, ParticleIndexKey a0) -> Particle
15178  get_value(CombineProvenance self, ObjectKey a0) -> Object
15179  get_value(CombineProvenance self, SparseFloatKey a0) -> IMP::Float
15180  get_value(CombineProvenance self, SparseIntKey a0) -> IMP::Int
15181  get_value(CombineProvenance self, SparseStringKey a0) -> IMP::String
15182  get_value(CombineProvenance self, SparseParticleIndexKey a0) -> ParticleIndex
15183  """
15184  return _IMP_core.CombineProvenance_get_value(self, *args)
15185 
15186  def set_value(self, *args):
15187  r"""
15188  set_value(CombineProvenance self, FloatKey a0, IMP::Float a1)
15189  set_value(CombineProvenance self, IntKey a0, IMP::Int a1)
15190  set_value(CombineProvenance self, FloatsKey a0, IMP::Floats a1)
15191  set_value(CombineProvenance self, IntsKey a0, IMP::Ints a1)
15192  set_value(CombineProvenance self, StringKey a0, IMP::String a1)
15193  set_value(CombineProvenance self, ParticleIndexKey a0, Particle a1)
15194  set_value(CombineProvenance self, ObjectKey a0, Object a1)
15195  set_value(CombineProvenance self, SparseFloatKey a0, IMP::Float a1)
15196  set_value(CombineProvenance self, SparseIntKey a0, IMP::Int a1)
15197  set_value(CombineProvenance self, SparseStringKey a0, IMP::String a1)
15198  set_value(CombineProvenance self, SparseParticleIndexKey a0, ParticleIndex a1)
15199  """
15200  return _IMP_core.CombineProvenance_set_value(self, *args)
15201 
15202  def remove_attribute(self, *args):
15203  r"""
15204  remove_attribute(CombineProvenance self, FloatKey a0)
15205  remove_attribute(CombineProvenance self, IntKey a0)
15206  remove_attribute(CombineProvenance self, FloatsKey a0)
15207  remove_attribute(CombineProvenance self, IntsKey a0)
15208  remove_attribute(CombineProvenance self, StringKey a0)
15209  remove_attribute(CombineProvenance self, ParticleIndexKey a0)
15210  remove_attribute(CombineProvenance self, ObjectKey a0)
15211  remove_attribute(CombineProvenance self, SparseFloatKey a0)
15212  remove_attribute(CombineProvenance self, SparseIntKey a0)
15213  remove_attribute(CombineProvenance self, SparseStringKey a0)
15214  remove_attribute(CombineProvenance self, SparseParticleIndexKey a0)
15215  """
15216  return _IMP_core.CombineProvenance_remove_attribute(self, *args)
15217 
15218  def has_attribute(self, *args):
15219  r"""
15220  has_attribute(CombineProvenance self, FloatKey a0) -> bool
15221  has_attribute(CombineProvenance self, IntKey a0) -> bool
15222  has_attribute(CombineProvenance self, FloatsKey a0) -> bool
15223  has_attribute(CombineProvenance self, IntsKey a0) -> bool
15224  has_attribute(CombineProvenance self, StringKey a0) -> bool
15225  has_attribute(CombineProvenance self, ParticleIndexKey a0) -> bool
15226  has_attribute(CombineProvenance self, ObjectKey a0) -> bool
15227  has_attribute(CombineProvenance self, SparseFloatKey a0) -> bool
15228  has_attribute(CombineProvenance self, SparseIntKey a0) -> bool
15229  has_attribute(CombineProvenance self, SparseStringKey a0) -> bool
15230  has_attribute(CombineProvenance self, SparseParticleIndexKey a0) -> bool
15231  """
15232  return _IMP_core.CombineProvenance_has_attribute(self, *args)
15233 
15234  def get_derivative(self, a0):
15235  r"""get_derivative(CombineProvenance self, FloatKey a0) -> double"""
15236  return _IMP_core.CombineProvenance_get_derivative(self, a0)
15237 
15238  def get_name(self):
15239  r"""get_name(CombineProvenance self) -> std::string"""
15240  return _IMP_core.CombineProvenance_get_name(self)
15241 
15242  def clear_caches(self):
15243  r"""clear_caches(CombineProvenance self)"""
15244  return _IMP_core.CombineProvenance_clear_caches(self)
15245 
15246  def set_name(self, a0):
15247  r"""set_name(CombineProvenance self, std::string a0)"""
15248  return _IMP_core.CombineProvenance_set_name(self, a0)
15249 
15250  def set_check_level(self, a0):
15251  r"""set_check_level(CombineProvenance self, IMP::CheckLevel a0)"""
15252  return _IMP_core.CombineProvenance_set_check_level(self, a0)
15253 
15254  def add_to_derivative(self, a0, a1, a2):
15255  r"""add_to_derivative(CombineProvenance self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
15256  return _IMP_core.CombineProvenance_add_to_derivative(self, a0, a1, a2)
15257 
15258  def set_is_optimized(self, a0, a1):
15259  r"""set_is_optimized(CombineProvenance self, FloatKey a0, bool a1)"""
15260  return _IMP_core.CombineProvenance_set_is_optimized(self, a0, a1)
15261 
15262  def get_is_optimized(self, a0):
15263  r"""get_is_optimized(CombineProvenance self, FloatKey a0) -> bool"""
15264  return _IMP_core.CombineProvenance_get_is_optimized(self, a0)
15265 
15266  def get_check_level(self):
15267  r"""get_check_level(CombineProvenance self) -> IMP::CheckLevel"""
15268  return _IMP_core.CombineProvenance_get_check_level(self)
15269 
15270  def __eq__(self, *args):
15271  r"""
15272  __eq__(CombineProvenance self, CombineProvenance o) -> bool
15273  __eq__(CombineProvenance self, Particle d) -> bool
15274  """
15275  return _IMP_core.CombineProvenance___eq__(self, *args)
15276 
15277  def __ne__(self, *args):
15278  r"""
15279  __ne__(CombineProvenance self, CombineProvenance o) -> bool
15280  __ne__(CombineProvenance self, Particle d) -> bool
15281  """
15282  return _IMP_core.CombineProvenance___ne__(self, *args)
15283 
15284  def __le__(self, *args):
15285  r"""
15286  __le__(CombineProvenance self, CombineProvenance o) -> bool
15287  __le__(CombineProvenance self, Particle d) -> bool
15288  """
15289  return _IMP_core.CombineProvenance___le__(self, *args)
15290 
15291  def __lt__(self, *args):
15292  r"""
15293  __lt__(CombineProvenance self, CombineProvenance o) -> bool
15294  __lt__(CombineProvenance self, Particle d) -> bool
15295  """
15296  return _IMP_core.CombineProvenance___lt__(self, *args)
15297 
15298  def __ge__(self, *args):
15299  r"""
15300  __ge__(CombineProvenance self, CombineProvenance o) -> bool
15301  __ge__(CombineProvenance self, Particle d) -> bool
15302  """
15303  return _IMP_core.CombineProvenance___ge__(self, *args)
15304 
15305  def __gt__(self, *args):
15306  r"""
15307  __gt__(CombineProvenance self, CombineProvenance o) -> bool
15308  __gt__(CombineProvenance self, Particle d) -> bool
15309  """
15310  return _IMP_core.CombineProvenance___gt__(self, *args)
15311 
15312  def __hash__(self):
15313  r"""__hash__(CombineProvenance self) -> std::size_t"""
15314  return _IMP_core.CombineProvenance___hash__(self)
15315 
15316  def __str__(self):
15317  r"""__str__(CombineProvenance self) -> std::string"""
15318  return _IMP_core.CombineProvenance___str__(self)
15319 
15320  def __repr__(self):
15321  r"""__repr__(CombineProvenance self) -> std::string"""
15322  return _IMP_core.CombineProvenance___repr__(self)
15323 
15324  def _get_as_binary(self):
15325  r"""_get_as_binary(CombineProvenance self) -> PyObject *"""
15326  return _IMP_core.CombineProvenance__get_as_binary(self)
15327 
15328  def _set_from_binary(self, p):
15329  r"""_set_from_binary(CombineProvenance self, PyObject * p)"""
15330  return _IMP_core.CombineProvenance__set_from_binary(self, p)
15331 
15332  def __getstate__(self):
15333  p = self._get_as_binary()
15334  if len(self.__dict__) > 1:
15335  d = self.__dict__.copy()
15336  del d['this']
15337  p = (d, p)
15338  return p
15339 
15340  def __setstate__(self, p):
15341  if not hasattr(self, 'this'):
15342  self.__init__()
15343  if isinstance(p, tuple):
15344  d, p = p
15345  self.__dict__.update(d)
15346  return self._set_from_binary(p)
15347 
15348  __swig_destroy__ = _IMP_core.delete_CombineProvenance
15349 
15350 # Register CombineProvenance in _IMP_core:
15351 _IMP_core.CombineProvenance_swigregister(CombineProvenance)
15352 class FilterProvenance(Provenance):
15353  r"""Proxy of C++ IMP::core::FilterProvenance class."""
15354 
15355  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
15356 
15357  def set_method(self, method):
15358  r"""set_method(FilterProvenance self, std::string method)"""
15359  return _IMP_core.FilterProvenance_set_method(self, method)
15360 
15361  def get_method(self):
15362  r"""get_method(FilterProvenance self) -> std::string"""
15363  return _IMP_core.FilterProvenance_get_method(self)
15364 
15365  def set_number_of_frames(self, frames):
15366  r"""set_number_of_frames(FilterProvenance self, int frames)"""
15367  return _IMP_core.FilterProvenance_set_number_of_frames(self, frames)
15368 
15369  def get_number_of_frames(self):
15370  r"""get_number_of_frames(FilterProvenance self) -> int"""
15371  return _IMP_core.FilterProvenance_get_number_of_frames(self)
15372 
15373  def set_threshold(self, threshold):
15374  r"""set_threshold(FilterProvenance self, double threshold)"""
15375  return _IMP_core.FilterProvenance_set_threshold(self, threshold)
15376 
15377  def get_threshold(self):
15378  r"""get_threshold(FilterProvenance self) -> double"""
15379  return _IMP_core.FilterProvenance_get_threshold(self)
15380 
15381  def __init__(self, *args):
15382  r"""
15383  __init__(FilterProvenance self) -> FilterProvenance
15384  __init__(FilterProvenance self, Model m, ParticleIndex id) -> FilterProvenance
15385  __init__(FilterProvenance self, _ParticleAdaptor d) -> FilterProvenance
15386  """
15387  _IMP_core.FilterProvenance_swiginit(self, _IMP_core.new_FilterProvenance(*args))
15388 
15389  @staticmethod
15390  def get_is_setup(*args):
15391  r"""
15392  get_is_setup(Model m, ParticleIndex pi) -> bool
15393  get_is_setup(_ParticleAdaptor p) -> bool
15394  """
15395  return _IMP_core.FilterProvenance_get_is_setup(*args)
15396 
15397  def show(self, *args):
15398  r"""show(FilterProvenance self, _ostream out=std::cout)"""
15399  return _IMP_core.FilterProvenance_show(self, *args)
15400 
15401  @staticmethod
15402  def setup_particle(*args):
15403  r"""
15404  setup_particle(Model m, ParticleIndex pi, std::string method, double threshold, int frames) -> FilterProvenance
15405  setup_particle(_ParticleAdaptor pa, std::string method, double threshold, int frames) -> FilterProvenance
15406  setup_particle(Model m, ParticleIndex pi, FilterProvenance o) -> FilterProvenance
15407  setup_particle(_ParticleAdaptor pa, FilterProvenance o) -> FilterProvenance
15408  """
15409  return _IMP_core.FilterProvenance_setup_particle(*args)
15410 
15411  def add_attribute(self, *args):
15412  r"""
15413  add_attribute(FilterProvenance self, FloatKey k, IMP::Float v, bool opt)
15414  add_attribute(FilterProvenance self, FloatKey a0, IMP::Float a1)
15415  add_attribute(FilterProvenance self, IntKey a0, IMP::Int a1)
15416  add_attribute(FilterProvenance self, FloatsKey a0, IMP::Floats a1)
15417  add_attribute(FilterProvenance self, IntsKey a0, IMP::Ints a1)
15418  add_attribute(FilterProvenance self, StringKey a0, IMP::String a1)
15419  add_attribute(FilterProvenance self, ParticleIndexKey a0, Particle a1)
15420  add_attribute(FilterProvenance self, ObjectKey a0, Object a1)
15421  add_attribute(FilterProvenance self, SparseFloatKey a0, IMP::Float a1)
15422  add_attribute(FilterProvenance self, SparseIntKey a0, IMP::Int a1)
15423  add_attribute(FilterProvenance self, SparseStringKey a0, IMP::String a1)
15424  add_attribute(FilterProvenance self, SparseParticleIndexKey a0, ParticleIndex a1)
15425  """
15426  return _IMP_core.FilterProvenance_add_attribute(self, *args)
15427 
15428  def get_value(self, *args):
15429  r"""
15430  get_value(FilterProvenance self, FloatKey a0) -> IMP::Float
15431  get_value(FilterProvenance self, IntKey a0) -> IMP::Int
15432  get_value(FilterProvenance self, FloatsKey a0) -> IMP::Floats
15433  get_value(FilterProvenance self, IntsKey a0) -> IMP::Ints
15434  get_value(FilterProvenance self, StringKey a0) -> IMP::String
15435  get_value(FilterProvenance self, ParticleIndexKey a0) -> Particle
15436  get_value(FilterProvenance self, ObjectKey a0) -> Object
15437  get_value(FilterProvenance self, SparseFloatKey a0) -> IMP::Float
15438  get_value(FilterProvenance self, SparseIntKey a0) -> IMP::Int
15439  get_value(FilterProvenance self, SparseStringKey a0) -> IMP::String
15440  get_value(FilterProvenance self, SparseParticleIndexKey a0) -> ParticleIndex
15441  """
15442  return _IMP_core.FilterProvenance_get_value(self, *args)
15443 
15444  def set_value(self, *args):
15445  r"""
15446  set_value(FilterProvenance self, FloatKey a0, IMP::Float a1)
15447  set_value(FilterProvenance self, IntKey a0, IMP::Int a1)
15448  set_value(FilterProvenance self, FloatsKey a0, IMP::Floats a1)
15449  set_value(FilterProvenance self, IntsKey a0, IMP::Ints a1)
15450  set_value(FilterProvenance self, StringKey a0, IMP::String a1)
15451  set_value(FilterProvenance self, ParticleIndexKey a0, Particle a1)
15452  set_value(FilterProvenance self, ObjectKey a0, Object a1)
15453  set_value(FilterProvenance self, SparseFloatKey a0, IMP::Float a1)
15454  set_value(FilterProvenance self, SparseIntKey a0, IMP::Int a1)
15455  set_value(FilterProvenance self, SparseStringKey a0, IMP::String a1)
15456  set_value(FilterProvenance self, SparseParticleIndexKey a0, ParticleIndex a1)
15457  """
15458  return _IMP_core.FilterProvenance_set_value(self, *args)
15459 
15460  def remove_attribute(self, *args):
15461  r"""
15462  remove_attribute(FilterProvenance self, FloatKey a0)
15463  remove_attribute(FilterProvenance self, IntKey a0)
15464  remove_attribute(FilterProvenance self, FloatsKey a0)
15465  remove_attribute(FilterProvenance self, IntsKey a0)
15466  remove_attribute(FilterProvenance self, StringKey a0)
15467  remove_attribute(FilterProvenance self, ParticleIndexKey a0)
15468  remove_attribute(FilterProvenance self, ObjectKey a0)
15469  remove_attribute(FilterProvenance self, SparseFloatKey a0)
15470  remove_attribute(FilterProvenance self, SparseIntKey a0)
15471  remove_attribute(FilterProvenance self, SparseStringKey a0)
15472  remove_attribute(FilterProvenance self, SparseParticleIndexKey a0)
15473  """
15474  return _IMP_core.FilterProvenance_remove_attribute(self, *args)
15475 
15476  def has_attribute(self, *args):
15477  r"""
15478  has_attribute(FilterProvenance self, FloatKey a0) -> bool
15479  has_attribute(FilterProvenance self, IntKey a0) -> bool
15480  has_attribute(FilterProvenance self, FloatsKey a0) -> bool
15481  has_attribute(FilterProvenance self, IntsKey a0) -> bool
15482  has_attribute(FilterProvenance self, StringKey a0) -> bool
15483  has_attribute(FilterProvenance self, ParticleIndexKey a0) -> bool
15484  has_attribute(FilterProvenance self, ObjectKey a0) -> bool
15485  has_attribute(FilterProvenance self, SparseFloatKey a0) -> bool
15486  has_attribute(FilterProvenance self, SparseIntKey a0) -> bool
15487  has_attribute(FilterProvenance self, SparseStringKey a0) -> bool
15488  has_attribute(FilterProvenance self, SparseParticleIndexKey a0) -> bool
15489  """
15490  return _IMP_core.FilterProvenance_has_attribute(self, *args)
15491 
15492  def get_derivative(self, a0):
15493  r"""get_derivative(FilterProvenance self, FloatKey a0) -> double"""
15494  return _IMP_core.FilterProvenance_get_derivative(self, a0)
15495 
15496  def get_name(self):
15497  r"""get_name(FilterProvenance self) -> std::string"""
15498  return _IMP_core.FilterProvenance_get_name(self)
15499 
15500  def clear_caches(self):
15501  r"""clear_caches(FilterProvenance self)"""
15502  return _IMP_core.FilterProvenance_clear_caches(self)
15503 
15504  def set_name(self, a0):
15505  r"""set_name(FilterProvenance self, std::string a0)"""
15506  return _IMP_core.FilterProvenance_set_name(self, a0)
15507 
15508  def set_check_level(self, a0):
15509  r"""set_check_level(FilterProvenance self, IMP::CheckLevel a0)"""
15510  return _IMP_core.FilterProvenance_set_check_level(self, a0)
15511 
15512  def add_to_derivative(self, a0, a1, a2):
15513  r"""add_to_derivative(FilterProvenance self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
15514  return _IMP_core.FilterProvenance_add_to_derivative(self, a0, a1, a2)
15515 
15516  def set_is_optimized(self, a0, a1):
15517  r"""set_is_optimized(FilterProvenance self, FloatKey a0, bool a1)"""
15518  return _IMP_core.FilterProvenance_set_is_optimized(self, a0, a1)
15519 
15520  def get_is_optimized(self, a0):
15521  r"""get_is_optimized(FilterProvenance self, FloatKey a0) -> bool"""
15522  return _IMP_core.FilterProvenance_get_is_optimized(self, a0)
15523 
15524  def get_check_level(self):
15525  r"""get_check_level(FilterProvenance self) -> IMP::CheckLevel"""
15526  return _IMP_core.FilterProvenance_get_check_level(self)
15527 
15528  def __eq__(self, *args):
15529  r"""
15530  __eq__(FilterProvenance self, FilterProvenance o) -> bool
15531  __eq__(FilterProvenance self, Particle d) -> bool
15532  """
15533  return _IMP_core.FilterProvenance___eq__(self, *args)
15534 
15535  def __ne__(self, *args):
15536  r"""
15537  __ne__(FilterProvenance self, FilterProvenance o) -> bool
15538  __ne__(FilterProvenance self, Particle d) -> bool
15539  """
15540  return _IMP_core.FilterProvenance___ne__(self, *args)
15541 
15542  def __le__(self, *args):
15543  r"""
15544  __le__(FilterProvenance self, FilterProvenance o) -> bool
15545  __le__(FilterProvenance self, Particle d) -> bool
15546  """
15547  return _IMP_core.FilterProvenance___le__(self, *args)
15548 
15549  def __lt__(self, *args):
15550  r"""
15551  __lt__(FilterProvenance self, FilterProvenance o) -> bool
15552  __lt__(FilterProvenance self, Particle d) -> bool
15553  """
15554  return _IMP_core.FilterProvenance___lt__(self, *args)
15555 
15556  def __ge__(self, *args):
15557  r"""
15558  __ge__(FilterProvenance self, FilterProvenance o) -> bool
15559  __ge__(FilterProvenance self, Particle d) -> bool
15560  """
15561  return _IMP_core.FilterProvenance___ge__(self, *args)
15562 
15563  def __gt__(self, *args):
15564  r"""
15565  __gt__(FilterProvenance self, FilterProvenance o) -> bool
15566  __gt__(FilterProvenance self, Particle d) -> bool
15567  """
15568  return _IMP_core.FilterProvenance___gt__(self, *args)
15569 
15570  def __hash__(self):
15571  r"""__hash__(FilterProvenance self) -> std::size_t"""
15572  return _IMP_core.FilterProvenance___hash__(self)
15573 
15574  def __str__(self):
15575  r"""__str__(FilterProvenance self) -> std::string"""
15576  return _IMP_core.FilterProvenance___str__(self)
15577 
15578  def __repr__(self):
15579  r"""__repr__(FilterProvenance self) -> std::string"""
15580  return _IMP_core.FilterProvenance___repr__(self)
15581 
15582  def _get_as_binary(self):
15583  r"""_get_as_binary(FilterProvenance self) -> PyObject *"""
15584  return _IMP_core.FilterProvenance__get_as_binary(self)
15585 
15586  def _set_from_binary(self, p):
15587  r"""_set_from_binary(FilterProvenance self, PyObject * p)"""
15588  return _IMP_core.FilterProvenance__set_from_binary(self, p)
15589 
15590  def __getstate__(self):
15591  p = self._get_as_binary()
15592  if len(self.__dict__) > 1:
15593  d = self.__dict__.copy()
15594  del d['this']
15595  p = (d, p)
15596  return p
15597 
15598  def __setstate__(self, p):
15599  if not hasattr(self, 'this'):
15600  self.__init__()
15601  if isinstance(p, tuple):
15602  d, p = p
15603  self.__dict__.update(d)
15604  return self._set_from_binary(p)
15605 
15606  __swig_destroy__ = _IMP_core.delete_FilterProvenance
15607 
15608 # Register FilterProvenance in _IMP_core:
15609 _IMP_core.FilterProvenance_swigregister(FilterProvenance)
15610 class ClusterProvenance(Provenance):
15611  r"""Proxy of C++ IMP::core::ClusterProvenance class."""
15612 
15613  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
15614 
15615  def set_number_of_members(self, members):
15616  r"""set_number_of_members(ClusterProvenance self, int members)"""
15617  return _IMP_core.ClusterProvenance_set_number_of_members(self, members)
15618 
15619  def get_number_of_members(self):
15620  r"""get_number_of_members(ClusterProvenance self) -> int"""
15621  return _IMP_core.ClusterProvenance_get_number_of_members(self)
15622 
15623  def set_precision(self, precision):
15624  r"""set_precision(ClusterProvenance self, double precision)"""
15625  return _IMP_core.ClusterProvenance_set_precision(self, precision)
15626 
15627  def get_precision(self):
15628  r"""get_precision(ClusterProvenance self) -> double"""
15629  return _IMP_core.ClusterProvenance_get_precision(self)
15630 
15631  def set_density(self, density):
15632  r"""set_density(ClusterProvenance self, std::string density)"""
15633  return _IMP_core.ClusterProvenance_set_density(self, density)
15634 
15635  def get_density(self):
15636  r"""get_density(ClusterProvenance self) -> std::string"""
15637  return _IMP_core.ClusterProvenance_get_density(self)
15638 
15639  def __init__(self, *args):
15640  r"""
15641  __init__(ClusterProvenance self) -> ClusterProvenance
15642  __init__(ClusterProvenance self, Model m, ParticleIndex id) -> ClusterProvenance
15643  __init__(ClusterProvenance self, _ParticleAdaptor d) -> ClusterProvenance
15644  """
15645  _IMP_core.ClusterProvenance_swiginit(self, _IMP_core.new_ClusterProvenance(*args))
15646 
15647  @staticmethod
15648  def get_is_setup(*args):
15649  r"""
15650  get_is_setup(Model m, ParticleIndex pi) -> bool
15651  get_is_setup(_ParticleAdaptor p) -> bool
15652  """
15653  return _IMP_core.ClusterProvenance_get_is_setup(*args)
15654 
15655  def show(self, *args):
15656  r"""show(ClusterProvenance self, _ostream out=std::cout)"""
15657  return _IMP_core.ClusterProvenance_show(self, *args)
15658 
15659  @staticmethod
15660  def setup_particle(*args):
15661  r"""
15662  setup_particle(Model m, ParticleIndex pi, int members) -> ClusterProvenance
15663  setup_particle(_ParticleAdaptor pa, int members) -> ClusterProvenance
15664  setup_particle(Model m, ParticleIndex pi, int members, double precision) -> ClusterProvenance
15665  setup_particle(_ParticleAdaptor pa, int members, double precision) -> ClusterProvenance
15666  setup_particle(Model m, ParticleIndex pi, int members, double precision, std::string density) -> ClusterProvenance
15667  setup_particle(_ParticleAdaptor pa, int members, double precision, std::string density) -> ClusterProvenance
15668  setup_particle(Model m, ParticleIndex pi, ClusterProvenance o) -> ClusterProvenance
15669  setup_particle(_ParticleAdaptor pa, ClusterProvenance o) -> ClusterProvenance
15670  """
15671  return _IMP_core.ClusterProvenance_setup_particle(*args)
15672 
15673  def add_attribute(self, *args):
15674  r"""
15675  add_attribute(ClusterProvenance self, FloatKey k, IMP::Float v, bool opt)
15676  add_attribute(ClusterProvenance self, FloatKey a0, IMP::Float a1)
15677  add_attribute(ClusterProvenance self, IntKey a0, IMP::Int a1)
15678  add_attribute(ClusterProvenance self, FloatsKey a0, IMP::Floats a1)
15679  add_attribute(ClusterProvenance self, IntsKey a0, IMP::Ints a1)
15680  add_attribute(ClusterProvenance self, StringKey a0, IMP::String a1)
15681  add_attribute(ClusterProvenance self, ParticleIndexKey a0, Particle a1)
15682  add_attribute(ClusterProvenance self, ObjectKey a0, Object a1)
15683  add_attribute(ClusterProvenance self, SparseFloatKey a0, IMP::Float a1)
15684  add_attribute(ClusterProvenance self, SparseIntKey a0, IMP::Int a1)
15685  add_attribute(ClusterProvenance self, SparseStringKey a0, IMP::String a1)
15686  add_attribute(ClusterProvenance self, SparseParticleIndexKey a0, ParticleIndex a1)
15687  """
15688  return _IMP_core.ClusterProvenance_add_attribute(self, *args)
15689 
15690  def get_value(self, *args):
15691  r"""
15692  get_value(ClusterProvenance self, FloatKey a0) -> IMP::Float
15693  get_value(ClusterProvenance self, IntKey a0) -> IMP::Int
15694  get_value(ClusterProvenance self, FloatsKey a0) -> IMP::Floats
15695  get_value(ClusterProvenance self, IntsKey a0) -> IMP::Ints
15696  get_value(ClusterProvenance self, StringKey a0) -> IMP::String
15697  get_value(ClusterProvenance self, ParticleIndexKey a0) -> Particle
15698  get_value(ClusterProvenance self, ObjectKey a0) -> Object
15699  get_value(ClusterProvenance self, SparseFloatKey a0) -> IMP::Float
15700  get_value(ClusterProvenance self, SparseIntKey a0) -> IMP::Int
15701  get_value(ClusterProvenance self, SparseStringKey a0) -> IMP::String
15702  get_value(ClusterProvenance self, SparseParticleIndexKey a0) -> ParticleIndex
15703  """
15704  return _IMP_core.ClusterProvenance_get_value(self, *args)
15705 
15706  def set_value(self, *args):
15707  r"""
15708  set_value(ClusterProvenance self, FloatKey a0, IMP::Float a1)
15709  set_value(ClusterProvenance self, IntKey a0, IMP::Int a1)
15710  set_value(ClusterProvenance self, FloatsKey a0, IMP::Floats a1)
15711  set_value(ClusterProvenance self, IntsKey a0, IMP::Ints a1)
15712  set_value(ClusterProvenance self, StringKey a0, IMP::String a1)
15713  set_value(ClusterProvenance self, ParticleIndexKey a0, Particle a1)
15714  set_value(ClusterProvenance self, ObjectKey a0, Object a1)
15715  set_value(ClusterProvenance self, SparseFloatKey a0, IMP::Float a1)
15716  set_value(ClusterProvenance self, SparseIntKey a0, IMP::Int a1)
15717  set_value(ClusterProvenance self, SparseStringKey a0, IMP::String a1)
15718  set_value(ClusterProvenance self, SparseParticleIndexKey a0, ParticleIndex a1)
15719  """
15720  return _IMP_core.ClusterProvenance_set_value(self, *args)
15721 
15722  def remove_attribute(self, *args):
15723  r"""
15724  remove_attribute(ClusterProvenance self, FloatKey a0)
15725  remove_attribute(ClusterProvenance self, IntKey a0)
15726  remove_attribute(ClusterProvenance self, FloatsKey a0)
15727  remove_attribute(ClusterProvenance self, IntsKey a0)
15728  remove_attribute(ClusterProvenance self, StringKey a0)
15729  remove_attribute(ClusterProvenance self, ParticleIndexKey a0)
15730  remove_attribute(ClusterProvenance self, ObjectKey a0)
15731  remove_attribute(ClusterProvenance self, SparseFloatKey a0)
15732  remove_attribute(ClusterProvenance self, SparseIntKey a0)
15733  remove_attribute(ClusterProvenance self, SparseStringKey a0)
15734  remove_attribute(ClusterProvenance self, SparseParticleIndexKey a0)
15735  """
15736  return _IMP_core.ClusterProvenance_remove_attribute(self, *args)
15737 
15738  def has_attribute(self, *args):
15739  r"""
15740  has_attribute(ClusterProvenance self, FloatKey a0) -> bool
15741  has_attribute(ClusterProvenance self, IntKey a0) -> bool
15742  has_attribute(ClusterProvenance self, FloatsKey a0) -> bool
15743  has_attribute(ClusterProvenance self, IntsKey a0) -> bool
15744  has_attribute(ClusterProvenance self, StringKey a0) -> bool
15745  has_attribute(ClusterProvenance self, ParticleIndexKey a0) -> bool
15746  has_attribute(ClusterProvenance self, ObjectKey a0) -> bool
15747  has_attribute(ClusterProvenance self, SparseFloatKey a0) -> bool
15748  has_attribute(ClusterProvenance self, SparseIntKey a0) -> bool
15749  has_attribute(ClusterProvenance self, SparseStringKey a0) -> bool
15750  has_attribute(ClusterProvenance self, SparseParticleIndexKey a0) -> bool
15751  """
15752  return _IMP_core.ClusterProvenance_has_attribute(self, *args)
15753 
15754  def get_derivative(self, a0):
15755  r"""get_derivative(ClusterProvenance self, FloatKey a0) -> double"""
15756  return _IMP_core.ClusterProvenance_get_derivative(self, a0)
15757 
15758  def get_name(self):
15759  r"""get_name(ClusterProvenance self) -> std::string"""
15760  return _IMP_core.ClusterProvenance_get_name(self)
15761 
15762  def clear_caches(self):
15763  r"""clear_caches(ClusterProvenance self)"""
15764  return _IMP_core.ClusterProvenance_clear_caches(self)
15765 
15766  def set_name(self, a0):
15767  r"""set_name(ClusterProvenance self, std::string a0)"""
15768  return _IMP_core.ClusterProvenance_set_name(self, a0)
15769 
15770  def set_check_level(self, a0):
15771  r"""set_check_level(ClusterProvenance self, IMP::CheckLevel a0)"""
15772  return _IMP_core.ClusterProvenance_set_check_level(self, a0)
15773 
15774  def add_to_derivative(self, a0, a1, a2):
15775  r"""add_to_derivative(ClusterProvenance self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
15776  return _IMP_core.ClusterProvenance_add_to_derivative(self, a0, a1, a2)
15777 
15778  def set_is_optimized(self, a0, a1):
15779  r"""set_is_optimized(ClusterProvenance self, FloatKey a0, bool a1)"""
15780  return _IMP_core.ClusterProvenance_set_is_optimized(self, a0, a1)
15781 
15782  def get_is_optimized(self, a0):
15783  r"""get_is_optimized(ClusterProvenance self, FloatKey a0) -> bool"""
15784  return _IMP_core.ClusterProvenance_get_is_optimized(self, a0)
15785 
15786  def get_check_level(self):
15787  r"""get_check_level(ClusterProvenance self) -> IMP::CheckLevel"""
15788  return _IMP_core.ClusterProvenance_get_check_level(self)
15789 
15790  def __eq__(self, *args):
15791  r"""
15792  __eq__(ClusterProvenance self, ClusterProvenance o) -> bool
15793  __eq__(ClusterProvenance self, Particle d) -> bool
15794  """
15795  return _IMP_core.ClusterProvenance___eq__(self, *args)
15796 
15797  def __ne__(self, *args):
15798  r"""
15799  __ne__(ClusterProvenance self, ClusterProvenance o) -> bool
15800  __ne__(ClusterProvenance self, Particle d) -> bool
15801  """
15802  return _IMP_core.ClusterProvenance___ne__(self, *args)
15803 
15804  def __le__(self, *args):
15805  r"""
15806  __le__(ClusterProvenance self, ClusterProvenance o) -> bool
15807  __le__(ClusterProvenance self, Particle d) -> bool
15808  """
15809  return _IMP_core.ClusterProvenance___le__(self, *args)
15810 
15811  def __lt__(self, *args):
15812  r"""
15813  __lt__(ClusterProvenance self, ClusterProvenance o) -> bool
15814  __lt__(ClusterProvenance self, Particle d) -> bool
15815  """
15816  return _IMP_core.ClusterProvenance___lt__(self, *args)
15817 
15818  def __ge__(self, *args):
15819  r"""
15820  __ge__(ClusterProvenance self, ClusterProvenance o) -> bool
15821  __ge__(ClusterProvenance self, Particle d) -> bool
15822  """
15823  return _IMP_core.ClusterProvenance___ge__(self, *args)
15824 
15825  def __gt__(self, *args):
15826  r"""
15827  __gt__(ClusterProvenance self, ClusterProvenance o) -> bool
15828  __gt__(ClusterProvenance self, Particle d) -> bool
15829  """
15830  return _IMP_core.ClusterProvenance___gt__(self, *args)
15831 
15832  def __hash__(self):
15833  r"""__hash__(ClusterProvenance self) -> std::size_t"""
15834  return _IMP_core.ClusterProvenance___hash__(self)
15835 
15836  def __str__(self):
15837  r"""__str__(ClusterProvenance self) -> std::string"""
15838  return _IMP_core.ClusterProvenance___str__(self)
15839 
15840  def __repr__(self):
15841  r"""__repr__(ClusterProvenance self) -> std::string"""
15842  return _IMP_core.ClusterProvenance___repr__(self)
15843 
15844  def _get_as_binary(self):
15845  r"""_get_as_binary(ClusterProvenance self) -> PyObject *"""
15846  return _IMP_core.ClusterProvenance__get_as_binary(self)
15847 
15848  def _set_from_binary(self, p):
15849  r"""_set_from_binary(ClusterProvenance self, PyObject * p)"""
15850  return _IMP_core.ClusterProvenance__set_from_binary(self, p)
15851 
15852  def __getstate__(self):
15853  p = self._get_as_binary()
15854  if len(self.__dict__) > 1:
15855  d = self.__dict__.copy()
15856  del d['this']
15857  p = (d, p)
15858  return p
15859 
15860  def __setstate__(self, p):
15861  if not hasattr(self, 'this'):
15862  self.__init__()
15863  if isinstance(p, tuple):
15864  d, p = p
15865  self.__dict__.update(d)
15866  return self._set_from_binary(p)
15867 
15868  __swig_destroy__ = _IMP_core.delete_ClusterProvenance
15869 
15870 # Register ClusterProvenance in _IMP_core:
15871 _IMP_core.ClusterProvenance_swigregister(ClusterProvenance)
15872 class ScriptProvenance(Provenance):
15873  r"""Proxy of C++ IMP::core::ScriptProvenance class."""
15874 
15875  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
15876 
15877  def set_filename(self, filename):
15878  r"""set_filename(ScriptProvenance self, std::string filename)"""
15879  return _IMP_core.ScriptProvenance_set_filename(self, filename)
15880 
15881  def get_filename(self):
15882  r"""get_filename(ScriptProvenance self) -> std::string"""
15883  return _IMP_core.ScriptProvenance_get_filename(self)
15884 
15885  def __init__(self, *args):
15886  r"""
15887  __init__(ScriptProvenance self) -> ScriptProvenance
15888  __init__(ScriptProvenance self, Model m, ParticleIndex id) -> ScriptProvenance
15889  __init__(ScriptProvenance self, _ParticleAdaptor d) -> ScriptProvenance
15890  """
15891  _IMP_core.ScriptProvenance_swiginit(self, _IMP_core.new_ScriptProvenance(*args))
15892 
15893  @staticmethod
15894  def get_is_setup(*args):
15895  r"""
15896  get_is_setup(Model m, ParticleIndex pi) -> bool
15897  get_is_setup(_ParticleAdaptor p) -> bool
15898  """
15899  return _IMP_core.ScriptProvenance_get_is_setup(*args)
15900 
15901  def show(self, *args):
15902  r"""show(ScriptProvenance self, _ostream out=std::cout)"""
15903  return _IMP_core.ScriptProvenance_show(self, *args)
15904 
15905  @staticmethod
15906  def setup_particle(*args):
15907  r"""
15908  setup_particle(Model m, ParticleIndex pi, std::string filename) -> ScriptProvenance
15909  setup_particle(_ParticleAdaptor pa, std::string filename) -> ScriptProvenance
15910  setup_particle(Model m, ParticleIndex pi, ScriptProvenance o) -> ScriptProvenance
15911  setup_particle(_ParticleAdaptor pa, ScriptProvenance o) -> ScriptProvenance
15912  """
15913  return _IMP_core.ScriptProvenance_setup_particle(*args)
15914 
15915  def add_attribute(self, *args):
15916  r"""
15917  add_attribute(ScriptProvenance self, FloatKey k, IMP::Float v, bool opt)
15918  add_attribute(ScriptProvenance self, FloatKey a0, IMP::Float a1)
15919  add_attribute(ScriptProvenance self, IntKey a0, IMP::Int a1)
15920  add_attribute(ScriptProvenance self, FloatsKey a0, IMP::Floats a1)
15921  add_attribute(ScriptProvenance self, IntsKey a0, IMP::Ints a1)
15922  add_attribute(ScriptProvenance self, StringKey a0, IMP::String a1)
15923  add_attribute(ScriptProvenance self, ParticleIndexKey a0, Particle a1)
15924  add_attribute(ScriptProvenance self, ObjectKey a0, Object a1)
15925  add_attribute(ScriptProvenance self, SparseFloatKey a0, IMP::Float a1)
15926  add_attribute(ScriptProvenance self, SparseIntKey a0, IMP::Int a1)
15927  add_attribute(ScriptProvenance self, SparseStringKey a0, IMP::String a1)
15928  add_attribute(ScriptProvenance self, SparseParticleIndexKey a0, ParticleIndex a1)
15929  """
15930  return _IMP_core.ScriptProvenance_add_attribute(self, *args)
15931 
15932  def get_value(self, *args):
15933  r"""
15934  get_value(ScriptProvenance self, FloatKey a0) -> IMP::Float
15935  get_value(ScriptProvenance self, IntKey a0) -> IMP::Int
15936  get_value(ScriptProvenance self, FloatsKey a0) -> IMP::Floats
15937  get_value(ScriptProvenance self, IntsKey a0) -> IMP::Ints
15938  get_value(ScriptProvenance self, StringKey a0) -> IMP::String
15939  get_value(ScriptProvenance self, ParticleIndexKey a0) -> Particle
15940  get_value(ScriptProvenance self, ObjectKey a0) -> Object
15941  get_value(ScriptProvenance self, SparseFloatKey a0) -> IMP::Float
15942  get_value(ScriptProvenance self, SparseIntKey a0) -> IMP::Int
15943  get_value(ScriptProvenance self, SparseStringKey a0) -> IMP::String
15944  get_value(ScriptProvenance self, SparseParticleIndexKey a0) -> ParticleIndex
15945  """
15946  return _IMP_core.ScriptProvenance_get_value(self, *args)
15947 
15948  def set_value(self, *args):
15949  r"""
15950  set_value(ScriptProvenance self, FloatKey a0, IMP::Float a1)
15951  set_value(ScriptProvenance self, IntKey a0, IMP::Int a1)
15952  set_value(ScriptProvenance self, FloatsKey a0, IMP::Floats a1)
15953  set_value(ScriptProvenance self, IntsKey a0, IMP::Ints a1)
15954  set_value(ScriptProvenance self, StringKey a0, IMP::String a1)
15955  set_value(ScriptProvenance self, ParticleIndexKey a0, Particle a1)
15956  set_value(ScriptProvenance self, ObjectKey a0, Object a1)
15957  set_value(ScriptProvenance self, SparseFloatKey a0, IMP::Float a1)
15958  set_value(ScriptProvenance self, SparseIntKey a0, IMP::Int a1)
15959  set_value(ScriptProvenance self, SparseStringKey a0, IMP::String a1)
15960  set_value(ScriptProvenance self, SparseParticleIndexKey a0, ParticleIndex a1)
15961  """
15962  return _IMP_core.ScriptProvenance_set_value(self, *args)
15963 
15964  def remove_attribute(self, *args):
15965  r"""
15966  remove_attribute(ScriptProvenance self, FloatKey a0)
15967  remove_attribute(ScriptProvenance self, IntKey a0)
15968  remove_attribute(ScriptProvenance self, FloatsKey a0)
15969  remove_attribute(ScriptProvenance self, IntsKey a0)
15970  remove_attribute(ScriptProvenance self, StringKey a0)
15971  remove_attribute(ScriptProvenance self, ParticleIndexKey a0)
15972  remove_attribute(ScriptProvenance self, ObjectKey a0)
15973  remove_attribute(ScriptProvenance self, SparseFloatKey a0)
15974  remove_attribute(ScriptProvenance self, SparseIntKey a0)
15975  remove_attribute(ScriptProvenance self, SparseStringKey a0)
15976  remove_attribute(ScriptProvenance self, SparseParticleIndexKey a0)
15977  """
15978  return _IMP_core.ScriptProvenance_remove_attribute(self, *args)
15979 
15980  def has_attribute(self, *args):
15981  r"""
15982  has_attribute(ScriptProvenance self, FloatKey a0) -> bool
15983  has_attribute(ScriptProvenance self, IntKey a0) -> bool
15984  has_attribute(ScriptProvenance self, FloatsKey a0) -> bool
15985  has_attribute(ScriptProvenance self, IntsKey a0) -> bool
15986  has_attribute(ScriptProvenance self, StringKey a0) -> bool
15987  has_attribute(ScriptProvenance self, ParticleIndexKey a0) -> bool
15988  has_attribute(ScriptProvenance self, ObjectKey a0) -> bool
15989  has_attribute(ScriptProvenance self, SparseFloatKey a0) -> bool
15990  has_attribute(ScriptProvenance self, SparseIntKey a0) -> bool
15991  has_attribute(ScriptProvenance self, SparseStringKey a0) -> bool
15992  has_attribute(ScriptProvenance self, SparseParticleIndexKey a0) -> bool
15993  """
15994  return _IMP_core.ScriptProvenance_has_attribute(self, *args)
15995 
15996  def get_derivative(self, a0):
15997  r"""get_derivative(ScriptProvenance self, FloatKey a0) -> double"""
15998  return _IMP_core.ScriptProvenance_get_derivative(self, a0)
15999 
16000  def get_name(self):
16001  r"""get_name(ScriptProvenance self) -> std::string"""
16002  return _IMP_core.ScriptProvenance_get_name(self)
16003 
16004  def clear_caches(self):
16005  r"""clear_caches(ScriptProvenance self)"""
16006  return _IMP_core.ScriptProvenance_clear_caches(self)
16007 
16008  def set_name(self, a0):
16009  r"""set_name(ScriptProvenance self, std::string a0)"""
16010  return _IMP_core.ScriptProvenance_set_name(self, a0)
16011 
16012  def set_check_level(self, a0):
16013  r"""set_check_level(ScriptProvenance self, IMP::CheckLevel a0)"""
16014  return _IMP_core.ScriptProvenance_set_check_level(self, a0)
16015 
16016  def add_to_derivative(self, a0, a1, a2):
16017  r"""add_to_derivative(ScriptProvenance self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
16018  return _IMP_core.ScriptProvenance_add_to_derivative(self, a0, a1, a2)
16019 
16020  def set_is_optimized(self, a0, a1):
16021  r"""set_is_optimized(ScriptProvenance self, FloatKey a0, bool a1)"""
16022  return _IMP_core.ScriptProvenance_set_is_optimized(self, a0, a1)
16023 
16024  def get_is_optimized(self, a0):
16025  r"""get_is_optimized(ScriptProvenance self, FloatKey a0) -> bool"""
16026  return _IMP_core.ScriptProvenance_get_is_optimized(self, a0)
16027 
16028  def get_check_level(self):
16029  r"""get_check_level(ScriptProvenance self) -> IMP::CheckLevel"""
16030  return _IMP_core.ScriptProvenance_get_check_level(self)
16031 
16032  def __eq__(self, *args):
16033  r"""
16034  __eq__(ScriptProvenance self, ScriptProvenance o) -> bool
16035  __eq__(ScriptProvenance self, Particle d) -> bool
16036  """
16037  return _IMP_core.ScriptProvenance___eq__(self, *args)
16038 
16039  def __ne__(self, *args):
16040  r"""
16041  __ne__(ScriptProvenance self, ScriptProvenance o) -> bool
16042  __ne__(ScriptProvenance self, Particle d) -> bool
16043  """
16044  return _IMP_core.ScriptProvenance___ne__(self, *args)
16045 
16046  def __le__(self, *args):
16047  r"""
16048  __le__(ScriptProvenance self, ScriptProvenance o) -> bool
16049  __le__(ScriptProvenance self, Particle d) -> bool
16050  """
16051  return _IMP_core.ScriptProvenance___le__(self, *args)
16052 
16053  def __lt__(self, *args):
16054  r"""
16055  __lt__(ScriptProvenance self, ScriptProvenance o) -> bool
16056  __lt__(ScriptProvenance self, Particle d) -> bool
16057  """
16058  return _IMP_core.ScriptProvenance___lt__(self, *args)
16059 
16060  def __ge__(self, *args):
16061  r"""
16062  __ge__(ScriptProvenance self, ScriptProvenance o) -> bool
16063  __ge__(ScriptProvenance self, Particle d) -> bool
16064  """
16065  return _IMP_core.ScriptProvenance___ge__(self, *args)
16066 
16067  def __gt__(self, *args):
16068  r"""
16069  __gt__(ScriptProvenance self, ScriptProvenance o) -> bool
16070  __gt__(ScriptProvenance self, Particle d) -> bool
16071  """
16072  return _IMP_core.ScriptProvenance___gt__(self, *args)
16073 
16074  def __hash__(self):
16075  r"""__hash__(ScriptProvenance self) -> std::size_t"""
16076  return _IMP_core.ScriptProvenance___hash__(self)
16077 
16078  def __str__(self):
16079  r"""__str__(ScriptProvenance self) -> std::string"""
16080  return _IMP_core.ScriptProvenance___str__(self)
16081 
16082  def __repr__(self):
16083  r"""__repr__(ScriptProvenance self) -> std::string"""
16084  return _IMP_core.ScriptProvenance___repr__(self)
16085 
16086  def _get_as_binary(self):
16087  r"""_get_as_binary(ScriptProvenance self) -> PyObject *"""
16088  return _IMP_core.ScriptProvenance__get_as_binary(self)
16089 
16090  def _set_from_binary(self, p):
16091  r"""_set_from_binary(ScriptProvenance self, PyObject * p)"""
16092  return _IMP_core.ScriptProvenance__set_from_binary(self, p)
16093 
16094  def __getstate__(self):
16095  p = self._get_as_binary()
16096  if len(self.__dict__) > 1:
16097  d = self.__dict__.copy()
16098  del d['this']
16099  p = (d, p)
16100  return p
16101 
16102  def __setstate__(self, p):
16103  if not hasattr(self, 'this'):
16104  self.__init__()
16105  if isinstance(p, tuple):
16106  d, p = p
16107  self.__dict__.update(d)
16108  return self._set_from_binary(p)
16109 
16110  __swig_destroy__ = _IMP_core.delete_ScriptProvenance
16111 
16112 # Register ScriptProvenance in _IMP_core:
16113 _IMP_core.ScriptProvenance_swigregister(ScriptProvenance)
16114 class SoftwareProvenance(Provenance):
16115  r"""Proxy of C++ IMP::core::SoftwareProvenance class."""
16116 
16117  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
16118 
16119  def set_software_name(self, name):
16120  r"""set_software_name(SoftwareProvenance self, std::string name)"""
16121  return _IMP_core.SoftwareProvenance_set_software_name(self, name)
16122 
16123  def get_software_name(self):
16124  r"""get_software_name(SoftwareProvenance self) -> std::string"""
16125  return _IMP_core.SoftwareProvenance_get_software_name(self)
16126 
16127  def set_version(self, version):
16128  r"""set_version(SoftwareProvenance self, std::string version)"""
16129  return _IMP_core.SoftwareProvenance_set_version(self, version)
16130 
16131  def get_version(self):
16132  r"""get_version(SoftwareProvenance self) -> std::string"""
16133  return _IMP_core.SoftwareProvenance_get_version(self)
16134 
16135  def set_location(self, location):
16136  r"""set_location(SoftwareProvenance self, std::string location)"""
16137  return _IMP_core.SoftwareProvenance_set_location(self, location)
16138 
16139  def get_location(self):
16140  r"""get_location(SoftwareProvenance self) -> std::string"""
16141  return _IMP_core.SoftwareProvenance_get_location(self)
16142 
16143  def __init__(self, *args):
16144  r"""
16145  __init__(SoftwareProvenance self) -> SoftwareProvenance
16146  __init__(SoftwareProvenance self, Model m, ParticleIndex id) -> SoftwareProvenance
16147  __init__(SoftwareProvenance self, _ParticleAdaptor d) -> SoftwareProvenance
16148  """
16149  _IMP_core.SoftwareProvenance_swiginit(self, _IMP_core.new_SoftwareProvenance(*args))
16150 
16151  @staticmethod
16152  def get_is_setup(*args):
16153  r"""
16154  get_is_setup(Model m, ParticleIndex pi) -> bool
16155  get_is_setup(_ParticleAdaptor p) -> bool
16156  """
16157  return _IMP_core.SoftwareProvenance_get_is_setup(*args)
16158 
16159  def show(self, *args):
16160  r"""show(SoftwareProvenance self, _ostream out=std::cout)"""
16161  return _IMP_core.SoftwareProvenance_show(self, *args)
16162 
16163  @staticmethod
16164  def setup_particle(*args):
16165  r"""
16166  setup_particle(Model m, ParticleIndex pi, std::string name, std::string version, std::string location) -> SoftwareProvenance
16167  setup_particle(_ParticleAdaptor pa, std::string name, std::string version, std::string location) -> SoftwareProvenance
16168  setup_particle(Model m, ParticleIndex pi, SoftwareProvenance o) -> SoftwareProvenance
16169  setup_particle(_ParticleAdaptor pa, SoftwareProvenance o) -> SoftwareProvenance
16170  """
16171  return _IMP_core.SoftwareProvenance_setup_particle(*args)
16172 
16173  def add_attribute(self, *args):
16174  r"""
16175  add_attribute(SoftwareProvenance self, FloatKey k, IMP::Float v, bool opt)
16176  add_attribute(SoftwareProvenance self, FloatKey a0, IMP::Float a1)
16177  add_attribute(SoftwareProvenance self, IntKey a0, IMP::Int a1)
16178  add_attribute(SoftwareProvenance self, FloatsKey a0, IMP::Floats a1)
16179  add_attribute(SoftwareProvenance self, IntsKey a0, IMP::Ints a1)
16180  add_attribute(SoftwareProvenance self, StringKey a0, IMP::String a1)
16181  add_attribute(SoftwareProvenance self, ParticleIndexKey a0, Particle a1)
16182  add_attribute(SoftwareProvenance self, ObjectKey a0, Object a1)
16183  add_attribute(SoftwareProvenance self, SparseFloatKey a0, IMP::Float a1)
16184  add_attribute(SoftwareProvenance self, SparseIntKey a0, IMP::Int a1)
16185  add_attribute(SoftwareProvenance self, SparseStringKey a0, IMP::String a1)
16186  add_attribute(SoftwareProvenance self, SparseParticleIndexKey a0, ParticleIndex a1)
16187  """
16188  return _IMP_core.SoftwareProvenance_add_attribute(self, *args)
16189 
16190  def get_value(self, *args):
16191  r"""
16192  get_value(SoftwareProvenance self, FloatKey a0) -> IMP::Float
16193  get_value(SoftwareProvenance self, IntKey a0) -> IMP::Int
16194  get_value(SoftwareProvenance self, FloatsKey a0) -> IMP::Floats
16195  get_value(SoftwareProvenance self, IntsKey a0) -> IMP::Ints
16196  get_value(SoftwareProvenance self, StringKey a0) -> IMP::String
16197  get_value(SoftwareProvenance self, ParticleIndexKey a0) -> Particle
16198  get_value(SoftwareProvenance self, ObjectKey a0) -> Object
16199  get_value(SoftwareProvenance self, SparseFloatKey a0) -> IMP::Float
16200  get_value(SoftwareProvenance self, SparseIntKey a0) -> IMP::Int
16201  get_value(SoftwareProvenance self, SparseStringKey a0) -> IMP::String
16202  get_value(SoftwareProvenance self, SparseParticleIndexKey a0) -> ParticleIndex
16203  """
16204  return _IMP_core.SoftwareProvenance_get_value(self, *args)
16205 
16206  def set_value(self, *args):
16207  r"""
16208  set_value(SoftwareProvenance self, FloatKey a0, IMP::Float a1)
16209  set_value(SoftwareProvenance self, IntKey a0, IMP::Int a1)
16210  set_value(SoftwareProvenance self, FloatsKey a0, IMP::Floats a1)
16211  set_value(SoftwareProvenance self, IntsKey a0, IMP::Ints a1)
16212  set_value(SoftwareProvenance self, StringKey a0, IMP::String a1)
16213  set_value(SoftwareProvenance self, ParticleIndexKey a0, Particle a1)
16214  set_value(SoftwareProvenance self, ObjectKey a0, Object a1)
16215  set_value(SoftwareProvenance self, SparseFloatKey a0, IMP::Float a1)
16216  set_value(SoftwareProvenance self, SparseIntKey a0, IMP::Int a1)
16217  set_value(SoftwareProvenance self, SparseStringKey a0, IMP::String a1)
16218  set_value(SoftwareProvenance self, SparseParticleIndexKey a0, ParticleIndex a1)
16219  """
16220  return _IMP_core.SoftwareProvenance_set_value(self, *args)
16221 
16222  def remove_attribute(self, *args):
16223  r"""
16224  remove_attribute(SoftwareProvenance self, FloatKey a0)
16225  remove_attribute(SoftwareProvenance self, IntKey a0)
16226  remove_attribute(SoftwareProvenance self, FloatsKey a0)
16227  remove_attribute(SoftwareProvenance self, IntsKey a0)
16228  remove_attribute(SoftwareProvenance self, StringKey a0)
16229  remove_attribute(SoftwareProvenance self, ParticleIndexKey a0)
16230  remove_attribute(SoftwareProvenance self, ObjectKey a0)
16231  remove_attribute(SoftwareProvenance self, SparseFloatKey a0)
16232  remove_attribute(SoftwareProvenance self, SparseIntKey a0)
16233  remove_attribute(SoftwareProvenance self, SparseStringKey a0)
16234  remove_attribute(SoftwareProvenance self, SparseParticleIndexKey a0)
16235  """
16236  return _IMP_core.SoftwareProvenance_remove_attribute(self, *args)
16237 
16238  def has_attribute(self, *args):
16239  r"""
16240  has_attribute(SoftwareProvenance self, FloatKey a0) -> bool
16241  has_attribute(SoftwareProvenance self, IntKey a0) -> bool
16242  has_attribute(SoftwareProvenance self, FloatsKey a0) -> bool
16243  has_attribute(SoftwareProvenance self, IntsKey a0) -> bool
16244  has_attribute(SoftwareProvenance self, StringKey a0) -> bool
16245  has_attribute(SoftwareProvenance self, ParticleIndexKey a0) -> bool
16246  has_attribute(SoftwareProvenance self, ObjectKey a0) -> bool
16247  has_attribute(SoftwareProvenance self, SparseFloatKey a0) -> bool
16248  has_attribute(SoftwareProvenance self, SparseIntKey a0) -> bool
16249  has_attribute(SoftwareProvenance self, SparseStringKey a0) -> bool
16250  has_attribute(SoftwareProvenance self, SparseParticleIndexKey a0) -> bool
16251  """
16252  return _IMP_core.SoftwareProvenance_has_attribute(self, *args)
16253 
16254  def get_derivative(self, a0):
16255  r"""get_derivative(SoftwareProvenance self, FloatKey a0) -> double"""
16256  return _IMP_core.SoftwareProvenance_get_derivative(self, a0)
16257 
16258  def get_name(self):
16259  r"""get_name(SoftwareProvenance self) -> std::string"""
16260  return _IMP_core.SoftwareProvenance_get_name(self)
16261 
16262  def clear_caches(self):
16263  r"""clear_caches(SoftwareProvenance self)"""
16264  return _IMP_core.SoftwareProvenance_clear_caches(self)
16265 
16266  def set_name(self, a0):
16267  r"""set_name(SoftwareProvenance self, std::string a0)"""
16268  return _IMP_core.SoftwareProvenance_set_name(self, a0)
16269 
16270  def set_check_level(self, a0):
16271  r"""set_check_level(SoftwareProvenance self, IMP::CheckLevel a0)"""
16272  return _IMP_core.SoftwareProvenance_set_check_level(self, a0)
16273 
16274  def add_to_derivative(self, a0, a1, a2):
16275  r"""add_to_derivative(SoftwareProvenance self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
16276  return _IMP_core.SoftwareProvenance_add_to_derivative(self, a0, a1, a2)
16277 
16278  def set_is_optimized(self, a0, a1):
16279  r"""set_is_optimized(SoftwareProvenance self, FloatKey a0, bool a1)"""
16280  return _IMP_core.SoftwareProvenance_set_is_optimized(self, a0, a1)
16281 
16282  def get_is_optimized(self, a0):
16283  r"""get_is_optimized(SoftwareProvenance self, FloatKey a0) -> bool"""
16284  return _IMP_core.SoftwareProvenance_get_is_optimized(self, a0)
16285 
16286  def get_check_level(self):
16287  r"""get_check_level(SoftwareProvenance self) -> IMP::CheckLevel"""
16288  return _IMP_core.SoftwareProvenance_get_check_level(self)
16289 
16290  def __eq__(self, *args):
16291  r"""
16292  __eq__(SoftwareProvenance self, SoftwareProvenance o) -> bool
16293  __eq__(SoftwareProvenance self, Particle d) -> bool
16294  """
16295  return _IMP_core.SoftwareProvenance___eq__(self, *args)
16296 
16297  def __ne__(self, *args):
16298  r"""
16299  __ne__(SoftwareProvenance self, SoftwareProvenance o) -> bool
16300  __ne__(SoftwareProvenance self, Particle d) -> bool
16301  """
16302  return _IMP_core.SoftwareProvenance___ne__(self, *args)
16303 
16304  def __le__(self, *args):
16305  r"""
16306  __le__(SoftwareProvenance self, SoftwareProvenance o) -> bool
16307  __le__(SoftwareProvenance self, Particle d) -> bool
16308  """
16309  return _IMP_core.SoftwareProvenance___le__(self, *args)
16310 
16311  def __lt__(self, *args):
16312  r"""
16313  __lt__(SoftwareProvenance self, SoftwareProvenance o) -> bool
16314  __lt__(SoftwareProvenance self, Particle d) -> bool
16315  """
16316  return _IMP_core.SoftwareProvenance___lt__(self, *args)
16317 
16318  def __ge__(self, *args):
16319  r"""
16320  __ge__(SoftwareProvenance self, SoftwareProvenance o) -> bool
16321  __ge__(SoftwareProvenance self, Particle d) -> bool
16322  """
16323  return _IMP_core.SoftwareProvenance___ge__(self, *args)
16324 
16325  def __gt__(self, *args):
16326  r"""
16327  __gt__(SoftwareProvenance self, SoftwareProvenance o) -> bool
16328  __gt__(SoftwareProvenance self, Particle d) -> bool
16329  """
16330  return _IMP_core.SoftwareProvenance___gt__(self, *args)
16331 
16332  def __hash__(self):
16333  r"""__hash__(SoftwareProvenance self) -> std::size_t"""
16334  return _IMP_core.SoftwareProvenance___hash__(self)
16335 
16336  def __str__(self):
16337  r"""__str__(SoftwareProvenance self) -> std::string"""
16338  return _IMP_core.SoftwareProvenance___str__(self)
16339 
16340  def __repr__(self):
16341  r"""__repr__(SoftwareProvenance self) -> std::string"""
16342  return _IMP_core.SoftwareProvenance___repr__(self)
16343 
16344  def _get_as_binary(self):
16345  r"""_get_as_binary(SoftwareProvenance self) -> PyObject *"""
16346  return _IMP_core.SoftwareProvenance__get_as_binary(self)
16347 
16348  def _set_from_binary(self, p):
16349  r"""_set_from_binary(SoftwareProvenance self, PyObject * p)"""
16350  return _IMP_core.SoftwareProvenance__set_from_binary(self, p)
16351 
16352  def __getstate__(self):
16353  p = self._get_as_binary()
16354  if len(self.__dict__) > 1:
16355  d = self.__dict__.copy()
16356  del d['this']
16357  p = (d, p)
16358  return p
16359 
16360  def __setstate__(self, p):
16361  if not hasattr(self, 'this'):
16362  self.__init__()
16363  if isinstance(p, tuple):
16364  d, p = p
16365  self.__dict__.update(d)
16366  return self._set_from_binary(p)
16367 
16368  __swig_destroy__ = _IMP_core.delete_SoftwareProvenance
16369 
16370 # Register SoftwareProvenance in _IMP_core:
16371 _IMP_core.SoftwareProvenance_swigregister(SoftwareProvenance)
16372 class Provenanced(IMP.Decorator):
16373  r"""Proxy of C++ IMP::core::Provenanced class."""
16374 
16375  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
16376 
16377  def get_provenance(self):
16378  r"""get_provenance(Provenanced self) -> Provenance"""
16379  return _IMP_core.Provenanced_get_provenance(self)
16380 
16381  def set_provenance(self, p):
16382  r"""set_provenance(Provenanced self, Provenance p)"""
16383  return _IMP_core.Provenanced_set_provenance(self, p)
16384 
16385  def __init__(self, *args):
16386  r"""
16387  __init__(Provenanced self) -> Provenanced
16388  __init__(Provenanced self, Model m, ParticleIndex id) -> Provenanced
16389  __init__(Provenanced self, _ParticleAdaptor d) -> Provenanced
16390  """
16391  _IMP_core.Provenanced_swiginit(self, _IMP_core.new_Provenanced(*args))
16392 
16393  @staticmethod
16394  def get_is_setup(*args):
16395  r"""
16396  get_is_setup(Model m, ParticleIndex pi) -> bool
16397  get_is_setup(_ParticleAdaptor p) -> bool
16398  """
16399  return _IMP_core.Provenanced_get_is_setup(*args)
16400 
16401  def show(self, *args):
16402  r"""show(Provenanced self, _ostream out=std::cout)"""
16403  return _IMP_core.Provenanced_show(self, *args)
16404 
16405  @staticmethod
16406  def setup_particle(*args):
16407  r"""
16408  setup_particle(Model m, ParticleIndex pi, Provenance p) -> Provenanced
16409  setup_particle(_ParticleAdaptor pa, Provenance p) -> Provenanced
16410  """
16411  return _IMP_core.Provenanced_setup_particle(*args)
16412 
16413  def add_attribute(self, *args):
16414  r"""
16415  add_attribute(Provenanced self, FloatKey k, IMP::Float v, bool opt)
16416  add_attribute(Provenanced self, FloatKey a0, IMP::Float a1)
16417  add_attribute(Provenanced self, IntKey a0, IMP::Int a1)
16418  add_attribute(Provenanced self, FloatsKey a0, IMP::Floats a1)
16419  add_attribute(Provenanced self, IntsKey a0, IMP::Ints a1)
16420  add_attribute(Provenanced self, StringKey a0, IMP::String a1)
16421  add_attribute(Provenanced self, ParticleIndexKey a0, Particle a1)
16422  add_attribute(Provenanced self, ObjectKey a0, Object a1)
16423  add_attribute(Provenanced self, SparseFloatKey a0, IMP::Float a1)
16424  add_attribute(Provenanced self, SparseIntKey a0, IMP::Int a1)
16425  add_attribute(Provenanced self, SparseStringKey a0, IMP::String a1)
16426  add_attribute(Provenanced self, SparseParticleIndexKey a0, ParticleIndex a1)
16427  """
16428  return _IMP_core.Provenanced_add_attribute(self, *args)
16429 
16430  def get_value(self, *args):
16431  r"""
16432  get_value(Provenanced self, FloatKey a0) -> IMP::Float
16433  get_value(Provenanced self, IntKey a0) -> IMP::Int
16434  get_value(Provenanced self, FloatsKey a0) -> IMP::Floats
16435  get_value(Provenanced self, IntsKey a0) -> IMP::Ints
16436  get_value(Provenanced self, StringKey a0) -> IMP::String
16437  get_value(Provenanced self, ParticleIndexKey a0) -> Particle
16438  get_value(Provenanced self, ObjectKey a0) -> Object
16439  get_value(Provenanced self, SparseFloatKey a0) -> IMP::Float
16440  get_value(Provenanced self, SparseIntKey a0) -> IMP::Int
16441  get_value(Provenanced self, SparseStringKey a0) -> IMP::String
16442  get_value(Provenanced self, SparseParticleIndexKey a0) -> ParticleIndex
16443  """
16444  return _IMP_core.Provenanced_get_value(self, *args)
16445 
16446  def set_value(self, *args):
16447  r"""
16448  set_value(Provenanced self, FloatKey a0, IMP::Float a1)
16449  set_value(Provenanced self, IntKey a0, IMP::Int a1)
16450  set_value(Provenanced self, FloatsKey a0, IMP::Floats a1)
16451  set_value(Provenanced self, IntsKey a0, IMP::Ints a1)
16452  set_value(Provenanced self, StringKey a0, IMP::String a1)
16453  set_value(Provenanced self, ParticleIndexKey a0, Particle a1)
16454  set_value(Provenanced self, ObjectKey a0, Object a1)
16455  set_value(Provenanced self, SparseFloatKey a0, IMP::Float a1)
16456  set_value(Provenanced self, SparseIntKey a0, IMP::Int a1)
16457  set_value(Provenanced self, SparseStringKey a0, IMP::String a1)
16458  set_value(Provenanced self, SparseParticleIndexKey a0, ParticleIndex a1)
16459  """
16460  return _IMP_core.Provenanced_set_value(self, *args)
16461 
16462  def remove_attribute(self, *args):
16463  r"""
16464  remove_attribute(Provenanced self, FloatKey a0)
16465  remove_attribute(Provenanced self, IntKey a0)
16466  remove_attribute(Provenanced self, FloatsKey a0)
16467  remove_attribute(Provenanced self, IntsKey a0)
16468  remove_attribute(Provenanced self, StringKey a0)
16469  remove_attribute(Provenanced self, ParticleIndexKey a0)
16470  remove_attribute(Provenanced self, ObjectKey a0)
16471  remove_attribute(Provenanced self, SparseFloatKey a0)
16472  remove_attribute(Provenanced self, SparseIntKey a0)
16473  remove_attribute(Provenanced self, SparseStringKey a0)
16474  remove_attribute(Provenanced self, SparseParticleIndexKey a0)
16475  """
16476  return _IMP_core.Provenanced_remove_attribute(self, *args)
16477 
16478  def has_attribute(self, *args):
16479  r"""
16480  has_attribute(Provenanced self, FloatKey a0) -> bool
16481  has_attribute(Provenanced self, IntKey a0) -> bool
16482  has_attribute(Provenanced self, FloatsKey a0) -> bool
16483  has_attribute(Provenanced self, IntsKey a0) -> bool
16484  has_attribute(Provenanced self, StringKey a0) -> bool
16485  has_attribute(Provenanced self, ParticleIndexKey a0) -> bool
16486  has_attribute(Provenanced self, ObjectKey a0) -> bool
16487  has_attribute(Provenanced self, SparseFloatKey a0) -> bool
16488  has_attribute(Provenanced self, SparseIntKey a0) -> bool
16489  has_attribute(Provenanced self, SparseStringKey a0) -> bool
16490  has_attribute(Provenanced self, SparseParticleIndexKey a0) -> bool
16491  """
16492  return _IMP_core.Provenanced_has_attribute(self, *args)
16493 
16494  def get_derivative(self, a0):
16495  r"""get_derivative(Provenanced self, FloatKey a0) -> double"""
16496  return _IMP_core.Provenanced_get_derivative(self, a0)
16497 
16498  def get_name(self):
16499  r"""get_name(Provenanced self) -> std::string"""
16500  return _IMP_core.Provenanced_get_name(self)
16501 
16502  def clear_caches(self):
16503  r"""clear_caches(Provenanced self)"""
16504  return _IMP_core.Provenanced_clear_caches(self)
16505 
16506  def set_name(self, a0):
16507  r"""set_name(Provenanced self, std::string a0)"""
16508  return _IMP_core.Provenanced_set_name(self, a0)
16509 
16510  def set_check_level(self, a0):
16511  r"""set_check_level(Provenanced self, IMP::CheckLevel a0)"""
16512  return _IMP_core.Provenanced_set_check_level(self, a0)
16513 
16514  def add_to_derivative(self, a0, a1, a2):
16515  r"""add_to_derivative(Provenanced self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
16516  return _IMP_core.Provenanced_add_to_derivative(self, a0, a1, a2)
16517 
16518  def set_is_optimized(self, a0, a1):
16519  r"""set_is_optimized(Provenanced self, FloatKey a0, bool a1)"""
16520  return _IMP_core.Provenanced_set_is_optimized(self, a0, a1)
16521 
16522  def get_is_optimized(self, a0):
16523  r"""get_is_optimized(Provenanced self, FloatKey a0) -> bool"""
16524  return _IMP_core.Provenanced_get_is_optimized(self, a0)
16525 
16526  def get_check_level(self):
16527  r"""get_check_level(Provenanced self) -> IMP::CheckLevel"""
16528  return _IMP_core.Provenanced_get_check_level(self)
16529 
16530  def __eq__(self, *args):
16531  r"""
16532  __eq__(Provenanced self, Provenanced o) -> bool
16533  __eq__(Provenanced self, Particle d) -> bool
16534  """
16535  return _IMP_core.Provenanced___eq__(self, *args)
16536 
16537  def __ne__(self, *args):
16538  r"""
16539  __ne__(Provenanced self, Provenanced o) -> bool
16540  __ne__(Provenanced self, Particle d) -> bool
16541  """
16542  return _IMP_core.Provenanced___ne__(self, *args)
16543 
16544  def __le__(self, *args):
16545  r"""
16546  __le__(Provenanced self, Provenanced o) -> bool
16547  __le__(Provenanced self, Particle d) -> bool
16548  """
16549  return _IMP_core.Provenanced___le__(self, *args)
16550 
16551  def __lt__(self, *args):
16552  r"""
16553  __lt__(Provenanced self, Provenanced o) -> bool
16554  __lt__(Provenanced self, Particle d) -> bool
16555  """
16556  return _IMP_core.Provenanced___lt__(self, *args)
16557 
16558  def __ge__(self, *args):
16559  r"""
16560  __ge__(Provenanced self, Provenanced o) -> bool
16561  __ge__(Provenanced self, Particle d) -> bool
16562  """
16563  return _IMP_core.Provenanced___ge__(self, *args)
16564 
16565  def __gt__(self, *args):
16566  r"""
16567  __gt__(Provenanced self, Provenanced o) -> bool
16568  __gt__(Provenanced self, Particle d) -> bool
16569  """
16570  return _IMP_core.Provenanced___gt__(self, *args)
16571 
16572  def __hash__(self):
16573  r"""__hash__(Provenanced self) -> std::size_t"""
16574  return _IMP_core.Provenanced___hash__(self)
16575 
16576  def __str__(self):
16577  r"""__str__(Provenanced self) -> std::string"""
16578  return _IMP_core.Provenanced___str__(self)
16579 
16580  def __repr__(self):
16581  r"""__repr__(Provenanced self) -> std::string"""
16582  return _IMP_core.Provenanced___repr__(self)
16583 
16584  def _get_as_binary(self):
16585  r"""_get_as_binary(Provenanced self) -> PyObject *"""
16586  return _IMP_core.Provenanced__get_as_binary(self)
16587 
16588  def _set_from_binary(self, p):
16589  r"""_set_from_binary(Provenanced self, PyObject * p)"""
16590  return _IMP_core.Provenanced__set_from_binary(self, p)
16591 
16592  def __getstate__(self):
16593  p = self._get_as_binary()
16594  if len(self.__dict__) > 1:
16595  d = self.__dict__.copy()
16596  del d['this']
16597  p = (d, p)
16598  return p
16599 
16600  def __setstate__(self, p):
16601  if not hasattr(self, 'this'):
16602  self.__init__()
16603  if isinstance(p, tuple):
16604  d, p = p
16605  self.__dict__.update(d)
16606  return self._set_from_binary(p)
16607 
16608  __swig_destroy__ = _IMP_core.delete_Provenanced
16609 
16610 # Register Provenanced in _IMP_core:
16611 _IMP_core.Provenanced_swigregister(Provenanced)
16612 
16613 def add_provenance(m, pi, p):
16614  r"""add_provenance(Model m, ParticleIndex pi, Provenance p)"""
16615  return _IMP_core.add_provenance(m, pi, p)
16616 
16617 def create_clone(p):
16618  r"""create_clone(Provenance p) -> Provenance"""
16619  return _IMP_core.create_clone(p)
16620 
16622  r"""
16623  get_transformation_aligning_first_to_second(IMP::ParticlesTemp const & a, IMP::ParticlesTemp const & b) -> Transformation3D
16624  get_transformation_aligning_first_to_second(IMP::ParticlesTemp const & a, IMP::Vector< IMP::VectorD< 3 >,std::allocator< IMP::VectorD< 3 > > > const & b) -> Transformation3D
16625  get_transformation_aligning_first_to_second(IMP::Vector< IMP::VectorD< 3 >,std::allocator< IMP::VectorD< 3 > > > const & a, IMP::ParticlesTemp const & b) -> Transformation3D
16626  """
16627  return _IMP_core.get_transformation_aligning_first_to_second(*args)
16628 
16629 def create_restraint(ps, pp):
16630  r"""create_restraint(PairScore ps, IMP::ParticlePair pp) -> Restraint"""
16631  return _IMP_core.create_restraint(ps, pp)
16633  r"""Proxy of C++ IMP::core::TruncatedHarmonic< IMP::core::LOWER > class."""
16634 
16635  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
16636 
16637  def __init__(self, *args):
16638  r"""
16639  __init__(TruncatedHarmonicLowerBound self, IMP::Float center, IMP::Float k, IMP::Float threshold, IMP::Float limit) -> TruncatedHarmonicLowerBound
16640  __init__(TruncatedHarmonicLowerBound self, IMP::Float center, IMP::Float k, IMP::Float threshold) -> TruncatedHarmonicLowerBound
16641  """
16642  _IMP_core.TruncatedHarmonicLowerBound_swiginit(self, _IMP_core.new_TruncatedHarmonicLowerBound(*args))
16643 
16644  def get_version_info(self):
16645  r"""get_version_info(TruncatedHarmonicLowerBound self) -> VersionInfo"""
16646  return _IMP_core.TruncatedHarmonicLowerBound_get_version_info(self)
16647  __swig_destroy__ = _IMP_core.delete_TruncatedHarmonicLowerBound
16648 
16649  def __str__(self):
16650  r"""__str__(TruncatedHarmonicLowerBound self) -> std::string"""
16651  return _IMP_core.TruncatedHarmonicLowerBound___str__(self)
16652 
16653  def __repr__(self):
16654  r"""__repr__(TruncatedHarmonicLowerBound self) -> std::string"""
16655  return _IMP_core.TruncatedHarmonicLowerBound___repr__(self)
16656 
16657  @staticmethod
16658  def get_from(o):
16659  return _object_cast_to_TruncatedHarmonic(o)
16660 
16661 
16662 # Register TruncatedHarmonicLowerBound in _IMP_core:
16663 _IMP_core.TruncatedHarmonicLowerBound_swigregister(TruncatedHarmonicLowerBound)
16665  r"""Proxy of C++ IMP::core::TruncatedHarmonic< IMP::core::UPPER > class."""
16666 
16667  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
16668 
16669  def __init__(self, *args):
16670  r"""
16671  __init__(TruncatedHarmonicUpperBound self, IMP::Float center, IMP::Float k, IMP::Float threshold, IMP::Float limit) -> TruncatedHarmonicUpperBound
16672  __init__(TruncatedHarmonicUpperBound self, IMP::Float center, IMP::Float k, IMP::Float threshold) -> TruncatedHarmonicUpperBound
16673  """
16674  _IMP_core.TruncatedHarmonicUpperBound_swiginit(self, _IMP_core.new_TruncatedHarmonicUpperBound(*args))
16675 
16676  def get_version_info(self):
16677  r"""get_version_info(TruncatedHarmonicUpperBound self) -> VersionInfo"""
16678  return _IMP_core.TruncatedHarmonicUpperBound_get_version_info(self)
16679  __swig_destroy__ = _IMP_core.delete_TruncatedHarmonicUpperBound
16680 
16681  def __str__(self):
16682  r"""__str__(TruncatedHarmonicUpperBound self) -> std::string"""
16683  return _IMP_core.TruncatedHarmonicUpperBound___str__(self)
16684 
16685  def __repr__(self):
16686  r"""__repr__(TruncatedHarmonicUpperBound self) -> std::string"""
16687  return _IMP_core.TruncatedHarmonicUpperBound___repr__(self)
16688 
16689  @staticmethod
16690  def get_from(o):
16691  return _object_cast_to_TruncatedHarmonic(o)
16692 
16693 
16694 # Register TruncatedHarmonicUpperBound in _IMP_core:
16695 _IMP_core.TruncatedHarmonicUpperBound_swigregister(TruncatedHarmonicUpperBound)
16697  r"""Proxy of C++ IMP::core::TruncatedHarmonic< IMP::core::BOTH > class."""
16698 
16699  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
16700 
16701  def __init__(self, *args):
16702  r"""
16703  __init__(TruncatedHarmonicBound self, IMP::Float center, IMP::Float k, IMP::Float threshold, IMP::Float limit) -> TruncatedHarmonicBound
16704  __init__(TruncatedHarmonicBound self, IMP::Float center, IMP::Float k, IMP::Float threshold) -> TruncatedHarmonicBound
16705  """
16706  _IMP_core.TruncatedHarmonicBound_swiginit(self, _IMP_core.new_TruncatedHarmonicBound(*args))
16707 
16708  def get_version_info(self):
16709  r"""get_version_info(TruncatedHarmonicBound self) -> VersionInfo"""
16710  return _IMP_core.TruncatedHarmonicBound_get_version_info(self)
16711  __swig_destroy__ = _IMP_core.delete_TruncatedHarmonicBound
16712 
16713  def __str__(self):
16714  r"""__str__(TruncatedHarmonicBound self) -> std::string"""
16715  return _IMP_core.TruncatedHarmonicBound___str__(self)
16716 
16717  def __repr__(self):
16718  r"""__repr__(TruncatedHarmonicBound self) -> std::string"""
16719  return _IMP_core.TruncatedHarmonicBound___repr__(self)
16720 
16721  @staticmethod
16722  def get_from(o):
16723  return _object_cast_to_TruncatedHarmonic(o)
16724 
16725 
16726 # Register TruncatedHarmonicBound in _IMP_core:
16727 _IMP_core.TruncatedHarmonicBound_swigregister(TruncatedHarmonicBound)
16728 class ParticleType(IMP._Value):
16729  r"""Proxy of C++ IMP::Key< 34897493 > class."""
16730 
16731  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
16732 
16733  def __init__(self, *args):
16734  r"""
16735  __init__(ParticleType self) -> ParticleType
16736  __init__(ParticleType self, std::string const & c, bool is_implicit_add_permitted=True) -> ParticleType
16737  __init__(ParticleType self, unsigned int i) -> ParticleType
16738  """
16739  _IMP_core.ParticleType_swiginit(self, _IMP_core.new_ParticleType(*args))
16740 
16741  @staticmethod
16742  def add_key(sc):
16743  r"""add_key(std::string sc) -> unsigned int"""
16744  return _IMP_core.ParticleType_add_key(sc)
16745 
16746  @staticmethod
16747  def get_key_exists(sc):
16748  r"""get_key_exists(std::string sc) -> bool"""
16749  return _IMP_core.ParticleType_get_key_exists(sc)
16750 
16751  def get_string(self):
16752  r"""get_string(ParticleType self) -> std::string const"""
16753  return _IMP_core.ParticleType_get_string(self)
16754 
16755  def __cmp__(self, o):
16756  r"""__cmp__(ParticleType self, ParticleType o) -> int"""
16757  return _IMP_core.ParticleType___cmp__(self, o)
16758 
16759  def __eq__(self, o):
16760  r"""__eq__(ParticleType self, ParticleType o) -> bool"""
16761  return _IMP_core.ParticleType___eq__(self, o)
16762 
16763  def __ne__(self, o):
16764  r"""__ne__(ParticleType self, ParticleType o) -> bool"""
16765  return _IMP_core.ParticleType___ne__(self, o)
16766 
16767  def __lt__(self, o):
16768  r"""__lt__(ParticleType self, ParticleType o) -> bool"""
16769  return _IMP_core.ParticleType___lt__(self, o)
16770 
16771  def __gt__(self, o):
16772  r"""__gt__(ParticleType self, ParticleType o) -> bool"""
16773  return _IMP_core.ParticleType___gt__(self, o)
16774 
16775  def __ge__(self, o):
16776  r"""__ge__(ParticleType self, ParticleType o) -> bool"""
16777  return _IMP_core.ParticleType___ge__(self, o)
16778 
16779  def __le__(self, o):
16780  r"""__le__(ParticleType self, ParticleType o) -> bool"""
16781  return _IMP_core.ParticleType___le__(self, o)
16782 
16783  def __hash__(self):
16784  r"""__hash__(ParticleType self) -> std::size_t"""
16785  return _IMP_core.ParticleType___hash__(self)
16786 
16787  def show(self, *args):
16788  r"""show(ParticleType self, _ostream out=std::cout)"""
16789  return _IMP_core.ParticleType_show(self, *args)
16790 
16791  @staticmethod
16792  def add_alias(old_key, new_name):
16793  r"""add_alias(ParticleType old_key, std::string new_name) -> ParticleType"""
16794  return _IMP_core.ParticleType_add_alias(old_key, new_name)
16795 
16796  @staticmethod
16797  def get_number_of_keys():
16798  r"""get_number_of_keys() -> unsigned int"""
16799  return _IMP_core.ParticleType_get_number_of_keys()
16800 
16801  def get_index(self):
16802  r"""get_index(ParticleType self) -> unsigned int"""
16803  return _IMP_core.ParticleType_get_index(self)
16804 
16805  @staticmethod
16806  def show_all(out):
16807  r"""show_all(_ostream out)"""
16808  return _IMP_core.ParticleType_show_all(out)
16809 
16810  @staticmethod
16811  def get_all_strings():
16812  r"""get_all_strings() -> IMP::Vector< std::string >"""
16813  return _IMP_core.ParticleType_get_all_strings()
16814 
16815  @staticmethod
16816  def get_number_unique():
16817  r"""get_number_unique() -> unsigned int"""
16818  return _IMP_core.ParticleType_get_number_unique()
16819 
16820  def __str__(self):
16821  r"""__str__(ParticleType self) -> std::string"""
16822  return _IMP_core.ParticleType___str__(self)
16823 
16824  def __repr__(self):
16825  r"""__repr__(ParticleType self) -> std::string"""
16826  return _IMP_core.ParticleType___repr__(self)
16827  __swig_destroy__ = _IMP_core.delete_ParticleType
16828 
16829 # Register ParticleType in _IMP_core:
16830 _IMP_core.ParticleType_swigregister(ParticleType)
16832  r"""Proxy of C++ IMP::core::GenericAttributeSingletonScore< UnaryFunction > class."""
16833 
16834  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
16835  __repr__ = _swig_repr
16836 
16837  def __init__(self, f, k):
16838  r"""__init__(AttributeSingletonScore self, UnaryFunction f, FloatKey k) -> AttributeSingletonScore"""
16839  _IMP_core.AttributeSingletonScore_swiginit(self, _IMP_core.new_AttributeSingletonScore(f, k))
16840 
16841  def do_get_inputs(self, m, pis):
16842  r"""do_get_inputs(AttributeSingletonScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
16843  return _IMP_core.AttributeSingletonScore_do_get_inputs(self, m, pis)
16844 
16845  def get_unary_function(self):
16846  r"""get_unary_function(AttributeSingletonScore self) -> UnaryFunction"""
16847  return _IMP_core.AttributeSingletonScore_get_unary_function(self)
16848 
16849  def get_key(self):
16850  r"""get_key(AttributeSingletonScore self) -> FloatKey"""
16851  return _IMP_core.AttributeSingletonScore_get_key(self)
16852 
16853  def evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked=False):
16854  r"""evaluate_indexes(AttributeSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
16855  return _IMP_core.AttributeSingletonScore_evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked)
16856 
16857  def evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked=False):
16858  r"""evaluate_indexes_scores(AttributeSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
16859  return _IMP_core.AttributeSingletonScore_evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked)
16860 
16861  def evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked=False):
16862  r"""evaluate_indexes_delta(AttributeSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, std::vector< unsigned int,std::allocator< unsigned int > > const & indexes, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
16863  return _IMP_core.AttributeSingletonScore_evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked)
16864 
16865  def evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked=False):
16866  r"""evaluate_if_good_indexes(AttributeSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, double max, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
16867  return _IMP_core.AttributeSingletonScore_evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked)
16868 
16869  def get_version_info(self):
16870  r"""get_version_info(AttributeSingletonScore self) -> VersionInfo"""
16871  return _IMP_core.AttributeSingletonScore_get_version_info(self)
16872  __swig_destroy__ = _IMP_core.delete_AttributeSingletonScore
16873 
16874  @staticmethod
16875  def get_from(o):
16876  return _object_cast_to_AttributeSingletonScore(o)
16877 
16878 
16879  def _get_jax(self, m, indexes):
16880  def score_float_key(jm, key, uf):
16881  return uf(jm[key][indexes])
16882 
16883  def score_xyz_key(jm, xyz_index, uf):
16884  return uf(jm['xyz'][indexes, xyz_index])
16885 
16886  uf = self.get_unary_function().get_derived_object()._get_jax()
16887  key = self.get_key()
16888  # First 7 FloatKeys are reserved in IMP and have to be handled
16889  # specially
16890  if key.get_index() >= 7:
16891  need_keys = [key]
16892  f = functools.partial(score_float_key, key=key.get_string(), uf=uf)
16893  elif key == XYZR.get_radius_key():
16894  need_keys = [] # We already have the radius in the JAX model
16895  f = functools.partial(score_float_key, key='r', uf=uf)
16896  elif key in XYZ.get_xyz_keys():
16897  need_keys = [] # We already have coordinates in the JAX model
16898  xyz_index = XYZ.get_xyz_keys().index(key)
16899  f = functools.partial(score_xyz_key, xyz_index=xyz_index, uf=uf)
16900  else:
16901  raise NotImplementedError("No support for key %s" % key)
16902  return self._wrap_jax(m, f, keys=need_keys)
16903 
16904 
16905 # Register AttributeSingletonScore in _IMP_core:
16906 _IMP_core.AttributeSingletonScore_swigregister(AttributeSingletonScore)
16907 
16909  r"""create_generic_attribute_singleton_score(UnaryFunction uf, FloatKey k) -> AttributeSingletonScore"""
16910  return _IMP_core.create_generic_attribute_singleton_score(uf, k)
16912  r"""Proxy of C++ IMP::core::GenericBoundingBox3DSingletonScore< UnaryFunction > class."""
16913 
16914  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
16915  __repr__ = _swig_repr
16916 
16917  def __init__(self, f, bb):
16918  r"""__init__(BoundingBox3DSingletonScore self, UnaryFunction f, BoundingBox3D bb) -> BoundingBox3DSingletonScore"""
16919  _IMP_core.BoundingBox3DSingletonScore_swiginit(self, _IMP_core.new_BoundingBox3DSingletonScore(f, bb))
16920 
16921  def get_unary_function(self):
16922  r"""get_unary_function(BoundingBox3DSingletonScore self) -> UnaryFunction"""
16923  return _IMP_core.BoundingBox3DSingletonScore_get_unary_function(self)
16924 
16925  def get_bounding_box(self):
16926  r"""get_bounding_box(BoundingBox3DSingletonScore self) -> BoundingBox3D"""
16927  return _IMP_core.BoundingBox3DSingletonScore_get_bounding_box(self)
16928 
16929  def do_get_inputs(self, m, pis):
16930  r"""do_get_inputs(BoundingBox3DSingletonScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
16931  return _IMP_core.BoundingBox3DSingletonScore_do_get_inputs(self, m, pis)
16932 
16933  def evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked=False):
16934  r"""evaluate_indexes(BoundingBox3DSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
16935  return _IMP_core.BoundingBox3DSingletonScore_evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked)
16936 
16937  def evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked=False):
16938  r"""evaluate_indexes_scores(BoundingBox3DSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
16939  return _IMP_core.BoundingBox3DSingletonScore_evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked)
16940 
16941  def evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked=False):
16942  r"""evaluate_indexes_delta(BoundingBox3DSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, std::vector< unsigned int,std::allocator< unsigned int > > const & indexes, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
16943  return _IMP_core.BoundingBox3DSingletonScore_evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked)
16944 
16945  def evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked=False):
16946  r"""evaluate_if_good_indexes(BoundingBox3DSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, double max, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
16947  return _IMP_core.BoundingBox3DSingletonScore_evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked)
16948 
16949  def get_version_info(self):
16950  r"""get_version_info(BoundingBox3DSingletonScore self) -> VersionInfo"""
16951  return _IMP_core.BoundingBox3DSingletonScore_get_version_info(self)
16952  __swig_destroy__ = _IMP_core.delete_BoundingBox3DSingletonScore
16953 
16954  @staticmethod
16955  def get_from(o):
16956  return _object_cast_to_BoundingBox3DSingletonScore(o)
16957 
16958 
16959  def _get_jax(self, m, indexes):
16960  import jax.numpy as jnp
16961  def score(jm, box_min, box_max, uf):
16962  xyzs = jm['xyz'][indexes]
16963  # This calculates the distance and the score for every point,
16964  # even those inside the box. IMP just returns zero for points
16965  # inside the box, skipping the distance calculation.
16966  # The implementation here is *probably* faster on a GPU since
16967  # we reduce the use of conditionals, and JAX will likely skip
16968  # the sqrt if uf is a harmonic, but this should be benchmarked.
16969  drs = jnp.linalg.norm(
16970  xyzs - jnp.clip(xyzs, box_min, box_max), axis=1)
16971  return uf(drs)
16972  uf = self.get_unary_function().get_derived_object()
16973  bb = self.get_bounding_box()
16974  f = functools.partial(score, box_min=jnp.asarray(bb.get_corner(0)),
16975  box_max=jnp.asarray(bb.get_corner(1)),
16976  uf=uf._get_jax())
16977  return self._wrap_jax(m, f)
16978 
16979 
16980 # Register BoundingBox3DSingletonScore in _IMP_core:
16981 _IMP_core.BoundingBox3DSingletonScore_swigregister(BoundingBox3DSingletonScore)
16982 
16983 def create_bounding_box_3d_singleton_score(f, bb):
16984  r"""create_bounding_box_3d_singleton_score(UnaryFunction f, BoundingBox3D bb) -> BoundingBox3DSingletonScore"""
16985  return _IMP_core.create_bounding_box_3d_singleton_score(f, bb)
16987  r"""Proxy of C++ IMP::core::GenericBoundingSphere3DSingletonScore< UnaryFunction > class."""
16988 
16989  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
16990  __repr__ = _swig_repr
16991 
16992  def __init__(self, f, sphere):
16993  r"""__init__(BoundingSphere3DSingletonScore self, UnaryFunction f, Sphere3D sphere) -> BoundingSphere3DSingletonScore"""
16994  _IMP_core.BoundingSphere3DSingletonScore_swiginit(self, _IMP_core.new_BoundingSphere3DSingletonScore(f, sphere))
16995 
16996  def do_get_inputs(self, m, pis):
16997  r"""do_get_inputs(BoundingSphere3DSingletonScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
16998  return _IMP_core.BoundingSphere3DSingletonScore_do_get_inputs(self, m, pis)
16999 
17000  def get_unary_function(self):
17001  r"""get_unary_function(BoundingSphere3DSingletonScore self) -> UnaryFunction"""
17002  return _IMP_core.BoundingSphere3DSingletonScore_get_unary_function(self)
17003 
17004  def get_sphere(self):
17005  r"""get_sphere(BoundingSphere3DSingletonScore self) -> Sphere3D"""
17006  return _IMP_core.BoundingSphere3DSingletonScore_get_sphere(self)
17007 
17008  def evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked=False):
17009  r"""evaluate_indexes(BoundingSphere3DSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
17010  return _IMP_core.BoundingSphere3DSingletonScore_evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked)
17011 
17012  def evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked=False):
17013  r"""evaluate_indexes_scores(BoundingSphere3DSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
17014  return _IMP_core.BoundingSphere3DSingletonScore_evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked)
17015 
17016  def evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked=False):
17017  r"""evaluate_indexes_delta(BoundingSphere3DSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, std::vector< unsigned int,std::allocator< unsigned int > > const & indexes, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
17018  return _IMP_core.BoundingSphere3DSingletonScore_evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked)
17019 
17020  def evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked=False):
17021  r"""evaluate_if_good_indexes(BoundingSphere3DSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, double max, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
17022  return _IMP_core.BoundingSphere3DSingletonScore_evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked)
17023 
17024  def get_version_info(self):
17025  r"""get_version_info(BoundingSphere3DSingletonScore self) -> VersionInfo"""
17026  return _IMP_core.BoundingSphere3DSingletonScore_get_version_info(self)
17027  __swig_destroy__ = _IMP_core.delete_BoundingSphere3DSingletonScore
17028 
17029  @staticmethod
17030  def get_from(o):
17031  return _object_cast_to_BoundingSphere3DSingletonScore(o)
17032 
17033 
17034  def _get_jax(self, m, indexes):
17035  import jax.numpy as jnp
17036  import jax.lax
17037  def score_with_radius(jm, inds, center, radius):
17038  xyzs = jm['xyz'][inds]
17039  radii = jm['r'][inds]
17040  drs = jnp.linalg.norm(xyzs - center) + radii - radius
17041  return jax.lax.select(drs < 0.000001, jnp.zeros_like(drs), uf(drs))
17042  def score_without_radius(jm, inds, center, radius):
17043  xyzs = jm['xyz'][inds]
17044  drs = jnp.linalg.norm(xyzs - center) - radius
17045  return jax.lax.select(drs < 0.000001, jnp.zeros_like(drs), uf(drs))
17046  without_radii_inds = []
17047  with_radii_inds = []
17048  for ind in indexes:
17049  if XYZR.get_is_setup(m, ind):
17050  with_radii_inds.append(ind)
17051  else:
17052  without_radii_inds.append(ind)
17053  without_radii_inds = jnp.asarray(without_radii_inds)
17054  with_radii_inds = jnp.asarray(with_radii_inds)
17055  uf = self.get_unary_function().get_derived_object()._get_jax()
17056  sphere = self.get_sphere()
17057  radius = sphere.get_radius()
17058  center = jnp.asarray(sphere.get_center())
17059  def score(jm):
17060  s = 0.
17061  if without_radii_inds.size > 0:
17062  s += score_without_radius(jm, without_radii_inds,
17063  center, radius)
17064  if with_radii_inds.size > 0:
17065  s += score_with_radius(jm, with_radii_inds, center, radius)
17066  return s
17067  return self._wrap_jax(m, score)
17068 
17069 
17070 # Register BoundingSphere3DSingletonScore in _IMP_core:
17071 _IMP_core.BoundingSphere3DSingletonScore_swigregister(BoundingSphere3DSingletonScore)
17072 
17073 def create_bounding_sphere_3d_singleton_score(f, sphere):
17074  r"""create_bounding_sphere_3d_singleton_score(UnaryFunction f, Sphere3D sphere) -> BoundingSphere3DSingletonScore"""
17075  return _IMP_core.create_bounding_sphere_3d_singleton_score(f, sphere)
17077  r"""Proxy of C++ IMP::core::GenericDistanceToSingletonScore< UnaryFunction > class."""
17078 
17079  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
17080  __repr__ = _swig_repr
17081 
17082  def __init__(self, *args):
17083  r"""
17084  __init__(DistanceToSingletonScore self, UnaryFunction f, Vector3D pt) -> DistanceToSingletonScore
17085  __init__(DistanceToSingletonScore self) -> DistanceToSingletonScore
17086  """
17087  _IMP_core.DistanceToSingletonScore_swiginit(self, _IMP_core.new_DistanceToSingletonScore(*args))
17088 
17089  def do_get_inputs(self, m, pis):
17090  r"""do_get_inputs(DistanceToSingletonScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
17091  return _IMP_core.DistanceToSingletonScore_do_get_inputs(self, m, pis)
17092 
17093  def get_unary_function(self):
17094  r"""get_unary_function(DistanceToSingletonScore self) -> UnaryFunction"""
17095  return _IMP_core.DistanceToSingletonScore_get_unary_function(self)
17096 
17097  def get_point(self):
17098  r"""get_point(DistanceToSingletonScore self) -> Vector3D"""
17099  return _IMP_core.DistanceToSingletonScore_get_point(self)
17100 
17101  def evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked=False):
17102  r"""evaluate_indexes(DistanceToSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
17103  return _IMP_core.DistanceToSingletonScore_evaluate_indexes(self, m, p, da, lower_bound, upper_bound, all_indexes_checked)
17104 
17105  def evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked=False):
17106  r"""evaluate_indexes_scores(DistanceToSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, unsigned int lower_bound, unsigned int upper_bound, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
17107  return _IMP_core.DistanceToSingletonScore_evaluate_indexes_scores(self, m, p, da, lower_bound, upper_bound, score, all_indexes_checked)
17108 
17109  def evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked=False):
17110  r"""evaluate_indexes_delta(DistanceToSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, std::vector< unsigned int,std::allocator< unsigned int > > const & indexes, std::vector< double,std::allocator< double > > & score, bool all_indexes_checked=False) -> double"""
17111  return _IMP_core.DistanceToSingletonScore_evaluate_indexes_delta(self, m, p, da, indexes, score, all_indexes_checked)
17112 
17113  def evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked=False):
17114  r"""evaluate_if_good_indexes(DistanceToSingletonScore self, Model m, IMP::ParticleIndexes const & p, DerivativeAccumulator da, double max, unsigned int lower_bound, unsigned int upper_bound, bool all_indexes_checked=False) -> double"""
17115  return _IMP_core.DistanceToSingletonScore_evaluate_if_good_indexes(self, m, p, da, max, lower_bound, upper_bound, all_indexes_checked)
17116 
17117  def get_version_info(self):
17118  r"""get_version_info(DistanceToSingletonScore self) -> VersionInfo"""
17119  return _IMP_core.DistanceToSingletonScore_get_version_info(self)
17120  __swig_destroy__ = _IMP_core.delete_DistanceToSingletonScore
17121 
17122  @staticmethod
17123  def get_from(o):
17124  return _object_cast_to_DistanceToSingletonScore(o)
17125 
17126 
17127  def _get_as_binary(self):
17128  r"""_get_as_binary(DistanceToSingletonScore self) -> PyObject *"""
17129  return _IMP_core.DistanceToSingletonScore__get_as_binary(self)
17130 
17131  def _set_from_binary(self, p):
17132  r"""_set_from_binary(DistanceToSingletonScore self, PyObject * p)"""
17133  return _IMP_core.DistanceToSingletonScore__set_from_binary(self, p)
17134 
17135  def __getstate__(self):
17136  p = self._get_as_binary()
17137  if len(self.__dict__) > 1:
17138  d = self.__dict__.copy()
17139  del d['this']
17140  p = (d, p)
17141  return p
17142 
17143  def __setstate__(self, p):
17144  if not hasattr(self, 'this'):
17145  self.__init__()
17146  if isinstance(p, tuple):
17147  d, p = p
17148  self.__dict__.update(d)
17149  return self._set_from_binary(p)
17150 
17151 
17152  def _get_jax(self, m, indexes):
17153  import jax.numpy as jnp
17154  def score(jm, point, uf):
17155  xyzs = jm['xyz'][indexes]
17156  drs = jnp.linalg.norm(xyzs - point, axis=1)
17157  return uf(drs)
17158  uf = self.get_unary_function().get_derived_object()
17159  f = functools.partial(score, point=jnp.array(self.get_point()),
17160  uf=uf._get_jax())
17161  return self._wrap_jax(m, f)
17162 
17163 
17164 # Register DistanceToSingletonScore in _IMP_core:
17165 _IMP_core.DistanceToSingletonScore_swigregister(DistanceToSingletonScore)
17166 
17167 def create_distance_to_singleton_score(f, pt):
17168  r"""create_distance_to_singleton_score(UnaryFunction f, Vector3D pt) -> DistanceToSingletonScore"""
17169  return _IMP_core.create_distance_to_singleton_score(f, pt)
17170 
17171 class SphereDistancePairScore(_SphereDistancePairScore.__bases__[0]):
17172  def __init__(self, uf):
17173  if isinstance(uf, HarmonicUpperBound):
17174  p = HarmonicUpperBoundSphereDistancePairScore(
17175  uf.get_mean(), uf.get_k())
17176  elif isinstance(uf, HarmonicLowerBound):
17177  if uf.get_mean() == 0.0:
17178  p = SoftSpherePairScore(uf.get_k())
17179  else:
17180  p = _SphereDistancePairScore(uf)
17181  elif isinstance(uf, Harmonic):
17182  p = HarmonicSphereDistancePairScore(
17183  uf.get_mean(), uf.get_k())
17184  else:
17185  p = _SphereDistancePairScore(uf)
17186  self.__dict__['_proxied'] = p
17187  def __getattr__(self, key):
17188  return getattr(self._proxied, key)
17189  def __setattr__(self, key, val):
17190  return setattr(self._proxied, key, val)
17191 
17192  def __getstate__(self):
17193  return self.__dict__['_proxied']
17194 
17195  def __setstate__(self, p):
17196  self.__dict__['_proxied'] = p
17197 
17198  def _get_jax(self, *args, **kwargs):
17199  return self._proxied._get_jax(*args, **kwargs)
17200 
17201  @staticmethod
17202  def get_from(o):
17203  try:
17204  p = HarmonicUpperBoundSphereDistancePairScore.get_from(o)
17205  except ValueError:
17206  try:
17207  p = HarmonicSphereDistancePairScore.get_from(o)
17208  except ValueError:
17209  try:
17210  p = SoftSpherePairScore.get_from(o)
17211  except ValueError:
17212  p = _SphereDistancePairScore.get_from(o)
17213  obj = object.__new__(SphereDistancePairScore)
17214  obj.__dict__['_proxied'] = p
17215  return obj
17216 
17217 
17218 
17219 def get_all_provenance(p, types=[StructureProvenance, SampleProvenance,
17220  CombineProvenance, FilterProvenance,
17221  ClusterProvenance, ScriptProvenance,
17222  SoftwareProvenance]):
17223  """Yield all provenance decorators of the given types for the particle.
17224  By default, all provenance types are returned. Provenance is returned
17225  in order, most recent first. If the particle has no provenance
17226  information, an empty generator is returned."""
17227  if Provenanced.get_is_setup(p):
17228  prov = Provenanced(p).get_provenance()
17229  while prov:
17230  for c in types:
17231  if c.get_is_setup(prov):
17232  yield c(prov)
17233  prov = prov.get_previous()
17234 
17236  """Tag the given particle with the current Python script.
17237  This is a noop if the particle is already so tagged."""
17238  main = sys.modules['__main__']
17239 # Can't do anything if running from an interactive interpreter
17240  if not hasattr(main, '__file__'):
17241  return
17242  f = IMP.get_absolute_path(main.__file__)
17243  for prov in get_all_provenance(p, types=[ScriptProvenance]):
17244  if prov.get_filename() == f:
17245  return
17246  m = p.get_model()
17247  provp = IMP.Particle(m)
17248  provp.set_name('script')
17249  prov = ScriptProvenance.setup_particle(provp, f)
17250  add_provenance(m, p, prov)
17251 
17252 def add_software_provenance(p, name, version, location):
17253  """Tag the given particle with the software used to create it.
17254  This is a noop if the particle is already so tagged."""
17255  for prov in get_all_provenance(p, types=[SoftwareProvenance]):
17256  if prov.get_software_name() == name and prov.get_version() == version \
17257  and prov.get_location() == location:
17258  return
17259  m = p.get_model()
17260  provp = IMP.Particle(m)
17261  provp.set_name('software')
17262  prov = SoftwareProvenance.setup_particle(provp, name, version, location)
17263  add_provenance(m, p, prov)
17264 
17266  """Tag the given particle as being created by the current version of IMP."""
17267  add_software_provenance(p, name="Integrative Modeling Platform (IMP)",
17268  version=IMP.get_module_version(),
17269  location="https://integrativemodeling.org")
17270 
17271 
17272 def get_module_name():
17273  r"""get_module_name() -> std::string const"""
17274  return _IMP_core.get_module_name()
17275 
17276 def get_module_version():
17277  r"""get_module_version() -> std::string const"""
17278  return _IMP_core.get_module_version()
17279 
17280 def get_example_path(fname):
17281  r"""get_example_path(std::string fname) -> std::string"""
17282  return _IMP_core.get_example_path(fname)
17283 
17284 def get_data_path(fname):
17285  r"""get_data_path(std::string fname) -> std::string"""
17286  return _IMP_core.get_data_path(fname)
17287 
17288 from . import _version_check
17289 _version_check.check_version(get_module_version())
17290 __version__ = get_module_version()
17291 
17292 
F visit_breadth_first(HD d, F f)
Apply the visitor to each particle, breadth first.
A base class for geometry contained in particles.
A base class for modifiers of ParticlesTemp.
GenericDistanceToSingletonScore< UnaryFunction > DistanceToSingletonScore
Rotation3D get_rotation_about_normalized_axis(const Vector3D &axis_norm, double angle)
Definition: Rotation3D.h:391
double get_kt(double T)
Return kT for a given temperature in units of [kcal/mol].
Abstract class for scoring object(s) of type ParticleIndexPair.
Definition: PairScore.h:44
double get_height(const Surface &s, const XYZR &d)
Get height of sphere above surface.
Definition: Surface.h:129
algebra::Transformation3D get_transformation_aligning_first_to_second(XYZsOrVector3ds a, XYZsOrVector3ds b)
double get_mean(const cv::Mat &mat, const cvIntMat &mask)
CheckLevel get_check_level()
Get the current audit mode.
Definition: exception.h:80
def add_script_provenance
Tag the given particle with the current Python script.
GenericBoundingSphere3DSingletonScore< UnaryFunction > BoundingSphere3DSingletonScore
Abstract predicate function.
Definition: QuadPredicate.h:31
Restraint * create_restraint(Score *s, const typename Score::Argument &t, std::string name=std::string())
Definition: generic.h:36
ParticleIndex get_root_rigid_body(RigidMember m)
Return the index of the outer-most rigid body containing the member.
algebra::ReferenceFrame3D get_initial_reference_frame(Model *m, const ParticleIndexes &pis)
The base class for geometry.
F visit_depth_first(HD d, F &f)
Apply functor F to each particle, traversing the hierarchy depth first.
XYZRs create_xyzr_particles(Model *m, unsigned int num, Float radius, Float box_side=10)
Create a set of particles with random coordinates.
A base class for geometry contained in particles.
double get_angle(Direction a, Direction b)
Get angle between directions.
A base class for geometry from a set of particles.
double get_dihedral(XYZ a, XYZ b, XYZ c, XYZ d)
Compute the dihedral angle (in radians) between the four particles.
Make CGAL functionality available to IMP.
Provenance create_clone(Provenance p)
Clone provenance (including previous provenance)
ParticlesTemp create_rigid_bodies(Model *m, unsigned int n, bool no_members=false)
std::string get_data_path(std::string file_name)
Return the full path to one of this module's data files.
void add_rigid_body_cache_key(ObjectKey k)
Base class for all samplers.
Definition: Sampler.h:31
Key< 34897493 > ParticleType
An IMP::Key object for identifying types of particles by strings.
Definition: Typed.h:28
algebra::Vector3D get_centroid(const XYZs &ps)
Get the centroid.
void add_particle(RMF::FileHandle fh, Particle *hs)
GenericHierarchies get_leaves(Hierarchy mhd)
Get all the leaves of the bit of hierarchy.
static FloatKeys get_internal_coordinate_keys()
Definition: rigid_bodies.h:618
Composable functors to implement scores via compile-time composition.
std::string get_example_path(std::string file_name)
Return the full path to one of this module's example files.
GenericHierarchies get_all_descendants(Hierarchy mhd)
Get all the particles in the subtree.
A base class for geometry from a set of particles.
def add_imp_provenance
Tag the given particle as being created by the current version of IMP.
display::Geometries create_blame_geometries(const RestraintsTemp &rs, const ParticlesTemp &ps, double max=NO_MAX, std::string name=std::string())
void show_rigid_body_hierarchy(RigidBody rb, TextOutput out=TextOutput(std::cout))
Implement a constraint on the Model.
Definition: Constraint.h:49
void add_restraint(RMF::FileHandle fh, Restraint *hs)
def add_software_provenance
Tag the given particle with the software used to create it.
Base class for objects in a Model that depend on other objects.
Definition: ModelObject.h:28
Abstract predicate function.
Ints get_index(const ParticlesTemp &particles, const Subset &subset, const Subsets &excluded)
Common base class for heavy weight IMP objects.
Definition: Object.h:111
int get_number_of_frames(const ::npctransport_proto::Assignment &config, double time_step)
Abstract class for scoring object(s) of type ParticleIndex.
ScoreStates maintain invariants in the Model.
Definition: ScoreState.h:56
Base class for all optimizers.
Definition: Optimizer.h:48
GenericAttributeSingletonScore< UnaryFunction > AttributeSingletonScore
SurfaceGeometry * create_geometry(const Surface s, std::string name=std::string("SurfaceGeometry%1%"))
Create a geometry from a Surface.
Definition: Surface.h:191
void add_restraints(RMF::FileHandle fh, const Restraints &hs)
algebra::BoundingBoxD< 3 > get_bounding_box(const XYZRs &ps)
Get the bounding box.
const algebra::Vector3D & get_vector_geometry(XYZ d)
Definition: XYZ.h:135
GenericHierarchies get_internal(Hierarchy mhd)
Get all the non-leaves of the bit of hierarchy.
Interface to specialized Particle types (e.g. atoms)
Definition: Decorator.h:119
std::ostream & show(Hierarchy h, std::ostream &out=std::cout)
Print the hierarchy using a given decorator to display each node.
std::string get_absolute_path(std::string file)
Convert a possibly relative path to an absolute path.
algebra::Sphere3D get_enclosing_sphere(const XYZs &v)
Get a sphere enclosing the set of XYZRs.
Base class for optimizers that act on individual attributes.
SurfaceGeometry * get_constrained_surface_geometry(const Surface s, std::string name="SurfaceGeometry%1%")
Get surface geometry constrained to the surface.
Definition: Surface.h:236
Abstract predicate function.
Definition: PairPredicate.h:31
General purpose algebraic and geometric methods that are expected to be used by a wide variety of IMP...
Represents a scoring function on the model.
void set_vector_geometry(XYZ d, const algebra::Vector3D &v)
Definition: XYZ.h:131
Shared optimizer state that is invoked upon commitment of new coordinates.
Hierarchy get_root(Hierarchy h)
Return the root of the hierarchy.
Abstract predicate function.
GenericBoundingBox3DSingletonScore< UnaryFunction > BoundingBox3DSingletonScore
Abstract class to implement hierarchical methods.
Definition: Refiner.h:36
double get_depth(const Surface &s, const XYZR &d)
Get depth of sphere below surface.
Definition: Surface.h:143
void set_enclosing_radius(XYZR b, const XYZs &v)
Set the radius of the first to enclose the list.
Class to handle individual particles of a Model object.
Definition: Particle.h:45
GenericAttributeSingletonScore< UF > * create_generic_attribute_singleton_score(UF *uf, FloatKey k)
void transform(RigidBody a, const algebra::Transformation3D &tr)
Transform a rigid body.
Definition: rigid_bodies.h:748
void assign_blame(const RestraintsTemp &rs, const ParticlesTemp &ps, FloatKey attribute)
std::string get_module_version()
Return the version of this module, as a string.
TruncatedHarmonic< BOTH > TruncatedHarmonicBound
TruncatedHarmonic< UPPER > TruncatedHarmonicUpperBound
static const FloatKeys & get_xyz_keys()
Get a vector containing the keys for x,y,z.
BallMover
Definition: BallMover.py:1
Output IMP model data in various file formats.
std::string get_chain_id(Hierarchy h)
Walk up the hierarchy to determine the chain id.
def get_all_provenance
Yield all provenance decorators of the given types for the particle.
Abstract class for scoring object(s) of type ParticleIndexTriplet.
Definition: TripletScore.h:44
void add_provenance(Model *m, ParticleIndex pi, Provenance p)
Add provenance to part of the model.
Tag part of the system to track how it was created.
Definition: provenance.h:632
double get_distance(const Surface &s, const XYZR &d)
Get distance from sphere to surface.
Definition: Surface.h:153
ParticleIndexes get_indexes(const ParticlesTemp &ps)
Get the indexes from a list of particles.
Abstract single variable functor class for score functions.
Definition: UnaryFunction.h:27
void set_enclosing_sphere(XYZR b, const XYZs &v, double slack=0)
Set the coordinates and radius of the first to enclose the list.
TruncatedHarmonic< LOWER > TruncatedHarmonicLowerBound
void set_check_level(CheckLevel tf)
Control runtime checks in the code.
Definition: exception.h:72
std::string get_module_version()
Return the version of this module, as a string.
A restraint is a term in an IMP ScoringFunction.
Definition: Restraint.h:56