ITK  5.2.0
Insight Toolkit
itkMeanSquaresImageToImageMetricv4.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 itkMeanSquaresImageToImageMetricv4_h
19 #define itkMeanSquaresImageToImageMetricv4_h
20 
24 
25 namespace itk
26 {
27 
40 template <typename TFixedImage,
41  typename TMovingImage,
42  typename TVirtualImage = TFixedImage,
43  typename TInternalComputationValueType = double,
44  typename TMetricTraits =
45  DefaultImageToImageMetricTraitsv4<TFixedImage, TMovingImage, TVirtualImage, TInternalComputationValueType>>
46 class ITK_TEMPLATE_EXPORT MeanSquaresImageToImageMetricv4
47  : public ImageToImageMetricv4<TFixedImage, TMovingImage, TVirtualImage, TInternalComputationValueType, TMetricTraits>
48 {
49 public:
50  ITK_DISALLOW_COPY_AND_MOVE(MeanSquaresImageToImageMetricv4);
51 
54  using Superclass =
58 
60  itkNewMacro(Self);
61 
64 
65  using DerivativeType = typename Superclass::DerivativeType;
66 
67  using FixedImagePointType = typename Superclass::FixedImagePointType;
68  using FixedImagePixelType = typename Superclass::FixedImagePixelType;
69  using FixedImageGradientType = typename Superclass::FixedImageGradientType;
70 
71  using MovingImagePointType = typename Superclass::MovingImagePointType;
72  using MovingImagePixelType = typename Superclass::MovingImagePixelType;
73  using MovingImageGradientType = typename Superclass::MovingImageGradientType;
74 
75  using MovingTransformType = typename Superclass::MovingTransformType;
76  using JacobianType = typename Superclass::JacobianType;
77  using VirtualImageType = typename Superclass::VirtualImageType;
78  using VirtualIndexType = typename Superclass::VirtualIndexType;
79  using VirtualPointType = typename Superclass::VirtualPointType;
80  using VirtualPointSetType = typename Superclass::VirtualPointSetType;
81 
82  /* Image dimension accessors */
83  static constexpr typename TVirtualImage::ImageDimensionType VirtualImageDimension = TVirtualImage::ImageDimension;
84  static constexpr typename TFixedImage::ImageDimensionType FixedImageDimension = TFixedImage::ImageDimension;
85  static constexpr typename TMovingImage::ImageDimensionType MovingImageDimension = TMovingImage::ImageDimension;
86 
87 protected:
89  ~MeanSquaresImageToImageMetricv4() override = default;
90 
92  ThreadedImageRegionPartitioner<Superclass::VirtualImageDimension>,
93  Superclass,
94  Self>;
95  friend class MeanSquaresImageToImageMetricv4GetValueAndDerivativeThreader<ThreadedIndexedContainerPartitioner,
96  Superclass,
97  Self>;
100  ThreadedImageRegionPartitioner<Superclass::VirtualImageDimension>,
101  Superclass,
102  Self>;
104  MeanSquaresImageToImageMetricv4GetValueAndDerivativeThreader<ThreadedIndexedContainerPartitioner, Superclass, Self>;
105 
106  void
107  PrintSelf(std::ostream & os, Indent indent) const override;
108 };
109 
110 } // end namespace itk
111 
112 #ifndef ITK_MANUAL_INSTANTIATION
113 # include "itkMeanSquaresImageToImageMetricv4.hxx"
114 #endif
115 
116 #endif
itk::ImageToImageMetricv4::FixedImageGradientType
typename MetricTraits::FixedImageGradientType FixedImageGradientType
Definition: itkImageToImageMetricv4.h:297
itk::ThreadedImageRegionPartitioner
Class for partitioning of an ImageRegion.
Definition: itkThreadedImageRegionPartitioner.h:45
itk::MeanSquaresImageToImageMetricv4GetValueAndDerivativeThreader
Processes points for MeanSquaresImageToImageMetricv4 GetValueAndDerivative.
Definition: itkMeanSquaresImageToImageMetricv4GetValueAndDerivativeThreader.h:33
itk::SmartPointer< Self >
itk::ImageToImageMetricv4::JacobianType
typename Superclass::JacobianType JacobianType
Definition: itkImageToImageMetricv4.h:227
itk::ImageToImageMetricv4::MovingImagePointType
typename MovingImageType::PointType MovingImagePointType
Definition: itkImageToImageMetricv4.h:246
itk::ImageToImageMetricv4::FixedImagePointType
typename FixedImageType::PointType FixedImagePointType
Definition: itkImageToImageMetricv4.h:239
itkDefaultImageToImageMetricTraitsv4.h
itk::LightObject
Light weight base class for most itk classes.
Definition: itkLightObject.h:59
itkImageToImageMetricv4.h
itk::ImageToImageMetricv4::VirtualIndexType
typename Superclass::VirtualIndexType VirtualIndexType
Definition: itkImageToImageMetricv4.h:261
itk
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....
Definition: itkAnnulusOperator.h:24
itk::ImageToImageMetricv4::MovingImageGradientType
typename MetricTraits::MovingImageGradientType MovingImageGradientType
Definition: itkImageToImageMetricv4.h:298
itk::MeanSquaresImageToImageMetricv4
Class implementing a mean squares metric.
Definition: itkMeanSquaresImageToImageMetricv4.h:46
itk::ImageToImageMetricv4::VirtualPointType
typename Superclass::VirtualPointType VirtualPointType
Definition: itkImageToImageMetricv4.h:258
itk::ImageToImageMetricv4
Definition: itkImageToImageMetricv4.h:174
itk::ImageToImageMetricv4::FixedImagePixelType
typename FixedImageType::PixelType FixedImagePixelType
Definition: itkImageToImageMetricv4.h:235
itk::ImageToImageMetricv4::MovingImagePixelType
typename MovingImageType::PixelType MovingImagePixelType
Definition: itkImageToImageMetricv4.h:242
itk::ObjectToObjectMetricBaseTemplate::DerivativeType
typename Superclass::DerivativeType DerivativeType
Definition: itkObjectToObjectMetricBase.h:112
itk::ImageToImageMetricv4::MovingTransformType
typename Superclass::MovingTransformType MovingTransformType
Definition: itkImageToImageMetricv4.h:221
itk::ImageToImageMetricv4::VirtualPointSetType
typename Superclass::VirtualPointSetType VirtualPointSetType
Definition: itkImageToImageMetricv4.h:262
itk::ImageToImageMetricv4::VirtualImageType
typename Superclass::VirtualImageType VirtualImageType
Definition: itkImageToImageMetricv4.h:251
itkMeanSquaresImageToImageMetricv4GetValueAndDerivativeThreader.h