11 from __future__
import print_function, division, absolute_import
15 from sys
import version_info
as _swig_python_version_info
19 import builtins
as __builtin__
25 strthis =
"proxy of " + self.this.__repr__()
26 except __builtin__.Exception:
28 return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,)
31 def _swig_setattr_nondynamic_instance_variable(set):
32 def set_instance_attr(self, name, value):
34 set(self, name, value)
35 elif name ==
"thisown":
37 elif hasattr(self, name)
and isinstance(getattr(type(self), name), property):
38 set(self, name, value)
40 raise AttributeError(
"You cannot add instance attributes to %s" % self)
41 return set_instance_attr
44 def _swig_setattr_nondynamic_class_variable(set):
45 def set_class_attr(cls, name, value):
46 if hasattr(cls, name)
and not isinstance(getattr(cls, name), property):
49 raise AttributeError(
"You cannot add class attributes to %s" % cls)
53 def _swig_add_metaclass(metaclass):
54 """Class decorator for adding a metaclass to a SWIG wrapped class - a slimmed down version of six.add_metaclass"""
56 return metaclass(cls.__name__, cls.__bases__, cls.__dict__.copy())
60 class _SwigNonDynamicMeta(type):
61 """Meta class to enforce nondynamic attributes (no new attributes) for a class"""
62 __setattr__ = _swig_setattr_nondynamic_class_variable(type.__setattr__)
67 class IMP_EXAMPLE_SwigPyIterator(object):
68 r"""Proxy of C++ swig::IMP_EXAMPLE_SwigPyIterator class."""
70 thisown = property(
lambda x: x.this.own(),
lambda x, v: x.this.own(v), doc=
"The membership flag")
72 def __init__(self, *args, **kwargs):
73 raise AttributeError(
"No constructor defined - class is abstract")
75 __swig_destroy__ = _IMP_example.delete_IMP_EXAMPLE_SwigPyIterator
78 r"""value(IMP_EXAMPLE_SwigPyIterator self) -> PyObject *"""
79 return _IMP_example.IMP_EXAMPLE_SwigPyIterator_value(self)
82 r"""incr(IMP_EXAMPLE_SwigPyIterator self, size_t n=1) -> IMP_EXAMPLE_SwigPyIterator"""
83 return _IMP_example.IMP_EXAMPLE_SwigPyIterator_incr(self, n)
86 r"""decr(IMP_EXAMPLE_SwigPyIterator self, size_t n=1) -> IMP_EXAMPLE_SwigPyIterator"""
87 return _IMP_example.IMP_EXAMPLE_SwigPyIterator_decr(self, n)
89 def distance(self, x):
90 r"""distance(IMP_EXAMPLE_SwigPyIterator self, IMP_EXAMPLE_SwigPyIterator x) -> ptrdiff_t"""
91 return _IMP_example.IMP_EXAMPLE_SwigPyIterator_distance(self, x)
94 r"""equal(IMP_EXAMPLE_SwigPyIterator self, IMP_EXAMPLE_SwigPyIterator x) -> bool"""
95 return _IMP_example.IMP_EXAMPLE_SwigPyIterator_equal(self, x)
98 r"""copy(IMP_EXAMPLE_SwigPyIterator self) -> IMP_EXAMPLE_SwigPyIterator"""
99 return _IMP_example.IMP_EXAMPLE_SwigPyIterator_copy(self)
102 r"""next(IMP_EXAMPLE_SwigPyIterator self) -> PyObject *"""
103 return _IMP_example.IMP_EXAMPLE_SwigPyIterator_next(self)
106 r"""__next__(IMP_EXAMPLE_SwigPyIterator self) -> PyObject *"""
107 return _IMP_example.IMP_EXAMPLE_SwigPyIterator___next__(self)
110 r"""previous(IMP_EXAMPLE_SwigPyIterator self) -> PyObject *"""
111 return _IMP_example.IMP_EXAMPLE_SwigPyIterator_previous(self)
113 def advance(self, n):
114 r"""advance(IMP_EXAMPLE_SwigPyIterator self, ptrdiff_t n) -> IMP_EXAMPLE_SwigPyIterator"""
115 return _IMP_example.IMP_EXAMPLE_SwigPyIterator_advance(self, n)
118 r"""__eq__(IMP_EXAMPLE_SwigPyIterator self, IMP_EXAMPLE_SwigPyIterator x) -> bool"""
119 return _IMP_example.IMP_EXAMPLE_SwigPyIterator___eq__(self, x)
122 r"""__ne__(IMP_EXAMPLE_SwigPyIterator self, IMP_EXAMPLE_SwigPyIterator x) -> bool"""
123 return _IMP_example.IMP_EXAMPLE_SwigPyIterator___ne__(self, x)
125 def __iadd__(self, n):
126 r"""__iadd__(IMP_EXAMPLE_SwigPyIterator self, ptrdiff_t n) -> IMP_EXAMPLE_SwigPyIterator"""
127 return _IMP_example.IMP_EXAMPLE_SwigPyIterator___iadd__(self, n)
129 def __isub__(self, n):
130 r"""__isub__(IMP_EXAMPLE_SwigPyIterator self, ptrdiff_t n) -> IMP_EXAMPLE_SwigPyIterator"""
131 return _IMP_example.IMP_EXAMPLE_SwigPyIterator___isub__(self, n)
133 def __add__(self, n):
134 r"""__add__(IMP_EXAMPLE_SwigPyIterator self, ptrdiff_t n) -> IMP_EXAMPLE_SwigPyIterator"""
135 return _IMP_example.IMP_EXAMPLE_SwigPyIterator___add__(self, n)
137 def __sub__(self, *args):
139 __sub__(IMP_EXAMPLE_SwigPyIterator self, ptrdiff_t n) -> IMP_EXAMPLE_SwigPyIterator
140 __sub__(IMP_EXAMPLE_SwigPyIterator self, IMP_EXAMPLE_SwigPyIterator x) -> ptrdiff_t
142 return _IMP_example.IMP_EXAMPLE_SwigPyIterator___sub__(self, *args)
147 _IMP_example.IMP_EXAMPLE_SwigPyIterator_swigregister(IMP_EXAMPLE_SwigPyIterator)
154 IMP_DEBUG = _IMP_example.IMP_DEBUG
156 IMP_RELEASE = _IMP_example.IMP_RELEASE
158 IMP_SILENT = _IMP_example.IMP_SILENT
160 IMP_PROGRESS = _IMP_example.IMP_PROGRESS
162 IMP_TERSE = _IMP_example.IMP_TERSE
164 IMP_VERBOSE = _IMP_example.IMP_VERBOSE
166 IMP_MEMORY = _IMP_example.IMP_MEMORY
168 IMP_NONE = _IMP_example.IMP_NONE
170 IMP_USAGE = _IMP_example.IMP_USAGE
172 IMP_INTERNAL = _IMP_example.IMP_INTERNAL
174 IMP_KERNEL_HAS_LOG4CXX = _IMP_example.IMP_KERNEL_HAS_LOG4CXX
176 IMP_COMPILER_HAS_CEREAL_RAW_POINTER = _IMP_example.IMP_COMPILER_HAS_CEREAL_RAW_POINTER
178 IMP_COMPILER_HAS_DEBUG_VECTOR = _IMP_example.IMP_COMPILER_HAS_DEBUG_VECTOR
180 IMP_COMPILER_HAS_RANDOM_SHUFFLE = _IMP_example.IMP_COMPILER_HAS_RANDOM_SHUFFLE
182 IMP_COMPILER_HAS_THREE_WAY = _IMP_example.IMP_COMPILER_HAS_THREE_WAY
184 IMP_KERNEL_HAS_BOOST_RANDOM = _IMP_example.IMP_KERNEL_HAS_BOOST_RANDOM
186 IMP_KERNEL_HAS_NUMPY = _IMP_example.IMP_KERNEL_HAS_NUMPY
188 IMP_KERNEL_HAS_GPERFTOOLS = _IMP_example.IMP_KERNEL_HAS_GPERFTOOLS
190 IMP_KERNEL_HAS_TCMALLOC_HEAPCHECKER = _IMP_example.IMP_KERNEL_HAS_TCMALLOC_HEAPCHECKER
192 IMP_KERNEL_HAS_TCMALLOC_HEAPPROFILER = _IMP_example.IMP_KERNEL_HAS_TCMALLOC_HEAPPROFILER
194 IMPKERNEL_SHOW_WARNINGS = _IMP_example.IMPKERNEL_SHOW_WARNINGS
198 class _DirectorObjects(object):
199 """@internal Simple class to keep references to director objects
200 to prevent premature deletion."""
203 def register(self, obj):
204 """Take a reference to a director object; will only work for
205 refcounted C++ classes"""
206 if hasattr(obj,
'get_ref_count'):
207 self._objects.append(obj)
209 """Only drop our reference and allow cleanup by Python if no other
210 Python references exist (we hold 3 references: one in self._objects,
211 one in x, and one in the argument list for getrefcount) *and* no
212 other C++ references exist (the Python object always holds one)"""
213 objs = [x
for x
in self._objects
if sys.getrefcount(x) > 3 \
214 or x.get_ref_count() > 1]
218 def get_object_count(self):
219 """Get number of director objects (useful for testing only)"""
220 return len(self._objects)
221 _director_objects = _DirectorObjects()
223 class _ostream(object):
224 r"""Proxy of C++ std::ostream class."""
226 thisown = property(
lambda x: x.this.own(),
lambda x, v: x.this.own(v), doc=
"The membership flag")
228 def __init__(self, *args, **kwargs):
229 raise AttributeError(
"No constructor defined")
230 __repr__ = _swig_repr
232 def write(self, osa_buf):
233 r"""write(_ostream self, char const * osa_buf)"""
234 return _IMP_example._ostream_write(self, osa_buf)
237 _IMP_example._ostream_swigregister(_ostream)
238 IMP_C_OPEN_BINARY = _IMP_example.IMP_C_OPEN_BINARY
241 IMP_CGAL_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_CGAL_HAS_BOOST_FILESYSTEM
243 IMP_CGAL_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_CGAL_HAS_BOOST_PROGRAMOPTIONS
245 IMP_CGAL_HAS_BOOST_RANDOM = _IMP_example.IMP_CGAL_HAS_BOOST_RANDOM
247 IMP_CGAL_HAS_BOOST_SYSTEM = _IMP_example.IMP_CGAL_HAS_BOOST_SYSTEM
249 IMP_CGAL_HAS_NUMPY = _IMP_example.IMP_CGAL_HAS_NUMPY
251 IMPCGAL_SHOW_WARNINGS = _IMP_example.IMPCGAL_SHOW_WARNINGS
254 IMP_ALGEBRA_HAS_IMP_CGAL = _IMP_example.IMP_ALGEBRA_HAS_IMP_CGAL
256 IMP_ALGEBRA_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_ALGEBRA_HAS_BOOST_FILESYSTEM
258 IMP_ALGEBRA_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_ALGEBRA_HAS_BOOST_PROGRAMOPTIONS
260 IMP_ALGEBRA_HAS_BOOST_RANDOM = _IMP_example.IMP_ALGEBRA_HAS_BOOST_RANDOM
262 IMP_ALGEBRA_HAS_BOOST_SYSTEM = _IMP_example.IMP_ALGEBRA_HAS_BOOST_SYSTEM
264 IMP_ALGEBRA_HAS_CGAL = _IMP_example.IMP_ALGEBRA_HAS_CGAL
266 IMP_ALGEBRA_HAS_NUMPY = _IMP_example.IMP_ALGEBRA_HAS_NUMPY
268 IMP_ALGEBRA_HAS_ANN = _IMP_example.IMP_ALGEBRA_HAS_ANN
270 IMPALGEBRA_SHOW_WARNINGS = _IMP_example.IMPALGEBRA_SHOW_WARNINGS
273 IMP_DISPLAY_HAS_IMP_CGAL = _IMP_example.IMP_DISPLAY_HAS_IMP_CGAL
275 IMP_DISPLAY_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_DISPLAY_HAS_BOOST_FILESYSTEM
277 IMP_DISPLAY_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_DISPLAY_HAS_BOOST_PROGRAMOPTIONS
279 IMP_DISPLAY_HAS_BOOST_RANDOM = _IMP_example.IMP_DISPLAY_HAS_BOOST_RANDOM
281 IMP_DISPLAY_HAS_BOOST_SYSTEM = _IMP_example.IMP_DISPLAY_HAS_BOOST_SYSTEM
283 IMP_DISPLAY_HAS_CGAL = _IMP_example.IMP_DISPLAY_HAS_CGAL
285 IMP_DISPLAY_HAS_NUMPY = _IMP_example.IMP_DISPLAY_HAS_NUMPY
287 IMPDISPLAY_SHOW_WARNINGS = _IMP_example.IMPDISPLAY_SHOW_WARNINGS
290 IMP_SCORE_FUNCTOR_HAS_IMP_CGAL = _IMP_example.IMP_SCORE_FUNCTOR_HAS_IMP_CGAL
292 IMP_SCORE_FUNCTOR_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_SCORE_FUNCTOR_HAS_BOOST_FILESYSTEM
294 IMP_SCORE_FUNCTOR_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_SCORE_FUNCTOR_HAS_BOOST_PROGRAMOPTIONS
296 IMP_SCORE_FUNCTOR_HAS_BOOST_RANDOM = _IMP_example.IMP_SCORE_FUNCTOR_HAS_BOOST_RANDOM
298 IMP_SCORE_FUNCTOR_HAS_BOOST_SYSTEM = _IMP_example.IMP_SCORE_FUNCTOR_HAS_BOOST_SYSTEM
300 IMP_SCORE_FUNCTOR_HAS_CGAL = _IMP_example.IMP_SCORE_FUNCTOR_HAS_CGAL
302 IMP_SCORE_FUNCTOR_HAS_HDF5 = _IMP_example.IMP_SCORE_FUNCTOR_HAS_HDF5
304 IMP_SCORE_FUNCTOR_HAS_NUMPY = _IMP_example.IMP_SCORE_FUNCTOR_HAS_NUMPY
306 IMPSCOREFUNCTOR_SHOW_WARNINGS = _IMP_example.IMPSCOREFUNCTOR_SHOW_WARNINGS
309 IMP_STATISTICS_HAS_IMP_CGAL = _IMP_example.IMP_STATISTICS_HAS_IMP_CGAL
311 IMP_STATISTICS_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_STATISTICS_HAS_BOOST_FILESYSTEM
313 IMP_STATISTICS_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_STATISTICS_HAS_BOOST_PROGRAMOPTIONS
315 IMP_STATISTICS_HAS_BOOST_RANDOM = _IMP_example.IMP_STATISTICS_HAS_BOOST_RANDOM
317 IMP_STATISTICS_HAS_BOOST_SYSTEM = _IMP_example.IMP_STATISTICS_HAS_BOOST_SYSTEM
319 IMP_STATISTICS_HAS_CGAL = _IMP_example.IMP_STATISTICS_HAS_CGAL
321 IMP_STATISTICS_HAS_NUMPY = _IMP_example.IMP_STATISTICS_HAS_NUMPY
323 IMPSTATISTICS_SHOW_WARNINGS = _IMP_example.IMPSTATISTICS_SHOW_WARNINGS
326 IMP_CORE_HAS_IMP_CGAL = _IMP_example.IMP_CORE_HAS_IMP_CGAL
328 IMP_CORE_HAS_IMP_KERNEL = _IMP_example.IMP_CORE_HAS_IMP_KERNEL
330 IMP_CORE_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_CORE_HAS_BOOST_FILESYSTEM
332 IMP_CORE_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_CORE_HAS_BOOST_PROGRAMOPTIONS
334 IMP_CORE_HAS_BOOST_RANDOM = _IMP_example.IMP_CORE_HAS_BOOST_RANDOM
336 IMP_CORE_HAS_BOOST_SYSTEM = _IMP_example.IMP_CORE_HAS_BOOST_SYSTEM
338 IMP_CORE_HAS_CGAL = _IMP_example.IMP_CORE_HAS_CGAL
340 IMP_CORE_HAS_HDF5 = _IMP_example.IMP_CORE_HAS_HDF5
342 IMP_CORE_HAS_NUMPY = _IMP_example.IMP_CORE_HAS_NUMPY
344 IMPCORE_SHOW_WARNINGS = _IMP_example.IMPCORE_SHOW_WARNINGS
347 IMP_CONTAINER_HAS_IMP_ALGEBRA = _IMP_example.IMP_CONTAINER_HAS_IMP_ALGEBRA
349 IMP_CONTAINER_HAS_IMP_CGAL = _IMP_example.IMP_CONTAINER_HAS_IMP_CGAL
351 IMP_CONTAINER_HAS_IMP_DISPLAY = _IMP_example.IMP_CONTAINER_HAS_IMP_DISPLAY
353 IMP_CONTAINER_HAS_IMP_KERNEL = _IMP_example.IMP_CONTAINER_HAS_IMP_KERNEL
355 IMP_CONTAINER_HAS_IMP_SCORE_FUNCTOR = _IMP_example.IMP_CONTAINER_HAS_IMP_SCORE_FUNCTOR
357 IMP_CONTAINER_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_CONTAINER_HAS_BOOST_FILESYSTEM
359 IMP_CONTAINER_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_CONTAINER_HAS_BOOST_PROGRAMOPTIONS
361 IMP_CONTAINER_HAS_BOOST_RANDOM = _IMP_example.IMP_CONTAINER_HAS_BOOST_RANDOM
363 IMP_CONTAINER_HAS_BOOST_SYSTEM = _IMP_example.IMP_CONTAINER_HAS_BOOST_SYSTEM
365 IMP_CONTAINER_HAS_CGAL = _IMP_example.IMP_CONTAINER_HAS_CGAL
367 IMP_CONTAINER_HAS_HDF5 = _IMP_example.IMP_CONTAINER_HAS_HDF5
369 IMP_CONTAINER_HAS_NUMPY = _IMP_example.IMP_CONTAINER_HAS_NUMPY
371 IMP_CONTAINER_HAS_PYTHON_IHM = _IMP_example.IMP_CONTAINER_HAS_PYTHON_IHM
373 IMP_CONTAINER_HAS_GOOGLE_DENSE_HASH_MAP = _IMP_example.IMP_CONTAINER_HAS_GOOGLE_DENSE_HASH_MAP
375 IMP_CONTAINER_HAS_ROBIN_MAP = _IMP_example.IMP_CONTAINER_HAS_ROBIN_MAP
377 IMPCONTAINER_SHOW_WARNINGS = _IMP_example.IMPCONTAINER_SHOW_WARNINGS
380 IMP_ATOM_HAS_IMP_CGAL = _IMP_example.IMP_ATOM_HAS_IMP_CGAL
382 IMP_ATOM_HAS_IMP_KERNEL = _IMP_example.IMP_ATOM_HAS_IMP_KERNEL
384 IMP_ATOM_HAS_IMP_SCORE_FUNCTOR = _IMP_example.IMP_ATOM_HAS_IMP_SCORE_FUNCTOR
386 IMP_ATOM_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_ATOM_HAS_BOOST_PROGRAMOPTIONS
388 IMP_ATOM_HAS_BOOST_RANDOM = _IMP_example.IMP_ATOM_HAS_BOOST_RANDOM
390 IMP_ATOM_HAS_BOOST_REGEX = _IMP_example.IMP_ATOM_HAS_BOOST_REGEX
392 IMP_ATOM_HAS_BOOST_SYSTEM = _IMP_example.IMP_ATOM_HAS_BOOST_SYSTEM
394 IMP_ATOM_HAS_CGAL = _IMP_example.IMP_ATOM_HAS_CGAL
396 IMP_ATOM_HAS_HDF5 = _IMP_example.IMP_ATOM_HAS_HDF5
398 IMP_ATOM_HAS_NUMPY = _IMP_example.IMP_ATOM_HAS_NUMPY
400 IMP_ATOM_HAS_PYTHON_IHM = _IMP_example.IMP_ATOM_HAS_PYTHON_IHM
402 IMPATOM_SHOW_WARNINGS = _IMP_example.IMPATOM_SHOW_WARNINGS
404 IMP_ATOM_TYPE_INDEX = _IMP_example.IMP_ATOM_TYPE_INDEX
406 IMP_RESIDUE_TYPE_INDEX = _IMP_example.IMP_RESIDUE_TYPE_INDEX
408 IMP_HIERARCHY_TYPE_INDEX = _IMP_example.IMP_HIERARCHY_TYPE_INDEX
410 IMP_CHAIN_TYPE_INDEX = _IMP_example.IMP_CHAIN_TYPE_INDEX
413 IMP_EM_HAS_IMP_CGAL = _IMP_example.IMP_EM_HAS_IMP_CGAL
415 IMP_EM_HAS_IMP_CONTAINER = _IMP_example.IMP_EM_HAS_IMP_CONTAINER
417 IMP_EM_HAS_IMP_DISPLAY = _IMP_example.IMP_EM_HAS_IMP_DISPLAY
419 IMP_EM_HAS_IMP_SCORE_FUNCTOR = _IMP_example.IMP_EM_HAS_IMP_SCORE_FUNCTOR
421 IMP_EM_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_EM_HAS_BOOST_FILESYSTEM
423 IMP_EM_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_EM_HAS_BOOST_PROGRAMOPTIONS
425 IMP_EM_HAS_BOOST_RANDOM = _IMP_example.IMP_EM_HAS_BOOST_RANDOM
427 IMP_EM_HAS_BOOST_REGEX = _IMP_example.IMP_EM_HAS_BOOST_REGEX
429 IMP_EM_HAS_BOOST_SYSTEM = _IMP_example.IMP_EM_HAS_BOOST_SYSTEM
431 IMP_EM_HAS_CGAL = _IMP_example.IMP_EM_HAS_CGAL
433 IMP_EM_HAS_HDF5 = _IMP_example.IMP_EM_HAS_HDF5
435 IMP_EM_HAS_NUMPY = _IMP_example.IMP_EM_HAS_NUMPY
437 IMP_EM_HAS_PYTHON_IHM = _IMP_example.IMP_EM_HAS_PYTHON_IHM
439 IMPEM_SHOW_WARNINGS = _IMP_example.IMPEM_SHOW_WARNINGS
442 IMP_SAXS_HAS_IMP_CGAL = _IMP_example.IMP_SAXS_HAS_IMP_CGAL
444 IMP_SAXS_HAS_IMP_CONTAINER = _IMP_example.IMP_SAXS_HAS_IMP_CONTAINER
446 IMP_SAXS_HAS_IMP_DISPLAY = _IMP_example.IMP_SAXS_HAS_IMP_DISPLAY
448 IMP_SAXS_HAS_IMP_KERNEL = _IMP_example.IMP_SAXS_HAS_IMP_KERNEL
450 IMP_SAXS_HAS_IMP_SCORE_FUNCTOR = _IMP_example.IMP_SAXS_HAS_IMP_SCORE_FUNCTOR
452 IMP_SAXS_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_SAXS_HAS_BOOST_FILESYSTEM
454 IMP_SAXS_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_SAXS_HAS_BOOST_PROGRAMOPTIONS
456 IMP_SAXS_HAS_BOOST_RANDOM = _IMP_example.IMP_SAXS_HAS_BOOST_RANDOM
458 IMP_SAXS_HAS_BOOST_REGEX = _IMP_example.IMP_SAXS_HAS_BOOST_REGEX
460 IMP_SAXS_HAS_BOOST_SYSTEM = _IMP_example.IMP_SAXS_HAS_BOOST_SYSTEM
462 IMP_SAXS_HAS_CGAL = _IMP_example.IMP_SAXS_HAS_CGAL
464 IMP_SAXS_HAS_HDF5 = _IMP_example.IMP_SAXS_HAS_HDF5
466 IMP_SAXS_HAS_NUMPY = _IMP_example.IMP_SAXS_HAS_NUMPY
468 IMP_SAXS_HAS_PYTHON_IHM = _IMP_example.IMP_SAXS_HAS_PYTHON_IHM
470 IMPSAXS_SHOW_WARNINGS = _IMP_example.IMPSAXS_SHOW_WARNINGS
473 IMP_ISD_HAS_IMP_CGAL = _IMP_example.IMP_ISD_HAS_IMP_CGAL
475 IMP_ISD_HAS_IMP_DISPLAY = _IMP_example.IMP_ISD_HAS_IMP_DISPLAY
477 IMP_ISD_HAS_IMP_SCORE_FUNCTOR = _IMP_example.IMP_ISD_HAS_IMP_SCORE_FUNCTOR
479 IMP_ISD_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_ISD_HAS_BOOST_FILESYSTEM
481 IMP_ISD_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_ISD_HAS_BOOST_PROGRAMOPTIONS
483 IMP_ISD_HAS_BOOST_RANDOM = _IMP_example.IMP_ISD_HAS_BOOST_RANDOM
485 IMP_ISD_HAS_BOOST_REGEX = _IMP_example.IMP_ISD_HAS_BOOST_REGEX
487 IMP_ISD_HAS_BOOST_SYSTEM = _IMP_example.IMP_ISD_HAS_BOOST_SYSTEM
489 IMP_ISD_HAS_CGAL = _IMP_example.IMP_ISD_HAS_CGAL
491 IMP_ISD_HAS_HDF5 = _IMP_example.IMP_ISD_HAS_HDF5
493 IMP_ISD_HAS_NUMPY = _IMP_example.IMP_ISD_HAS_NUMPY
495 IMP_ISD_HAS_PYTHON_IHM = _IMP_example.IMP_ISD_HAS_PYTHON_IHM
497 IMPISD_SHOW_WARNINGS = _IMP_example.IMPISD_SHOW_WARNINGS
500 IMP_RMF_HAS_IMP_CGAL = _IMP_example.IMP_RMF_HAS_IMP_CGAL
502 IMP_RMF_HAS_IMP_EM = _IMP_example.IMP_RMF_HAS_IMP_EM
504 IMP_RMF_HAS_IMP_SAXS = _IMP_example.IMP_RMF_HAS_IMP_SAXS
506 IMP_RMF_HAS_IMP_SCORE_FUNCTOR = _IMP_example.IMP_RMF_HAS_IMP_SCORE_FUNCTOR
508 IMP_RMF_HAS_IMP_STATISTICS = _IMP_example.IMP_RMF_HAS_IMP_STATISTICS
510 IMP_RMF_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_RMF_HAS_BOOST_FILESYSTEM
512 IMP_RMF_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_RMF_HAS_BOOST_PROGRAMOPTIONS
514 IMP_RMF_HAS_BOOST_RANDOM = _IMP_example.IMP_RMF_HAS_BOOST_RANDOM
516 IMP_RMF_HAS_BOOST_REGEX = _IMP_example.IMP_RMF_HAS_BOOST_REGEX
518 IMP_RMF_HAS_BOOST_SYSTEM = _IMP_example.IMP_RMF_HAS_BOOST_SYSTEM
520 IMP_RMF_HAS_CGAL = _IMP_example.IMP_RMF_HAS_CGAL
522 IMP_RMF_HAS_HDF5 = _IMP_example.IMP_RMF_HAS_HDF5
524 IMP_RMF_HAS_NUMPY = _IMP_example.IMP_RMF_HAS_NUMPY
526 IMP_RMF_HAS_PYTHON_IHM = _IMP_example.IMP_RMF_HAS_PYTHON_IHM
528 IMPRMF_SHOW_WARNINGS = _IMP_example.IMPRMF_SHOW_WARNINGS
532 IMP_DOMINO_HAS_IMP_ATOM = _IMP_example.IMP_DOMINO_HAS_IMP_ATOM
534 IMP_DOMINO_HAS_IMP_CGAL = _IMP_example.IMP_DOMINO_HAS_IMP_CGAL
536 IMP_DOMINO_HAS_IMP_EM = _IMP_example.IMP_DOMINO_HAS_IMP_EM
538 IMP_DOMINO_HAS_IMP_ISD = _IMP_example.IMP_DOMINO_HAS_IMP_ISD
540 IMP_DOMINO_HAS_IMP_KERNEL = _IMP_example.IMP_DOMINO_HAS_IMP_KERNEL
542 IMP_DOMINO_HAS_IMP_RMF = _IMP_example.IMP_DOMINO_HAS_IMP_RMF
544 IMP_DOMINO_HAS_IMP_SAXS = _IMP_example.IMP_DOMINO_HAS_IMP_SAXS
546 IMP_DOMINO_HAS_IMP_SCORE_FUNCTOR = _IMP_example.IMP_DOMINO_HAS_IMP_SCORE_FUNCTOR
548 IMP_DOMINO_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_DOMINO_HAS_BOOST_FILESYSTEM
550 IMP_DOMINO_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_DOMINO_HAS_BOOST_PROGRAMOPTIONS
552 IMP_DOMINO_HAS_BOOST_RANDOM = _IMP_example.IMP_DOMINO_HAS_BOOST_RANDOM
554 IMP_DOMINO_HAS_BOOST_REGEX = _IMP_example.IMP_DOMINO_HAS_BOOST_REGEX
556 IMP_DOMINO_HAS_BOOST_SYSTEM = _IMP_example.IMP_DOMINO_HAS_BOOST_SYSTEM
558 IMP_DOMINO_HAS_CGAL = _IMP_example.IMP_DOMINO_HAS_CGAL
560 IMP_DOMINO_HAS_HDF5 = _IMP_example.IMP_DOMINO_HAS_HDF5
562 IMP_DOMINO_HAS_NUMPY = _IMP_example.IMP_DOMINO_HAS_NUMPY
564 IMP_DOMINO_HAS_RMF = _IMP_example.IMP_DOMINO_HAS_RMF
566 IMP_DOMINO_HAS_PYTHON_IHM = _IMP_example.IMP_DOMINO_HAS_PYTHON_IHM
568 IMPDOMINO_SHOW_WARNINGS = _IMP_example.IMPDOMINO_SHOW_WARNINGS
572 IMP_EXAMPLE_HAS_IMP_ALGEBRA = _IMP_example.IMP_EXAMPLE_HAS_IMP_ALGEBRA
574 IMP_EXAMPLE_HAS_IMP_CGAL = _IMP_example.IMP_EXAMPLE_HAS_IMP_CGAL
576 IMP_EXAMPLE_HAS_IMP_DISPLAY = _IMP_example.IMP_EXAMPLE_HAS_IMP_DISPLAY
578 IMP_EXAMPLE_HAS_IMP_EM = _IMP_example.IMP_EXAMPLE_HAS_IMP_EM
580 IMP_EXAMPLE_HAS_IMP_ISD = _IMP_example.IMP_EXAMPLE_HAS_IMP_ISD
582 IMP_EXAMPLE_HAS_IMP_KERNEL = _IMP_example.IMP_EXAMPLE_HAS_IMP_KERNEL
584 IMP_EXAMPLE_HAS_IMP_RMF = _IMP_example.IMP_EXAMPLE_HAS_IMP_RMF
586 IMP_EXAMPLE_HAS_IMP_SAXS = _IMP_example.IMP_EXAMPLE_HAS_IMP_SAXS
588 IMP_EXAMPLE_HAS_IMP_SCORE_FUNCTOR = _IMP_example.IMP_EXAMPLE_HAS_IMP_SCORE_FUNCTOR
590 IMP_EXAMPLE_HAS_IMP_STATISTICS = _IMP_example.IMP_EXAMPLE_HAS_IMP_STATISTICS
592 IMP_EXAMPLE_HAS_BOOST_FILESYSTEM = _IMP_example.IMP_EXAMPLE_HAS_BOOST_FILESYSTEM
594 IMP_EXAMPLE_HAS_BOOST_GRAPH = _IMP_example.IMP_EXAMPLE_HAS_BOOST_GRAPH
596 IMP_EXAMPLE_HAS_BOOST_PROGRAMOPTIONS = _IMP_example.IMP_EXAMPLE_HAS_BOOST_PROGRAMOPTIONS
598 IMP_EXAMPLE_HAS_BOOST_RANDOM = _IMP_example.IMP_EXAMPLE_HAS_BOOST_RANDOM
600 IMP_EXAMPLE_HAS_BOOST_REGEX = _IMP_example.IMP_EXAMPLE_HAS_BOOST_REGEX
602 IMP_EXAMPLE_HAS_BOOST_SYSTEM = _IMP_example.IMP_EXAMPLE_HAS_BOOST_SYSTEM
604 IMP_EXAMPLE_HAS_CGAL = _IMP_example.IMP_EXAMPLE_HAS_CGAL
606 IMP_EXAMPLE_HAS_HDF5 = _IMP_example.IMP_EXAMPLE_HAS_HDF5
608 IMP_EXAMPLE_HAS_NUMPY = _IMP_example.IMP_EXAMPLE_HAS_NUMPY
610 IMP_EXAMPLE_HAS_RMF = _IMP_example.IMP_EXAMPLE_HAS_RMF
612 IMP_EXAMPLE_HAS_PYTHON_IHM = _IMP_example.IMP_EXAMPLE_HAS_PYTHON_IHM
614 IMP_EXAMPLE_HAS_EXAMPLEDEPENDENCY = _IMP_example.IMP_EXAMPLE_HAS_EXAMPLEDEPENDENCY
616 IMPEXAMPLE_SHOW_WARNINGS = _IMP_example.IMPEXAMPLE_SHOW_WARNINGS
619 _object_types.append(
"ExampleRestraint")
622 def _object_cast_to_ExampleRestraint(o):
623 r"""_object_cast_to_ExampleRestraint(Object o) -> ExampleRestraint"""
624 return _IMP_example._object_cast_to_ExampleRestraint(o)
626 def ExampleDecorators(l=[]):
627 return [ExampleDecorator(x)
for x
in l]
628 _plural_types.append(
"ExampleDecorators")
631 _value_types.append(
"ExampleDecorator")
634 _object_types.append(
"ExampleUnaryFunction")
637 def _object_cast_to_ExampleUnaryFunction(o):
638 r"""_object_cast_to_ExampleUnaryFunction(Object o) -> ExampleUnaryFunction"""
639 return _IMP_example._object_cast_to_ExampleUnaryFunction(o)
641 _object_types.append(
"ExampleSingletonModifier")
644 def _object_cast_to_ExampleSingletonModifier(o):
645 r"""_object_cast_to_ExampleSingletonModifier(Object o) -> ExampleSingletonModifier"""
646 return _IMP_example._object_cast_to_ExampleSingletonModifier(o)
648 _object_types.append(
"ExamplePairScore")
651 def _object_cast_to_ExamplePairScore(o):
652 r"""_object_cast_to_ExamplePairScore(Object o) -> ExamplePairScore"""
653 return _IMP_example._object_cast_to_ExamplePairScore(o)
655 _object_types.append(
"ExampleSubsetFilterTable")
658 def _object_cast_to_ExampleSubsetFilterTable(o):
659 r"""_object_cast_to_ExampleSubsetFilterTable(Object o) -> ExampleSubsetFilterTable"""
660 return _IMP_example._object_cast_to_ExampleSubsetFilterTable(o)
662 _object_types.append(
"ExampleConstraint")
665 def _object_cast_to_ExampleConstraint(o):
666 r"""_object_cast_to_ExampleConstraint(Object o) -> ExampleConstraint"""
667 return _IMP_example._object_cast_to_ExampleConstraint(o)
669 _object_types.append(
"ExampleObject")
672 def _object_cast_to_ExampleObject(o):
673 r"""_object_cast_to_ExampleObject(Object o) -> ExampleObject"""
674 return _IMP_example._object_cast_to_ExampleObject(o)
676 ExampleTemplateClass3Ds=list
677 _plural_types.append(
"ExampleTemplateClass3Ds")
678 _value_types.append(
"ExampleTemplateClass3D")
681 def create_model_and_particles():
686 for i
in range(0,100):
687 p = m.add_particle(
"p")
691 d.set_coordinates_are_optimized(
True)
697 """An example restraint written in Python.
698 This should be functionally equivalent to the C++ ExampleRestraint.
700 def __init__(self, m, p, k):
701 IMP.Restraint.__init__(self, m,
"PythonExampleRestraint%1%")
702 self.p, self.k = p, k
704 def do_add_score_and_derivatives(self, sa):
706 score = .5 * self.k * d.get_z() * d.get_z()
707 if sa.get_derivative_accumulator():
708 deriv = self.k * d.get_z()
709 d.add_to_derivative(2, deriv, sa.get_derivative_accumulator())
713 return [self.
get_model().get_particle(self.p)]
719 """An example PairScore written in Python.
720 This should be functionally equivalent to the C++ ExamplePairScore.
722 def __init__(self, x0, k):
723 IMP.PairScore.__init__(self)
724 self.x0, self.k = x0, k
729 diff = (d0.get_coordinates()
730 - d1.get_coordinates()).get_magnitude() - self.x0
731 score = .5 * self.k * diff * diff
734 delta = d0.get_coordinates() - d1.get_coordinates()
735 udelta = delta.get_unit_vector()
737 d0.add_to_derivatives(udelta * dv, da)
738 d1.add_to_derivatives(-udelta * dv, da)
748 """An example UnaryFunction written in Python.
749 This should be functionally equivalent to the C++ ExampleUnaryFunction.
751 def __init__(self, center, k):
752 IMP.UnaryFunction.__init__(self)
753 self.center, self.k = center, k
756 return (self.
evaluate(feature), self.k * (feature - self.center))
759 return .5 * self.k * (feature - self.center) * (feature - self.center)
765 """An example Constraint written in Python.
766 This should be functionally equivalent to the C++ ExampleConstraint.
771 def __init__(self, p):
772 IMP.Constraint.__init__(self, p.get_model(),
"ExampleConstraint%1%")
775 PythonExampleConstraint.k =
IMP.IntKey(
"Constraint key")
776 if not p.has_attribute(self.k):
777 p.add_attribute(self.k, 0)
779 def do_update_attributes(self):
780 self.p.set_value(self.k, self.p.get_value(self.k) + 1)
782 def do_update_derivatives(self, da):
795 """An example SingletonModifier written in Python.
796 This should be functionally equivalent to the C++
797 ExampleSingletonModifier.
800 def __init__(self, bb):
801 IMP.SingletonModifier.__init__(self,
"ExampleSingletonModifier%1%")
808 while d.get_coordinate(i) < self.bb.get_corner(0)[i]:
809 d.set_coordinate(i,d.get_coordinate(i) + \
810 (self.bb.get_corner(1)[i] - self.bb.get_corner(0)[i]))
811 while d.get_coordinate(i) > self.bb.get_corner(1)[i]:
812 d.set_coordinate(i,d.get_coordinate(i) - \
813 (self.bb.get_corner(1)[i] - self.bb.get_corner(0)[i]))
823 r"""Proxy of C++ IMP::example::ExampleRestraint class."""
825 thisown = property(
lambda x: x.this.own(),
lambda x, v: x.this.own(v), doc=
"The membership flag")
827 def __init__(self, *args):
829 __init__(ExampleRestraint self, Model m, ParticleIndex p, double k) -> ExampleRestraint
830 __init__(ExampleRestraint self) -> ExampleRestraint
832 _IMP_example.ExampleRestraint_swiginit(self, _IMP_example.new_ExampleRestraint(*args))
834 def do_add_score_and_derivatives(self, sa):
835 r"""do_add_score_and_derivatives(ExampleRestraint self, ScoreAccumulator sa)"""
836 return _IMP_example.ExampleRestraint_do_add_score_and_derivatives(self, sa)
839 r"""do_get_inputs(ExampleRestraint self) -> IMP::ModelObjectsTemp"""
840 return _IMP_example.ExampleRestraint_do_get_inputs(self)
843 r"""get_version_info(ExampleRestraint self) -> VersionInfo"""
844 return _IMP_example.ExampleRestraint_get_version_info(self)
845 __swig_destroy__ = _IMP_example.delete_ExampleRestraint
848 r"""__str__(ExampleRestraint self) -> std::string"""
849 return _IMP_example.ExampleRestraint___str__(self)
852 r"""__repr__(ExampleRestraint self) -> std::string"""
853 return _IMP_example.ExampleRestraint___repr__(self)
857 return _object_cast_to_ExampleRestraint(o)
860 def _get_as_binary(self):
861 r"""_get_as_binary(ExampleRestraint self) -> PyObject *"""
862 return _IMP_example.ExampleRestraint__get_as_binary(self)
864 def _set_from_binary(self, p):
865 r"""_set_from_binary(ExampleRestraint self, PyObject * p)"""
866 return _IMP_example.ExampleRestraint__set_from_binary(self, p)
868 def __getstate__(self):
869 p = self._get_as_binary()
870 if len(self.__dict__) > 1:
871 d = self.__dict__.copy()
876 def __setstate__(self, p):
877 if not hasattr(self,
'this'):
879 if isinstance(p, tuple):
881 self.__dict__.update(d)
882 return self._set_from_binary(p)
886 _IMP_example.ExampleRestraint_swigregister(ExampleRestraint)
888 r"""Proxy of C++ IMP::example::ExampleDecorator class."""
890 thisown = property(
lambda x: x.this.own(),
lambda x, v: x.this.own(v), doc=
"The membership flag")
892 def get_decorator_name(self):
893 r"""get_decorator_name(ExampleDecorator self) -> std::string"""
894 return _IMP_example.ExampleDecorator_get_decorator_name(self)
896 def set_decorator_name(self, nm):
897 r"""set_decorator_name(ExampleDecorator self, std::string nm)"""
898 return _IMP_example.ExampleDecorator_set_decorator_name(self, nm)
900 def __init__(self, *args):
902 __init__(ExampleDecorator self) -> ExampleDecorator
903 __init__(ExampleDecorator self, Model m, ParticleIndex id) -> ExampleDecorator
904 __init__(ExampleDecorator self, _ParticleAdaptor d) -> ExampleDecorator
906 _IMP_example.ExampleDecorator_swiginit(self, _IMP_example.new_ExampleDecorator(*args))
909 def get_is_setup(*args):
911 get_is_setup(Model m, ParticleIndex pi) -> bool
912 get_is_setup(_ParticleAdaptor p) -> bool
914 return _IMP_example.ExampleDecorator_get_is_setup(*args)
916 def show(self, *args):
917 r"""show(ExampleDecorator self, _ostream out=std::cout)"""
918 return _IMP_example.ExampleDecorator_show(self, *args)
921 def setup_particle(*args):
923 setup_particle(Model m, ParticleIndex pi, std::string name) -> ExampleDecorator
924 setup_particle(_ParticleAdaptor pa, std::string name) -> ExampleDecorator
926 return _IMP_example.ExampleDecorator_setup_particle(*args)
928 def add_attribute(self, *args):
930 add_attribute(ExampleDecorator self, FloatKey k, IMP::Float v, bool opt)
931 add_attribute(ExampleDecorator self, FloatKey a0, IMP::Float a1)
932 add_attribute(ExampleDecorator self, IntKey a0, IMP::Int a1)
933 add_attribute(ExampleDecorator self, FloatsKey a0, IMP::Floats a1)
934 add_attribute(ExampleDecorator self, IntsKey a0, IMP::Ints a1)
935 add_attribute(ExampleDecorator self, StringKey a0, IMP::String a1)
936 add_attribute(ExampleDecorator self, ParticleIndexKey a0, Particle a1)
937 add_attribute(ExampleDecorator self, ObjectKey a0, Object a1)
938 add_attribute(ExampleDecorator self, SparseFloatKey a0, IMP::Float a1)
939 add_attribute(ExampleDecorator self, SparseIntKey a0, IMP::Int a1)
940 add_attribute(ExampleDecorator self, SparseStringKey a0, IMP::String a1)
941 add_attribute(ExampleDecorator self, SparseParticleIndexKey a0, ParticleIndex a1)
943 return _IMP_example.ExampleDecorator_add_attribute(self, *args)
945 def get_value(self, *args):
947 get_value(ExampleDecorator self, FloatKey a0) -> IMP::Float
948 get_value(ExampleDecorator self, IntKey a0) -> IMP::Int
949 get_value(ExampleDecorator self, FloatsKey a0) -> IMP::Floats
950 get_value(ExampleDecorator self, IntsKey a0) -> IMP::Ints
951 get_value(ExampleDecorator self, StringKey a0) -> IMP::String
952 get_value(ExampleDecorator self, ParticleIndexKey a0) -> Particle
953 get_value(ExampleDecorator self, ObjectKey a0) -> Object
954 get_value(ExampleDecorator self, SparseFloatKey a0) -> IMP::Float
955 get_value(ExampleDecorator self, SparseIntKey a0) -> IMP::Int
956 get_value(ExampleDecorator self, SparseStringKey a0) -> IMP::String
957 get_value(ExampleDecorator self, SparseParticleIndexKey a0) -> ParticleIndex
959 return _IMP_example.ExampleDecorator_get_value(self, *args)
961 def set_value(self, *args):
963 set_value(ExampleDecorator self, FloatKey a0, IMP::Float a1)
964 set_value(ExampleDecorator self, IntKey a0, IMP::Int a1)
965 set_value(ExampleDecorator self, FloatsKey a0, IMP::Floats a1)
966 set_value(ExampleDecorator self, IntsKey a0, IMP::Ints a1)
967 set_value(ExampleDecorator self, StringKey a0, IMP::String a1)
968 set_value(ExampleDecorator self, ParticleIndexKey a0, Particle a1)
969 set_value(ExampleDecorator self, ObjectKey a0, Object a1)
970 set_value(ExampleDecorator self, SparseFloatKey a0, IMP::Float a1)
971 set_value(ExampleDecorator self, SparseIntKey a0, IMP::Int a1)
972 set_value(ExampleDecorator self, SparseStringKey a0, IMP::String a1)
973 set_value(ExampleDecorator self, SparseParticleIndexKey a0, ParticleIndex a1)
975 return _IMP_example.ExampleDecorator_set_value(self, *args)
977 def remove_attribute(self, *args):
979 remove_attribute(ExampleDecorator self, FloatKey a0)
980 remove_attribute(ExampleDecorator self, IntKey a0)
981 remove_attribute(ExampleDecorator self, FloatsKey a0)
982 remove_attribute(ExampleDecorator self, IntsKey a0)
983 remove_attribute(ExampleDecorator self, StringKey a0)
984 remove_attribute(ExampleDecorator self, ParticleIndexKey a0)
985 remove_attribute(ExampleDecorator self, ObjectKey a0)
986 remove_attribute(ExampleDecorator self, SparseFloatKey a0)
987 remove_attribute(ExampleDecorator self, SparseIntKey a0)
988 remove_attribute(ExampleDecorator self, SparseStringKey a0)
989 remove_attribute(ExampleDecorator self, SparseParticleIndexKey a0)
991 return _IMP_example.ExampleDecorator_remove_attribute(self, *args)
993 def has_attribute(self, *args):
995 has_attribute(ExampleDecorator self, FloatKey a0) -> bool
996 has_attribute(ExampleDecorator self, IntKey a0) -> bool
997 has_attribute(ExampleDecorator self, FloatsKey a0) -> bool
998 has_attribute(ExampleDecorator self, IntsKey a0) -> bool
999 has_attribute(ExampleDecorator self, StringKey a0) -> bool
1000 has_attribute(ExampleDecorator self, ParticleIndexKey a0) -> bool
1001 has_attribute(ExampleDecorator self, ObjectKey a0) -> bool
1002 has_attribute(ExampleDecorator self, SparseFloatKey a0) -> bool
1003 has_attribute(ExampleDecorator self, SparseIntKey a0) -> bool
1004 has_attribute(ExampleDecorator self, SparseStringKey a0) -> bool
1005 has_attribute(ExampleDecorator self, SparseParticleIndexKey a0) -> bool
1007 return _IMP_example.ExampleDecorator_has_attribute(self, *args)
1009 def get_derivative(self, a0):
1010 r"""get_derivative(ExampleDecorator self, FloatKey a0) -> double"""
1011 return _IMP_example.ExampleDecorator_get_derivative(self, a0)
1014 r"""get_name(ExampleDecorator self) -> std::string"""
1015 return _IMP_example.ExampleDecorator_get_name(self)
1018 r"""clear_caches(ExampleDecorator self)"""
1019 return _IMP_example.ExampleDecorator_clear_caches(self)
1021 def set_name(self, a0):
1022 r"""set_name(ExampleDecorator self, std::string a0)"""
1023 return _IMP_example.ExampleDecorator_set_name(self, a0)
1026 r"""set_check_level(ExampleDecorator self, IMP::CheckLevel a0)"""
1027 return _IMP_example.ExampleDecorator_set_check_level(self, a0)
1029 def add_to_derivative(self, a0, a1, a2):
1030 r"""add_to_derivative(ExampleDecorator self, FloatKey a0, double a1, DerivativeAccumulator a2)"""
1031 return _IMP_example.ExampleDecorator_add_to_derivative(self, a0, a1, a2)
1033 def set_is_optimized(self, a0, a1):
1034 r"""set_is_optimized(ExampleDecorator self, FloatKey a0, bool a1)"""
1035 return _IMP_example.ExampleDecorator_set_is_optimized(self, a0, a1)
1037 def get_is_optimized(self, a0):
1038 r"""get_is_optimized(ExampleDecorator self, FloatKey a0) -> bool"""
1039 return _IMP_example.ExampleDecorator_get_is_optimized(self, a0)
1041 def get_check_level(self):
1042 r"""get_check_level(ExampleDecorator self) -> IMP::CheckLevel"""
1043 return _IMP_example.ExampleDecorator_get_check_level(self)
1045 def __eq__(self, *args):
1047 __eq__(ExampleDecorator self, ExampleDecorator o) -> bool
1048 __eq__(ExampleDecorator self, Particle d) -> bool
1050 return _IMP_example.ExampleDecorator___eq__(self, *args)
1052 def __ne__(self, *args):
1054 __ne__(ExampleDecorator self, ExampleDecorator o) -> bool
1055 __ne__(ExampleDecorator self, Particle d) -> bool
1057 return _IMP_example.ExampleDecorator___ne__(self, *args)
1059 def __le__(self, *args):
1061 __le__(ExampleDecorator self, ExampleDecorator o) -> bool
1062 __le__(ExampleDecorator self, Particle d) -> bool
1064 return _IMP_example.ExampleDecorator___le__(self, *args)
1066 def __lt__(self, *args):
1068 __lt__(ExampleDecorator self, ExampleDecorator o) -> bool
1069 __lt__(ExampleDecorator self, Particle d) -> bool
1071 return _IMP_example.ExampleDecorator___lt__(self, *args)
1073 def __ge__(self, *args):
1075 __ge__(ExampleDecorator self, ExampleDecorator o) -> bool
1076 __ge__(ExampleDecorator self, Particle d) -> bool
1078 return _IMP_example.ExampleDecorator___ge__(self, *args)
1080 def __gt__(self, *args):
1082 __gt__(ExampleDecorator self, ExampleDecorator o) -> bool
1083 __gt__(ExampleDecorator self, Particle d) -> bool
1085 return _IMP_example.ExampleDecorator___gt__(self, *args)
1088 r"""__hash__(ExampleDecorator self) -> std::size_t"""
1089 return _IMP_example.ExampleDecorator___hash__(self)
1092 r"""__str__(ExampleDecorator self) -> std::string"""
1093 return _IMP_example.ExampleDecorator___str__(self)
1096 r"""__repr__(ExampleDecorator self) -> std::string"""
1097 return _IMP_example.ExampleDecorator___repr__(self)
1099 def _get_as_binary(self):
1100 r"""_get_as_binary(ExampleDecorator self) -> PyObject *"""
1101 return _IMP_example.ExampleDecorator__get_as_binary(self)
1103 def _set_from_binary(self, p):
1104 r"""_set_from_binary(ExampleDecorator self, PyObject * p)"""
1105 return _IMP_example.ExampleDecorator__set_from_binary(self, p)
1107 def __getstate__(self):
1108 p = self._get_as_binary()
1109 if len(self.__dict__) > 1:
1110 d = self.__dict__.copy()
1115 def __setstate__(self, p):
1116 if not hasattr(self,
'this'):
1118 if isinstance(p, tuple):
1120 self.__dict__.update(d)
1121 return self._set_from_binary(p)
1123 __swig_destroy__ = _IMP_example.delete_ExampleDecorator
1126 _IMP_example.ExampleDecorator_swigregister(ExampleDecorator)
1128 def __lshift__(out, n):
1129 r"""__lshift__(_ostream out, ExampleDecorator n) -> _ostream"""
1130 return _IMP_example.__lshift__(out, n)
1132 r"""Proxy of C++ IMP::example::ExampleUnaryFunction class."""
1134 thisown = property(
lambda x: x.this.own(),
lambda x, v: x.this.own(v), doc=
"The membership flag")
1136 def __init__(self, *args):
1138 __init__(ExampleUnaryFunction self, IMP::Float center, IMP::Float k) -> ExampleUnaryFunction
1139 __init__(ExampleUnaryFunction self) -> ExampleUnaryFunction
1141 _IMP_example.ExampleUnaryFunction_swiginit(self, _IMP_example.new_ExampleUnaryFunction(*args))
1144 r"""get_version_info(ExampleUnaryFunction self) -> VersionInfo"""
1145 return _IMP_example.ExampleUnaryFunction_get_version_info(self)
1146 __swig_destroy__ = _IMP_example.delete_ExampleUnaryFunction
1149 r"""__str__(ExampleUnaryFunction self) -> std::string"""
1150 return _IMP_example.ExampleUnaryFunction___str__(self)
1153 r"""__repr__(ExampleUnaryFunction self) -> std::string"""
1154 return _IMP_example.ExampleUnaryFunction___repr__(self)
1158 return _object_cast_to_ExampleUnaryFunction(o)
1161 def _get_as_binary(self):
1162 r"""_get_as_binary(ExampleUnaryFunction self) -> PyObject *"""
1163 return _IMP_example.ExampleUnaryFunction__get_as_binary(self)
1165 def _set_from_binary(self, p):
1166 r"""_set_from_binary(ExampleUnaryFunction self, PyObject * p)"""
1167 return _IMP_example.ExampleUnaryFunction__set_from_binary(self, p)
1169 def __getstate__(self):
1170 p = self._get_as_binary()
1171 if len(self.__dict__) > 1:
1172 d = self.__dict__.copy()
1177 def __setstate__(self, p):
1178 if not hasattr(self,
'this'):
1180 if isinstance(p, tuple):
1182 self.__dict__.update(d)
1183 return self._set_from_binary(p)
1187 _IMP_example.ExampleUnaryFunction_swigregister(ExampleUnaryFunction)
1189 r"""Proxy of C++ IMP::example::ExampleObject class."""
1191 thisown = property(
lambda x: x.this.own(),
lambda x, v: x.this.own(v), doc=
"The membership flag")
1193 def __init__(self, *args):
1195 __init__(ExampleObject self, IMP::Floats const & data) -> ExampleObject
1196 __init__(ExampleObject self) -> ExampleObject
1198 _IMP_example.ExampleObject_swiginit(self, _IMP_example.new_ExampleObject(*args))
1200 def get_data(self, i):
1201 r"""get_data(ExampleObject self, unsigned int i) -> double"""
1202 return _IMP_example.ExampleObject_get_data(self, i)
1205 r"""get_version_info(ExampleObject self) -> VersionInfo"""
1206 return _IMP_example.ExampleObject_get_version_info(self)
1207 __swig_destroy__ = _IMP_example.delete_ExampleObject
1210 r"""__str__(ExampleObject self) -> std::string"""
1211 return _IMP_example.ExampleObject___str__(self)
1214 r"""__repr__(ExampleObject self) -> std::string"""
1215 return _IMP_example.ExampleObject___repr__(self)
1219 return _object_cast_to_ExampleObject(o)
1222 def _get_as_binary(self):
1223 r"""_get_as_binary(ExampleObject self) -> PyObject *"""
1224 return _IMP_example.ExampleObject__get_as_binary(self)
1226 def _set_from_binary(self, p):
1227 r"""_set_from_binary(ExampleObject self, PyObject * p)"""
1228 return _IMP_example.ExampleObject__set_from_binary(self, p)
1230 def __getstate__(self):
1231 p = self._get_as_binary()
1232 if len(self.__dict__) > 1:
1233 d = self.__dict__.copy()
1238 def __setstate__(self, p):
1239 if not hasattr(self,
'this'):
1241 if isinstance(p, tuple):
1243 self.__dict__.update(d)
1244 return self._set_from_binary(p)
1248 _IMP_example.ExampleObject_swigregister(ExampleObject)
1250 r"""Proxy of C++ IMP::example::ExampleSingletonModifier class."""
1252 thisown = property(
lambda x: x.this.own(),
lambda x, v: x.this.own(v), doc=
"The membership flag")
1254 def __init__(self, *args):
1256 __init__(ExampleSingletonModifier self, BoundingBox3D bb) -> ExampleSingletonModifier
1257 __init__(ExampleSingletonModifier self) -> ExampleSingletonModifier
1259 _IMP_example.ExampleSingletonModifier_swiginit(self, _IMP_example.new_ExampleSingletonModifier(*args))
1262 r"""do_get_inputs(ExampleSingletonModifier self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
1263 return _IMP_example.ExampleSingletonModifier_do_get_inputs(self, m, pis)
1266 r"""do_get_outputs(ExampleSingletonModifier self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
1267 return _IMP_example.ExampleSingletonModifier_do_get_outputs(self, m, pis)
1270 r"""get_version_info(ExampleSingletonModifier self) -> VersionInfo"""
1271 return _IMP_example.ExampleSingletonModifier_get_version_info(self)
1272 __swig_destroy__ = _IMP_example.delete_ExampleSingletonModifier
1275 r"""__str__(ExampleSingletonModifier self) -> std::string"""
1276 return _IMP_example.ExampleSingletonModifier___str__(self)
1279 r"""__repr__(ExampleSingletonModifier self) -> std::string"""
1280 return _IMP_example.ExampleSingletonModifier___repr__(self)
1284 return _object_cast_to_ExampleSingletonModifier(o)
1287 def _get_as_binary(self):
1288 r"""_get_as_binary(ExampleSingletonModifier self) -> PyObject *"""
1289 return _IMP_example.ExampleSingletonModifier__get_as_binary(self)
1291 def _set_from_binary(self, p):
1292 r"""_set_from_binary(ExampleSingletonModifier self, PyObject * p)"""
1293 return _IMP_example.ExampleSingletonModifier__set_from_binary(self, p)
1295 def __getstate__(self):
1296 p = self._get_as_binary()
1297 if len(self.__dict__) > 1:
1298 d = self.__dict__.copy()
1303 def __setstate__(self, p):
1304 if not hasattr(self,
'this'):
1306 if isinstance(p, tuple):
1308 self.__dict__.update(d)
1309 return self._set_from_binary(p)
1313 _IMP_example.ExampleSingletonModifier_swigregister(ExampleSingletonModifier)
1315 r"""Proxy of C++ IMP::example::ExamplePairScore class."""
1317 thisown = property(
lambda x: x.this.own(),
lambda x, v: x.this.own(v), doc=
"The membership flag")
1319 def __init__(self, *args):
1321 __init__(ExamplePairScore self, double x0, double k) -> ExamplePairScore
1322 __init__(ExamplePairScore self) -> ExamplePairScore
1324 _IMP_example.ExamplePairScore_swiginit(self, _IMP_example.new_ExamplePairScore(*args))
1327 r"""do_get_inputs(ExamplePairScore self, Model m, IMP::ParticleIndexes const & pis) -> IMP::ModelObjectsTemp"""
1328 return _IMP_example.ExamplePairScore_do_get_inputs(self, m, pis)
1331 r"""get_version_info(ExamplePairScore self) -> VersionInfo"""
1332 return _IMP_example.ExamplePairScore_get_version_info(self)
1333 __swig_destroy__ = _IMP_example.delete_ExamplePairScore
1336 r"""__str__(ExamplePairScore self) -> std::string"""
1337 return _IMP_example.ExamplePairScore___str__(self)
1340 r"""__repr__(ExamplePairScore self) -> std::string"""
1341 return _IMP_example.ExamplePairScore___repr__(self)
1345 return _object_cast_to_ExamplePairScore(o)
1348 def _get_as_binary(self):
1349 r"""_get_as_binary(ExamplePairScore self) -> PyObject *"""
1350 return _IMP_example.ExamplePairScore__get_as_binary(self)
1352 def _set_from_binary(self, p):
1353 r"""_set_from_binary(ExamplePairScore self, PyObject * p)"""
1354 return _IMP_example.ExamplePairScore__set_from_binary(self, p)
1356 def __getstate__(self):
1357 p = self._get_as_binary()
1358 if len(self.__dict__) > 1:
1359 d = self.__dict__.copy()
1364 def __setstate__(self, p):
1365 if not hasattr(self,
'this'):
1367 if isinstance(p, tuple):
1369 self.__dict__.update(d)
1370 return self._set_from_binary(p)
1374 _IMP_example.ExamplePairScore_swigregister(ExamplePairScore)
1376 r"""Proxy of C++ IMP::example::ExampleSubsetFilterTable class."""
1378 thisown = property(
lambda x: x.this.own(),
lambda x, v: x.this.own(v), doc=
"The membership flag")
1380 def __init__(self, max_diff, pt):
1381 r"""__init__(ExampleSubsetFilterTable self, unsigned int max_diff, IMP::ParticlesTemp const & pt) -> ExampleSubsetFilterTable"""
1382 _IMP_example.ExampleSubsetFilterTable_swiginit(self, _IMP_example.new_ExampleSubsetFilterTable(max_diff, pt))
1385 r"""get_version_info(ExampleSubsetFilterTable self) -> VersionInfo"""
1386 return _IMP_example.ExampleSubsetFilterTable_get_version_info(self)
1387 __swig_destroy__ = _IMP_example.delete_ExampleSubsetFilterTable
1390 r"""__str__(ExampleSubsetFilterTable self) -> std::string"""
1391 return _IMP_example.ExampleSubsetFilterTable___str__(self)
1394 r"""__repr__(ExampleSubsetFilterTable self) -> std::string"""
1395 return _IMP_example.ExampleSubsetFilterTable___repr__(self)
1399 return _object_cast_to_ExampleSubsetFilterTable(o)
1403 _IMP_example.ExampleSubsetFilterTable_swigregister(ExampleSubsetFilterTable)
1405 r"""Proxy of C++ IMP::example::ExampleConstraint class."""
1407 thisown = property(
lambda x: x.this.own(),
lambda x, v: x.this.own(v), doc=
"The membership flag")
1409 def __init__(self, *args):
1411 __init__(ExampleConstraint self, Particle p) -> ExampleConstraint
1412 __init__(ExampleConstraint self) -> ExampleConstraint
1414 _IMP_example.ExampleConstraint_swiginit(self, _IMP_example.new_ExampleConstraint(*args))
1417 r"""do_get_inputs(ExampleConstraint self) -> IMP::ModelObjectsTemp"""
1418 return _IMP_example.ExampleConstraint_do_get_inputs(self)
1421 r"""do_get_outputs(ExampleConstraint self) -> IMP::ModelObjectsTemp"""
1422 return _IMP_example.ExampleConstraint_do_get_outputs(self)
1426 r"""get_key() -> IntKey"""
1427 return _IMP_example.ExampleConstraint_get_key()
1430 r"""get_version_info(ExampleConstraint self) -> VersionInfo"""
1431 return _IMP_example.ExampleConstraint_get_version_info(self)
1432 __swig_destroy__ = _IMP_example.delete_ExampleConstraint
1435 r"""__str__(ExampleConstraint self) -> std::string"""
1436 return _IMP_example.ExampleConstraint___str__(self)
1439 r"""__repr__(ExampleConstraint self) -> std::string"""
1440 return _IMP_example.ExampleConstraint___repr__(self)
1444 return _object_cast_to_ExampleConstraint(o)
1447 def _get_as_binary(self):
1448 r"""_get_as_binary(ExampleConstraint self) -> PyObject *"""
1449 return _IMP_example.ExampleConstraint__get_as_binary(self)
1451 def _set_from_binary(self, p):
1452 r"""_set_from_binary(ExampleConstraint self, PyObject * p)"""
1453 return _IMP_example.ExampleConstraint__set_from_binary(self, p)
1455 def __getstate__(self):
1456 p = self._get_as_binary()
1457 if len(self.__dict__) > 1:
1458 d = self.__dict__.copy()
1463 def __setstate__(self, p):
1464 if not hasattr(self,
'this'):
1466 if isinstance(p, tuple):
1468 self.__dict__.update(d)
1469 return self._set_from_binary(p)
1473 _IMP_example.ExampleConstraint_swigregister(ExampleConstraint)
1476 r"""get_number_of_incidences(IMP::ParticlesTemp const & psa, IMP::ParticlesTemp const & psb, double point_distance) -> unsigned int"""
1477 return _IMP_example.get_number_of_incidences(psa, psb, point_distance)
1480 r"""create_chain_restraint(Model m, IMP::ParticleIndexes const & ps, double length_factor, double k, std::string name) -> Restraint"""
1481 return _IMP_example.create_chain_restraint(m, ps, length_factor, k, name)
1484 r"""create_excluded_volume(Model m, IMP::ParticleIndexes const & ps, double k, std::string name) -> Restraint"""
1485 return _IMP_example.create_excluded_volume(m, ps, k, name)
1487 r"""Proxy of C++ IMP::example::ExampleTemplateClassD< 3 > class."""
1489 thisown = property(
lambda x: x.this.own(),
lambda x, v: x.this.own(v), doc=
"The membership flag")
1491 def __init__(self, *args):
1493 __init__(ExampleTemplateClass3D self) -> ExampleTemplateClass3D
1494 __init__(ExampleTemplateClass3D self, Vector3D a, Vector3D b) -> ExampleTemplateClass3D
1496 _IMP_example.ExampleTemplateClass3D_swiginit(self, _IMP_example.new_ExampleTemplateClass3D(*args))
1498 def get_point(self, i):
1499 r"""get_point(ExampleTemplateClass3D self, unsigned int i) -> Vector3D"""
1500 return _IMP_example.ExampleTemplateClass3D_get_point(self, i)
1502 def show(self, *args):
1503 r"""show(ExampleTemplateClass3D self, _ostream out=std::cout)"""
1504 return _IMP_example.ExampleTemplateClass3D_show(self, *args)
1507 r"""__str__(ExampleTemplateClass3D self) -> std::string"""
1508 return _IMP_example.ExampleTemplateClass3D___str__(self)
1511 r"""__repr__(ExampleTemplateClass3D self) -> std::string"""
1512 return _IMP_example.ExampleTemplateClass3D___repr__(self)
1513 __swig_destroy__ = _IMP_example.delete_ExampleTemplateClass3D
1516 _IMP_example.ExampleTemplateClass3D_swigregister(ExampleTemplateClass3D)
1519 r"""get_module_version() -> std::string const"""
1520 return _IMP_example.get_module_version()
1523 r"""get_example_path(std::string fname) -> std::string"""
1524 return _IMP_example.get_example_path(fname)
1527 r"""get_data_path(std::string fname) -> std::string"""
1528 return _IMP_example.get_data_path(fname)
1530 from .
import _version_check
unsigned int get_number_of_incidences(const ParticlesTemp &psa, const ParticlesTemp &psb, double point_distance)
A base class for modifiers of ParticlesTemp.
Abstract class for scoring object(s) of type ParticleIndexPair.
virtual double evaluate(double feature) const
Calculate score with respect to the given feature.
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)
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()
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.
Class for storing model, its restraints, constraints, and particles.
An example simple object which is reference counted.
A simple decorator which adds a name to a particle.
An example Constraint written in Python.
An example singleton modifier.
Common base class for heavy weight IMP objects.
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.
Interface to specialized Particle types (e.g. atoms)
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.
virtual DerivativePair evaluate_with_derivative(double feature) const
Calculate score and derivative with respect to the given feature.
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
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.
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.