ITK  4.2.0
Insight Segmentation and Registration Toolkit
itkExpectationBasedPointSetToPointSetMetricv4.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 __itkExpectationBasedPointSetToPointSetMetricv4_h
19 #define __itkExpectationBasedPointSetToPointSetMetricv4_h
20 
22 #include "itkPointSet.h"
23 #include "itkImage.h"
24 
25 namespace itk
26 {
43 template<class TFixedPointSet, class TMovingPointSet = TFixedPointSet>
45  public PointSetToPointSetMetricv4<TFixedPointSet, TMovingPointSet>
46 {
47 public:
48 
54 
56  itkNewMacro( Self );
57 
60 
62  typedef typename Superclass::MeasureType MeasureType;
63  typedef typename Superclass::DerivativeType DerivativeType;
64  typedef typename Superclass::LocalDerivativeType LocalDerivativeType;
65  typedef typename Superclass::PointType PointType;
67  typedef typename Superclass::PointIdentifier PointIdentifier;
68  typedef typename Superclass::NeighborsIdentifierType NeighborsIdentifierType;
69 
73  virtual MeasureType GetLocalNeighborhoodValue( const PointType & ) const;
74 
78  virtual void GetLocalNeighborhoodValueAndDerivative( const PointType &,
79  MeasureType &, LocalDerivativeType & ) const;
80 
86  itkSetMacro( PointSetSigma, CoordRepType );
87 
89  itkGetConstMacro( PointSetSigma, CoordRepType );
90 
95  itkSetMacro( EvaluationKNeighborhood, unsigned int );
96 
101  itkGetConstMacro( EvaluationKNeighborhood, unsigned int );
102 
103  void Initialize( void ) throw ( ExceptionObject );
104 
105 protected:
107  virtual ~ExpectationBasedPointSetToPointSetMetricv4();
108 
110  void PrintSelf( std::ostream & os, Indent indent ) const;
111 
112 private:
113  ExpectationBasedPointSetToPointSetMetricv4( const Self & ); //purposely not implemented
114  void operator=( const Self & ); //purposely not implemented
115 
116  typedef typename PointType::VectorType VectorType;
117  typedef typename NeighborsIdentifierType::const_iterator NeighborsIterator;
118 
119  CoordRepType m_PointSetSigma;
120  MeasureType m_PreFactor;
121  MeasureType m_Denominator;
122  unsigned int m_EvaluationKNeighborhood;
123 
124 };
125 } // end namespace itk
126 
127 #ifndef ITK_MANUAL_INSTANTIATION
128 #include "itkExpectationBasedPointSetToPointSetMetricv4.hxx"
129 #endif
130 
131 #endif
132