casacore
Public Member Functions | Protected Member Functions | Private Attributes | List of all members
casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator > Class Template Referenceabstract

This is the virtual base class from which concrete QuantileComputer classes are derived. More...

#include <StatisticsAlgorithmQuantileComputer.h>

Public Member Functions

 StatisticsAlgorithmQuantileComputer ()=delete
 
virtual ~StatisticsAlgorithmQuantileComputer ()
 
virtual StatisticsAlgorithmQuantileComputer< CASA_STATP > * clone () const =0
 clone this object by returning a pointer to a copy More...
 
void deleteSortedArray ()
 delete any (partially) sorted array More...
 
virtual void reset ()
 reset this object by clearing data. More...
 
void setDataset (StatisticsDataset< CASA_STATP > *ds)
 This must be called upon the copy or assignment of the associated statistics algorithm object. More...
 
std::vector< AccumType > & _getSortedArray ()
 FIXME make protected once refactor is complete. More...
 
void _setSortedArray (const std::vector< AccumType > &v)
 FIXME make protected once refactor is complete. More...
 
void setMedian (CountedPtr< AccumType > median)
 

Protected Member Functions

 StatisticsAlgorithmQuantileComputer (StatisticsDataset< CASA_STATP > *ds)
 ds should be the dataset object held in the StatisticsAlgorithm object. More...
 
 StatisticsAlgorithmQuantileComputer (const StatisticsAlgorithmQuantileComputer &other)
 use copy semantics. More...
 
StatisticsAlgorithmQuantileComputeroperator= (const StatisticsAlgorithmQuantileComputer &other)
 use copy semantics. More...
 
StatisticsDataset< CASA_STATP > * _getDataset ()
 
CountedPtr< AccumType > _getMedian () const
 
CountedPtr< AccumType > _getMedianAbsDevMedian () const
 
void _setMedianAbsDevMedian (CountedPtr< AccumType > medAbsDevMed)
 

Private Attributes

std::vector< AccumType > _sortedArray
 
StatisticsDataset< CASA_STATP > * _dataset
 This pointer references the (non-pointer) object in the associated non-QuantileComputer computer object, so this should not be wrapped in a smart pointer. More...
 
CountedPtr< AccumType > _median
 
CountedPtr< AccumType > _medAbsDevMed
 

Detailed Description

template<class AccumType, class DataIterator, class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
class casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >

This is the virtual base class from which concrete QuantileComputer classes are derived.

The API developer should never explicitly instantiate a QuantileComputer class; they are used internally by other StatsFramework classes. See the documentation of StatisticsAlgorithm for more details.

Definition at line 44 of file StatisticsAlgorithmQuantileComputer.h.

Constructor & Destructor Documentation

◆ StatisticsAlgorithmQuantileComputer() [1/3]

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::StatisticsAlgorithmQuantileComputer ( )
delete

◆ ~StatisticsAlgorithmQuantileComputer()

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
virtual casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::~StatisticsAlgorithmQuantileComputer ( )
virtual

◆ StatisticsAlgorithmQuantileComputer() [2/3]

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::StatisticsAlgorithmQuantileComputer ( StatisticsDataset< CASA_STATP > *  ds)
protected

ds should be the dataset object held in the StatisticsAlgorithm object.

The QuantileComputer calculator object should never hold its own version of a dataset object. The algorithm object (caller of this method) is always responsible for deleting the passed object, usually upon its destruction.

◆ StatisticsAlgorithmQuantileComputer() [3/3]

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::StatisticsAlgorithmQuantileComputer ( const StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator > &  other)
protected

use copy semantics.

statistics algorithm object's responsibility to set the _dataset object in the new QuantileComputer calculator object upon a copy. The underlying _dataset object in the new stats calculator object should be a reference to the new _dataset object in the copied statistics algorithm object.

Member Function Documentation

◆ _getDataset()

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
StatisticsDataset<CASA_STATP>* casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::_getDataset ( )
inlineprotected

◆ _getMedian()

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
CountedPtr<AccumType> casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::_getMedian ( ) const
inlineprotected

◆ _getMedianAbsDevMedian()

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
CountedPtr<AccumType> casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::_getMedianAbsDevMedian ( ) const
inlineprotected

◆ _getSortedArray()

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
std::vector<AccumType>& casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::_getSortedArray ( )
inline

◆ _setMedianAbsDevMedian()

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
void casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::_setMedianAbsDevMedian ( CountedPtr< AccumType >  medAbsDevMed)
inlineprotected

◆ _setSortedArray()

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
void casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::_setSortedArray ( const std::vector< AccumType > &  v)
inline

◆ clone()

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
virtual StatisticsAlgorithmQuantileComputer<CASA_STATP>* casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::clone ( ) const
pure virtual

◆ deleteSortedArray()

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
void casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::deleteSortedArray ( )

delete any (partially) sorted array

◆ operator=()

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
StatisticsAlgorithmQuantileComputer& casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::operator= ( const StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator > &  other)
protected

use copy semantics.

The _dataset object is not copied. It is the associated statistics algorithm object's responsibility to set the _dataset object in the new QuantileComputer calculator object upon an assignment. The underlying _dataset object in the new stats calculator object should be a reference to that in the newly assigned statistics algorithm object.

◆ reset()

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
virtual void casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::reset ( )
virtual

◆ setDataset()

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
void casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::setDataset ( StatisticsDataset< CASA_STATP > *  ds)

This must be called upon the copy or assignment of the associated statistics algorithm object.

Otherwise, there is generally no reason to call it.

◆ setMedian()

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
void casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::setMedian ( CountedPtr< AccumType >  median)
inline

Member Data Documentation

◆ _dataset

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
StatisticsDataset<CASA_STATP>* casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::_dataset
private

This pointer references the (non-pointer) object in the associated non-QuantileComputer computer object, so this should not be wrapped in a smart pointer.

Definition at line 119 of file StatisticsAlgorithmQuantileComputer.h.

Referenced by casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::_getDataset().

◆ _medAbsDevMed

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
CountedPtr<AccumType> casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::_medAbsDevMed
private

◆ _median

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
CountedPtr<AccumType> casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::_median
private

◆ _sortedArray

template<class AccumType , class DataIterator , class MaskIterator = const Bool *, class WeightsIterator = DataIterator>
std::vector<AccumType> casacore::StatisticsAlgorithmQuantileComputer< AccumType, DataIterator, MaskIterator, WeightsIterator >::_sortedArray
private

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