Package gmisclib :: Module mcmc :: Class NotGoodPosition
[frames] | no frames]

Class NotGoodPosition

source code


This is raised by user code (e.g. in the problem_definition.logP method or in problem_definition.fixer) to indicate that the current position is not computable or is unacceptable in some other way. This is assumed to be a permanent problem: i.e. the mathematical model blows up for this set of parameters.

Instance Methods
 
__init__(self, *s)
x.__init__(...) initializes x; see help(type(x)) for signature
source code
NotGoodPosition
add_args(self, *s)
Typical usage:
source code

Inherited from exceptions.ValueError: __new__

Inherited from exceptions.BaseException: __delattr__, __getattribute__, __getitem__, __getslice__, __reduce__, __repr__, __setattr__, __setstate__, __str__, __unicode__

Inherited from object: __format__, __hash__, __reduce_ex__, __sizeof__, __subclasshook__

Properties

Inherited from exceptions.BaseException: args, message

Inherited from object: __class__

Method Details

__init__(self, *s)
(Constructor)

source code 

x.__init__(...) initializes x; see help(type(x)) for signature

Overrides: object.__init__
(inherited documentation)

add_args(self, *s)

source code 

Typical usage:

       try:
               something
       except NotGoodPosition, ex:
               raise ex.add_args(more, args, added, here)
Parameters:
  • s - a tuple of arguments to add onto the tail of the exception's args list.
Returns: NotGoodPosition
The modified exception.

Note: This modifies the original object and returns it.