ITK  5.2.0
Insight Toolkit
itkCumulativeGaussianCostFunction.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright NumFOCUS
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 itkCumulativeGaussianCostFunction_h
19 #define itkCumulativeGaussianCostFunction_h
20 
22 #include "ITKOptimizersExport.h"
23 
24 namespace itk
25 {
52 {
53 public:
59 
62 
64  itkNewMacro(Self);
65 
67  using ParametersType = Superclass::ParametersType;
68  using MeasureType = Superclass::MeasureType;
69  using DerivativeType = Superclass::DerivativeType;
70 
73  enum
74  {
75  SpaceDimension = 4
76  };
77 
79  void
80  GetDerivative(const ParametersType & itkNotUsed(parameters), DerivativeType & itkNotUsed(derivative)) const override
81  {}
82 
84  MeasureType
85  GetValue(const ParametersType & parameters) const override;
86 
88  MeasureType *
89  GetValuePointer(ParametersType & parameters);
90 
92  double
93  CalculateFitError(MeasureType * setTestArray);
94 
96  double
97  EvaluateCumulativeGaussian(double argument) const;
98 
100  unsigned int
101  GetNumberOfParameters() const override;
102 
104  unsigned int
105  GetNumberOfValues() const override;
106 
108  void
109  Initialize(unsigned int rangeDimension);
110 
112  void
113  SetOriginalDataArray(MeasureType * setOriginalDataArray);
114 
115 protected:
117  ~CumulativeGaussianCostFunction() override;
118 
119  void
120  PrintSelf(std::ostream & os, Indent indent) const override;
121 
122 private:
125 
127  unsigned int m_RangeDimension;
128 
133 };
134 } // end namespace itk
135 
136 #endif
itk::MultipleValuedCostFunction
This class is a base for the CostFunctions returning a multiple values.
Definition: itkMultipleValuedCostFunction.h:35
itk::OptimizerParameters< TInternalComputationValueType >
itk::CumulativeGaussianCostFunction::m_RangeDimension
unsigned int m_RangeDimension
Definition: itkCumulativeGaussianCostFunction.h:127
itk::CumulativeGaussianCostFunction::m_MeasurePointer
MeasureType * m_MeasurePointer
Definition: itkCumulativeGaussianCostFunction.h:131
itk::CumulativeGaussianCostFunction::m_Parameters
ParametersType m_Parameters
Definition: itkCumulativeGaussianCostFunction.h:132
itk::SmartPointer< Self >
itk::Indent
Control indentation during Print() invocation.
Definition: itkIndent.h:49
itk::LightObject
Light weight base class for most itk classes.
Definition: itkLightObject.h:59
itk::CumulativeGaussianCostFunction::GetDerivative
void GetDerivative(const ParametersType &, DerivativeType &) const override
Definition: itkCumulativeGaussianCostFunction.h:80
itk::CumulativeGaussianCostFunction::DerivativeType
Superclass::DerivativeType DerivativeType
Definition: itkCumulativeGaussianCostFunction.h:69
itk::CumulativeGaussianCostFunction::m_OriginalDataArray
MeasureType * m_OriginalDataArray
Definition: itkCumulativeGaussianCostFunction.h:124
itkMultipleValuedCostFunction.h
itk::CumulativeGaussianCostFunction
Cost function for the Cumulative Gaussian Optimizer.
Definition: itkCumulativeGaussianCostFunction.h:51
itk
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....
Definition: itkAnnulusOperator.h:24
itk::Array< double >
itk::CumulativeGaussianCostFunction::m_Measure
MeasureType m_Measure
Definition: itkCumulativeGaussianCostFunction.h:130