#include <itkVariableDimensionHistogram.h>
Inheritance diagram for itk::Statistics::VariableDimensionHistogram< TMeasurement, TFrequencyContainer >:


This class stores measurement vectors in the context of n-dimensional histogram.
VariableDimensionHistogram represents an ND histogram. Histogram bins can be regularly or irregularly spaced. The storage for the histogram is managed via the FrequencyContainer specified by the template argument. The default frequency container is a DenseFrequencyContainer. A SparseFrequencyContainer can be used as an alternative.
Frequencies of a bin (SetFrequency(), IncreaseFrequency()) can be specified by measurement, index, or instance identifier.
Measurements can be queried by bin index or instance identifier. In this case, the measurement returned in the centroid of the histogram bin.
The Initialize() method is used to specified the number of bins for each dimension of the histogram. An overloaded version also allows for regularly spaced bins to defined. To define irregularly sized bins, use the SetBinMin()/SetBinMax() methods.
Definition at line 71 of file itkVariableDimensionHistogram.h.
Public Types | |
| typedef std::vector< BinMaxVectorType > | BinMaxContainerType |
| typedef std::vector< MeasurementType > | BinMaxVectorType |
| typedef std::vector< BinMinVectorType > | BinMinContainerType |
| typedef std::vector< MeasurementType > | BinMinVectorType |
| typedef SmartPointer< const Self > | ConstPointer |
| typedef FrequencyContainerType::Pointer | FrequencyContainerPointer |
| typedef TFrequencyContainer | FrequencyContainerType |
| typedef FrequencyContainerType::FrequencyType | FrequencyType |
| typedef itk::Array< long > | IndexType |
| typedef IndexType::ValueType | IndexValueType |
| typedef Superclass::InstanceIdentifier | InstanceIdentifier |
| typedef TMeasurement | MeasurementType |
| typedef Superclass::MeasurementVectorSizeType | MeasurementVectorSizeType |
| typedef Superclass::MeasurementVectorType | MeasurementVectorType |
| typedef SmartPointer< Self > | Pointer |
| typedef VariableDimensionHistogram | Self |
| typedef itk::Array< long > | SizeType |
| typedef SizeType::ValueType | SizeValueType |
| typedef Sample< Array< TMeasurement > > | Superclass |
| typedef FrequencyContainerType::TotalFrequencyType | TotalFrequencyType |
| typedef MeasurementVectorType | ValueType |
Public Member Functions | |
| ConstIterator | Begin () const |
| Iterator | Begin () |
| virtual LightObject::Pointer | CreateAnother () const |
| virtual void | DebugOff () const |
| virtual void | DebugOn () const |
| virtual void | Delete () |
| ConstIterator | End () const |
| Iterator | End () |
| const MeasurementType & | GetBinMax (const unsigned int dimension, const unsigned long nbin) const |
| const MeasurementType & | GetBinMaxFromValue (const unsigned int dimension, const float value) const |
| const MeasurementType & | GetBinMin (const unsigned int dimension, const unsigned long nbin) const |
| const MeasurementType & | GetBinMinFromValue (const unsigned int dimension, const float value) const |
| virtual bool | GetClipBinsAtEnds () |
| Command * | GetCommand (unsigned long tag) |
| bool | GetDebug () const |
| const BinMaxVectorType & | GetDimensionMaxs (const unsigned int dimension) const |
| const BinMinVectorType & | GetDimensionMins (const unsigned int dimension) const |
| FrequencyType | GetFrequency (const unsigned long n, const unsigned int dimension) const |
| FrequencyType | GetFrequency (const IndexType &index) const |
| FrequencyType | GetFrequency (const InstanceIdentifier &id) const |
| MeasurementVectorType & | GetHistogramMaxFromIndex (const IndexType &index) |
| MeasurementVectorType & | GetHistogramMaxFromValue (const MeasurementVectorType &measurement) |
| MeasurementVectorType & | GetHistogramMinFromIndex (const IndexType &index) |
| MeasurementVectorType & | GetHistogramMinFromValue (const MeasurementVectorType &measurement) |
| const IndexType & | GetIndex (const InstanceIdentifier &id) const |
| bool | GetIndex (const MeasurementVectorType &measurement, IndexType &index) const |
| InstanceIdentifier | GetInstanceIdentifier (const IndexType &index) const |
| const BinMaxContainerType & | GetMaxs () const |
| MeasurementType | GetMeasurement (const unsigned long n, const unsigned int dimension) const |
| const MeasurementVectorType & | GetMeasurementVector (const IndexType &index) const |
| const MeasurementVectorType & | GetMeasurementVector (const InstanceIdentifier &id) const |
| virtual MeasurementVectorSizeType | GetMeasurementVectorSize () const |
| const MetaDataDictionary & | GetMetaDataDictionary (void) const |
| MetaDataDictionary & | GetMetaDataDictionary (void) |
| const BinMinContainerType & | GetMins () const |
| virtual unsigned long | GetMTime () const |
| virtual const char * | GetNameOfClass () const |
| virtual int | GetReferenceCount () const |
| SizeValueType | GetSize (const unsigned int dimension) const |
| SizeType | GetSize () const |
| TotalFrequencyType | GetTotalFrequency () const |
| bool | HasObserver (const EventObject &event) const |
| bool | IncreaseFrequency (const MeasurementVectorType &measurement, const FrequencyType value) |
| bool | IncreaseFrequency (const IndexType &index, const FrequencyType value) |
| bool | IncreaseFrequency (const InstanceIdentifier &id, const FrequencyType value) |
| void | Initialize (const SizeType &size, MeasurementVectorType &lowerBound, MeasurementVectorType &upperBound) |
| void | Initialize (const SizeType &size) |
| void | InvokeEvent (const EventObject &) const |
| void | InvokeEvent (const EventObject &) |
| bool | IsIndexOutOfBounds (const IndexType &index) const |
| virtual void | Modified () const |
| void | Print (std::ostream &os, Indent indent=0) const |
| virtual void | Register () const |
| void | RemoveAllObservers () |
| void | RemoveObserver (unsigned long tag) |
| void | SetBinMax (const unsigned int dimension, unsigned long nbin, const MeasurementType max) |
| void | SetBinMin (const unsigned int dimension, const unsigned long nbin, const MeasurementType min) |
| virtual void | SetClipBinsAtEnds (bool _arg) |
| void | SetDebug (bool debugFlag) const |
| bool | SetFrequency (const MeasurementVectorType &measurement, const FrequencyType value) |
| bool | SetFrequency (const IndexType &index, const FrequencyType value) |
| bool | SetFrequency (const InstanceIdentifier &id, const FrequencyType value) |
| void | SetFrequency (const FrequencyType value) |
| Set Get macros for the length of the measurement vector *virtual void | SetMeasurementVectorSize (const MeasurementVectorSizeType s) |
| void | SetMetaDataDictionary (const MetaDataDictionary &rhs) |
| virtual void | SetReferenceCount (int) |
| void | SetToZero () |
| unsigned int | Size () const |
| virtual void | UnRegister () const |
Static Public Member Functions | |
| static void | BreakOnError () |
| static bool | GetGlobalWarningDisplay () |
| static void | GlobalWarningDisplayOff () |
| static void | GlobalWarningDisplayOn () |
| static Pointer | New () |
| This is a global flag that controls whether any warning *or error messages are displayed *static void | SetGlobalWarningDisplay (bool flag) |
Public Attributes | |
| Allow people to add remove invoke observers(callbacks) to any ITK *object.This is an implementation of the subject/observer design *pattern.An observer is added by specifying an event to respond to *and an itk unsigned lon | AddObserver )(const EventObject &event, Command *) const |
| This is a global flag that controls whether any | debug |
| Get the pth percentile value for a dimension **Let assume * | interval = max - min |
| Get the pth percentile value for a dimension **Let assume * | max = max value of the dimension of the bin |
| Get the pth percentile value for a dimension **Let assume * | min = min value of the dimension of the bin |
| Get the pth percentile value for a dimension **Let assume | n = the index of the bin where the p-th percentile value is |
| *and | pb |
| Get the pth percentile value for a dimension **Let assume * | pp = cumlated proportion until n-1 bin |
| *and *the percentile | value |
Protected Member Functions | |
| bool | PrintObservers (std::ostream &os, Indent indent) const |
| void | PrintSelf (std::ostream &os, Indent indent) const |
| virtual void | PrintTrailer (std::ostream &os, Indent indent) const |
| Sample () | |
| void | SetMeasurementVectorSize (const MeasurementVectorSizeType) |
| VariableDimensionHistogram () | |
| virtual | ~VariableDimensionHistogram () |
Protected Attributes | |
| int | m_ReferenceCount |
| SimpleFastMutexLock | m_ReferenceCountLock |
| SizeType | m_Size |
| Methods invoked by virtual Print() to print information about the object *including superclasses.Typically not called by the user(use Print()*instead) but used in the hierarchical print process to combine the *output of several classes.*/virtual void PrintSelf(std voi | PrintHeader )(std::ostream &os, Indent indent) const |
Classes | |
| class | ConstIterator |
| class | Iterator |
|
|||||
|
Definition at line 117 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Definition at line 115 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Definition at line 116 of file itkVariableDimensionHistogram.h. |
|
|||||
|
bin min max value storage types Definition at line 114 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Reimplemented from itk::Statistics::Sample< Array< TMeasurement > >. Definition at line 80 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Definition at line 99 of file itkVariableDimensionHistogram.h. |
|
|||||
|
frequency container typedef Definition at line 98 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Frequency value and TotalFrequency type from superclass Reimplemented from itk::Statistics::Sample< Array< TMeasurement > >. Definition at line 102 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Index typedef support. An index is used to access pixel values. Definition at line 106 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Definition at line 107 of file itkVariableDimensionHistogram.h. |
|
|||||
|
InstanceIdentifier typedef. This identifier is a unique sequential id for each measurement vector in a Sample subclass. Reimplemented from itk::Statistics::Sample< Array< TMeasurement > >. Definition at line 93 of file itkVariableDimensionHistogram.h. |
|
|||||
|
type of an element of a measurement vector Reimplemented from itk::Statistics::Sample< Array< TMeasurement > >. Definition at line 86 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Typedef for the length of each measurement vector Reimplemented from itk::Statistics::Sample< Array< TMeasurement > >. Definition at line 94 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Common sample class typedefs Reimplemented from itk::Statistics::Sample< Array< TMeasurement > >. Definition at line 92 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Reimplemented from itk::Statistics::Sample< Array< TMeasurement > >. Definition at line 79 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Standard typedefs Reimplemented from itk::Statistics::Sample< Array< TMeasurement > >. Definition at line 77 of file itkVariableDimensionHistogram.h. |
|
|||||
|
size array type Definition at line 110 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Definition at line 111 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Reimplemented from itk::Statistics::Sample< Array< TMeasurement > >. Definition at line 78 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Total frequency type Reimplemented from itk::Statistics::Sample< Array< TMeasurement > >. Definition at line 103 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Definition at line 95 of file itkVariableDimensionHistogram.h. |
|
|||||||||
|
|
|
|||||||||
|
Definition at line 482 of file itkVariableDimensionHistogram.h. |
|
||||||||||
|
Definition at line 468 of file itkVariableDimensionHistogram.h. |
|
||||||||||
|
Definition at line 457 of file itkVariableDimensionHistogram.h. |
|
|
This method is called when itkExceptionMacro executes. It allows the debugger to break on error. |
|
|
Create an object from an instance, potentially deferring to a factory. This method allows you to create an instance of an object that is exactly the same type as the referring object. This is useful in cases where an object has been cast back to a base class. Reimplemented from itk::LightObject. |
|
|
Turn debugging output off. |
|
|
Turn debugging output on. |
|
|
Delete an itk object. This method should always be used to delete an object when the new operator was used to create it. Using the C delete method will not work with reference counting. |
|
||||||||||
|
Definition at line 474 of file itkVariableDimensionHistogram.h. References itk::fem::this. |
|
||||||||||
|
Definition at line 463 of file itkVariableDimensionHistogram.h. References itk::fem::this. |
|
||||||||||||||||
|
Get the maximum value of nth bin of dimension d Definition at line 181 of file itkVariableDimensionHistogram.h. |
|
||||||||||||||||
|
Get the maximum of the bin along dimension d corresponding to a particular measurement. |
|
||||||||||||||||
|
Get the minimum value of nth bin of dimension d Definition at line 176 of file itkVariableDimensionHistogram.h. |
|
||||||||||||||||
|
Get the minimum of the bin along dimension d corresponding to a particular measurement. |
|
|||||||||
|
Is set to false if the bins at edges of the histogram extend to +/- infinity. |
|
|
Get the command associated with the given tag. NOTE: This returns a pointer to a Command, but it is safe to asign this to a Command::Pointer. Since Command inherits from LightObject, at this point in the code, only a pointer or a reference to the Command can be used. |
|
|
Get the value of the debug flag. |
|
||||||||||
|
Get the vector of maximums along a dimension Definition at line 210 of file itkVariableDimensionHistogram.h. |
|
||||||||||
|
Get the vector of bin minimums along a dimension Definition at line 206 of file itkVariableDimensionHistogram.h. |
|
||||||||||||||||
|
Get the frequency of a dimension's nth element. |
|
||||||||||
|
Get the frequency of an index |
|
||||||||||
|
Get the frequency of an instance indentifier Implements itk::Statistics::Sample< Array< TMeasurement > >. Definition at line 236 of file itkVariableDimensionHistogram.h. |
|
|
|
|
||||||||||
|
Get the maximums of the bin corresponding to a particular index |
|
||||||||||
|
Get the maximums of the bin corresponding to a particular measurement |
|
||||||||||
|
Get the minimums of the bin corresponding to a particular index |
|
||||||||||
|
Get the minimums of the bin corresponding to a particular measurement |
|
||||||||||
|
Get the index that is uniquely labelled by an instance identifier The corresponding id is the offset of the index This method uses ImageBase::ComputeIndex() method |
|
||||||||||||||||
|
Get the index of histogram corresponding to the specified measurement value. Returns true if index is valid and false if the measurement is outside the histogram |
|
||||||||||
|
Get the instance identifier of the bin that is indexed by the index. The corresponding instance identifier is the offset of the index This method uses ImageBase::ComputeIndex() method |
|
|||||||||
|
Method the maximums of the bins Definition at line 218 of file itkVariableDimensionHistogram.h. |
|
||||||||||||||||
|
Get the measurement a bin along a specified dimension. This is the midpoint of the bin along that dimension. |
|
||||||||||
|
Get the measurement of an index. This is the centroid of the bin. |
|
||||||||||
|
Get the measurement of an instance identifier. This is the centroid of the bin. Implements itk::Statistics::Sample< Array< TMeasurement > >. |
|
|
|
|
|
|
|
|
|
|
|||||||||
|
Get the minimums of the bins Definition at line 214 of file itkVariableDimensionHistogram.h. |
|
|
|||||||||
|
Run-time type information (and related methods). Reimplemented from itk::Statistics::Sample< Array< TMeasurement > >. |
|
|
Gets the reference count on this object. Definition at line 98 of file itkLightObject.h. |
|
||||||||||
|
Get the size of histogram along a specified dimension Definition at line 170 of file itkVariableDimensionHistogram.h. References itk::m_Size. |
|
||||||||||
|
Get the size (N-dimensional) of the histogram Definition at line 166 of file itkVariableDimensionHistogram.h. References itk::m_Size. |
|
|||||||||
|
Get the total frequency in the histogram Implements itk::Statistics::Sample< Array< TMeasurement > >. |
|
|
Definition at line 100 of file itkObject.h. References itk::Object::SetGlobalWarningDisplay(). |
|
|
Definition at line 98 of file itkObject.h. References itk::Object::SetGlobalWarningDisplay(). |
|
|
Return true if an observer is registered for this event. |
|
||||||||||||||||
|
Increase the frequency of a measurement. Frequency is increased by the specified value. Returns false if the measurement is outside the bounds of the histogram. |
|
||||||||||||||||
|
Increase the frequency of an index. Frequency is increased by the specified value. Returns false if the bin is out of bounds. |
|
||||||||||||||||
|
Increase the frequency of an instance identifier. Frequency is increased by the specified value. Returns false if the bin is out of bounds. Definition at line 264 of file itkVariableDimensionHistogram.h. |
|
||||||||||||||||||||
|
Initialize the histogram using equal size bins. To assign bin's min and max values along each dimension use SetBinMin() and SetBinMax() functions. |
|
||||||||||
|
Initialize the histogram, generating the offset table and preparing the frequency container. Subclasses should call this method in their Initialize() method. |
|
|
Call Execute on all the Commands observing this event id. The actions triggered by this call doesn't modify this object. |
|
|
Call Execute on all the Commands observing this event id. |
|
||||||||||
|
Returns true if the given index is out of bound meaning one of index is not between [0, last index] |
|
|
|||||||||
|
standard New() method support Reimplemented from itk::Object. |
|
||||||||||||
|
Cause the object to print itself out. |
|
||||||||||||
|
|
|
||||||||||||||||
|
Methods invoked by Print() to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes. Reimplemented from itk::Statistics::Sample< Array< TMeasurement > >. |
|
||||||||||||
|
|
|
|
Increase the reference count (mark as used by another object). Reimplemented from itk::LightObject. |
|
|
Remove all observers . |
|
|
Remove the observer with this tag value. |
|
|
Definition at line 130 of file itkSample.h. |
|
||||||||||||||||||||
|
Set the maximum value of nth bin of dimension d Definition at line 191 of file itkVariableDimensionHistogram.h. |
|
||||||||||||||||||||
|
Set the minimum value of nth bin of dimension d Definition at line 186 of file itkVariableDimensionHistogram.h. |
|
||||||||||
|
Set to false to have the bins at edges of the histogram extend to +/- infinity. |
|
|
Set the value of the debug flag. A non-zero value turns debugging on. |
|
||||||||||||||||
|
Set the frequency of a measurement. Returns false if the bin is out of bounds. |
|
||||||||||||||||
|
Set the frequency of an index. Returns false if the bin is out of bounds. |
|
||||||||||||||||
|
Set the frequency of an instance identifier. Returns false if the bin is out of bounds. Definition at line 247 of file itkVariableDimensionHistogram.h. |
|
||||||||||
|
Set all the bins in the histogram to a specified frequency |
|
|
Referenced by itk::Object::GlobalWarningDisplayOff(), and itk::Object::GlobalWarningDisplayOn(). |
|
|
Definition at line 113 of file itkSample.h. |
|
||||||||||
|
Set the length of each measurement vector = dimension of the histogram. The method will destructively set the size of all other parameters of the histogram. This method should be called only from the Initialize() method. |
|
|
|
|
|
Sets the reference count (use with care) Reimplemented from itk::LightObject. |
|
|||||||||
|
Initialize the values of the histogram bins to zero |
|
|||||||||
|
Returns the number of instances (bins or cells) in this container Implements itk::Statistics::Sample< Array< TMeasurement > >. |
|
|
Decrease the reference count (release by another object). Reimplemented from itk::LightObject. |
|
|
|
|
|
Definition at line 94 of file itkObject.h. |
|
|||||
|
Definition at line 305 of file itkVariableDimensionHistogram.h. |
|
|
Number of uses of this object by other objects. Definition at line 119 of file itkLightObject.h. |
|
|
Mutex lock to protect modification to the reference count Definition at line 122 of file itkLightObject.h. |
|
|||||
|
Definition at line 490 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Definition at line 304 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Definition at line 303 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Definition at line 302 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Initial value: Definition at line 307 of file itkVariableDimensionHistogram.h. |
|
|||||
|
Definition at line 306 of file itkVariableDimensionHistogram.h. |
|
|
|
|
|||||
|
Initial value: * min + ((p - pp ) / pb) * interval * If p is greater than or equal to 0.5 * the percentile value = * max - ((pp - p) / pb) * interval */ double Quantile(const unsigned int dimension, const double &p) const Definition at line 310 of file itkVariableDimensionHistogram.h. |
1.4.2 written by Dimitri van Heesch,
© 1997-2000