#include <itkWeightedCentroidKdTreeGenerator.h>
Inheritance diagram for itk::Statistics::WeightedCentroidKdTreeGenerator< TSample >:


The KdTree object stores measurment vectors in a k-d tree structure that is a binary tree. The partition value is the median value of one of the k dimension (partition dimension). The partition dimension is determined by the spread of measurement values in each dimension. The partition dimension is the dimension has the widest spread. Our implementation of k-d tree doesn't have any construction or insertion logic. Users should use this class or the KdTreeGenerator class.
This class is derived from the KdTreeGenerator class. The only difference between this class and the KdTreeGenerator class is that the nonterminal node type of this class is KdTreeWeightedCentroidNonterminalNode and that of the KdTreeGenerator is KdTreeNonterminalNode. Therefore, the public interface is identical to each other. The nonterminal node generation routines differ.
To run this generator, users should provides the bucket size (SetBucketSize method) and the input sample (SetSample method). The Update method will run this generator. To get the resulting KdTree object, call the GetOutput method.
Recent API changes: The static const macro to get the length of a measurement vector, 'MeasurementVectorSize' has been removed to allow the length of a measurement vector to be specified at run time. It is now obtained from the sample set as input. You may query this length using the function GetMeasurementVectorSize().
Definition at line 66 of file itkWeightedCentroidKdTreeGenerator.h.
Public Types | |
| typedef SmartPointer< const Self > | ConstPointer |
| typedef Superclass::KdTreeNodeType | KdTreeNodeType |
| typedef Superclass::KdTreeType | KdTreeType |
| typedef Superclass::MeasurementType | MeasurementType |
| typedef unsigned int | MeasurementVectorSizeType |
| typedef Superclass::MeasurementVectorType | MeasurementVectorType |
| typedef KdTreeType::Pointer | OutputPointer |
| typedef KdTreeType | OutputType |
| typedef SmartPointer< Self > | Pointer |
| typedef WeightedCentroidKdTreeGenerator | Self |
| typedef Superclass::SubsamplePointer | SubsamplePointer |
| typedef Superclass::SubsampleType | SubsampleType |
| typedef KdTreeGenerator< TSample > | Superclass |
Public Member Functions | |
| virtual LightObject::Pointer | CreateAnother () const |
| virtual void | DebugOff () const |
| virtual void | DebugOn () const |
| virtual void | Delete () |
| void | GenerateData () |
| Command * | GetCommand (unsigned long tag) |
| bool | GetDebug () const |
| virtual unsigned int | GetMeasurementVectorSize () const |
| const MetaDataDictionary & | GetMetaDataDictionary (void) const |
| MetaDataDictionary & | GetMetaDataDictionary (void) |
| virtual unsigned long | GetMTime () const |
| virtual const char * | GetNameOfClass () const |
| OutputPointer | GetOutput () |
| virtual int | GetReferenceCount () const |
| bool | HasObserver (const EventObject &event) const |
| void | InvokeEvent (const EventObject &) const |
| void | InvokeEvent (const EventObject &) |
| 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 | SetBucketSize (int size) |
| void | SetDebug (bool debugFlag) const |
| void | SetMetaDataDictionary (const MetaDataDictionary &rhs) |
| virtual void | SetReferenceCount (int) |
| void | SetSample (TSample *sample) |
| virtual void | UnRegister () const |
| void | Update () |
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 |
| unsigned int | TotalInstance |
Protected Member Functions | |
| virtual KdTreeNodeType * | GenerateNonterminalNode (int beginIndex, int endIndex, MeasurementVectorType &lowerBound, MeasurementVectorType &upperBound, int level) |
| KdTreeNodeType * | GenerateTreeLoop (int beginIndex, int endIndex, MeasurementVectorType &lowerBound, MeasurementVectorType &upperBound, int level) |
| SubsamplePointer | GetSubsample () |
| 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 |
| WeightedCentroidKdTreeGenerator () | |
| virtual | ~WeightedCentroidKdTreeGenerator () |
Protected Attributes | |
| int | m_ReferenceCount |
| SimpleFastMutexLock | m_ReferenceCountLock |
| 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 |
|
|||||
|
Reimplemented from itk::Statistics::KdTreeGenerator< TSample >. Definition at line 74 of file itkWeightedCentroidKdTreeGenerator.h. |
|
|||||
|
Typedef for the k-d tree node type Reimplemented from itk::Statistics::KdTreeGenerator< TSample >. Definition at line 88 of file itkWeightedCentroidKdTreeGenerator.h. |
|
|||||
|
Typedef for the k-d tree Reimplemented from itk::Statistics::KdTreeGenerator< TSample >. Definition at line 87 of file itkWeightedCentroidKdTreeGenerator.h. |
|
|||||
|
Reimplemented from itk::Statistics::KdTreeGenerator< TSample >. Definition at line 84 of file itkWeightedCentroidKdTreeGenerator.h. |
|
|||||
|
Typedef for the length of each measurement vector Definition at line 89 of file itkKdTreeGenerator.h. |
|
|||||
|
typedef alias for the source data container Reimplemented from itk::Statistics::KdTreeGenerator< TSample >. Definition at line 80 of file itkWeightedCentroidKdTreeGenerator.h. |
|
|||||
|
Typedef for the smart pointer to the k-d tree Definition at line 98 of file itkKdTreeGenerator.h. |
|
|||||
|
Type alias for the k-d tree type Definition at line 95 of file itkKdTreeGenerator.h. |
|
|||||
|
Reimplemented from itk::Statistics::KdTreeGenerator< TSample >. Definition at line 73 of file itkWeightedCentroidKdTreeGenerator.h. |
|
|||||
|
Standard class typedefs Reimplemented from itk::Statistics::KdTreeGenerator< TSample >. Definition at line 71 of file itkWeightedCentroidKdTreeGenerator.h. |
|
|||||
|
Typedef for the smart pointer to the Subsample Reimplemented from itk::Statistics::KdTreeGenerator< TSample >. Definition at line 86 of file itkWeightedCentroidKdTreeGenerator.h. |
|
|||||
|
Typedef for the internal Subsample Reimplemented from itk::Statistics::KdTreeGenerator< TSample >. Definition at line 85 of file itkWeightedCentroidKdTreeGenerator.h. |
|
|||||
|
Reimplemented from itk::Statistics::KdTreeGenerator< TSample >. Definition at line 72 of file itkWeightedCentroidKdTreeGenerator.h. |
|
|||||||||
|
Constructor |
|
|||||||||
|
Destructor Definition at line 96 of file itkWeightedCentroidKdTreeGenerator.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. |
|
|||||||||
|
Runs this k-d tree construction algorithm. |
|
||||||||||||||||||||||||||||
|
Nonterminal node generation routine Reimplemented from itk::Statistics::KdTreeGenerator< TSample >. |
|
||||||||||||||||||||||||||||
|
Tree generation loop |
|
|
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 macro to get the length of the measurement vectors that are being held in the 'sample' that is passed to this class |
|
|
|
|
|
|
|
|
|||||||||
|
Run-time type information (and related methods) Reimplemented from itk::Statistics::KdTreeGenerator< TSample >. |
|
||||||||||
|
Returns the pointer to the generated k-d tree. Definition at line 117 of file itkKdTreeGenerator.h. |
|
|
Gets the reference count on this object. Definition at line 98 of file itkLightObject.h. |
|
|||||||||
|
Returns the smart pointer to the internal Subsample object. Definition at line 144 of file itkKdTreeGenerator.h. |
|
|
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. |
|
|
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. |
|
|
|||||||||
|
Method for creation through the object factory. Reimplemented from itk::Statistics::KdTreeGenerator< TSample >. |
|
||||||||||||
|
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::KdTreeGenerator< TSample >. |
|
||||||||||||
|
|
|
|
Increase the reference count (mark as used by another object). Reimplemented from itk::LightObject. |
|
|
Remove all observers . |
|
|
Remove the observer with this tag value. |
|
||||||||||
|
Sets the number of measurement vectors that can be stored in a terminal node. |
|
|
Set the value of the debug flag. A non-zero value turns debugging on. |
|
|
Referenced by itk::Object::GlobalWarningDisplayOff(), and itk::Object::GlobalWarningDisplayOn(). |
|
|
|
|
|
Sets the reference count (use with care) Reimplemented from itk::LightObject. |
|
||||||||||
|
Sets the input sample that provides the measurement vectors. |
|
|
Decrease the reference count (release by another object). Reimplemented from itk::LightObject. |
|
||||||||||
|
Runs this k-d tree construction algorithm. Definition at line 121 of file itkKdTreeGenerator.h. References HardConnectedComponentImageFilter::GenerateData(). |
|
|
|
|
|
Definition at line 94 of file itkObject.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. |
|
|
|
|
|||||
|
The number of measurement vectors in an object of this class. Definition at line 128 of file itkKdTreeGenerator.h. |
1.4.2 written by Dimitri van Heesch,
© 1997-2000