IMP logo
IMP Reference Guide  2.22.0
The Integrative Modeling Platform
example/__init__.py
1 # This file was automatically generated by SWIG (https://www.swig.org).
2 # Version 4.3.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-2024 IMP Inventors. All rights reserved.
10 
11 
12 
13 
14 from sys import version_info as _swig_python_version_info
15 import _IMP_example
16 
17 try:
18  import builtins as __builtin__
19 except ImportError:
20  import __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 def _swig_add_metaclass(metaclass):
53  """Class decorator for adding a metaclass to a SWIG wrapped class - a slimmed down version of six.add_metaclass"""
54  def wrapper(cls):
55  return metaclass(cls.__name__, cls.__bases__, cls.__dict__.copy())
56  return wrapper
57 
58 
59 class _SwigNonDynamicMeta(type):
60  """Meta class to enforce nondynamic attributes (no new attributes) for a class"""
61  __setattr__ = _swig_setattr_nondynamic_class_variable(type.__setattr__)
62 
63 
64 import weakref
65 
66 class IMP_EXAMPLE_SwigPyIterator(object):
67  r"""Proxy of C++ swig::IMP_EXAMPLE_SwigPyIterator class."""
68 
69  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
70 
71  def __init__(self, *args, **kwargs):
72  raise AttributeError("No constructor defined - class is abstract")
73  __repr__ = _swig_repr
74  __swig_destroy__ = _IMP_example.delete_IMP_EXAMPLE_SwigPyIterator
75 
76  def value(self):
77  r"""value(IMP_EXAMPLE_SwigPyIterator self) -> PyObject *"""
78  return _IMP_example.IMP_EXAMPLE_SwigPyIterator_value(self)
79 
80  def incr(self, n=1):
81  r"""incr(IMP_EXAMPLE_SwigPyIterator self, size_t n=1) -> IMP_EXAMPLE_SwigPyIterator"""
82  return _IMP_example.IMP_EXAMPLE_SwigPyIterator_incr(self, n)
83 
84  def decr(self, n=1):
85  r"""decr(IMP_EXAMPLE_SwigPyIterator self, size_t n=1) -> IMP_EXAMPLE_SwigPyIterator"""
86  return _IMP_example.IMP_EXAMPLE_SwigPyIterator_decr(self, n)
87 
88  def distance(self, x):
89  r"""distance(IMP_EXAMPLE_SwigPyIterator self, IMP_EXAMPLE_SwigPyIterator x) -> ptrdiff_t"""
90  return _IMP_example.IMP_EXAMPLE_SwigPyIterator_distance(self, x)
91 
92  def equal(self, x):
93  r"""equal(IMP_EXAMPLE_SwigPyIterator self, IMP_EXAMPLE_SwigPyIterator x) -> bool"""
94  return _IMP_example.IMP_EXAMPLE_SwigPyIterator_equal(self, x)
95 
96  def copy(self):
97  r"""copy(IMP_EXAMPLE_SwigPyIterator self) -> IMP_EXAMPLE_SwigPyIterator"""
98  return _IMP_example.IMP_EXAMPLE_SwigPyIterator_copy(self)
99 
100  def next(self):
101  r"""next(IMP_EXAMPLE_SwigPyIterator self) -> PyObject *"""
102  return _IMP_example.IMP_EXAMPLE_SwigPyIterator_next(self)
103 
104  def __next__(self):
105  r"""__next__(IMP_EXAMPLE_SwigPyIterator self) -> PyObject *"""
106  return _IMP_example.IMP_EXAMPLE_SwigPyIterator___next__(self)
107 
108  def previous(self):
109  r"""previous(IMP_EXAMPLE_SwigPyIterator self) -> PyObject *"""
110  return _IMP_example.IMP_EXAMPLE_SwigPyIterator_previous(self)
111 
112  def advance(self, n):
113  r"""advance(IMP_EXAMPLE_SwigPyIterator self, ptrdiff_t n) -> IMP_EXAMPLE_SwigPyIterator"""
114  return _IMP_example.IMP_EXAMPLE_SwigPyIterator_advance(self, n)
115 
116  def __eq__(self, x):
117  r"""__eq__(IMP_EXAMPLE_SwigPyIterator self, IMP_EXAMPLE_SwigPyIterator x) -> bool"""
118  return _IMP_example.IMP_EXAMPLE_SwigPyIterator___eq__(self, x)
119 
120  def __ne__(self, x):
121  r"""__ne__(IMP_EXAMPLE_SwigPyIterator self, IMP_EXAMPLE_SwigPyIterator x) -> bool"""
122  return _IMP_example.IMP_EXAMPLE_SwigPyIterator___ne__(self, x)
123 
124  def __iadd__(self, n):
125  r"""__iadd__(IMP_EXAMPLE_SwigPyIterator self, ptrdiff_t n) -> IMP_EXAMPLE_SwigPyIterator"""
126  return _IMP_example.IMP_EXAMPLE_SwigPyIterator___iadd__(self, n)
127 
128  def __isub__(self, n):
129  r"""__isub__(IMP_EXAMPLE_SwigPyIterator self, ptrdiff_t n) -> IMP_EXAMPLE_SwigPyIterator"""
130  return _IMP_example.IMP_EXAMPLE_SwigPyIterator___isub__(self, n)
131 
132  def __add__(self, n):
133  r"""__add__(IMP_EXAMPLE_SwigPyIterator self, ptrdiff_t n) -> IMP_EXAMPLE_SwigPyIterator"""
134  return _IMP_example.IMP_EXAMPLE_SwigPyIterator___add__(self, n)
135 
136  def __sub__(self, *args):
137  r"""
138  __sub__(IMP_EXAMPLE_SwigPyIterator self, ptrdiff_t n) -> IMP_EXAMPLE_SwigPyIterator
139  __sub__(IMP_EXAMPLE_SwigPyIterator self, IMP_EXAMPLE_SwigPyIterator x) -> ptrdiff_t
140  """
141  return _IMP_example.IMP_EXAMPLE_SwigPyIterator___sub__(self, *args)
142  def __iter__(self):
143  return self
144 
145 # Register IMP_EXAMPLE_SwigPyIterator in _IMP_example:
146 _IMP_example.IMP_EXAMPLE_SwigPyIterator_swigregister(IMP_EXAMPLE_SwigPyIterator)
147 
148 _value_types=[]
149 _object_types=[]
150 _raii_types=[]
151 _plural_types=[]
152 
153 IMP_DEBUG = _IMP_example.IMP_DEBUG
154 
155 IMP_RELEASE = _IMP_example.IMP_RELEASE
156 
157 IMP_SILENT = _IMP_example.IMP_SILENT
158 
159 IMP_PROGRESS = _IMP_example.IMP_PROGRESS
160 
161 IMP_TERSE = _IMP_example.IMP_TERSE
162 
163 IMP_VERBOSE = _IMP_example.IMP_VERBOSE
164 
165 IMP_MEMORY = _IMP_example.IMP_MEMORY
166 
167 IMP_NONE = _IMP_example.IMP_NONE
168 
169 IMP_USAGE = _IMP_example.IMP_USAGE
170 
171 IMP_INTERNAL = _IMP_example.IMP_INTERNAL
172 
173 IMP_KERNEL_HAS_LOG4CXX = _IMP_example.IMP_KERNEL_HAS_LOG4CXX
174 
175 IMP_COMPILER_HAS_CEREAL_RAW_POINTER = _IMP_example.IMP_COMPILER_HAS_CEREAL_RAW_POINTER
176 
177 IMP_COMPILER_HAS_DEBUG_VECTOR = _IMP_example.IMP_COMPILER_HAS_DEBUG_VECTOR
178 
179 IMP_COMPILER_HAS_RANDOM_SHUFFLE = _IMP_example.IMP_COMPILER_HAS_RANDOM_SHUFFLE
180 
181 IMP_COMPILER_HAS_THREE_WAY = _IMP_example.IMP_COMPILER_HAS_THREE_WAY
182 
183 IMP_KERNEL_HAS_BOOST_RANDOM = _IMP_example.IMP_KERNEL_HAS_BOOST_RANDOM
184 
185 IMP_KERNEL_HAS_NUMPY = _IMP_example.IMP_KERNEL_HAS_NUMPY
186 
187 IMP_KERNEL_HAS_GPERFTOOLS = _IMP_example.IMP_KERNEL_HAS_GPERFTOOLS
188 
189 IMP_KERNEL_HAS_TCMALLOC_HEAPCHECKER = _IMP_example.IMP_KERNEL_HAS_TCMALLOC_HEAPCHECKER
190 
191 IMP_KERNEL_HAS_TCMALLOC_HEAPPROFILER = _IMP_example.IMP_KERNEL_HAS_TCMALLOC_HEAPPROFILER
192 
193 IMPKERNEL_SHOW_WARNINGS = _IMP_example.IMPKERNEL_SHOW_WARNINGS
194 
195 
196 import sys
197 class _DirectorObjects:
198  """@internal Simple class to keep references to director objects
199  to prevent premature deletion."""
200  def __init__(self):
201  self._objects = []
202  def register(self, obj):
203  """Take a reference to a director object; will only work for
204  refcounted C++ classes"""
205  if hasattr(obj, 'get_ref_count'):
206  self._objects.append(obj)
207  def cleanup(self):
208  """Only drop our reference and allow cleanup by Python if no other
209  Python references exist (we hold 3 references: one in self._objects,
210  one in x, and one in the argument list for getrefcount) *and* no
211  other C++ references exist (the Python object always holds one)"""
212  objs = [x for x in self._objects if sys.getrefcount(x) > 3 \
213  or x.get_ref_count() > 1]
214 # Do in two steps so the references are kept until the end of the
215 # function (deleting references may trigger a fresh call to this method)
216  self._objects = objs
217  def get_object_count(self):
218  """Get number of director objects (useful for testing only)"""
219  return len(self._objects)
220 _director_objects = _DirectorObjects()
221 
222 class _ostream(object):
223  r"""Proxy of C++ std::ostream class."""
224 
225  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
226 
227  def __init__(self, *args, **kwargs):
228  raise AttributeError("No constructor defined")
229  __repr__ = _swig_repr
230 
231  def write(self, osa_buf):
232  r"""write(_ostream self, char const * osa_buf)"""
233  return _IMP_example._ostream_write(self, osa_buf)
234 
235 # Register _ostream in _IMP_example:
236 _IMP_example._ostream_swigregister(_ostream)
237 IMP_C_OPEN_BINARY = _IMP_example.IMP_C_OPEN_BINARY
238 
239 import IMP
240 IMP_CGAL_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_CGAL_HAS_BOOST_FILESYSTEM
241 
242 IMP_CGAL_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_CGAL_HAS_BOOST_PROGRAMOPTIONS
243 
244 IMP_CGAL_HAS_BOOST_RANDOM = _IMP_example.IMP_CGAL_HAS_BOOST_RANDOM
245 
246 IMP_CGAL_HAS_BOOST_SYSTEM = _IMP_example.IMP_CGAL_HAS_BOOST_SYSTEM
247 
248 IMP_CGAL_HAS_NUMPY = _IMP_example.IMP_CGAL_HAS_NUMPY
249 
250 IMPCGAL_SHOW_WARNINGS = _IMP_example.IMPCGAL_SHOW_WARNINGS
251 
252 import IMP.cgal
253 IMP_ALGEBRA_HAS_IMP_CGAL = _IMP_example.IMP_ALGEBRA_HAS_IMP_CGAL
254 
255 IMP_ALGEBRA_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_ALGEBRA_HAS_BOOST_FILESYSTEM
256 
257 IMP_ALGEBRA_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_ALGEBRA_HAS_BOOST_PROGRAMOPTIONS
258 
259 IMP_ALGEBRA_HAS_BOOST_RANDOM = _IMP_example.IMP_ALGEBRA_HAS_BOOST_RANDOM
260 
261 IMP_ALGEBRA_HAS_BOOST_SYSTEM = _IMP_example.IMP_ALGEBRA_HAS_BOOST_SYSTEM
262 
263 IMP_ALGEBRA_HAS_CGAL = _IMP_example.IMP_ALGEBRA_HAS_CGAL
264 
265 IMP_ALGEBRA_HAS_NUMPY = _IMP_example.IMP_ALGEBRA_HAS_NUMPY
266 
267 IMP_ALGEBRA_HAS_ANN = _IMP_example.IMP_ALGEBRA_HAS_ANN
268 
269 IMPALGEBRA_SHOW_WARNINGS = _IMP_example.IMPALGEBRA_SHOW_WARNINGS
270 
271 import IMP.algebra
272 IMP_DISPLAY_HAS_IMP_CGAL = _IMP_example.IMP_DISPLAY_HAS_IMP_CGAL
273 
274 IMP_DISPLAY_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_DISPLAY_HAS_BOOST_FILESYSTEM
275 
276 IMP_DISPLAY_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_DISPLAY_HAS_BOOST_PROGRAMOPTIONS
277 
278 IMP_DISPLAY_HAS_BOOST_RANDOM = _IMP_example.IMP_DISPLAY_HAS_BOOST_RANDOM
279 
280 IMP_DISPLAY_HAS_BOOST_SYSTEM = _IMP_example.IMP_DISPLAY_HAS_BOOST_SYSTEM
281 
282 IMP_DISPLAY_HAS_CGAL = _IMP_example.IMP_DISPLAY_HAS_CGAL
283 
284 IMP_DISPLAY_HAS_NUMPY = _IMP_example.IMP_DISPLAY_HAS_NUMPY
285 
286 IMPDISPLAY_SHOW_WARNINGS = _IMP_example.IMPDISPLAY_SHOW_WARNINGS
287 
288 import IMP.display
289 IMP_SCORE_FUNCTOR_HAS_IMP_CGAL = _IMP_example.IMP_SCORE_FUNCTOR_HAS_IMP_CGAL
290 
291 IMP_SCORE_FUNCTOR_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_SCORE_FUNCTOR_HAS_BOOST_FILESYSTEM
292 
293 IMP_SCORE_FUNCTOR_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_SCORE_FUNCTOR_HAS_BOOST_PROGRAMOPTIONS
294 
295 IMP_SCORE_FUNCTOR_HAS_BOOST_RANDOM = _IMP_example.IMP_SCORE_FUNCTOR_HAS_BOOST_RANDOM
296 
297 IMP_SCORE_FUNCTOR_HAS_BOOST_SYSTEM = _IMP_example.IMP_SCORE_FUNCTOR_HAS_BOOST_SYSTEM
298 
299 IMP_SCORE_FUNCTOR_HAS_CGAL = _IMP_example.IMP_SCORE_FUNCTOR_HAS_CGAL
300 
301 IMP_SCORE_FUNCTOR_HAS_HDF5 = _IMP_example.IMP_SCORE_FUNCTOR_HAS_HDF5
302 
303 IMP_SCORE_FUNCTOR_HAS_NUMPY = _IMP_example.IMP_SCORE_FUNCTOR_HAS_NUMPY
304 
305 IMPSCOREFUNCTOR_SHOW_WARNINGS = _IMP_example.IMPSCOREFUNCTOR_SHOW_WARNINGS
306 
307 import IMP.score_functor
308 IMP_STATISTICS_HAS_IMP_CGAL = _IMP_example.IMP_STATISTICS_HAS_IMP_CGAL
309 
310 IMP_STATISTICS_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_STATISTICS_HAS_BOOST_FILESYSTEM
311 
312 IMP_STATISTICS_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_STATISTICS_HAS_BOOST_PROGRAMOPTIONS
313 
314 IMP_STATISTICS_HAS_BOOST_RANDOM = _IMP_example.IMP_STATISTICS_HAS_BOOST_RANDOM
315 
316 IMP_STATISTICS_HAS_BOOST_SYSTEM = _IMP_example.IMP_STATISTICS_HAS_BOOST_SYSTEM
317 
318 IMP_STATISTICS_HAS_CGAL = _IMP_example.IMP_STATISTICS_HAS_CGAL
319 
320 IMP_STATISTICS_HAS_NUMPY = _IMP_example.IMP_STATISTICS_HAS_NUMPY
321 
322 IMPSTATISTICS_SHOW_WARNINGS = _IMP_example.IMPSTATISTICS_SHOW_WARNINGS
323 
324 import IMP.statistics
325 IMP_CORE_HAS_IMP_CGAL = _IMP_example.IMP_CORE_HAS_IMP_CGAL
326 
327 IMP_CORE_HAS_IMP_KERNEL = _IMP_example.IMP_CORE_HAS_IMP_KERNEL
328 
329 IMP_CORE_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_CORE_HAS_BOOST_FILESYSTEM
330 
331 IMP_CORE_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_CORE_HAS_BOOST_PROGRAMOPTIONS
332 
333 IMP_CORE_HAS_BOOST_RANDOM = _IMP_example.IMP_CORE_HAS_BOOST_RANDOM
334 
335 IMP_CORE_HAS_BOOST_SYSTEM = _IMP_example.IMP_CORE_HAS_BOOST_SYSTEM
336 
337 IMP_CORE_HAS_CGAL = _IMP_example.IMP_CORE_HAS_CGAL
338 
339 IMP_CORE_HAS_HDF5 = _IMP_example.IMP_CORE_HAS_HDF5
340 
341 IMP_CORE_HAS_NUMPY = _IMP_example.IMP_CORE_HAS_NUMPY
342 
343 IMPCORE_SHOW_WARNINGS = _IMP_example.IMPCORE_SHOW_WARNINGS
344 
345 import IMP.core
346 IMP_CONTAINER_HAS_IMP_ALGEBRA = _IMP_example.IMP_CONTAINER_HAS_IMP_ALGEBRA
347 
348 IMP_CONTAINER_HAS_IMP_CGAL = _IMP_example.IMP_CONTAINER_HAS_IMP_CGAL
349 
350 IMP_CONTAINER_HAS_IMP_DISPLAY = _IMP_example.IMP_CONTAINER_HAS_IMP_DISPLAY
351 
352 IMP_CONTAINER_HAS_IMP_KERNEL = _IMP_example.IMP_CONTAINER_HAS_IMP_KERNEL
353 
354 IMP_CONTAINER_HAS_IMP_SCORE_FUNCTOR = _IMP_example.IMP_CONTAINER_HAS_IMP_SCORE_FUNCTOR
355 
356 IMP_CONTAINER_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_CONTAINER_HAS_BOOST_FILESYSTEM
357 
358 IMP_CONTAINER_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_CONTAINER_HAS_BOOST_PROGRAMOPTIONS
359 
360 IMP_CONTAINER_HAS_BOOST_RANDOM = _IMP_example.IMP_CONTAINER_HAS_BOOST_RANDOM
361 
362 IMP_CONTAINER_HAS_BOOST_SYSTEM = _IMP_example.IMP_CONTAINER_HAS_BOOST_SYSTEM
363 
364 IMP_CONTAINER_HAS_CGAL = _IMP_example.IMP_CONTAINER_HAS_CGAL
365 
366 IMP_CONTAINER_HAS_HDF5 = _IMP_example.IMP_CONTAINER_HAS_HDF5
367 
368 IMP_CONTAINER_HAS_NUMPY = _IMP_example.IMP_CONTAINER_HAS_NUMPY
369 
370 IMP_CONTAINER_HAS_PYTHON_IHM = _IMP_example.IMP_CONTAINER_HAS_PYTHON_IHM
371 
372 IMP_CONTAINER_HAS_GOOGLE_DENSE_HASH_MAP = _IMP_example.IMP_CONTAINER_HAS_GOOGLE_DENSE_HASH_MAP
373 
374 IMP_CONTAINER_HAS_ROBIN_MAP = _IMP_example.IMP_CONTAINER_HAS_ROBIN_MAP
375 
376 IMPCONTAINER_SHOW_WARNINGS = _IMP_example.IMPCONTAINER_SHOW_WARNINGS
377 
378 import IMP.container
379 IMP_ATOM_HAS_IMP_CGAL = _IMP_example.IMP_ATOM_HAS_IMP_CGAL
380 
381 IMP_ATOM_HAS_IMP_KERNEL = _IMP_example.IMP_ATOM_HAS_IMP_KERNEL
382 
383 IMP_ATOM_HAS_IMP_SCORE_FUNCTOR = _IMP_example.IMP_ATOM_HAS_IMP_SCORE_FUNCTOR
384 
385 IMP_ATOM_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_ATOM_HAS_BOOST_PROGRAMOPTIONS
386 
387 IMP_ATOM_HAS_BOOST_RANDOM = _IMP_example.IMP_ATOM_HAS_BOOST_RANDOM
388 
389 IMP_ATOM_HAS_BOOST_REGEX = _IMP_example.IMP_ATOM_HAS_BOOST_REGEX
390 
391 IMP_ATOM_HAS_BOOST_SYSTEM = _IMP_example.IMP_ATOM_HAS_BOOST_SYSTEM
392 
393 IMP_ATOM_HAS_CGAL = _IMP_example.IMP_ATOM_HAS_CGAL
394 
395 IMP_ATOM_HAS_HDF5 = _IMP_example.IMP_ATOM_HAS_HDF5
396 
397 IMP_ATOM_HAS_NUMPY = _IMP_example.IMP_ATOM_HAS_NUMPY
398 
399 IMP_ATOM_HAS_PYTHON_IHM = _IMP_example.IMP_ATOM_HAS_PYTHON_IHM
400 
401 IMPATOM_SHOW_WARNINGS = _IMP_example.IMPATOM_SHOW_WARNINGS
402 
403 IMP_ATOM_TYPE_INDEX = _IMP_example.IMP_ATOM_TYPE_INDEX
404 
405 IMP_RESIDUE_TYPE_INDEX = _IMP_example.IMP_RESIDUE_TYPE_INDEX
406 
407 IMP_HIERARCHY_TYPE_INDEX = _IMP_example.IMP_HIERARCHY_TYPE_INDEX
408 
409 IMP_CHAIN_TYPE_INDEX = _IMP_example.IMP_CHAIN_TYPE_INDEX
410 
411 import IMP.atom
412 IMP_EM_HAS_IMP_CGAL = _IMP_example.IMP_EM_HAS_IMP_CGAL
413 
414 IMP_EM_HAS_IMP_CONTAINER = _IMP_example.IMP_EM_HAS_IMP_CONTAINER
415 
416 IMP_EM_HAS_IMP_DISPLAY = _IMP_example.IMP_EM_HAS_IMP_DISPLAY
417 
418 IMP_EM_HAS_IMP_SCORE_FUNCTOR = _IMP_example.IMP_EM_HAS_IMP_SCORE_FUNCTOR
419 
420 IMP_EM_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_EM_HAS_BOOST_FILESYSTEM
421 
422 IMP_EM_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_EM_HAS_BOOST_PROGRAMOPTIONS
423 
424 IMP_EM_HAS_BOOST_RANDOM = _IMP_example.IMP_EM_HAS_BOOST_RANDOM
425 
426 IMP_EM_HAS_BOOST_REGEX = _IMP_example.IMP_EM_HAS_BOOST_REGEX
427 
428 IMP_EM_HAS_BOOST_SYSTEM = _IMP_example.IMP_EM_HAS_BOOST_SYSTEM
429 
430 IMP_EM_HAS_CGAL = _IMP_example.IMP_EM_HAS_CGAL
431 
432 IMP_EM_HAS_HDF5 = _IMP_example.IMP_EM_HAS_HDF5
433 
434 IMP_EM_HAS_NUMPY = _IMP_example.IMP_EM_HAS_NUMPY
435 
436 IMP_EM_HAS_PYTHON_IHM = _IMP_example.IMP_EM_HAS_PYTHON_IHM
437 
438 IMPEM_SHOW_WARNINGS = _IMP_example.IMPEM_SHOW_WARNINGS
439 
440 import IMP.em
441 IMP_SAXS_HAS_IMP_CGAL = _IMP_example.IMP_SAXS_HAS_IMP_CGAL
442 
443 IMP_SAXS_HAS_IMP_CONTAINER = _IMP_example.IMP_SAXS_HAS_IMP_CONTAINER
444 
445 IMP_SAXS_HAS_IMP_DISPLAY = _IMP_example.IMP_SAXS_HAS_IMP_DISPLAY
446 
447 IMP_SAXS_HAS_IMP_KERNEL = _IMP_example.IMP_SAXS_HAS_IMP_KERNEL
448 
449 IMP_SAXS_HAS_IMP_SCORE_FUNCTOR = _IMP_example.IMP_SAXS_HAS_IMP_SCORE_FUNCTOR
450 
451 IMP_SAXS_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_SAXS_HAS_BOOST_FILESYSTEM
452 
453 IMP_SAXS_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_SAXS_HAS_BOOST_PROGRAMOPTIONS
454 
455 IMP_SAXS_HAS_BOOST_RANDOM = _IMP_example.IMP_SAXS_HAS_BOOST_RANDOM
456 
457 IMP_SAXS_HAS_BOOST_REGEX = _IMP_example.IMP_SAXS_HAS_BOOST_REGEX
458 
459 IMP_SAXS_HAS_BOOST_SYSTEM = _IMP_example.IMP_SAXS_HAS_BOOST_SYSTEM
460 
461 IMP_SAXS_HAS_CGAL = _IMP_example.IMP_SAXS_HAS_CGAL
462 
463 IMP_SAXS_HAS_HDF5 = _IMP_example.IMP_SAXS_HAS_HDF5
464 
465 IMP_SAXS_HAS_NUMPY = _IMP_example.IMP_SAXS_HAS_NUMPY
466 
467 IMP_SAXS_HAS_PYTHON_IHM = _IMP_example.IMP_SAXS_HAS_PYTHON_IHM
468 
469 IMPSAXS_SHOW_WARNINGS = _IMP_example.IMPSAXS_SHOW_WARNINGS
470 
471 import IMP.saxs
472 IMP_ISD_HAS_IMP_CGAL = _IMP_example.IMP_ISD_HAS_IMP_CGAL
473 
474 IMP_ISD_HAS_IMP_DISPLAY = _IMP_example.IMP_ISD_HAS_IMP_DISPLAY
475 
476 IMP_ISD_HAS_IMP_SCORE_FUNCTOR = _IMP_example.IMP_ISD_HAS_IMP_SCORE_FUNCTOR
477 
478 IMP_ISD_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_ISD_HAS_BOOST_FILESYSTEM
479 
480 IMP_ISD_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_ISD_HAS_BOOST_PROGRAMOPTIONS
481 
482 IMP_ISD_HAS_BOOST_RANDOM = _IMP_example.IMP_ISD_HAS_BOOST_RANDOM
483 
484 IMP_ISD_HAS_BOOST_REGEX = _IMP_example.IMP_ISD_HAS_BOOST_REGEX
485 
486 IMP_ISD_HAS_BOOST_SYSTEM = _IMP_example.IMP_ISD_HAS_BOOST_SYSTEM
487 
488 IMP_ISD_HAS_CGAL = _IMP_example.IMP_ISD_HAS_CGAL
489 
490 IMP_ISD_HAS_HDF5 = _IMP_example.IMP_ISD_HAS_HDF5
491 
492 IMP_ISD_HAS_NUMPY = _IMP_example.IMP_ISD_HAS_NUMPY
493 
494 IMP_ISD_HAS_PYTHON_IHM = _IMP_example.IMP_ISD_HAS_PYTHON_IHM
495 
496 IMPISD_SHOW_WARNINGS = _IMP_example.IMPISD_SHOW_WARNINGS
497 
498 import IMP.isd
499 IMP_RMF_HAS_IMP_CGAL = _IMP_example.IMP_RMF_HAS_IMP_CGAL
500 
501 IMP_RMF_HAS_IMP_EM = _IMP_example.IMP_RMF_HAS_IMP_EM
502 
503 IMP_RMF_HAS_IMP_SAXS = _IMP_example.IMP_RMF_HAS_IMP_SAXS
504 
505 IMP_RMF_HAS_IMP_SCORE_FUNCTOR = _IMP_example.IMP_RMF_HAS_IMP_SCORE_FUNCTOR
506 
507 IMP_RMF_HAS_IMP_STATISTICS = _IMP_example.IMP_RMF_HAS_IMP_STATISTICS
508 
509 IMP_RMF_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_RMF_HAS_BOOST_FILESYSTEM
510 
511 IMP_RMF_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_RMF_HAS_BOOST_PROGRAMOPTIONS
512 
513 IMP_RMF_HAS_BOOST_RANDOM = _IMP_example.IMP_RMF_HAS_BOOST_RANDOM
514 
515 IMP_RMF_HAS_BOOST_REGEX = _IMP_example.IMP_RMF_HAS_BOOST_REGEX
516 
517 IMP_RMF_HAS_BOOST_SYSTEM = _IMP_example.IMP_RMF_HAS_BOOST_SYSTEM
518 
519 IMP_RMF_HAS_CGAL = _IMP_example.IMP_RMF_HAS_CGAL
520 
521 IMP_RMF_HAS_HDF5 = _IMP_example.IMP_RMF_HAS_HDF5
522 
523 IMP_RMF_HAS_NUMPY = _IMP_example.IMP_RMF_HAS_NUMPY
524 
525 IMP_RMF_HAS_PYTHON_IHM = _IMP_example.IMP_RMF_HAS_PYTHON_IHM
526 
527 IMPRMF_SHOW_WARNINGS = _IMP_example.IMPRMF_SHOW_WARNINGS
528 
529 import IMP.rmf
530 import RMF
531 IMP_DOMINO_HAS_IMP_ATOM = _IMP_example.IMP_DOMINO_HAS_IMP_ATOM
532 
533 IMP_DOMINO_HAS_IMP_CGAL = _IMP_example.IMP_DOMINO_HAS_IMP_CGAL
534 
535 IMP_DOMINO_HAS_IMP_EM = _IMP_example.IMP_DOMINO_HAS_IMP_EM
536 
537 IMP_DOMINO_HAS_IMP_ISD = _IMP_example.IMP_DOMINO_HAS_IMP_ISD
538 
539 IMP_DOMINO_HAS_IMP_KERNEL = _IMP_example.IMP_DOMINO_HAS_IMP_KERNEL
540 
541 IMP_DOMINO_HAS_IMP_RMF = _IMP_example.IMP_DOMINO_HAS_IMP_RMF
542 
543 IMP_DOMINO_HAS_IMP_SAXS = _IMP_example.IMP_DOMINO_HAS_IMP_SAXS
544 
545 IMP_DOMINO_HAS_IMP_SCORE_FUNCTOR = _IMP_example.IMP_DOMINO_HAS_IMP_SCORE_FUNCTOR
546 
547 IMP_DOMINO_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_DOMINO_HAS_BOOST_FILESYSTEM
548 
549 IMP_DOMINO_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_DOMINO_HAS_BOOST_PROGRAMOPTIONS
550 
551 IMP_DOMINO_HAS_BOOST_RANDOM = _IMP_example.IMP_DOMINO_HAS_BOOST_RANDOM
552 
553 IMP_DOMINO_HAS_BOOST_REGEX = _IMP_example.IMP_DOMINO_HAS_BOOST_REGEX
554 
555 IMP_DOMINO_HAS_BOOST_SYSTEM = _IMP_example.IMP_DOMINO_HAS_BOOST_SYSTEM
556 
557 IMP_DOMINO_HAS_CGAL = _IMP_example.IMP_DOMINO_HAS_CGAL
558 
559 IMP_DOMINO_HAS_HDF5 = _IMP_example.IMP_DOMINO_HAS_HDF5
560 
561 IMP_DOMINO_HAS_NUMPY = _IMP_example.IMP_DOMINO_HAS_NUMPY
562 
563 IMP_DOMINO_HAS_RMF = _IMP_example.IMP_DOMINO_HAS_RMF
564 
565 IMP_DOMINO_HAS_PYTHON_IHM = _IMP_example.IMP_DOMINO_HAS_PYTHON_IHM
566 
567 IMPDOMINO_SHOW_WARNINGS = _IMP_example.IMPDOMINO_SHOW_WARNINGS
568 
569 import RMF_HDF5
570 import IMP.domino
571 IMP_EXAMPLE_HAS_IMP_ALGEBRA = _IMP_example.IMP_EXAMPLE_HAS_IMP_ALGEBRA
572 
573 IMP_EXAMPLE_HAS_IMP_CGAL = _IMP_example.IMP_EXAMPLE_HAS_IMP_CGAL
574 
575 IMP_EXAMPLE_HAS_IMP_DISPLAY = _IMP_example.IMP_EXAMPLE_HAS_IMP_DISPLAY
576 
577 IMP_EXAMPLE_HAS_IMP_EM = _IMP_example.IMP_EXAMPLE_HAS_IMP_EM
578 
579 IMP_EXAMPLE_HAS_IMP_ISD = _IMP_example.IMP_EXAMPLE_HAS_IMP_ISD
580 
581 IMP_EXAMPLE_HAS_IMP_KERNEL = _IMP_example.IMP_EXAMPLE_HAS_IMP_KERNEL
582 
583 IMP_EXAMPLE_HAS_IMP_RMF = _IMP_example.IMP_EXAMPLE_HAS_IMP_RMF
584 
585 IMP_EXAMPLE_HAS_IMP_SAXS = _IMP_example.IMP_EXAMPLE_HAS_IMP_SAXS
586 
587 IMP_EXAMPLE_HAS_IMP_SCORE_FUNCTOR = _IMP_example.IMP_EXAMPLE_HAS_IMP_SCORE_FUNCTOR
588 
589 IMP_EXAMPLE_HAS_IMP_STATISTICS = _IMP_example.IMP_EXAMPLE_HAS_IMP_STATISTICS
590 
591 IMP_EXAMPLE_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_EXAMPLE_HAS_BOOST_FILESYSTEM
592 
593 IMP_EXAMPLE_HAS_BOOST_GRAPH = _IMP_example.IMP_EXAMPLE_HAS_BOOST_GRAPH
594 
595 IMP_EXAMPLE_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_EXAMPLE_HAS_BOOST_PROGRAMOPTIONS
596 
597 IMP_EXAMPLE_HAS_BOOST_RANDOM = _IMP_example.IMP_EXAMPLE_HAS_BOOST_RANDOM
598 
599 IMP_EXAMPLE_HAS_BOOST_REGEX = _IMP_example.IMP_EXAMPLE_HAS_BOOST_REGEX
600 
601 IMP_EXAMPLE_HAS_BOOST_SYSTEM = _IMP_example.IMP_EXAMPLE_HAS_BOOST_SYSTEM
602 
603 IMP_EXAMPLE_HAS_CGAL = _IMP_example.IMP_EXAMPLE_HAS_CGAL
604 
605 IMP_EXAMPLE_HAS_HDF5 = _IMP_example.IMP_EXAMPLE_HAS_HDF5
606 
607 IMP_EXAMPLE_HAS_NUMPY = _IMP_example.IMP_EXAMPLE_HAS_NUMPY
608 
609 IMP_EXAMPLE_HAS_RMF = _IMP_example.IMP_EXAMPLE_HAS_RMF
610 
611 IMP_EXAMPLE_HAS_PYTHON_IHM = _IMP_example.IMP_EXAMPLE_HAS_PYTHON_IHM
612 
613 IMP_EXAMPLE_HAS_EXAMPLEDEPENDENCY = _IMP_example.IMP_EXAMPLE_HAS_EXAMPLEDEPENDENCY
614 
615 IMPEXAMPLE_SHOW_WARNINGS = _IMP_example.IMPEXAMPLE_SHOW_WARNINGS
616 
617 
618 _object_types.append("ExampleRestraint")
619 
620 
621 def _object_cast_to_ExampleRestraint(o):
622  r"""_object_cast_to_ExampleRestraint(Object o) -> ExampleRestraint"""
623  return _IMP_example._object_cast_to_ExampleRestraint(o)
624 
625 def ExampleDecorators(l=[]):
626  return [ExampleDecorator(x) for x in l]
627 _plural_types.append("ExampleDecorators")
628 
629 
630 _value_types.append("ExampleDecorator")
631 
632 
633 _object_types.append("ExampleUnaryFunction")
634 
635 
636 def _object_cast_to_ExampleUnaryFunction(o):
637  r"""_object_cast_to_ExampleUnaryFunction(Object o) -> ExampleUnaryFunction"""
638  return _IMP_example._object_cast_to_ExampleUnaryFunction(o)
639 
640 _object_types.append("ExampleSingletonModifier")
641 
642 
643 def _object_cast_to_ExampleSingletonModifier(o):
644  r"""_object_cast_to_ExampleSingletonModifier(Object o) -> ExampleSingletonModifier"""
645  return _IMP_example._object_cast_to_ExampleSingletonModifier(o)
646 
647 _object_types.append("ExamplePairScore")
648 
649 
650 def _object_cast_to_ExamplePairScore(o):
651  r"""_object_cast_to_ExamplePairScore(Object o) -> ExamplePairScore"""
652  return _IMP_example._object_cast_to_ExamplePairScore(o)
653 
654 _object_types.append("ExampleSubsetFilterTable")
655 
656 
657 def _object_cast_to_ExampleSubsetFilterTable(o):
658  r"""_object_cast_to_ExampleSubsetFilterTable(Object o) -> ExampleSubsetFilterTable"""
659  return _IMP_example._object_cast_to_ExampleSubsetFilterTable(o)
660 
661 _object_types.append("ExampleConstraint")
662 
663 
664 def _object_cast_to_ExampleConstraint(o):
665  r"""_object_cast_to_ExampleConstraint(Object o) -> ExampleConstraint"""
666  return _IMP_example._object_cast_to_ExampleConstraint(o)
667 
668 _object_types.append("ExampleObject")
669 
670 
671 def _object_cast_to_ExampleObject(o):
672  r"""_object_cast_to_ExampleObject(Object o) -> ExampleObject"""
673  return _IMP_example._object_cast_to_ExampleObject(o)
674 
675 ExampleTemplateClass3Ds=list
676 _plural_types.append("ExampleTemplateClass3Ds")
677 _value_types.append("ExampleTemplateClass3D")
678 
679 
680 def create_model_and_particles():
681  m = IMP.Model()
684  IMP.algebra.Vector3D(10,10,10))
685  for i in range(0,100):
686  p = m.add_particle("p")
687  sc.add(p)
690  d.set_coordinates_are_optimized(True)
691  return (m, sc)
692 
693 
694 
696  """An example restraint written in Python.
697  This should be functionally equivalent to the C++ ExampleRestraint.
698  """
699  def __init__(self, m, p, k):
700  IMP.Restraint.__init__(self, m, "PythonExampleRestraint%1%")
701  self.p, self.k = p, k
702 
703  def do_add_score_and_derivatives(self, sa):
704  d = IMP.core.XYZ(self.get_model(), self.p)
705  score = .5 * self.k * d.get_z() * d.get_z()
706  if sa.get_derivative_accumulator():
707  deriv = self.k * d.get_z()
708  d.add_to_derivative(2, deriv, sa.get_derivative_accumulator())
709  sa.add_score(score)
710 
711  def do_get_inputs(self):
712  return [self.get_model().get_particle(self.p)]
713 
714 
715 
716 
718  """An example PairScore written in Python.
719  This should be functionally equivalent to the C++ ExamplePairScore.
720  """
721  def __init__(self, x0, k):
722  IMP.PairScore.__init__(self)
723  self.x0, self.k = x0, k
724 
725  def evaluate_index(self, m, pip, da):
726  d0 = IMP.core.XYZ(m, pip[0])
727  d1 = IMP.core.XYZ(m, pip[1])
728  diff = (d0.get_coordinates()
729  - d1.get_coordinates()).get_magnitude() - self.x0
730  score = .5 * self.k * diff * diff
731  if da:
732 # derivatives are requested
733  delta = d0.get_coordinates() - d1.get_coordinates()
734  udelta = delta.get_unit_vector()
735  dv = self.k * diff
736  d0.add_to_derivatives(udelta * dv, da)
737  d1.add_to_derivatives(-udelta * dv, da)
738  return score
739 
740  def do_get_inputs(self, m, pis):
741  return IMP.get_particles(m, pis)
742 
743 
744 
745 
747  """An example UnaryFunction written in Python.
748  This should be functionally equivalent to the C++ ExampleUnaryFunction.
749  """
750  def __init__(self, center, k):
751  IMP.UnaryFunction.__init__(self)
752  self.center, self.k = center, k
753 
754  def evaluate_with_derivative(self, feature):
755  return (self.evaluate(feature), self.k * (feature - self.center))
756 
757  def evaluate(self, feature):
758  return .5 * self.k * (feature - self.center) * (feature - self.center)
759 
760 
761 
762 
764  """An example Constraint written in Python.
765  This should be functionally equivalent to the C++ ExampleConstraint.
766  """
767 
768  k = None
769 
770  def __init__(self, p):
771  IMP.Constraint.__init__(self, p.get_model(), "ExampleConstraint%1%")
772  self.p = p
773  if self.k is None:
774  PythonExampleConstraint.k = IMP.IntKey("Constraint key")
775  if not p.has_attribute(self.k):
776  p.add_attribute(self.k, 0)
777 
778  def do_update_attributes(self):
779  self.p.set_value(self.k, self.p.get_value(self.k) + 1)
780 
781  def do_update_derivatives(self, da):
782  pass
783 
784  def do_get_inputs(self):
785  return [self.p]
786 
787  def do_get_outputs(self):
788  return [self.p]
789 
790 
791 
792 
794  """An example SingletonModifier written in Python.
795  This should be functionally equivalent to the C++
796  ExampleSingletonModifier.
797  """
798 
799  def __init__(self, bb):
800  IMP.SingletonModifier.__init__(self, "ExampleSingletonModifier%1%")
801  self.bb = bb
802 
803  def apply_index(self, m, pi):
804  d = IMP.core.XYZ(m, pi)
805  for i in range(3):
806 # shift the coordinate until it is in the box
807  while d.get_coordinate(i) < self.bb.get_corner(0)[i]:
808  d.set_coordinate(i,d.get_coordinate(i) + \
809  (self.bb.get_corner(1)[i] - self.bb.get_corner(0)[i]))
810  while d.get_coordinate(i) > self.bb.get_corner(1)[i]:
811  d.set_coordinate(i,d.get_coordinate(i) - \
812  (self.bb.get_corner(1)[i] - self.bb.get_corner(0)[i]))
813 
814  def do_get_inputs(self, m, pis):
815  return IMP.get_particles(m, pis)
816 
817  def do_get_outputs(self, m, pis):
818  return self.do_get_inputs(m, pis)
819 
820 
822  r"""Proxy of C++ IMP::example::ExampleRestraint class."""
823 
824  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
825 
826  def __init__(self, *args):
827  r"""
828  __init__(ExampleRestraint self, Model m, ParticleIndex p, double k) -> ExampleRestraint
829  __init__(ExampleRestraint self) -> ExampleRestraint
830  """
831  _IMP_example.ExampleRestraint_swiginit(self, _IMP_example.new_ExampleRestraint(*args))
832 
833  def do_add_score_and_derivatives(self, sa):
834  r"""do_add_score_and_derivatives(ExampleRestraint self, ScoreAccumulator sa)"""
835  return _IMP_example.ExampleRestraint_do_add_score_and_derivatives(self, sa)
836 
837  def do_get_inputs(self):
838  r"""do_get_inputs(ExampleRestraint self) -> IMP::ModelObjectsTemp"""
839  return _IMP_example.ExampleRestraint_do_get_inputs(self)
840 
841  def get_version_info(self):
842  r"""get_version_info(ExampleRestraint self) -> VersionInfo"""
843  return _IMP_example.ExampleRestraint_get_version_info(self)
844  __swig_destroy__ = _IMP_example.delete_ExampleRestraint
845 
846  def __str__(self):
847  r"""__str__(ExampleRestraint self) -> std::string"""
848  return _IMP_example.ExampleRestraint___str__(self)
849 
850  def __repr__(self):
851  r"""__repr__(ExampleRestraint self) -> std::string"""
852  return _IMP_example.ExampleRestraint___repr__(self)
853 
854  @staticmethod
855  def get_from(o):
856  return _object_cast_to_ExampleRestraint(o)
857 
858 
859  def _get_as_binary(self):
860  r"""_get_as_binary(ExampleRestraint self) -> PyObject *"""
861  return _IMP_example.ExampleRestraint__get_as_binary(self)
862 
863  def _set_from_binary(self, p):
864  r"""_set_from_binary(ExampleRestraint self, PyObject * p)"""
865  return _IMP_example.ExampleRestraint__set_from_binary(self, p)
866 
867  def __getstate__(self):
868  p = self._get_as_binary()
869  if len(self.__dict__) > 1:
870  d = self.__dict__.copy()
871  del d['this']
872  p = (d, p)
873  return p
874 
875  def __setstate__(self, p):
876  if not hasattr(self, 'this'):
877  self.__init__()
878  if isinstance(p, tuple):
879  d, p = p
880  self.__dict__.update(d)
881  return self._set_from_binary(p)
882 
883 
884 # Register ExampleRestraint in _IMP_example:
885 _IMP_example.ExampleRestraint_swigregister(ExampleRestraint)
887  r"""Proxy of C++ IMP::example::ExampleDecorator class."""
888 
889  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
890 
891  def get_decorator_name(self):
892  r"""get_decorator_name(ExampleDecorator self) -> std::string"""
893  return _IMP_example.ExampleDecorator_get_decorator_name(self)
894 
895  def set_decorator_name(self, nm):
896  r"""set_decorator_name(ExampleDecorator self, std::string nm)"""
897  return _IMP_example.ExampleDecorator_set_decorator_name(self, nm)
898 
899  def __init__(self, *args):
900  r"""
901  __init__(ExampleDecorator self) -> ExampleDecorator
902  __init__(ExampleDecorator self, Model m, ParticleIndex id) -> ExampleDecorator
903  __init__(ExampleDecorator self, _ParticleAdaptor d) -> ExampleDecorator
904  """
905  _IMP_example.ExampleDecorator_swiginit(self, _IMP_example.new_ExampleDecorator(*args))
906 
907  @staticmethod
908  def get_is_setup(*args):
909  r"""
910  get_is_setup(Model m, ParticleIndex pi) -> bool
911  get_is_setup(_ParticleAdaptor p) -> bool
912  """
913  return _IMP_example.ExampleDecorator_get_is_setup(*args)
914 
915  def show(self, *args):
916  r"""show(ExampleDecorator self, _ostream out=std::cout)"""
917  return _IMP_example.ExampleDecorator_show(self, *args)
918 
919  @staticmethod
920  def setup_particle(*args):
921  r"""
922  setup_particle(Model m, ParticleIndex pi, std::string name) -> ExampleDecorator
923  setup_particle(_ParticleAdaptor pa, std::string name) -> ExampleDecorator
924  """
925  return _IMP_example.ExampleDecorator_setup_particle(*args)
926 
927  def add_attribute(self, *args):
928  r"""
929  add_attribute(ExampleDecorator self, FloatKey k, IMP::Float v, bool opt)
930  add_attribute(ExampleDecorator self, FloatKey a0, IMP::Float a1)
931  add_attribute(ExampleDecorator self, IntKey a0, IMP::Int a1)
932  add_attribute(ExampleDecorator self, FloatsKey a0, IMP::Floats a1)
933  add_attribute(ExampleDecorator self, IntsKey a0, IMP::Ints a1)
934  add_attribute(ExampleDecorator self, StringKey a0, IMP::String a1)
935  add_attribute(ExampleDecorator self, ParticleIndexKey a0, Particle a1)
936  add_attribute(ExampleDecorator self, ObjectKey a0, Object a1)
937  add_attribute(ExampleDecorator self, SparseFloatKey a0, IMP::Float a1)
938  add_attribute(ExampleDecorator self, SparseIntKey a0, IMP::Int a1)
939  add_attribute(ExampleDecorator self, SparseStringKey a0, IMP::String a1)
940  add_attribute(ExampleDecorator self, SparseParticleIndexKey a0, ParticleIndex a1)
941  """
942  return _IMP_example.ExampleDecorator_add_attribute(self, *args)
943 
944  def get_value(self, *args):
945  r"""
946  get_value(ExampleDecorator self, FloatKey a0) -> IMP::Float
947  get_value(ExampleDecorator self, IntKey a0) -> IMP::Int
948  get_value(ExampleDecorator self, FloatsKey a0) -> IMP::Floats
949  get_value(ExampleDecorator self, IntsKey a0) -> IMP::Ints
950  get_value(ExampleDecorator self, StringKey a0) -> IMP::String
951  get_value(ExampleDecorator self, ParticleIndexKey a0) -> Particle
952  get_value(ExampleDecorator self, ObjectKey a0) -> Object
953  get_value(ExampleDecorator self, SparseFloatKey a0) -> IMP::Float
954  get_value(ExampleDecorator self, SparseIntKey a0) -> IMP::Int
955  get_value(ExampleDecorator self, SparseStringKey a0) -> IMP::String
956  get_value(ExampleDecorator self, SparseParticleIndexKey a0) -> ParticleIndex
957  """
958  return _IMP_example.ExampleDecorator_get_value(self, *args)
959 
960  def set_value(self, *args):
961  r"""
962  set_value(ExampleDecorator self, FloatKey a0, IMP::Float a1)
963  set_value(ExampleDecorator self, IntKey a0, IMP::Int a1)
964  set_value(ExampleDecorator self, FloatsKey a0, IMP::Floats a1)
965  set_value(ExampleDecorator self, IntsKey a0, IMP::Ints a1)
966  set_value(ExampleDecorator self, StringKey a0, IMP::String a1)
967  set_value(ExampleDecorator self, ParticleIndexKey a0, Particle a1)
968  set_value(ExampleDecorator self, ObjectKey a0, Object a1)
969  set_value(ExampleDecorator self, SparseFloatKey a0, IMP::Float a1)
970  set_value(ExampleDecorator self, SparseIntKey a0, IMP::Int a1)
971  set_value(ExampleDecorator self, SparseStringKey a0, IMP::String a1)
972  set_value(ExampleDecorator self, SparseParticleIndexKey a0, ParticleIndex a1)
973  """
974  return _IMP_example.ExampleDecorator_set_value(self, *args)
975 
976  def remove_attribute(self, *args):
977  r"""
978  remove_attribute(ExampleDecorator self, FloatKey a0)
979  remove_attribute(ExampleDecorator self, IntKey a0)
980  remove_attribute(ExampleDecorator self, FloatsKey a0)
981  remove_attribute(ExampleDecorator self, IntsKey a0)
982  remove_attribute(ExampleDecorator self, StringKey a0)
983  remove_attribute(ExampleDecorator self, ParticleIndexKey a0)
984  remove_attribute(ExampleDecorator self, ObjectKey a0)
985  remove_attribute(ExampleDecorator self, SparseFloatKey a0)
986  remove_attribute(ExampleDecorator self, SparseIntKey a0)
987  remove_attribute(ExampleDecorator self, SparseStringKey a0)
988  remove_attribute(ExampleDecorator self, SparseParticleIndexKey a0)
989  """
990  return _IMP_example.ExampleDecorator_remove_attribute(self, *args)
991 
992  def has_attribute(self, *args):
993  r"""
994  has_attribute(ExampleDecorator self, FloatKey a0) -> bool
995  has_attribute(ExampleDecorator self, IntKey a0) -> bool
996  has_attribute(ExampleDecorator self, FloatsKey a0) -> bool
997  has_attribute(ExampleDecorator self, IntsKey a0) -> bool
998  has_attribute(ExampleDecorator self, StringKey a0) -> bool
999  has_attribute(ExampleDecorator self, ParticleIndexKey a0) -> bool
1000  has_attribute(ExampleDecorator self, ObjectKey a0) -> bool
1001  has_attribute(ExampleDecorator self, SparseFloatKey a0) -> bool
1002  has_attribute(ExampleDecorator self, SparseIntKey a0) -> bool
1003  has_attribute(ExampleDecorator self, SparseStringKey a0) -> bool
1004  has_attribute(ExampleDecorator self, SparseParticleIndexKey a0) -> bool
1005  """
1006  return _IMP_example.ExampleDecorator_has_attribute(self, *args)
1007 
1008  def get_derivative(self, a0):
1009  r"""get_derivative(ExampleDecorator self, FloatKey a0) -> double"""
1010  return _IMP_example.ExampleDecorator_get_derivative(self, a0)
1011 
1012  def get_name(self):
1013  r"""get_name(ExampleDecorator self) -> std::string"""
1014  return _IMP_example.ExampleDecorator_get_name(self)
1015 
1016  def clear_caches(self):
1017  r"""clear_caches(ExampleDecorator self)"""
1018  return _IMP_example.ExampleDecorator_clear_caches(self)
1019 
1020  def set_name(self, a0):
1021  r"""set_name(ExampleDecorator self, std::string a0)"""
1022  return _IMP_example.ExampleDecorator_set_name(self, a0)
1023 
1024  def set_check_level(self, a0):
1025  r"""set_check_level(ExampleDecorator self, IMP::CheckLevel a0)"""
1026  return _IMP_example.ExampleDecorator_set_check_level(self, a0)
1027 
1028  def add_to_derivative(self, a0, a1, a2):
1029  r"""add_to_derivative(ExampleDecorator self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
1030  return _IMP_example.ExampleDecorator_add_to_derivative(self, a0, a1, a2)
1031 
1032  def set_is_optimized(self, a0, a1):
1033  r"""set_is_optimized(ExampleDecorator self, FloatKey a0, bool a1)"""
1034  return _IMP_example.ExampleDecorator_set_is_optimized(self, a0, a1)
1035 
1036  def get_is_optimized(self, a0):
1037  r"""get_is_optimized(ExampleDecorator self, FloatKey a0) -> bool"""
1038  return _IMP_example.ExampleDecorator_get_is_optimized(self, a0)
1039 
1040  def get_check_level(self):
1041  r"""get_check_level(ExampleDecorator self) -> IMP::CheckLevel"""
1042  return _IMP_example.ExampleDecorator_get_check_level(self)
1043 
1044  def __eq__(self, *args):
1045  r"""
1046  __eq__(ExampleDecorator self, ExampleDecorator o) -> bool
1047  __eq__(ExampleDecorator self, Particle d) -> bool
1048  """
1049  return _IMP_example.ExampleDecorator___eq__(self, *args)
1050 
1051  def __ne__(self, *args):
1052  r"""
1053  __ne__(ExampleDecorator self, ExampleDecorator o) -> bool
1054  __ne__(ExampleDecorator self, Particle d) -> bool
1055  """
1056  return _IMP_example.ExampleDecorator___ne__(self, *args)
1057 
1058  def __le__(self, *args):
1059  r"""
1060  __le__(ExampleDecorator self, ExampleDecorator o) -> bool
1061  __le__(ExampleDecorator self, Particle d) -> bool
1062  """
1063  return _IMP_example.ExampleDecorator___le__(self, *args)
1064 
1065  def __lt__(self, *args):
1066  r"""
1067  __lt__(ExampleDecorator self, ExampleDecorator o) -> bool
1068  __lt__(ExampleDecorator self, Particle d) -> bool
1069  """
1070  return _IMP_example.ExampleDecorator___lt__(self, *args)
1071 
1072  def __ge__(self, *args):
1073  r"""
1074  __ge__(ExampleDecorator self, ExampleDecorator o) -> bool
1075  __ge__(ExampleDecorator self, Particle d) -> bool
1076  """
1077  return _IMP_example.ExampleDecorator___ge__(self, *args)
1078 
1079  def __gt__(self, *args):
1080  r"""
1081  __gt__(ExampleDecorator self, ExampleDecorator o) -> bool
1082  __gt__(ExampleDecorator self, Particle d) -> bool
1083  """
1084  return _IMP_example.ExampleDecorator___gt__(self, *args)
1085 
1086  def __hash__(self):
1087  r"""__hash__(ExampleDecorator self) -> std::size_t"""
1088  return _IMP_example.ExampleDecorator___hash__(self)
1089 
1090  def __str__(self):
1091  r"""__str__(ExampleDecorator self) -> std::string"""
1092  return _IMP_example.ExampleDecorator___str__(self)
1093 
1094  def __repr__(self):
1095  r"""__repr__(ExampleDecorator self) -> std::string"""
1096  return _IMP_example.ExampleDecorator___repr__(self)
1097 
1098  def _get_as_binary(self):
1099  r"""_get_as_binary(ExampleDecorator self) -> PyObject *"""
1100  return _IMP_example.ExampleDecorator__get_as_binary(self)
1101 
1102  def _set_from_binary(self, p):
1103  r"""_set_from_binary(ExampleDecorator self, PyObject * p)"""
1104  return _IMP_example.ExampleDecorator__set_from_binary(self, p)
1105 
1106  def __getstate__(self):
1107  p = self._get_as_binary()
1108  if len(self.__dict__) > 1:
1109  d = self.__dict__.copy()
1110  del d['this']
1111  p = (d, p)
1112  return p
1113 
1114  def __setstate__(self, p):
1115  if not hasattr(self, 'this'):
1116  self.__init__()
1117  if isinstance(p, tuple):
1118  d, p = p
1119  self.__dict__.update(d)
1120  return self._set_from_binary(p)
1121 
1122  __swig_destroy__ = _IMP_example.delete_ExampleDecorator
1123 
1124 # Register ExampleDecorator in _IMP_example:
1125 _IMP_example.ExampleDecorator_swigregister(ExampleDecorator)
1126 
1127 def __lshift__(out, n):
1128  r"""__lshift__(_ostream out, ExampleDecorator n) -> _ostream"""
1129  return _IMP_example.__lshift__(out, n)
1131  r"""Proxy of C++ IMP::example::ExampleUnaryFunction class."""
1132 
1133  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
1134 
1135  def __init__(self, *args):
1136  r"""
1137  __init__(ExampleUnaryFunction self, IMP::Float center, IMP::Float k) -> ExampleUnaryFunction
1138  __init__(ExampleUnaryFunction self) -> ExampleUnaryFunction
1139  """
1140  _IMP_example.ExampleUnaryFunction_swiginit(self, _IMP_example.new_ExampleUnaryFunction(*args))
1141 
1142  def get_version_info(self):
1143  r"""get_version_info(ExampleUnaryFunction self) -> VersionInfo"""
1144  return _IMP_example.ExampleUnaryFunction_get_version_info(self)
1145  __swig_destroy__ = _IMP_example.delete_ExampleUnaryFunction
1146 
1147  def __str__(self):
1148  r"""__str__(ExampleUnaryFunction self) -> std::string"""
1149  return _IMP_example.ExampleUnaryFunction___str__(self)
1150 
1151  def __repr__(self):
1152  r"""__repr__(ExampleUnaryFunction self) -> std::string"""
1153  return _IMP_example.ExampleUnaryFunction___repr__(self)
1154 
1155  @staticmethod
1156  def get_from(o):
1157  return _object_cast_to_ExampleUnaryFunction(o)
1158 
1159 
1160  def _get_as_binary(self):
1161  r"""_get_as_binary(ExampleUnaryFunction self) -> PyObject *"""
1162  return _IMP_example.ExampleUnaryFunction__get_as_binary(self)
1163 
1164  def _set_from_binary(self, p):
1165  r"""_set_from_binary(ExampleUnaryFunction self, PyObject * p)"""
1166  return _IMP_example.ExampleUnaryFunction__set_from_binary(self, p)
1167 
1168  def __getstate__(self):
1169  p = self._get_as_binary()
1170  if len(self.__dict__) > 1:
1171  d = self.__dict__.copy()
1172  del d['this']
1173  p = (d, p)
1174  return p
1175 
1176  def __setstate__(self, p):
1177  if not hasattr(self, 'this'):
1178  self.__init__()
1179  if isinstance(p, tuple):
1180  d, p = p
1181  self.__dict__.update(d)
1182  return self._set_from_binary(p)
1183 
1184 
1185 # Register ExampleUnaryFunction in _IMP_example:
1186 _IMP_example.ExampleUnaryFunction_swigregister(ExampleUnaryFunction)
1187 class ExampleObject(IMP.Object):
1188  r"""Proxy of C++ IMP::example::ExampleObject class."""
1189 
1190  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
1191 
1192  def __init__(self, *args):
1193  r"""
1194  __init__(ExampleObject self, IMP::Floats const & data) -> ExampleObject
1195  __init__(ExampleObject self) -> ExampleObject
1196  """
1197  _IMP_example.ExampleObject_swiginit(self, _IMP_example.new_ExampleObject(*args))
1198 
1199  def get_data(self, i):
1200  r"""get_data(ExampleObject self, unsigned int i) -> double"""
1201  return _IMP_example.ExampleObject_get_data(self, i)
1202 
1203  def get_version_info(self):
1204  r"""get_version_info(ExampleObject self) -> VersionInfo"""
1205  return _IMP_example.ExampleObject_get_version_info(self)
1206  __swig_destroy__ = _IMP_example.delete_ExampleObject
1207 
1208  def __str__(self):
1209  r"""__str__(ExampleObject self) -> std::string"""
1210  return _IMP_example.ExampleObject___str__(self)
1211 
1212  def __repr__(self):
1213  r"""__repr__(ExampleObject self) -> std::string"""
1214  return _IMP_example.ExampleObject___repr__(self)
1215 
1216  @staticmethod
1217  def get_from(o):
1218  return _object_cast_to_ExampleObject(o)
1219 
1220 
1221  def _get_as_binary(self):
1222  r"""_get_as_binary(ExampleObject self) -> PyObject *"""
1223  return _IMP_example.ExampleObject__get_as_binary(self)
1224 
1225  def _set_from_binary(self, p):
1226  r"""_set_from_binary(ExampleObject self, PyObject * p)"""
1227  return _IMP_example.ExampleObject__set_from_binary(self, p)
1228 
1229  def __getstate__(self):
1230  p = self._get_as_binary()
1231  if len(self.__dict__) > 1:
1232  d = self.__dict__.copy()
1233  del d['this']
1234  p = (d, p)
1235  return p
1236 
1237  def __setstate__(self, p):
1238  if not hasattr(self, 'this'):
1239  self.__init__()
1240  if isinstance(p, tuple):
1241  d, p = p
1242  self.__dict__.update(d)
1243  return self._set_from_binary(p)
1244 
1245 
1246 # Register ExampleObject in _IMP_example:
1247 _IMP_example.ExampleObject_swigregister(ExampleObject)
1249  r"""Proxy of C++ IMP::example::ExampleSingletonModifier class."""
1250 
1251  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
1252 
1253  def __init__(self, *args):
1254  r"""
1255  __init__(ExampleSingletonModifier self, BoundingBox3D bb) -> ExampleSingletonModifier
1256  __init__(ExampleSingletonModifier self) -> ExampleSingletonModifier
1257  """
1258  _IMP_example.ExampleSingletonModifier_swiginit(self, _IMP_example.new_ExampleSingletonModifier(*args))
1259 
1260  def do_get_inputs(self, m, pis):
1261  r"""do_get_inputs(ExampleSingletonModifier self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
1262  return _IMP_example.ExampleSingletonModifier_do_get_inputs(self, m, pis)
1263 
1264  def do_get_outputs(self, m, pis):
1265  r"""do_get_outputs(ExampleSingletonModifier self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
1266  return _IMP_example.ExampleSingletonModifier_do_get_outputs(self, m, pis)
1267 
1268  def get_version_info(self):
1269  r"""get_version_info(ExampleSingletonModifier self) -> VersionInfo"""
1270  return _IMP_example.ExampleSingletonModifier_get_version_info(self)
1271  __swig_destroy__ = _IMP_example.delete_ExampleSingletonModifier
1272 
1273  def __str__(self):
1274  r"""__str__(ExampleSingletonModifier self) -> std::string"""
1275  return _IMP_example.ExampleSingletonModifier___str__(self)
1276 
1277  def __repr__(self):
1278  r"""__repr__(ExampleSingletonModifier self) -> std::string"""
1279  return _IMP_example.ExampleSingletonModifier___repr__(self)
1280 
1281  @staticmethod
1282  def get_from(o):
1283  return _object_cast_to_ExampleSingletonModifier(o)
1284 
1285 
1286  def _get_as_binary(self):
1287  r"""_get_as_binary(ExampleSingletonModifier self) -> PyObject *"""
1288  return _IMP_example.ExampleSingletonModifier__get_as_binary(self)
1289 
1290  def _set_from_binary(self, p):
1291  r"""_set_from_binary(ExampleSingletonModifier self, PyObject * p)"""
1292  return _IMP_example.ExampleSingletonModifier__set_from_binary(self, p)
1293 
1294  def __getstate__(self):
1295  p = self._get_as_binary()
1296  if len(self.__dict__) > 1:
1297  d = self.__dict__.copy()
1298  del d['this']
1299  p = (d, p)
1300  return p
1301 
1302  def __setstate__(self, p):
1303  if not hasattr(self, 'this'):
1304  self.__init__()
1305  if isinstance(p, tuple):
1306  d, p = p
1307  self.__dict__.update(d)
1308  return self._set_from_binary(p)
1309 
1310 
1311 # Register ExampleSingletonModifier in _IMP_example:
1312 _IMP_example.ExampleSingletonModifier_swigregister(ExampleSingletonModifier)
1314  r"""Proxy of C++ IMP::example::ExamplePairScore class."""
1315 
1316  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
1317 
1318  def __init__(self, *args):
1319  r"""
1320  __init__(ExamplePairScore self, double x0, double k) -> ExamplePairScore
1321  __init__(ExamplePairScore self) -> ExamplePairScore
1322  """
1323  _IMP_example.ExamplePairScore_swiginit(self, _IMP_example.new_ExamplePairScore(*args))
1324 
1325  def do_get_inputs(self, m, pis):
1326  r"""do_get_inputs(ExamplePairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
1327  return _IMP_example.ExamplePairScore_do_get_inputs(self, m, pis)
1328 
1329  def get_version_info(self):
1330  r"""get_version_info(ExamplePairScore self) -> VersionInfo"""
1331  return _IMP_example.ExamplePairScore_get_version_info(self)
1332  __swig_destroy__ = _IMP_example.delete_ExamplePairScore
1333 
1334  def __str__(self):
1335  r"""__str__(ExamplePairScore self) -> std::string"""
1336  return _IMP_example.ExamplePairScore___str__(self)
1337 
1338  def __repr__(self):
1339  r"""__repr__(ExamplePairScore self) -> std::string"""
1340  return _IMP_example.ExamplePairScore___repr__(self)
1341 
1342  @staticmethod
1343  def get_from(o):
1344  return _object_cast_to_ExamplePairScore(o)
1345 
1346 
1347  def _get_as_binary(self):
1348  r"""_get_as_binary(ExamplePairScore self) -> PyObject *"""
1349  return _IMP_example.ExamplePairScore__get_as_binary(self)
1350 
1351  def _set_from_binary(self, p):
1352  r"""_set_from_binary(ExamplePairScore self, PyObject * p)"""
1353  return _IMP_example.ExamplePairScore__set_from_binary(self, p)
1354 
1355  def __getstate__(self):
1356  p = self._get_as_binary()
1357  if len(self.__dict__) > 1:
1358  d = self.__dict__.copy()
1359  del d['this']
1360  p = (d, p)
1361  return p
1362 
1363  def __setstate__(self, p):
1364  if not hasattr(self, 'this'):
1365  self.__init__()
1366  if isinstance(p, tuple):
1367  d, p = p
1368  self.__dict__.update(d)
1369  return self._set_from_binary(p)
1370 
1371 
1372 # Register ExamplePairScore in _IMP_example:
1373 _IMP_example.ExamplePairScore_swigregister(ExamplePairScore)
1375  r"""Proxy of C++ IMP::example::ExampleSubsetFilterTable class."""
1376 
1377  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
1378 
1379  def __init__(self, max_diff, pt):
1380  r"""__init__(ExampleSubsetFilterTable self, unsigned int max_diff, IMP::ParticlesTemp const & pt) -> ExampleSubsetFilterTable"""
1381  _IMP_example.ExampleSubsetFilterTable_swiginit(self, _IMP_example.new_ExampleSubsetFilterTable(max_diff, pt))
1382 
1383  def get_version_info(self):
1384  r"""get_version_info(ExampleSubsetFilterTable self) -> VersionInfo"""
1385  return _IMP_example.ExampleSubsetFilterTable_get_version_info(self)
1386  __swig_destroy__ = _IMP_example.delete_ExampleSubsetFilterTable
1387 
1388  def __str__(self):
1389  r"""__str__(ExampleSubsetFilterTable self) -> std::string"""
1390  return _IMP_example.ExampleSubsetFilterTable___str__(self)
1391 
1392  def __repr__(self):
1393  r"""__repr__(ExampleSubsetFilterTable self) -> std::string"""
1394  return _IMP_example.ExampleSubsetFilterTable___repr__(self)
1395 
1396  @staticmethod
1397  def get_from(o):
1398  return _object_cast_to_ExampleSubsetFilterTable(o)
1399 
1400 
1401 # Register ExampleSubsetFilterTable in _IMP_example:
1402 _IMP_example.ExampleSubsetFilterTable_swigregister(ExampleSubsetFilterTable)
1404  r"""Proxy of C++ IMP::example::ExampleConstraint class."""
1405 
1406  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
1407 
1408  def __init__(self, *args):
1409  r"""
1410  __init__(ExampleConstraint self, Particle p) -> ExampleConstraint
1411  __init__(ExampleConstraint self) -> ExampleConstraint
1412  """
1413  _IMP_example.ExampleConstraint_swiginit(self, _IMP_example.new_ExampleConstraint(*args))
1414 
1415  def do_get_inputs(self):
1416  r"""do_get_inputs(ExampleConstraint self) -> IMP::ModelObjectsTemp"""
1417  return _IMP_example.ExampleConstraint_do_get_inputs(self)
1418 
1419  def do_get_outputs(self):
1420  r"""do_get_outputs(ExampleConstraint self) -> IMP::ModelObjectsTemp"""
1421  return _IMP_example.ExampleConstraint_do_get_outputs(self)
1422 
1423  @staticmethod
1424  def get_key():
1425  r"""get_key() -> IntKey"""
1426  return _IMP_example.ExampleConstraint_get_key()
1427 
1428  def get_version_info(self):
1429  r"""get_version_info(ExampleConstraint self) -> VersionInfo"""
1430  return _IMP_example.ExampleConstraint_get_version_info(self)
1431  __swig_destroy__ = _IMP_example.delete_ExampleConstraint
1432 
1433  def __str__(self):
1434  r"""__str__(ExampleConstraint self) -> std::string"""
1435  return _IMP_example.ExampleConstraint___str__(self)
1436 
1437  def __repr__(self):
1438  r"""__repr__(ExampleConstraint self) -> std::string"""
1439  return _IMP_example.ExampleConstraint___repr__(self)
1440 
1441  @staticmethod
1442  def get_from(o):
1443  return _object_cast_to_ExampleConstraint(o)
1444 
1445 
1446  def _get_as_binary(self):
1447  r"""_get_as_binary(ExampleConstraint self) -> PyObject *"""
1448  return _IMP_example.ExampleConstraint__get_as_binary(self)
1449 
1450  def _set_from_binary(self, p):
1451  r"""_set_from_binary(ExampleConstraint self, PyObject * p)"""
1452  return _IMP_example.ExampleConstraint__set_from_binary(self, p)
1453 
1454  def __getstate__(self):
1455  p = self._get_as_binary()
1456  if len(self.__dict__) > 1:
1457  d = self.__dict__.copy()
1458  del d['this']
1459  p = (d, p)
1460  return p
1461 
1462  def __setstate__(self, p):
1463  if not hasattr(self, 'this'):
1464  self.__init__()
1465  if isinstance(p, tuple):
1466  d, p = p
1467  self.__dict__.update(d)
1468  return self._set_from_binary(p)
1469 
1470 
1471 # Register ExampleConstraint in _IMP_example:
1472 _IMP_example.ExampleConstraint_swigregister(ExampleConstraint)
1473 
1474 def get_number_of_incidences(psa, psb, point_distance):
1475  r"""get_number_of_incidences(IMP::ParticlesTemp const & psa, IMP::ParticlesTemp const & psb, double point_distance) -> unsigned int"""
1476  return _IMP_example.get_number_of_incidences(psa, psb, point_distance)
1477 
1478 def create_chain_restraint(m, ps, length_factor, k, name):
1479  r"""create_chain_restraint(Model m, IMP::ParticleIndexes const & ps, double length_factor, double k, std::string name) -> Restraint"""
1480  return _IMP_example.create_chain_restraint(m, ps, length_factor, k, name)
1481 
1482 def create_excluded_volume(m, ps, k, name):
1483  r"""create_excluded_volume(Model m, IMP::ParticleIndexes const & ps, double k, std::string name) -> Restraint"""
1484  return _IMP_example.create_excluded_volume(m, ps, k, name)
1485 class ExampleTemplateClass3D(object):
1486  r"""Proxy of C++ IMP::example::ExampleTemplateClassD< 3 > class."""
1487 
1488  thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
1489 
1490  def __init__(self, *args):
1491  r"""
1492  __init__(ExampleTemplateClass3D self) -> ExampleTemplateClass3D
1493  __init__(ExampleTemplateClass3D self, Vector3D a, Vector3D b) -> ExampleTemplateClass3D
1494  """
1495  _IMP_example.ExampleTemplateClass3D_swiginit(self, _IMP_example.new_ExampleTemplateClass3D(*args))
1496 
1497  def get_point(self, i):
1498  r"""get_point(ExampleTemplateClass3D self, unsigned int i) -> Vector3D"""
1499  return _IMP_example.ExampleTemplateClass3D_get_point(self, i)
1500 
1501  def show(self, *args):
1502  r"""show(ExampleTemplateClass3D self, _ostream out=std::cout)"""
1503  return _IMP_example.ExampleTemplateClass3D_show(self, *args)
1504 
1505  def __str__(self):
1506  r"""__str__(ExampleTemplateClass3D self) -> std::string"""
1507  return _IMP_example.ExampleTemplateClass3D___str__(self)
1508 
1509  def __repr__(self):
1510  r"""__repr__(ExampleTemplateClass3D self) -> std::string"""
1511  return _IMP_example.ExampleTemplateClass3D___repr__(self)
1512  __swig_destroy__ = _IMP_example.delete_ExampleTemplateClass3D
1513 
1514 # Register ExampleTemplateClass3D in _IMP_example:
1515 _IMP_example.ExampleTemplateClass3D_swigregister(ExampleTemplateClass3D)
1516 
1517 def get_module_version():
1518  r"""get_module_version() -> std::string const"""
1519  return _IMP_example.get_module_version()
1520 
1521 def get_example_path(fname):
1522  r"""get_example_path(std::string fname) -> std::string"""
1523  return _IMP_example.get_example_path(fname)
1524 
1525 def get_data_path(fname):
1526  r"""get_data_path(std::string fname) -> std::string"""
1527  return _IMP_example.get_data_path(fname)
1528 
1529 from . import _version_check
1530 _version_check.check_version(get_module_version())
1531 __version__ = get_module_version()
1532 
1533 
unsigned int get_number_of_incidences(const ParticlesTemp &psa, const ParticlesTemp &psb, double point_distance)
Definition: counting.h:23
A base class for modifiers of ParticlesTemp.
Abstract class for scoring object(s) of type ParticleIndexPair.
Definition: PairScore.h:44
virtual double evaluate(double feature) const
Calculate score with respect to the given feature.
Definition: UnaryFunction.h:35
An example PairScore written in Python.
An example SingletonModifier written in Python.
Various classes to hold sets of particles.
static XYZR setup_particle(Model *m, ParticleIndex pi)
Definition: XYZR.h:48
An example UnaryFunction written in Python.
Make CGAL functionality available to IMP.
A line segment templated on the dimension.
ParticlesTemp get_particles(Model *m, const ParticleIndexes &ps)
Get the particles from a list of indexes.
virtual void clear_caches()
Definition: Object.h:270
virtual ModelObjectsTemp do_get_outputs(Model *m, const ParticleIndexes &pis) const =0
Overload this method to specify the outputs.
Composable functors to implement scores via compile-time composition.
Restraint * create_excluded_volume(Model *m, const ParticleIndexes &ps, double k, std::string name)
Vector3D get_random_vector_in(const Cylinder3D &c)
Generate a random vector in a cylinder with uniform density.
Code to compute statistical measures.
Implement a constraint on the Model.
Definition: Constraint.h:49
Class for storing model, its restraints, constraints, and particles.
Definition: Model.h:86
An example simple object which is reference counted.
Definition: ExampleObject.h:31
A simple decorator which adds a name to a particle.
An example Constraint written in Python.
Common base class for heavy weight IMP objects.
Definition: Object.h:111
Store a list of ParticleIndexes.
An example restraint written in Python.
virtual ModelObjectsTemp do_get_inputs(Model *m, const ParticleIndexes &pis) const =0
Overload this method to specify the inputs.
Restrain a particle to be in the x,y plane.
Basic utilities for handling cryo-electron microscopy 3D density maps.
A decorator for a particle with x,y,z coordinates.
Definition: XYZ.h:30
Interface to specialized Particle types (e.g. atoms)
Definition: Decorator.h:119
virtual ModelObjectsTemp do_get_outputs() const =0
Basic functionality that is expected to be used by a wide variety of IMP users.
General purpose algebraic and geometric methods that are expected to be used by a wide variety of IMP...
virtual void apply_index(Model *m, ParticleIndex v) const =0
std::string get_module_version()
Return the version of this module, as a string.
virtual VersionInfo get_version_info() const
Get information about the module and version of the object.
Definition: Object.h:206
virtual DerivativePair evaluate_with_derivative(double feature) const
Calculate score and derivative with respect to the given feature.
Definition: UnaryFunction.h:50
VectorD< 3 > Vector3D
Definition: VectorD.h:408
void set_check_level(CheckLevel l)
Apply a harmonic to the distance between two particles.
Restraint * create_chain_restraint(Model *m, const ParticleIndexes &ps, double length_factor, double k, std::string name)
std::string get_example_path(std::string file_name)
Return the full path to one of this module's example files.
Model * get_model() const
Definition: ModelObject.h:64
A trivial constraint that just increments a counter.
Output IMP model data in various file formats.
Functionality for loading, creating, manipulating and scoring atomic structures.
std::string get_data_path(std::string file_name)
Return the full path to one of this module's data files.
Support for the RMF file format for storing hierarchical molecular data and markup.
Abstract single variable functor class for score functions.
Definition: UnaryFunction.h:27
virtual ModelObjectsTemp do_get_inputs() const =0
Divide-and-conquer inferential optimization in discrete space.
virtual double evaluate_index(Model *m, const ParticleIndexPair &vt, DerivativeAccumulator *da) const =0
Compute the score and the derivative if needed.
Support for small angle X-ray scattering (SAXS) data.
Inferential scoring building on methods developed as part of the Inferential Structure Determination ...
A restraint is a term in an IMP ScoringFunction.
Definition: Restraint.h:56