Class RegistrationMeasure
- java.lang.Object
-
- gov.nih.mipav.model.algorithms.registration.RegistrationMeasure
-
- Direct Known Subclasses:
RegistrationMeasureCorrelationRatio
,RegistrationMeasureLeastSquares
,RegistrationMeasureNormalizedMutualInformation
public abstract class RegistrationMeasure extends java.lang.Object
This is an abstract class used to compute the measure of registration between the specified target image and a registered source image. This class create the registered source image to have the same dimensions as the input target image. The measure calculations do not require the specification of the number of dimensions.
-
-
Field Summary
Fields Modifier and Type Field Description protected int
m_iNumSamples
Total number of samples in the target image.protected ModelSimpleImage
m_kImageReg
Information and data for the registered image.protected ModelSimpleImage
m_kImageTrg
Information and data for the target (reference) image.
-
Constructor Summary
Constructors Modifier Constructor Description protected
RegistrationMeasure()
Constructor.
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected static ModelSimpleImage
createEmptyImage()
Can be used by constructors to create an empty 3D image.abstract RegistrationMeasure
createNew()
Create a new instance of this measure.abstract double
getError()
Return the current error measure between the target image and the registered source image.ModelSimpleImage
getImageRegistered()
Access the image containing the registered source values.abstract java.lang.String
getName()
Return the name of the particular registration measure.void
setImages(ModelSimpleImage kImageSrc, ModelSimpleImage kImageTrg)
Setup the measure to use information from the target image and the original source image.abstract void
updateRegistration(int iIndex, float fNewValue)
Update the specified value in the registered source image.
-
-
-
Field Detail
-
m_iNumSamples
protected int m_iNumSamples
Total number of samples in the target image.
-
m_kImageReg
protected ModelSimpleImage m_kImageReg
Information and data for the registered image. Has the same number of samples as does the target image.
-
m_kImageTrg
protected ModelSimpleImage m_kImageTrg
Information and data for the target (reference) image.
-
-
Method Detail
-
createNew
public abstract RegistrationMeasure createNew()
Create a new instance of this measure. That is, the same type and having the same properties. But initially, the target is not defined.- Returns:
- RegistrationMeasure Newly created instance.
-
getError
public abstract double getError()
Return the current error measure between the target image and the registered source image.- Returns:
- double Error measure value. Range of value depends on paricular implementation based on type of error measure.
-
getName
public abstract java.lang.String getName()
Return the name of the particular registration measure.- Returns:
- String Contains the name of the particular registration measure.
-
updateRegistration
public abstract void updateRegistration(int iIndex, float fNewValue)
Update the specified value in the registered source image. Causes a change in the computed error measure.- Parameters:
iIndex
- int Linear array index for the value to be updated.fNewValue
- float New registered source image value to store at the specified index.
-
getImageRegistered
public ModelSimpleImage getImageRegistered()
Access the image containing the registered source values.- Returns:
- ModelSimpleImage Information and data for the registered source image values. The size of this array is the same properties as the target image.
-
setImages
public void setImages(ModelSimpleImage kImageSrc, ModelSimpleImage kImageTrg)
Setup the measure to use information from the target image and the original source image. Each derived class override of this method must call this method.- Parameters:
kImageSrc
- ModelSimpleImage Contains information and data about the original source image. This array may be empty but not null.kImageTrg
- ModelSimpleImage Contains information and data about yhe target image. This array may be empty but not null.
-
createEmptyImage
protected static ModelSimpleImage createEmptyImage()
Can be used by constructors to create an empty 3D image.- Returns:
- ModelSimpleImage Reference to a newly created empty image.
-
-