ITK  4.13.0
Insight Segmentation and Registration Toolkit
itkManifoldParzenWindowsPointSetFunction.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 #ifndef itkManifoldParzenWindowsPointSetFunction_h
19 #define itkManifoldParzenWindowsPointSetFunction_h
20 
21 #include "itkPointSetFunction.h"
22 
24 #include "itkMatrix.h"
25 #include "itkPointSet.h"
26 #include "itkPointsLocator.h"
27 #include "itkVector.h"
28 
29 #include <vector>
30 
31 namespace itk
32 {
33 
44 template <typename TPointSet, typename TOutput = double, typename TCoordRep = double>
45 class ITK_TEMPLATE_EXPORT ManifoldParzenWindowsPointSetFunction
46 : public PointSetFunction<TPointSet, TOutput, TCoordRep>
47 {
48 public:
53 
55  itkNewMacro(Self);
56 
58  itkStaticConstMacro( PointDimension, unsigned int, TPointSet::PointDimension );
59 
60  typedef typename Superclass::InputPointSetType InputPointSetType;
61  typedef typename Superclass::InputPointType InputPointType;
62 
64  typedef TPointSet PointSetType;
66  typedef typename PointSetType::PointsContainer PointsContainer;
67  typedef typename PointsContainer::ElementIdentifier PointIdentifier;
68 
70  typedef TOutput RealType;
71  typedef TOutput OutputType;
72  typedef TCoordRep CoordRepType;
73 
77 
78  typedef typename Statistics::
82  typedef std::vector<GaussianPointer> GaussianContainerType;
84 
92  itkSetMacro( CovarianceKNeighborhood, unsigned int );
93 
95  itkGetConstMacro( CovarianceKNeighborhood, unsigned int );
96 
103  itkSetMacro( EvaluationKNeighborhood, unsigned int );
104 
106  itkGetConstMacro( EvaluationKNeighborhood, unsigned int );
107 
112  itkSetMacro( RegularizationSigma, RealType );
113 
115  itkGetConstMacro( RegularizationSigma, RealType );
116 
122  itkSetMacro( KernelSigma, RealType );
123 
125  itkGetConstMacro( KernelSigma, RealType );
126 
131  itkSetMacro( Normalize, bool );
132 
137  itkGetConstMacro( Normalize, bool );
138 
143  itkBooleanMacro( Normalize );
144 
150  itkSetMacro( UseAnisotropicCovariances, bool );
151 
157  itkGetConstMacro( UseAnisotropicCovariances, bool );
158 
164  itkBooleanMacro( UseAnisotropicCovariances );
165 
167  virtual void SetInputPointSet( const InputPointSetType * ) ITK_OVERRIDE;
168 
170  virtual TOutput Evaluate( const InputPointType & ) const ITK_OVERRIDE;
171 
173  GaussianConstPointer GetGaussian( PointIdentifier ) const;
174 
176  itkGetModifiableObjectMacro(PointsLocator, PointsLocatorType );
177 
178 protected:
180  virtual ~ManifoldParzenWindowsPointSetFunction() ITK_OVERRIDE;
181  void PrintSelf( std::ostream& os, Indent indent ) const ITK_OVERRIDE;
182 
183  void GenerateData();
184 
185 private:
186  ITK_DISALLOW_COPY_AND_ASSIGN(ManifoldParzenWindowsPointSetFunction);
187 
188  typename PointsLocatorType::Pointer m_PointsLocator;
189 
190  unsigned int m_CovarianceKNeighborhood;
191  unsigned int m_EvaluationKNeighborhood;
192  RealType m_RegularizationSigma;
193  RealType m_KernelSigma;
194 
196  bool m_Normalize;
197  bool m_UseAnisotropicCovariances;
198 };
199 
200 } // end namespace itk
201 
202 #ifndef ITK_MANUAL_INSTANTIATION
203 #include "itkManifoldParzenWindowsPointSetFunction.hxx"
204 #endif
205 
206 #endif
Light weight base class for most itk classes.
Statistics::GaussianMembershipFunction< PointType > GaussianType
Point set function based on n-dimensional parzen windowing.
PointsLocatorType::NeighborsIdentifierType NeighborsIdentifierType
Accelerate geometric searches for points.
PointSetFunction< TPointSet, TOutput, TCoordRep > Superclass
GaussianMembershipFunction models class membership through a multivariate Gaussian function...
Evaluates a function of an image at specified position.
TreeType::InstanceIdentifierVectorType NeighborsIdentifierType
Control indentation during Print() invocation.
Definition: itkIndent.h:49