[ VIGRA Homepage | Function Index | Class Index | Namespaces | File List | Main Page ]

| DynamicAccumulatorChainArray< T, Selected > Class Template Reference |

Create an array of dynamic accumulator chains containing the selected per-region and global statistics and their dependencies. More...

`#include <vigra/accumulator.hxx>`

Inheritance diagram for DynamicAccumulatorChainArray< T, Selected >:

## Public Member Functions
void | activate (std::string tag)
template<class TAG >
void | activate ()
void | activateAll ()
ArrayVector< std::string > | activeNames () const
bool | isActive (std::string tag) const
template<class TAG >
bool | isActive () const
unsigned int | passesRequired () const
Public Member Functions inherited from AccumulatorChainArray< T, Selected, true >
MultiArrayIndex | ignoredLabel () const
void | ignoreLabel (MultiArrayIndex l)
MultiArrayIndex | maxRegionLabel () const
void | merge (unsigned i, unsigned j)
void | merge (AccumulatorChainArray const &o)
void | merge (AccumulatorChainArray const &o, ArrayLike const &labelMapping)
void | operator+= (AccumulatorChainArray const &o)
void | operator+= (AccumulatorChainImpl const &o)
unsigned int | regionCount () const
void | setCoordinateOffset (MultiArrayIndex k, SHAPE const &offset)
void | setCoordinateOffset (SHAPE const &offset) void reset(unsigned int reset_to_pass=0)
void | setHistogramOptions (HistogramOptions const &options)
void | setHistogramOptions (HistogramOptions const &regionoptions, HistogramOptions const &globaloptions)
void | setMaxRegionLabel (unsigned label)
void | updatePassN (T const &t, unsigned int N)
void | updatePassN (T const &t, double weight, unsigned int N)

## Additional Inherited Members
Static Public Member Functions inherited from AccumulatorChainArray< T, Selected, true >
static ArrayVector < std::string > const & | tagNames ()

## Detailed Description

### template<class T, class Selected>
class vigra::acc::DynamicAccumulatorChainArray< T, Selected >

Create an array of dynamic accumulator chains containing the selected per-region and global statistics and their dependencies.

DynamicAccumulatorChainArray is used to compute per-region statistics (as well as global statistics) with run-time activation. A set of statistics is selected at run-time and from this set statistics can be activated at run-time by calling activate<stat>() or activate(std::string stat).

The template parameters are as follows:

- T: The input type, type of CoupledHandle (for access to coordinates, labels and weights)
- Selected: statistics to be computed and index specifier for the CoupledHandle, wrapped with Select

Usage:

const int dim = 3; //dimension of MultiArray
typedef double DataType;
typedef double WeightType;
typedef unsigned int LabelType;
typedef vigra::CoupledIteratorType<dim, DataType, WeightType, LabelType>::HandleType Handle;
DynamicAccumulatorChainArray<Handle, Select<DataArg<1>, WeightArg<2>, LabelArg<3>, Mean, Variance, ...> > a;

See Feature Accumulators for more information and examples of use.

## Member Function Documentation

void activate | ( | std::string | tag | ) |

Activate statistic 'tag'. Alias names are not recognized. If the statistic is not in the accumulator chain a PreconditionViolation is thrown.

void activate | ( |  | ) |

activate<TAG>() activates statistic 'TAG'. If the statistic is not in the accumulator chain it is ignored. (?)

void activateAll | ( |  | ) |

Activate all statistics in the accumulator chain.

bool isActive | ( | std::string | tag | ) | const

Return true if the statistic 'tag' is active, i.e. activate(std::string tag) or activate<TAG>() has been called. If the statistic is not in the accumulator chain a PreconditionViolation is thrown. (Note that alias names are not recognized.)

bool isActive | ( |  | ) | const

isActive<TAG>() returns true if statistic 'TAG' is active, i.e. activate(std::string tag) or activate<TAG>() has been called. If the statistic is not in the accumulator chain, true is returned. (?)

ArrayVector<std::string> activeNames | ( |  | ) | const

Return names of all statistics in the accumulator chain that are active.

unsigned int passesRequired | ( |  | ) | const

Return number of passes required to compute the active statistics in the accumulator chain.

The documentation for this class was generated from the following file:

- vigra/accumulator.hxx

© Ullrich Köthe (ullrich.koethe@iwr.uni-heidelberg.de) Heidelberg Collaboratory for Image Processing, University of Heidelberg, Germany | html generated using doxygen and Python vigra 1.11.0 (Fri May 19 2017)