go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
itkTransformBendingEnergyPenaltyTerm.h
Go to the documentation of this file.
1/*=========================================================================
2 *
3 * Copyright UMC Utrecht and contributors
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 itkTransformBendingEnergyPenaltyTerm_h
19#define itkTransformBendingEnergyPenaltyTerm_h
20
22#include "itkImageGridSampler.h"
23
24namespace itk
25{
26
49template <class TFixedImage, class TScalarType>
50class ITK_TEMPLATE_EXPORT TransformBendingEnergyPenaltyTerm : public TransformPenaltyTerm<TFixedImage, TScalarType>
51{
52public:
54
58 using Pointer = SmartPointer<Self>;
59 using ConstPointer = SmartPointer<const Self>;
60
62 itkNewMacro(Self);
63
66
68 using typename Superclass::CoordinateRepresentationType;
69 using typename Superclass::MovingImageType;
70 using typename Superclass::MovingImagePixelType;
71 using typename Superclass::MovingImagePointer;
72 using typename Superclass::MovingImageConstPointer;
73 using typename Superclass::FixedImageType;
74 using typename Superclass::FixedImagePointer;
75 using typename Superclass::FixedImageConstPointer;
76 using typename Superclass::FixedImageRegionType;
77 using typename Superclass::TransformType;
78 using typename Superclass::TransformPointer;
79 using typename Superclass::InputPointType;
80 using typename Superclass::OutputPointType;
81 using typename Superclass::TransformParametersType;
82 using typename Superclass::TransformJacobianType;
84 using typename Superclass::InterpolatorType;
85 using typename Superclass::InterpolatorPointer;
86 using typename Superclass::RealType;
87 using typename Superclass::GradientPixelType;
88 using typename Superclass::GradientImageType;
89 using typename Superclass::GradientImagePointer;
90 using typename Superclass::FixedImageMaskType;
94 using typename Superclass::MeasureType;
95 using typename Superclass::DerivativeType;
97 using typename Superclass::ParametersType;
101 using typename Superclass::ScalarType;
102 using typename Superclass::ThreadInfoType;
103
112
114 using typename Superclass::SpatialJacobianType;
116 using typename Superclass::SpatialHessianType;
118 using typename Superclass::InternalMatrixType;
119
121 itkStaticConstMacro(FixedImageDimension, unsigned int, FixedImageType::ImageDimension);
122
124 MeasureType
125 GetValue(const ParametersType & parameters) const override;
126
128 void
129 GetDerivative(const ParametersType & parameters, DerivativeType & derivative) const override;
130
132 virtual void
133 GetValueAndDerivativeSingleThreaded(const ParametersType & parameters,
134 MeasureType & value,
135 DerivativeType & derivative) const;
136
137 void
138 GetValueAndDerivative(const ParametersType & parameters,
139 MeasureType & value,
140 DerivativeType & derivative) const override;
141
143 void
144 ThreadedGetValueAndDerivative(ThreadIdType threadID) const override;
145
147 void
148 AfterThreadedGetValueAndDerivative(MeasureType & value, DerivativeType & derivative) const override;
149
150protected:
152 using typename Superclass::FixedImageIndexType;
155 using typename Superclass::FixedImagePointType;
159
162
165};
166
167} // end namespace itk
168
169#ifndef ITK_MANUAL_INSTANTIATION
170# include "itkTransformBendingEnergyPenaltyTerm.hxx"
171#endif
172
173#endif // #ifndef itkTransformBendingEnergyPenaltyTerm_h
Deformable transform using a B-spline representation.
This class combines two transforms: an 'initial transform' with a 'current transform'.
typename BSplineOrder1TransformType::Pointer BSplineOrder1TransformPointer
typename ImageSamplerType::OutputVectorContainerPointer ImageSampleContainerPointer
typename AdvancedTransformType::NonZeroJacobianIndicesType NonZeroJacobianIndicesType
typename FixedImageIndexType::IndexValueType FixedImageIndexValueType
typename ImageSamplerType::OutputVectorContainerType ImageSampleContainerType
ImageMaskSpatialObject< Self::FixedImageDimension > FixedImageMaskType
typename BSplineOrder3TransformType::Pointer BSplineOrder3TransformPointer
typename BSplineOrder2TransformType::Pointer BSplineOrder2TransformPointer
typename InterpolatorType::ContinuousIndexType MovingImageContinuousIndexType
typename AdvancedTransformType::NumberOfParametersType NumberOfParametersType
ImageMaskSpatialObject< Self::MovingImageDimension > MovingImageMaskType
A cost function that calculates the bending energy of a transformation.
virtual void GetValueAndDerivativeSingleThreaded(const ParametersType &parameters, MeasureType &value, DerivativeType &derivative) const
void GetDerivative(const ParametersType &parameters, DerivativeType &derivative) const override
ITK_DISALLOW_COPY_AND_MOVE(TransformBendingEnergyPenaltyTerm)
~TransformBendingEnergyPenaltyTerm() override=default
void ThreadedGetValueAndDerivative(ThreadIdType threadID) const override
void GetValueAndDerivative(const ParametersType &parameters, MeasureType &value, DerivativeType &derivative) const override
MeasureType GetValue(const ParametersType &parameters) const override
void AfterThreadedGetValueAndDerivative(MeasureType &value, DerivativeType &derivative) const override
itkStaticConstMacro(FixedImageDimension, unsigned int, FixedImageType::ImageDimension)
A cost function that calculates a penalty term on a transformation.
typename TransformType::JacobianOfSpatialJacobianType JacobianOfSpatialJacobianType
typename Superclass::AdvancedTransformType TransformType
typename TransformType::SpatialHessianType SpatialHessianType
typename TransformType::SpatialJacobianType SpatialJacobianType
typename TransformType::InternalMatrixType InternalMatrixType
typename TransformType::JacobianOfSpatialHessianType JacobianOfSpatialHessianType


Generated on 2024-07-17 for elastix by doxygen 1.11.0 (9b424b03c9833626cd435af22a444888fbbb192d) elastix logo