18 #ifndef itkDisplacementFieldTransform_h
19 #define itkDisplacementFieldTransform_h
86 <
typename TParametersValueType,
unsigned int NDimensions>
88 public Transform<TParametersValueType, NDimensions, NDimensions>
136 typedef typename Superclass::InputCovariantVectorType
138 typedef typename Superclass::OutputCovariantVectorType
146 typedef typename Superclass::InputDiffusionTensor3DType
148 typedef typename Superclass::OutputDiffusionTensor3DType
161 itkStaticConstMacro(
Dimension,
unsigned int, NDimensions );
221 using Superclass::TransformVector;
224 itkExceptionMacro(
"TransformVector(Vector) unimplemented, use "
225 "TransformVector(Vector,Point)" );
231 itkExceptionMacro(
"TransformVector(Vector) unimplemented, use "
232 "TransformVector(Vector,Point)" );
237 itkExceptionMacro(
"TransformVector(Vector) unimplemented, use "
238 "TransformVector(Vector,Point)" );
242 using Superclass::TransformDiffusionTensor3D;
246 itkExceptionMacro(
"TransformDiffusionTensor(Tensor) unimplemented, use "
247 "TransformDiffusionTensor(Tensor,Point)" );
254 itkExceptionMacro(
"TransformDiffusionTensor(Tensor) unimplemented, use "
255 "TransformDiffusionTensor(Tensor,Point)" );
259 using Superclass::TransformCovariantVector;
263 itkExceptionMacro(
"TransformCovariantVector(CovariantVector) "
264 "unimplemented, use TransformCovariantVector(CovariantVector,Point)" );
271 itkExceptionMacro(
"TransformCovariantVector(CovariantVector) "
272 "unimplemented, use TransformCovariantVector(CovariantVector,Point)" );
279 if( &(this->m_Parameters) != ¶ms )
281 if( params.Size() != this->m_Parameters.Size() )
283 itkExceptionMacro(
"Input parameters size (" << params.Size()
284 <<
") does not match internal size ("
285 << this->m_Parameters.Size() <<
").");
288 this->m_Parameters = params;
303 virtual void SetFixedParameters(
const FixedParametersType & ) ITK_OVERRIDE;
329 j = this->m_IdentityJacobian;
342 j = this->m_IdentityJacobian;
349 virtual void ComputeJacobianWithRespectToPosition(
const InputPointType & x, JacobianType & j )
const ITK_OVERRIDE;
355 virtual void ComputeInverseJacobianWithRespectToPosition(
const InputPointType & x, JacobianType & j )
const ITK_OVERRIDE;
361 virtual void ComputeJacobianWithRespectToPosition(
const IndexType & x, JacobianType & j )
const;
374 virtual void GetInverseJacobianOfForwardFieldWithRespectToPosition(
const InputPointType & point,
375 JacobianType & jacobian,
376 bool useSVD =
false )
const;
389 virtual void GetInverseJacobianOfForwardFieldWithRespectToPosition(
const IndexType & index, JacobianType & jacobian,
390 bool useSVD =
false )
const;
392 virtual void UpdateTransformParameters(
const DerivativeType & update, ScalarType factor = 1.0 ) ITK_OVERRIDE;
396 bool GetInverse( Self *inverse ) const;
400 virtual InverseTransformBasePointer GetInverseTransform() const ITK_OVERRIDE;
402 virtual
void SetIdentity();
407 return Self::DisplacementField;
422 itkSetMacro(CoordinateTolerance,
double);
423 itkGetConstMacro(CoordinateTolerance,
double);
433 itkSetMacro(DirectionTolerance,
double);
434 itkGetConstMacro(DirectionTolerance,
double);
441 void PrintSelf( std::ostream& os,
Indent indent ) const ITK_OVERRIDE;
470 virtual
void ComputeJacobianWithRespectToPositionInternal(const
IndexType & index,
JacobianType & jacobian,
471 bool doInverseJacobian) const;
477 virtual
void VerifyFixedParametersInformation();
483 virtual
void SetFixedParametersFromDisplacementField() const;
485 double m_CoordinateTolerance;
486 double m_DirectionTolerance;
492 #ifndef ITK_MANUAL_INSTANTIATION
493 #include "itkDisplacementFieldTransform.hxx"
496 #endif // itkDisplacementFieldTransform_h
Superclass::RegionType RegionType
Light weight base class for most itk classes.
unsigned long ModifiedTimeType
Class to hold and manage parameters of type Image<Vector<...>,...>, used in Transforms, etc.
Class to hold and manage different parameter types used during optimization.
Superclass::IndexType IndexType
Superclass::SizeType SizeType
const unsigned int Dimension
Control indentation during Print() invocation.
Base class for all vector image interpolaters.
A templated class holding a n-Dimensional covariant vector.
Templated n-dimensional image class.
ImageBaseType::IndexType IndexType