Package gmisclib :: Module mcmc_indexclass :: Class index_base
[frames] | no frames]

Class index_base

source code


Instance Methods
 
__init__(self, keymap, name=None)
x.__init__(...) initializes x; see help(type(x)) for signature
source code
 
clear(self) source code
 
p(self, *key) source code
 
p_lower(self, ll, *key) source code
 
p_range(self, lb, ub, *key) source code
 
pN(self, num, *key) source code
 
pNr(self, num, low, high, *key) source code
 
pNl(self, num, low, high, *key) source code
numpy.ndarray
get_prms(self)
Returns: a vector of the adjustable parameters
source code
 
columns(self) source code
int
n(self)
Returns: the number of adjustable parameters.
source code
 
i_k_val(self) source code
 
comment(self, c) source code
 
hash(self) source code
 
__call__(self) source code
 
logdens(self, x) source code
 
set_all_fixed(self, kv)
This sets a whole dictionary's worth of fixed parameters.
source code
 
set_fixed(self, v, *k)
You can have "fixed" parameters that are not updated by the MCMC optimizer.
source code
a dictionary from parameter name to value.
get_fixed(self)
Get only the fixed parameters.
source code
 
get_all(self) source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties

Inherited from object: __class__

Method Details

__init__(self, keymap, name=None)
(Constructor)

source code 

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

Overrides: object.__init__
(inherited documentation)

get_prms(self)

source code 
Returns: numpy.ndarray
a vector of the adjustable parameters

n(self)

source code 
Returns: int
the number of adjustable parameters.

Note: to include the number of fixed parameters, you can take len(self._p).

set_all_fixed(self, kv)

source code 

This sets a whole dictionary's worth of fixed parameters.

Parameters:
  • kv (dict) - parameters to set

set_fixed(self, v, *k)

source code 

You can have "fixed" parameters that are not updated by the MCMC optimizer. This sets one of them.

Parameters:
  • v - the value
  • k - the key.