Class VabraSubjectTargetPairs

java.lang.Object
gov.nih.mipav.model.algorithms.registration.vabra.VabraSubjectTargetPairs
All Implemented Interfaces:
de.jtem.numericalMethods.calculus.function.RealFunctionOfOneVariable

public class VabraSubjectTargetPairs extends Object implements de.jtem.numericalMethods.calculus.function.RealFunctionOfOneVariable
  • Field Details

    • maxDimensions

      private int maxDimensions
    • subject

      private VabraVolumeCollection subject
    • deformedSubject

      private VabraVolumeCollection deformedSubject
    • target

      private VabraVolumeCollection target
    • targetBinned

      private VabraVolumeCollection targetBinned
    • deformedSubjectBinned

      private VabraVolumeCollection deformedSubjectBinned
    • currentDownSampleFactor

      private double currentDownSampleFactor
    • boundingBox

      private int[] boundingBox
    • currentDeformField

      private float[] currentDeformField
    • totalDeformField

      private float[] totalDeformField
    • origSubjectList

      private ModelImage origSubjectList
    • origTargetList

      private ModelImage origTargetList
    • chInterpType

      private int chInterpType
    • numOfBins

      private int numOfBins
    • RobustMinThresh

      private float RobustMinThresh
    • RobustMaxThresh

      private float RobustMaxThresh
    • defFieldUpdateMode

      private int defFieldUpdateMode
    • curX

      private int curX
    • curY

      private int curY
    • curZ

      private int curZ
    • deformedSubjectCopy

      private VabraVolumeCollection deformedSubjectCopy
    • totalDeformFieldSplit

      private ModelImage[] totalDeformFieldSplit
    • levelCount

      private int levelCount
    • resCount

      private int resCount
    • rbf

      private VabraRBF rbf
    • lambda

      private static double lambda
    • localROI

      private int[] localROI
    • localCoarseGradient

      private double[] localCoarseGradient
    • coarseLocalRegionCenter

      private int[] coarseLocalRegionCenter
    • directionsOptmizationWeight

      private double[] directionsOptmizationWeight
    • domainMax

      private double domainMax
    • domainMin

      private double domainMin
    • tolerance

      private double tolerance
    • commitCount

      private int commitCount
    • origJointST

      private int[] origJointST
    • currentJointST

      private int[] currentJointST
    • defSTxPlus

      private int[] defSTxPlus
    • defSTxMinus

      private int[] defSTxMinus
    • defSTyPlus

      private int[] defSTyPlus
    • defSTyMinus

      private int[] defSTyMinus
    • defSTzPlus

      private int[] defSTzPlus
    • defSTzMinus

      private int[] defSTzMinus
    • defSxPlus

      private int[] defSxPlus
    • defSxMinus

      private int[] defSxMinus
    • defSyPlus

      private int[] defSyPlus
    • defSyMinus

      private int[] defSyMinus
    • defSzPlus

      private int[] defSzPlus
    • defSzMinus

      private int[] defSzMinus
    • origDeformedSubject

      private int[] origDeformedSubject
    • origTarget

      private int[] origTarget
    • currentDeformedSubject

      private int[] currentDeformedSubject
  • Constructor Details

    • VabraSubjectTargetPairs

      public VabraSubjectTargetPairs(ModelImage subjectVols, ModelImage targetVols, float robustMaxT, float robustMinT, int numBins, int interpType, boolean useMNMI, double[] directionsOptmizationWeight, int defFieldUpdateMode)
  • Method Details

    • robustMaximum

      private static final float robustMaximum(float[] image, float ratio, int scales, int nx, int ny, int nz)
      Robust maximum estimation
      Parameters:
      ratio - float fraction in [0,1]: the minimum number of points above or equal to the maximum over the total volume
      scales - int: the number of times the scale is refined for finding the robust maximum
      nx - ,ny,nz image dimensions
      Returns:
      the robust maximum value
    • robustMinimum

      private static final float robustMinimum(float[] image, float ratio, int scales, int nx, int ny, int nz)
      Robust maximum estimation
      Parameters:
      ratio - float fraction in [0,1]: the minimum number of points below or equal to the minimum over the total volume
      scales - int: the number of times the scale is refined for finding the robust minimum
      Returns:
      the robust minimum value
    • coarseGradientParameters

      public int coarseGradientParameters()
    • dispose

      public void dispose()
    • prepareForNextLevel

      public int[] prepareForNextLevel()
    • setResolution

      public void setResolution(float downSampleFactor)
    • threshAtRobustMaxAndMin

      private void threshAtRobustMaxAndMin(VabraVolumeCollection imgVec)
    • updateDefField

      private void updateDefField(int[] regionToUpdate)
    • calculateBoundingBox

      void calculateBoundingBox()
    • getDeformationField

      ModelImage getDeformationField()
    • getDeformedSubject

      ModelImage getDeformedSubject()
    • getDomainMax

      public double getDomainMax()
    • getDomainMin

      public double getDomainMin()
    • getDomainTolerance

      public double getDomainTolerance()
    • getValue

      public double getValue(double c)
    • coarseGradient

      public void coarseGradient(int[] regionCenter, double[] results)
    • updateFromCoarseOptimization

      void updateFromCoarseOptimization(double coeff)
    • coarseOptimize

      public double coarseOptimize(int[] regionCenter, double[] gradient)
    • coarseCostFunctionCommit

      private double coarseCostFunctionCommit(double coeff, boolean commitUpdate)
    • coarseCostFunction

      private double coarseCostFunction(double coeff)
    • getRBF

      public VabraRBF getRBF()
    • copyHist

      private int[] copyHist(int[] in)
    • copyHist

      private int[][] copyHist(int[][] in)
    • copyHist

      private int[][][] copyHist(int[][][] vol)
    • resetCurrentHistograms

      private void resetCurrentHistograms()
    • updateHistograms

      private void updateHistograms(VabraVolumeCollection normedTarget, VabraVolumeCollection normedDeformedSubject, int[] boundingBox)
    • getCurrentNMI

      private double getCurrentNMI()
    • adjustOrigBins

      private void adjustOrigBins(int subBin, int tarBin, int newBin)
    • getNMIGradients

      private void getNMIGradients(double[] results, double[] deltaC)
    • adjustGradientBins

      private void adjustGradientBins(VabraVolumeCollection subject, double x, double y, double z, int[] subjectHist, int[] jointHist, int targetBins, int subjectBins)
    • adjustBins

      private void adjustBins(int[] subjectHist, int[] jointHist, int subBin, int tarBin, int newBin)
    • eval

      public double eval(double arg0)
      Specified by:
      eval in interface de.jtem.numericalMethods.calculus.function.RealFunctionOfOneVariable