Isis 3 Programmer Reference
|
Selection class derived from the Pure Virtual Parent Class for all Selection classes. More...
#include <CentroidApolloPan.h>
Public Member Functions | |
CentroidApolloPan (double pixel_size_microns) | |
Constructs a CentroidApolloPan object. More... | |
virtual | ~CentroidApolloPan () |
Destroys the CentroidApolloPan object. More... | |
bool | setPixelSize (double microns) |
Set the pixel size in microns. More... | |
int | elipticalReduction (Chip *selectionChip, double percent_selected, double play, int patience_limit) |
This method will take advantage of all the apriori knowlege we have of the size and orientation of the ellipse to speed up elliptical reduction. More... | |
int | selectAdaptive (Chip *inputChip, Chip *selectionChip) |
Given a range of DN this function creates a biniary chip for all continuous pixels that have the DN within the specified range using the center pixel of the chip as the seed value. More... | |
int | select (Chip *inputChip, Chip *selectionChip) |
Given a range of DN this function creates a biniary chip for all continuous pixels that have the DN within the specified range using the center pixel of the chip as the seed value. More... | |
int | setDNRange (double minimumDN, double maximumDN) |
Set the range of the DNs. More... | |
double | getMinDN () |
double | getMaxDN () |
int | centerOfMass (Chip *selectionChip, double *sample, double *line) |
int | centerOfMassWeighted (Chip *inputChip, Chip *selectionChip, double *sample, double *line) |
bool | ellipseFrom5Pts (Ellipse *ell, double pts[5][2]) |
double | elipsePercentSelected (Chip *selectionChip, Ellipse *ell) |
std::vector< double > | minimumBoundingElipse (std::vector< std::vector< int > > pts, Ellipse *ell) |
bool | ellipseFromCubic (Ellipse *ell, double cubic[6]) |
bool | ellipseAxesAreaFromMatrix (Ellipse *ell) |
bool | bestFitEllipse (Ellipse *ell, std::vector< std::vector< int > > *pts, double play, unsigned int max_iter) |
bool | pointInEllipse (Ellipse *ell, double pt[2], double play) |
bool | ellipseInChip (Ellipse *ell, Chip *chip) |
bool | ellipseFromCenterAxesAngle (Ellipse *ell, double centerSample, double centerLine, double semiMajor, double semiMinor, double theta) |
void | selectionEdge (Chip *selectionChip, std::vector< std::vector< int > > *pts) |
Private Attributes | |
double | m_pixelSize |
pixel size in microns More... | |
double | m_maxDN |
The max DN value to be included in the selection. More... | |
double | m_minDN |
The min DN value to be included in the selection. More... | |
Selection class derived from the Pure Virtual Parent Class for all Selection classes.
Description coming soon
Definition at line 28 of file CentroidApolloPan.h.
Isis::CentroidApolloPan::CentroidApolloPan | ( | double | pixelSizeMicrons | ) |
Constructs a CentroidApolloPan object.
pixelSizeMicrons | The pixel size in microns |
Definition at line 36 of file CentroidApolloPan.cpp.
|
virtual |
Destroys the CentroidApolloPan object.
Definition at line 48 of file CentroidApolloPan.cpp.
|
virtual |
This method will take advantage of all the apriori knowlege we have of the size and orientation of the ellipse to speed up elliptical reduction.
The general elliptical reduction tool provided in the selection class is slow for the very large and potentially noisy ellipses of the apollo pan data.
Specifically we know: semiMajor Axis,a, is approximately parrallel to the sample chip axis and is approximately 60 5-micron pixels long semiMinor Axis,b, is approximately parrallel to the line chip axis and is approximately 60 5-micron pixels long
Hence we know the center of the ellipse is on the range [a+1,Samples-a],[b+1,lines-b] (because the entire ellipse must be within the chip)
this->pixel_size will be used to do any scaling neccessary
Algorithim: Step 1: Compile an array of all points on the border of the selected area Step 2: Choose a previously unused hypothesis center point from the range [a+1,samples-a],[b+1,lines-b] Step 3: For a given hypothesized ellipse center in the search set, define the Ellipse. Step 4: Do a least squares generization. Any points within a distance of play pixels to the edge of the ellipse are included in the gernalization. The distance check is repeated for every iteration so the ellipse can effective grow to include more points. Step 5: If the generization is successfully check to see if the area is at least as great as the current best, and that the ellipse is contained in the chip Step 6: If the area is great enough check that the percent selected is at least percent_selected. Step 7: If all above tests are passed then we have a new Best ellipse and the number of consecutive emptySets is zeroed. Otherwise emptySets++ Step 8: repeat steps 2 through 7 until pacience_limit consecquitive failures to find a better (larger area) elipse have occured
selectionChip | Binary chip of selected and unselected pixels |
percent_selected | Minimum percent of selected points |
play | Distance allowed in the least squares generization |
patience_limit | Maximum number of empty sets allowed |
printf("Debug: a: %lf b: %lf majorAxis: %lf %lf\n",ellBest.semiMajor,ellBest.semiMinor,ellBest.majorAxis[0],ellBest.majorAxis[1]);
Reimplemented from Isis::Selection.
Definition at line 192 of file CentroidApolloPan.cpp.
References Isis::Chip::GetValue(), Isis::Chip::Lines(), Isis::Chip::Samples(), and Isis::Chip::SetValue().
|
inherited |
Definition at line 147 of file Centroid.cpp.
|
inherited |
Definition at line 139 of file Centroid.cpp.
Given a range of DN this function creates a biniary chip for all continuous pixels that have the DN within the specified range using the center pixel of the chip as the seed value.
inputChip | Pointer to the input chip |
selectionChip | Pointer to the binary chip of selected and unselected pixels |
Implements Isis::Selection.
Definition at line 30 of file Centroid.cpp.
References Isis::Chip::ChipLine(), Isis::Chip::ChipSample(), Isis::Chip::GetValue(), Isis::Chip::Lines(), Isis::Chip::Samples(), Isis::Chip::SetAllValues(), Isis::Chip::SetSize(), and Isis::Chip::SetValue().
Referenced by Isis::AutoReg::SetSubpixelPosition().
Given a range of DN this function creates a biniary chip for all continuous pixels that have the DN within the specified range using the center pixel of the chip as the seed value.
inputChip | Chip centered around some centroidable feature (dark or light continous block of pixels) | |
[out] | selectionChip | Binary chip of selected and unselected pixels |
Definition at line 74 of file CentroidApolloPan.cpp.
References Isis::Chip::GetValue(), Isis::Chip::Lines(), and Isis::Chip::Samples().
|
inherited |
Set the range of the DNs.
minimumDN | The min DN value of the range |
maximumDN | The max DN value of the range |
Definition at line 126 of file Centroid.cpp.
Referenced by Isis::AutoReg::SetSubpixelPosition().
bool Isis::CentroidApolloPan::setPixelSize | ( | double | microns | ) |
Set the pixel size in microns.
microns | The pixel size value to set |
Definition at line 57 of file CentroidApolloPan.cpp.
|
privateinherited |
The max DN value to be included in the selection.
Definition at line 41 of file Centroid.h.
|
privateinherited |
The min DN value to be included in the selection.
Definition at line 42 of file Centroid.h.
|
private |
pixel size in microns
Definition at line 39 of file CentroidApolloPan.h.