|
Isis 3 Programmer Reference
|
14 #include "Statistics.h"
262 QString GradientFilterString()
const;
310 void Distance(
double &sampDistance,
double &lineDistance) {
327 inline bool IsIdeal(
double fit);
360 void ZScores(
double &score1,
double &score2)
const {
418 Chip &fChip,
int startSamp,
int startLine,
int endSamp,
int endLine,
419 int bestSamp,
int bestLine);
422 virtual bool CompareFits(
double fit1,
double fit2);
double p_minimumPatternZScore
Minimum pattern Z-Score.
void Init()
Initialize AutoReg object private variables.
double GoodnessOfFit() const
Return the goodness of fit of the match algorithm.
void SetChipSample(double sample)
Sets the search chip subpixel sample that matches the pattern tack sample.
int p_windowSize
Surface model window size.
virtual ~AutoReg()
Destroy AutoReg object.
int ReductionFactor()
Return the reduction factor.
double p_goodnessOfFit
Goodness of fit of the match algorithm.
Chip p_reducedPatternChip
Pattern Chip with reduction factor.
double p_distanceTolerance
Maximum distance the surface model solution may be from the best whole pixel fit in the fit chip.
double MinimumZScore() const
Return minimumPatternZScore.
int p_surfaceModelSolutionInvalidCount
Registration statistics SurfaceModelSolutionInvalid keyword.
Contains Pvl Groups and Pvl Objects.
@ Sobel
Sobel gradient filter.
double p_zScoreMin
First Z-Score of pattern chip.
double p_cubeSample
Cube sample.
Chip p_patternChip
Chip to be matched.
@ None
default, no gradient filter
void SetSurfaceModelWindowSize(int size)
Set the surface model window size.
double p_sampMovement
The number of samples the point moved.
int p_fitChipToleranceNotMetCount
Registration statistics FitChipToleranceNotMet keyword.
void ZScores(double &score1, double &score2) const
Return the ZScores of the pattern chip.
bool SetSubpixelPosition(Chip &window)
Set the search chip sample and line to subpixel values if possible.
@ PatternZScoreNotMet
Pattern data max or min does not pass the z-score test.
@ AdaptiveAlgorithmFailed
Error occured in Adaptive algorithm.
int p_subpixelSuccesses
Registration statistics Success keyword.
void Parse(Pvl &pvl)
Initialize parameters in the AutoReg class using a PVL specification.
void SetReductionFactor(int reductionFactor)
Set the reduction factor used to speed up the pattern matching algorithm.
void SetGoodnessOfFit(double fit)
Sets the goodness of fit for adaptive algorithms.
int p_bestSamp
Sample value of best fit.
void SobelGradient(Buffer &in, double &v)
Compute a Sobel gradient based on an input buffer.
Chip * RegistrationSearchChip()
Return pointer to search chip used in registration.
Chip p_gradientPatternChip
Chip to be matched with gradient applied.
bool p_subpixelAccuracy
Indicates whether sub-pixel accuracy is enabled. Default is true.
double p_chipSample
Chip sample.
AutoReg::RegisterStatus Register()
Walk the pattern chip through the search chip to find the best registration.
Container for cube-like labels.
void SetSubsearchValidPercent(const double percent)
Set the amount of data in the search chip's subchip that must be valid.
Chip * SearchChip()
Return pointer to search chip.
Chip p_reducedFitChip
Fit Chip with reduction factor.
double p_lineMovement
The number of lines the point moved.
AutoReg(Pvl &pvl)
Create AutoReg object.
int p_bestLine
Line value of best fit.
int p_reduceFactor
Reduction factor.
double p_zScoreMax
Second Z-Score of pattern chip.
virtual QString AlgorithmName() const =0
Returns the name of the algorithm.
Isis::AutoReg::RegisterStatus p_registrationStatus
Registration status to be returned by Register().
Chip p_fitChip
Results from MatchAlgorithm() method.
double ChipSample() const
Return the search chip sample that best matched.
Chip p_reducedSearchChip
Search Chip with reduction factor.
virtual double MatchAlgorithm(Chip &pattern, Chip &subsearch)=0
Given two identically sized chips return a double that indicates how well they match.
void SetGradientFilterType(const QString &gradientFilterType)
Set the gradient filter type to be applied to the search and pattern chips.
Chip * ReducedSearchChip()
Return pointer to reduced search chip.
Buffer for reading and writing cube data.
PvlGroup UpdatedTemplate()
Returns a PvlGroup containing the PvlKeywords of the parameters this object was most recently run wit...
PvlGroup RegTemplate()
This function returns the keywords that this object was created from.
double p_cubeLine
Cube line.
void SetTolerance(double tolerance)
Set the tolerance for an acceptable goodness of fit.
@ SurfaceModelSolutionInvalid
Could not model surface for sub-pixel accuracy.
bool SubPixelAccuracy()
Return whether this object will attempt to register to whole or sub-pixel accuracy.
@ SuccessSubPixel
Success registering to sub-pixel accuracy.
int p_patternChipNotEnoughValidDataCount
Registration statistics PatternNotEnoughValidData keyword.
int p_surfaceModelDistanceInvalidCount
Registration statistics SurfaceModelDistanceInvalid keyword.
Contains multiple PvlContainers.
virtual double IdealFit() const =0
Returns the ideal (perfect) fit that could be returned by the MatchAlgorithm.
@ PatternChipNotEnoughValidData
Not enough valid data in pattern chip.
virtual double MostLenientTolerance()
Minimum tolerance specific to algorithm.
double CubeSample() const
Return the search chip cube sample that best matched.
AutoReg::GradientFilterType p_gradientFilterType
Type of gradient filter to use before matching.
double WindowSize() const
Return window size.
Chip Reduce(Chip &chip, int reductionFactor)
This method reduces the given chip by the given reduction factor.
double p_subsearchValidPercent
Percentage of data in subsearch chip that must be valid.
bool IsIdeal(double fit)
Returns true if the fit parameter is arbitrarily close to the ideal fit value.
Chip * PatternChip()
Return pointer to pattern chip.
virtual AutoReg::RegisterStatus Registration(Chip &sChip, Chip &pChip, Chip &fChip, int startSamp, int startLine, int endSamp, int endLine, int bestSamp, int bestLine)
Performs matching between the pattern and search at both whole-pixel and subpixel levels.
virtual bool CompareFits(double fit1, double fit2)
This virtual method must return if the 1st fit is equal to or better than the second fit.
@ SurfaceModelDistanceInvalid
Surface model moves registration more than one pixel.
int p_patternZScoreNotMetCount
Registration statistics PatternZScoreNotMet keyword.
Chip * ReducedFitChip()
Return pointer to reduced fit chip.
double PatternValidPercent() const
Return pattern chip valid percent. The default value is.
RegisterStatus
Enumeration of the Register() method's return status.
double Tolerance() const
Return match algorithm tolerance.
int p_surfaceModelNotEnoughValidDataCount
Registration statistics SurfaceModelNotEnoughValidData keyword.
PvlObject p_template
AutoRegistration object that created this projection.
Pvl RegistrationStatistics()
This returns the cumulative registration statistics.
@ FitChipToleranceNotMet
Goodness of fit tolerance not satisfied.
Chip p_searchChip
Chip to be searched for best registration.
double ChipLine() const
Return the search chip line that best matched.
Chip * FitChip()
Return pointer to fit chip.
@ SurfaceModelNotEnoughValidData
Not enough points to fit a surface model for sub-pixel accuracy.
double p_tolerance
Tolerance for acceptable goodness of fit in match algorithm.
int p_fitChipNoDataCount
Registration statistics FitChipNoData keyword.
double p_chipLine
Chip line.
Chip p_gradientSearchChip
Chip to be searched for best registration with gradient applied.
Chip * ReducedPatternChip()
Return pointer to reduced pattern chip.
void SetSubPixelAccuracy(bool on)
If the sub-pixel accuracy is enabled, the Register() method will attempt to match the pattern chip to...
@ FitChipNoData
Fit chip did not have any valid data.
A small chip of data used for pattern matching.
int p_totalRegistrations
Registration Statistics Total keyword.
double CubeLine() const
Return the search chip cube line that best matched.
void Distance(double &sampDistance, double &lineDistance)
Return the distance point moved.
virtual Pvl AlgorithmStatistics(Pvl &pvl)
Provide (adaptive) algorithms a chance to report results.
void SetChipLine(double line)
Sets the search chip subpixel line that matches the pattern tack line.
double SubsearchValidPercent() const
Return subsearch chip valid percent.
void ApplyGradientFilter(Chip &chip)
Run a gradient filter over the chip.
double p_bestFit
Goodness of fit for adaptive algorithms.
double p_patternValidPercent
Percentage of data in pattern chip that must be valid.
void SetPatternZScoreMinimum(double minimum)
Set the minimum pattern zscore.
bool Success() const
Return whether the match algorithm succeeded or not.
void SetChipInterpolator(const QString &interpolator)
Sets the Chip class interpolator type to be used to load pattern and search chips.
void SetPatternValidPercent(const double percent)
Set the amount of data in the pattern chip that must be valid.
@ SuccessPixel
Success registering to whole pixel.
This is free and unencumbered software released into the public domain.
Chip * RegistrationPatternChip()
Return pointer to pattern chip used in registration.
bool ComputeChipZScore(Chip &chip)
This method computes the given Chip's Z-Score.
int p_pixelSuccesses
Registration statistics Success keyword.
void Match(Chip &sChip, Chip &pChip, Chip &fChip, int startSamp, int endSamp, int startLine, int endLine)
Empty copy constructor.
void SetSurfaceModelDistanceTolerance(double distance)
Set a distance the surface model solution is allowed to move away from the best whole pixel fit in th...
GradientFilterType
Enumeration of the different types of gradient filters that can be applied to the pattern and search ...
double DistanceTolerance() const
Return distance tolerance.