Package csb :: Package statistics :: Package samplers :: Package mc :: Module multichain :: Class AbstractExchangeMC
[frames] | no frames]

Class AbstractExchangeMC

source code

     object --+            
              |            
AbstractSampler --+        
                  |        
         AbstractMC --+    
                      |    
     AbstractEnsembleMC --+
                          |
                         AbstractExchangeMC
Known Subclasses:

Abstract class for Monte Carlo sampling algorithms employing some replica exchange method.

Nested Classes

Inherited from AbstractSampler: __metaclass__

Instance Methods
 
__init__(self, samplers, param_infos)
x.__init__(...) initializes x; see help(type(x)) for signature
source code
boolean
swap(self, index)
Perform swap between sampler pair described by param_infos[index] and return outcome (true = accepted, false = rejected).
source code

Inherited from AbstractEnsembleMC: sample

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

Class Variables
  __abstractmethods__ = frozenset(['_calc_pacc_swap', '_propose_...
Properties
list of floats acceptance_rates
Return swap acceptance rates.
list of AbstractSwapParameterInfo param_infos
List of SwapParameterInfo instances holding all necessary parameters.
  statistics

Inherited from AbstractEnsembleMC: energy

Inherited from AbstractMC: state

Inherited from object: __class__

Method Details

__init__(self, samplers, param_infos)
(Constructor)

source code 

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

Parameters:
  • samplers (list of AbstractSingleChainMC) - samplers which sample from their respective equilibrium distributions
  • param_infos (list of AbstractSwapParameterInfo) - list of ParameterInfo instances providing information needed for performing swaps
Overrides: object.__init__
(inherited documentation)

swap(self, index)

source code 

Perform swap between sampler pair described by param_infos[index] and return outcome (true = accepted, false = rejected).

Parameters:
  • index (int) - index of swap pair in param_infos
Returns: boolean

Class Variable Details

__abstractmethods__

Value:
frozenset(['_calc_pacc_swap', '_propose_swap'])

Property Details

acceptance_rates

Return swap acceptance rates.

Get Method:
unreachable.acceptance_rates(self) - Return swap acceptance rates.
Type:
list of floats

param_infos

List of SwapParameterInfo instances holding all necessary parameters.

Get Method:
unreachable.param_infos(self) - List of SwapParameterInfo instances holding all necessary parameters.
Type:
list of AbstractSwapParameterInfo

statistics

Get Method:
unreachable.statistics(self)