ITK  5.0.0
Insight Segmentation and Registration Toolkit
itkVariationalDiffeomorphicRegistrationFilter.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 itkVariationalDiffeomorphicRegistrationFilter_h
19 #define itkVariationalDiffeomorphicRegistrationFilter_h
20 
23 
24 
25 namespace itk {
26 
79 template< typename TFixedImage, typename TMovingImage, typename TDisplacementField>
81  : public VariationalRegistrationFilter< TFixedImage, TMovingImage, TDisplacementField >
82 {
83 public:
84  ITK_DISALLOW_COPY_AND_ASSIGN(VariationalDiffeomorphicRegistrationFilter);
85 
89  TFixedImage, TMovingImage, TDisplacementField >;
92 
94  itkNewMacro(Self);
95 
98 
100  static constexpr unsigned int ImageDimension = Superclass::ImageDimension;
101 
103  using FixedImageType = TFixedImage;
104  using FixedImagePointer = typename FixedImageType::Pointer;
105  using FixedImageConstPointer = typename FixedImageType::ConstPointer;
106 
108  using MovingImageType = TMovingImage;
109  using MovingImagePointer = typename MovingImageType::Pointer;
110  using MovingImageConstPointer = typename MovingImageType::ConstPointer;
111 
113  using DisplacementFieldType = TDisplacementField;
114  using DisplacementFieldPointer = typename DisplacementFieldType::Pointer;
115 
118 
121 
124 
127 
129  itkSetMacro( NumberOfExponentiatorIterations, unsigned int );
130 
132  itkGetConstMacro( NumberOfExponentiatorIterations, unsigned int );
133 
135  void SetInitialDisplacementField( DisplacementFieldType * ptr ) override;
136 
139  { return m_DisplacementField; }
140 
143  { this->SetInput( ptr ); }
144 
147  { return this->GetOutput(); }
148 
149 protected:
152 
154  void PrintSelf(std::ostream& os, Indent indent) const override;
155 
157  void Initialize() override;
158 
160  void ApplyUpdate( const TimeStepType& dt ) override;
161 
164  virtual void CalcDeformationFromVelocityField( const DisplacementFieldType * velocityField );
165 
169 
172 
175  { return m_Exponentiator; }
176 
177 private:
181 
184 
185 };
186 
187 }// end namespace itk
188 
189 #ifndef ITK_MANUAL_INSTANTIATION
190 # include "itkVariationalDiffeomorphicRegistrationFilter.hxx"
191 #endif
192 
193 #endif
Light weight base class for most itk classes.
void ApplyUpdate(const TimeStepType &dt) override
virtual void CalcDeformationFromVelocityField(const DisplacementFieldType *velocityField)
Flexible framework for deformable registration of two images using PDE-based variational registration...
typename Superclass::OutputImageType OutputImageType
Diffeomorphic deformable registration of two images using static velocity fields. ...
void SetInitialDisplacementField(DisplacementFieldType *ptr) override
void PrintSelf(std::ostream &os, Indent indent) const override
virtual void SetInput(const InputImageType *image)
Computes a diffeomorphic displacement field as the Lie group exponential of a vector field...
itk::ExponentialDisplacementFieldImageFilter< DisplacementFieldType, DisplacementFieldType > FieldExponentiatorType
VariationalRegistrationFunction< FixedImageType, MovingImageType, DisplacementFieldType > RegistrationFunctionType
typename Superclass::TimeStepType TimeStepType
Control indentation during Print() invocation.
Definition: itkIndent.h:49
VariationalRegistrationRegularizer< DisplacementFieldType > RegularizerType