NifTK
16.4.1 - 0798f20
CMIC's Translational Medical Imaging Platform
|
Implement a gradient descent optimization suitable for FFD and Fluid deformation. More...
Public Types | |
typedef LocalSimilarityMeasureGradientDescentOptimizer | Self |
typedef SingleValuedNonLinearOptimizer | Superclass |
typedef SmartPointer< Self > | Pointer |
typedef SmartPointer< const Self > | ConstPointer |
typedef SimilarityMeasure < TFixedImage, TMovingImage > | ImageToImageMetricType |
typedef const ImageToImageMetricType * | ImageToImageMetricPointer |
typedef TFixedImage | FixedImageType |
typedef FixedImageType::PixelType | FixedImagePixelType |
typedef FixedImageType * | FixedImagePointer |
typedef FixedImageType::Pointer | FixedImageSmartPointer |
typedef TMovingImage | MovingImageType |
typedef MovingImageType::PixelType | MovingImagePixelType |
typedef MovingImageType * | MovingImagePointer |
typedef DeformableTransform < TFixedImage, TScalarType, Dimension, TDeformationScalar > | DeformableTransformType |
typedef DeformableTransformType::Pointer | DeformableTransformPointer |
typedef double | MeasureType |
typedef InterpolateImageFunction < TFixedImage, TScalarType > | RegriddingInterpolatorType |
typedef RegriddingInterpolatorType::Pointer | RegriddingInterpolatorPointer |
typedef ResampleImageFilter < TFixedImage, TFixedImage > | ResampleFilterType |
typedef ResampleFilterType::Pointer | ResampleFilterPointer |
typedef DeformableTransformType::JacobianDeterminantFilterType::OutputImageType | JacobianImageType |
Protected Member Functions | |
LocalSimilarityMeasureGradientDescentOptimizer () | |
virtual | ~LocalSimilarityMeasureGradientDescentOptimizer () |
void | PrintSelf (std::ostream &os, Indent indent) const override |
virtual void | Initialize () |
virtual double | CalculateNextStep (int iterationNumber, double currentSimilarity, const ParametersType ¤t, ParametersType &next)=0 |
virtual void | CleanUp () |
virtual void | ReGrid (bool isResetCurrentPosition) |
virtual void | ComposeJacobian () |
Implement a gradient descent optimization suitable for FFD and Fluid deformation.
typedef SmartPointer<const Self> itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::ConstPointer |
typedef DeformableTransformType::Pointer itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::DeformableTransformPointer |
typedef DeformableTransform<TFixedImage, TScalarType, Dimension, TDeformationScalar> itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::DeformableTransformType |
typedef FixedImageType::PixelType itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::FixedImagePixelType |
typedef FixedImageType* itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::FixedImagePointer |
typedef FixedImageType::Pointer itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::FixedImageSmartPointer |
typedef TFixedImage itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::FixedImageType |
typedef const ImageToImageMetricType* itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::ImageToImageMetricPointer |
typedef SimilarityMeasure<TFixedImage, TMovingImage> itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::ImageToImageMetricType |
Typedefs.
typedef DeformableTransformType::JacobianDeterminantFilterType::OutputImageType itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::JacobianImageType |
typedef double itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::MeasureType |
typedef MovingImageType::PixelType itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::MovingImagePixelType |
typedef MovingImageType* itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::MovingImagePointer |
typedef TMovingImage itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::MovingImageType |
typedef SmartPointer<Self> itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::Pointer |
typedef RegriddingInterpolatorType::Pointer itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::RegriddingInterpolatorPointer |
typedef InterpolateImageFunction< TFixedImage, TScalarType > itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::RegriddingInterpolatorType |
typedef ResampleFilterType::Pointer itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::ResampleFilterPointer |
typedef ResampleImageFilter< TFixedImage, TFixedImage > itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::ResampleFilterType |
typedef LocalSimilarityMeasureGradientDescentOptimizer itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::Self |
Standard class typedefs.
typedef SingleValuedNonLinearOptimizer itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::Superclass |
|
protected |
|
inlineprotectedvirtual |
|
protectedpure virtual |
Calculate a potential step following the gradient direction.
|
inlineprotectedvirtual |
For any cleanup of optimizer.
|
inlineprotectedvirtual |
Compose the new Jacobian using current and regridded parameters.
|
virtual |
|
virtual |
|
virtual |
|
virtual |
Standard Type Macro.
Reimplemented in itk::FFDSteepestGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >, itk::FFDConjugateGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >, and itk::FFDGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >.
|
inlinevirtual |
Return the composed Jacobian.
|
virtual |
Get the current iteration number.
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
Set the maximize flag.
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
inlinevirtual |
Return the regridded fixed image.
|
virtual |
|
virtual |
|
inlinevirtual |
Return the regridded moving image.
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
Get the value of the stop flag.
|
virtual |
Get the current value of the cost function.
|
virtual |
|
virtual |
|
virtual |
|
inlineprotectedvirtual |
For any initialisation of optimizer.
itk::LocalSimilarityMeasureGradientDescentOptimizer< TFixedImage, TMovingImage, TScalarType, TDeformationScalar >::itkStaticConstMacro | ( | Dimension | , |
unsigned | int, | ||
TFixedImage::ImageDimension | |||
) |
Get the number of dimensions we are working in.
|
virtual |
|
virtual |
|
overrideprotected |
|
protectedvirtual |
Do the re-gridding.
|
virtual |
Resume previously stopped optimization with current parameters
|
virtual |
Get/Set the CheckJacobianBelowZero flag.
|
virtual |
Get/Set MinimumDeformationMagnitudeThreshold flag.
|
virtual |
Get/Set similarity measure checking flag.
|
virtual |
Set the deformable transform externally.
|
virtual |
At each iteration, filename to decide where we dump the next set of parameters. Default "vtk".
|
virtual |
At each iteration, filename to decide where we dump the deformation field. Default "tmp.next.field".
|
virtual |
Set/Get IsAbsRegriddedImage
|
virtual |
Set/Get.
|
virtual |
If we can't find a better value of the transformation, we reduce step size and keep hunting.
|
virtual |
If for some reason, the Jacobian is negative, we reduce the step size and keep hunting.
|
virtual |
|
virtual |
Set/Get the maximum number of iterations.
|
virtual |
If the largest magnitude deformation vector is < MinimumDeformationMagnitudeThreshold, we stop.
|
virtual |
If any voxel Jacobian drops below MinimumJacobianThreshold we regrid.
|
virtual |
So we can force optimizer to stop if cost function not doing much.
|
virtual |
Set/Get the minimum step size.
|
virtual |
At each iteration, filename to decide where we dump the next set of parameters. Default "vtk".
|
virtual |
At each iteration, filename to decide where we dump the next set of parameters. Default "tmp.next.params".
|
virtual |
Each time we regrid, file extension to dump regridded image to. Default "nii".
|
virtual |
Each time we regrid, filename to dump regridded image to. Default "tmp.regridded".
|
virtual |
Set/Get the regridded moving image pad value.
|
virtual |
Set the regridding interpolator.
|
virtual |
If we decide to regrid, we can also tweak the step size and keep hunting.
|
virtual |
Set/Get the initial step size.
|
virtual |
At each iteration, flag to decide if we dump the deformation field.
|
virtual |
At each iteration, flag to decide if we dump the next set of parameters.
|
virtual |
Each time we regrid, flag to decide if we dump the regridded image.
|
overridevirtual |
Start optimization.
|
virtual |
Stop optimization.
|
protected |
Check for jacobian below zero or not. Default true.
|
protected |
Check for min deformation change or not. Default true.
|
protected |
Check for better similarity measure or not.
|
protected |
Composed Jacobian image calculated along the regridding.
|
protected |
The current number of iterations.
|
protected |
The deformable transform.
|
protected |
File extension for deformation field.
|
protected |
File name for deformation field.
|
protected |
Fixed image.
|
protected |
Metric.
|
protected |
Set to true to apply an abs filter to the regridded image.
|
protected |
Propagate the regridded moving image when re-gridding, if set to true. Exaxctly the same as original Christensen fluid paper. The reason for preferring this is that the interpolation of the image may be more accurate than the interpolation of thee deformation field.
|
protected |
If we can't find a better position, we reduce the step size, and keep iterating.
|
protected |
If for some reason, Jacobian is negative, we reduce step size, and keep iterating.
|
protected |
Set whether we are maximizing or not.
|
protected |
The max. number of iterations.
|
protected |
If the deformation is < this threshold, we stop.
|
protected |
If the Jacobian is < this threshold, we regrid.
|
protected |
If the similarity doesn't improve over this threshold, we stop.
|
protected |
Minimum step size.
|
protected |
Moving image.
|
protected |
The potential next parameters (subject to Jacobian/Deformation/Cost function checks).
|
protected |
File extension for next parameters at each iteration.
|
protected |
Filename for next parameters at each iteration.
|
protected |
Regridded moving image, resampled to same type as fixed image.
|
protected |
File extension for regridded image.
|
protected |
Filename for regridded image.
|
protected |
Regridded moving image, resampled to same type as fixed image.
|
protected |
Pad value for regridded image. Default 0.
|
protected |
Store the regrid
|
protected |
So we can set a regridding interpolator, different from the one we use during registration.
|
protected |
The number of the times we have regridded.
|
protected |
To actually do the resampling.
|
protected |
If Jacobian hits our lowest threshold, and we regrid, we also change step size and keep iterating.
|
protected |
Step Size.
|
protected |
Set this flag to stop the optimisation.
|
protected |
The current value of the cost function/similarity measure.
|
protected |
Writes the deformation field at each iteration (to check that the parameters were applied properly.
|
protected |
Writes the next parameters at each iteration.
|
protected |
So we can optionally turn on dumping out the regridded image.