Isis 3 Programmer Reference
ControlNetValidMeasure.cpp
1
7/* SPDX-License-Identifier: CC0-1.0 */
8
9#include "ControlNetValidMeasure.h"
10#include "Cube.h"
11#include "Camera.h"
12#include "ControlMeasure.h"
13#include "CubeManager.h"
14#include "MeasureValidationResults.h"
15#include "SerialNumberList.h"
16#include "SpecialPixel.h"
17#include "UniversalGroundMap.h"
18
19namespace Isis {
20
31
32 if(pPvl != NULL && pPvl->hasGroup("ValidMeasure")) {
33 Parse(*pPvl);
34 }
35 else {
37 }
38 mStatisticsGrp = PvlGroup("Statistics");
39 }
40
51
52 if(pPvl.hasGroup("ValidMeasure")) {
53 Parse(pPvl);
54 }
55 else {
57 }
58 mStatisticsGrp = PvlGroup("Statistics");
59 }
60
89
96 mStdOptionsGrp = PvlGroup("StandardOptions");
97
100
106 mStdOptionsGrp += Isis::PvlKeyword("MaxResolution", (mdMaxResolution == DBL_MAX ? "NA" : toString(mdSampleResTolerance)));
109
110 mStdOptionsGrp += Isis::PvlKeyword("SampleResidual", (mdSampleResTolerance == DBL_MAX ? "NA" : toString(mdSampleResTolerance)));
111 mStdOptionsGrp += Isis::PvlKeyword("LineResidual", (mdLineResTolerance == DBL_MAX ? "NA" : toString(mdLineResTolerance)));
112 mStdOptionsGrp += Isis::PvlKeyword("ResidualMagnitude", (mdResidualTolerance == DBL_MAX ? "NA" : toString(mdResidualTolerance)));
113
117 }
118
127
136 void ControlNetValidMeasure::ReadSerialNumbers(QString psSerialNumfile) {
137 mSerialNumbers = SerialNumberList(psSerialNumfile, true, &mStatus);
138
140 }
141
151 mPvlOpGrp = pvlDef.findGroup("ValidMeasure", Pvl::Traverse);
152
153 mStdOptionsGrp = PvlGroup("StandardOptions");
154
162
164 }
165
180 double pSample, double pLine, const ControlMeasure *pMeasure, Cube *pCube,
181 PvlGroup *pMeasureGrp) {
182
183 // Get the Camera
184 Camera *measureCamera = NULL;
185 if(mbCameraRequired) {
186 try {
187 measureCamera = pCube->camera();
188 }
189 catch(IException &e) {
190 QString msg = "Cannot Create Camera for Image:" + pCube->fileName();
191 throw IException(IException::User, msg, _FILEINFO_);
192 }
193 }
194
195 return ValidStandardOptions(pSample, pLine, pMeasure,
196 pCube, measureCamera, pMeasureGrp);
197 }
198
199
201 double pSample, double pLine, const ControlMeasure *pMeasure, Cube *pCube,
202 Camera *measureCamera, PvlGroup *pMeasureGrp) {
203
206 mdDnValue = 0;
209 mdLineResidual = 0;
211 m_sampleShift = 0;
212 m_lineShift = 0;
213 m_pixelShift = 0;
214
215 if (measureCamera != NULL) {
216 bool success = measureCamera->SetImage(pSample, pLine);
217 if (success) {
218 mdEmissionAngle = measureCamera->EmissionAngle();
219 mdIncidenceAngle = measureCamera->IncidenceAngle();
220 mdResolution = measureCamera->PixelResolution();
221 }
222 }
223
224 if (pMeasure != NULL) {
225 double temp = pMeasure->GetSampleResidual();
226 if (temp != Null) {
227 mdSampleResidual = fabs(temp);
228 }
229
230 temp = pMeasure->GetLineResidual();
231 if (temp != Null) {
232 mdLineResidual = fabs(temp);
233 }
234
235 temp = pMeasure->GetResidualMagnitude();
236 if (temp != Null) {
237 mdResidualMagnitude = fabs(temp);
238 }
239
240 temp = pMeasure->GetSampleShift();
241 if (temp != Null) {
242 m_sampleShift = fabs(temp);
243 }
244
245 temp = pMeasure->GetLineShift();
246 if (temp != Null) {
247 m_lineShift = fabs(temp);
248 }
249
250 temp = pMeasure->GetPixelShift();
251 if (temp != Null) {
252 m_pixelShift = fabs(temp);
253 }
254 }
255
256 if(mbValidateDN) {
257 Isis::Portal inPortal(1, 1, pCube->pixelType());
258 inPortal.SetPosition(pSample, pLine, 1);
259 pCube->read(inPortal);
260 mdDnValue = inPortal[0];
261 }
262
263 if(pMeasureGrp != NULL) {
265 *pMeasureGrp += Isis::PvlKeyword("EmissionAngle", toString(mdEmissionAngle));
266 *pMeasureGrp += Isis::PvlKeyword("IncidenceAngle", toString(mdIncidenceAngle));
267 *pMeasureGrp += Isis::PvlKeyword("Resolution", toString(mdResolution));
268 }
269 else {
270 *pMeasureGrp += Isis::PvlKeyword("EmissionAngle", "Invalid Emission Angle");
271 *pMeasureGrp += Isis::PvlKeyword("IncidenceAngle", "Invalid Incidence Angle");
272 *pMeasureGrp += Isis::PvlKeyword("Resolution", "Invalid Resolution");
273 }
274 if(mbValidateDN) {
275 *pMeasureGrp += Isis::PvlKeyword("DNValue", toString(mdDnValue));
276 }
277 *pMeasureGrp += Isis::PvlKeyword("SampleResidual", toString(mdSampleResidual));
278 *pMeasureGrp += Isis::PvlKeyword("LineResidual", toString(mdLineResidual));
279 *pMeasureGrp += Isis::PvlKeyword("ResidualMagnitude", toString(mdResidualMagnitude));
280
281 *pMeasureGrp += Isis::PvlKeyword("SampleShift", toString(m_sampleShift));
282 *pMeasureGrp += Isis::PvlKeyword("LineShift", toString(m_lineShift));
283 *pMeasureGrp += Isis::PvlKeyword("PixelShift", toString(m_pixelShift));
284 }
285
286 MeasureValidationResults results;
287
288 if(mbCameraRequired) {
290 results.addFailure(MeasureValidationResults::EmissionAngle,
292 }
293
295 results.addFailure(MeasureValidationResults::IncidenceAngle,
297 }
298
300 results.addFailure(MeasureValidationResults::Resolution,
302 }
303 }
304
305 if(mbValidateDN) {
306 if(!ValidDnValue(mdDnValue)) {
307 results.addFailure(MeasureValidationResults::DNValue,
309 }
310 }
311
313 if(!PixelsFromEdge((int)pSample, (int)pLine, pCube)) {
314 results.addFailure(MeasureValidationResults::PixelsFromEdge, miPixelsFromEdge);
315 }
316
317 if(!MetersFromEdge((int)pSample, (int)pLine, pCube)) {
318 results.addFailure(MeasureValidationResults::MetersFromEdge,
320 }
321 }
322
323 if(pMeasure != NULL) {
325 mdResidualMagnitude, results);
327 m_pixelShift, results);
328 }
329
330 return results;
331 }
332
346 double pSample, double pLine, Cube *pCube, PvlGroup *pMeasureGrp) {
347
348 return ValidStandardOptions(pSample, pLine, NULL, pCube, pMeasureGrp);
349
350 }
351
352
366 const ControlMeasure * pMeasure, Cube *pCube, PvlGroup *pMeasureGrp) {
367
368 double dSample, dLine;
369 dSample = pMeasure->GetSample();
370 dLine = pMeasure->GetLine();
371
372 return (ValidStandardOptions(dSample, dLine, pMeasure, pCube, pMeasureGrp));
373 }
374
375
377 const ControlMeasure * pMeasure, Cube *pCube, Camera *camera,
378 PvlGroup *pMeasureGrp) {
379
380 double dSample, dLine;
381 dSample = pMeasure->GetSample();
382 dLine = pMeasure->GetLine();
383
384 return ValidStandardOptions(dSample, dLine, pMeasure,
385 pCube, camera, pMeasureGrp);
386 }
387
395 // Parse the Pixels from edge
396 if(mPvlOpGrp.hasKeyword("PixelsFromEdge")) {
397 miPixelsFromEdge = mPvlOpGrp["PixelsFromEdge"];
398 if(miPixelsFromEdge < 0) {
400 }
401 else {
402 mbValidateFromEdge = true;
403 }
405 }
406 // Parse the Meters from edge
407 if(mPvlOpGrp.hasKeyword("MetersFromEdge")) {
408 mdMetersFromEdge = mPvlOpGrp["MetersFromEdge"];
409 if(mdMetersFromEdge < 0) {
411 }
412 else {
413 mbValidateFromEdge = true;
414 }
416 }
417 }
418
427 if(mPvlOpGrp.hasKeyword("MinResolution")){
428 mdMinResolution = mPvlOpGrp["MinResolution"];
429 mbCameraRequired = true;
430 }
431 else {
432 mdMinResolution = 0;
433 }
435
436 if(mPvlOpGrp.hasKeyword("MaxResolution")){
437 mdMaxResolution = mPvlOpGrp["MaxResolution"];
438 mbCameraRequired = true;
439 }
440 else {
441 mdMaxResolution = DBL_MAX;
442 }
443 mStdOptionsGrp += Isis::PvlKeyword("MaxResolution", (mdMaxResolution == DBL_MAX ? "NA" : toString(mdMaxResolution)));
444
445 if(mdMinResolution < 0 || mdMaxResolution < 0) {
446 QString msg = "Invalid Resolution value(s), Resolution must be greater than zero";
447 throw IException(IException::User, msg, _FILEINFO_);
448 }
449
451 QString msg = "MinResolution must be less than MaxResolution";
452 throw IException(IException::User, msg, _FILEINFO_);
453 }
454 }
455
465 if(mPvlOpGrp.hasKeyword("MinDN")) {
466 mdMinDN = mPvlOpGrp["MinDN"];
467 mbValidateDN = true;
468 }
469 else {
471 }
473
474 if(mPvlOpGrp.hasKeyword("MaxDN")) {
475 mdMaxDN = mPvlOpGrp["MaxDN"];
476 mbValidateDN = true;
477 }
478 else {
480 }
482
483 if(mdMaxDN < mdMinDN) {
484 QString msg = "MinDN must be less than MaxDN";
485 throw IException(IException::User, msg, _FILEINFO_);
486 }
487 }
488
498 if(mPvlOpGrp.hasKeyword("MinEmission")) {
499 mdMinEmissionAngle = mPvlOpGrp["MinEmission"];
500 mbCameraRequired = true;
501 if(mdMinEmissionAngle < 0 || mdMinEmissionAngle > 135) {
502 QString msg = "Invalid Min Emission Angle, Valid Range is [0-135]";
503 throw IException(IException::User, msg, _FILEINFO_);
504 }
505 }
507
508 if(mPvlOpGrp.hasKeyword("MaxEmission")) {
509 mdMaxEmissionAngle = mPvlOpGrp["MaxEmission"];
510 mbCameraRequired = true;
511 if(mdMaxEmissionAngle < 0 || mdMaxEmissionAngle > 135) {
512 QString msg = "Invalid Max Emission Angle, Valid Range is [0-135]";
513 throw IException(IException::User, msg, _FILEINFO_);
514 }
515 }
517
519 QString msg = "Min EmissionAngle must be less than Max EmissionAngle";
520 throw IException(IException::User, msg, _FILEINFO_);
521 }
522
523 }
524
534 if(mPvlOpGrp.hasKeyword("MinIncidence")) {
535 mdMinIncidenceAngle = mPvlOpGrp["MinIncidence"];
536 mbCameraRequired = true;
537 if(mdMinIncidenceAngle < 0 || mdMinIncidenceAngle > 135) {
538 QString msg = "Invalid Min Incidence Angle, Valid Range is [0-135]";
539 throw IException(IException::User, msg, _FILEINFO_);
540 }
541 }
543
544 if(mPvlOpGrp.hasKeyword("MaxIncidence")) {
545 mdMaxIncidenceAngle = mPvlOpGrp["MaxIncidence"];
546 mbCameraRequired = true;
547 if(mdMaxIncidenceAngle < 0 || mdMaxIncidenceAngle > 135) {
548 QString msg = "Invalid Max Incidence Angle, Valid Range is [0-135]";
549 throw IException(IException::User, msg, _FILEINFO_);
550 }
551 }
553
555 QString msg = "Min IncidenceAngle must be less than Max IncidenceAngle";
556 throw IException(IException::User, msg, _FILEINFO_);
557 }
558 }
559
566 bool bRes=false;
567 bool bResMag = false;
568 if(mPvlOpGrp.hasKeyword("SampleResidual")) {
569 mdSampleResTolerance = mPvlOpGrp["SampleResidual"];
570 if(mdSampleResTolerance < 0) {
571 QString msg = "Invalid Sample Residual, must be greater than zero";
572 throw IException(IException::User, msg, _FILEINFO_);
573 }
574 bRes = true;
575 }
576 mStdOptionsGrp += Isis::PvlKeyword("SampleResidual", (mdSampleResTolerance == DBL_MAX ? "NA" : toString(mdSampleResTolerance)));
577
578 if(mPvlOpGrp.hasKeyword("LineResidual")) {
579 mdLineResTolerance = mPvlOpGrp["LineResidual"];
580 if(mdLineResTolerance < 0) {
581 QString msg = "Invalid Line Residual, must be greater than zero";
582 throw IException(IException::User, msg, _FILEINFO_);
583 }
584 bRes = true;
585 }
586 mStdOptionsGrp += Isis::PvlKeyword("LineResidual", (mdLineResTolerance == DBL_MAX ? "NA" : toString(mdLineResTolerance)));
587
588 if(mPvlOpGrp.hasKeyword("ResidualMagnitude")) {
589 mdResidualTolerance = mPvlOpGrp["ResidualMagnitude"];
590 if(mdResidualTolerance < 0) {
591 QString msg = "Invalid Residual Magnitude Tolerance, must be greater than zero";
592 throw IException(IException::User, msg, _FILEINFO_);
593 }
594 bResMag = true;
595 }
596 mStdOptionsGrp += Isis::PvlKeyword("ResidualMagnitude", (mdResidualTolerance == DBL_MAX ? "NA" : toString(mdResidualTolerance)));
597
598 if(bRes && bResMag) {
599 QString msg = "Cannot have both Sample/Line Residuals and Residual Magnitude.";
600 msg += "\nChoose either Sample/Line Residual or Residual Magnitude";
601 throw IException(IException::User, msg, _FILEINFO_);
602 }
603 }
604
605
611 bool hasSampleLineShift = false;
612 if (mPvlOpGrp.hasKeyword("SampleShift")) {
613 m_sampleShiftTolerance = mPvlOpGrp["SampleShift"];
614 if (m_sampleShiftTolerance < 0) {
615 QString msg = "Invalid Sample Shift tolerance:"
616 " must be greater than or equal to zero";
617 throw IException(IException::User, msg, _FILEINFO_);
618 }
619 hasSampleLineShift = true;
620 }
622
623 if (mPvlOpGrp.hasKeyword("LineShift")) {
624 m_lineShiftTolerance = mPvlOpGrp["LineShift"];
625 if (m_lineShiftTolerance < 0) {
626 QString msg = "Invalid Line Shift tolerance:"
627 " must be greater than or equal to zero";
628 throw IException(IException::User, msg, _FILEINFO_);
629 }
630 hasSampleLineShift = true;
631 }
633
634 bool hasPixelShift = false;
635 if (mPvlOpGrp.hasKeyword("PixelShift")) {
636 m_pixelShiftTolerance = mPvlOpGrp["PixelShift"];
637 if (m_pixelShiftTolerance < 0) {
638 QString msg = "Invalid Pixel Shift tolerance:"
639 " must be greater than or equal to zero";
640 throw IException(IException::User, msg, _FILEINFO_);
641 }
642 hasPixelShift = true;
643 }
645
646 if (hasSampleLineShift && hasPixelShift) {
647 QString msg = "Cannot have both Sample/Line Shift and Pixel Shift";
648 msg += " tolerances.\n";
649 msg += "Choose either Sample/Line Shift or Pixel Shift to validate on";
650 throw IException(IException::User, msg, _FILEINFO_);
651 }
652 }
653
654
666 bool ControlNetValidMeasure::ValidEmissionAngle(double pdEmissionAngle) {
667 if(pdEmissionAngle < mdMinEmissionAngle || pdEmissionAngle > mdMaxEmissionAngle) {
668 return false;
669 }
670 return true;
671 }
672
684 bool ControlNetValidMeasure::ValidIncidenceAngle(double pdIncidenceAngle) {
685 if(pdIncidenceAngle < mdMinIncidenceAngle || pdIncidenceAngle > mdMaxIncidenceAngle) {
686 return false;
687 }
688 return true;
689 }
690
702 if(Isis::IsSpecial(pdDnValue) || pdDnValue < mdMinDN || pdDnValue > mdMaxDN) {
703 return false;
704 }
705 return true;
706 }
707
718 bool ControlNetValidMeasure::ValidResolution(double pdResolution) {
719 if(pdResolution < mdMinResolution || pdResolution > mdMaxResolution) {
720 return false;
721 }
722 return true;
723 }
724
725
740 double pdLineResidual, double pdResidualMagnitude,
741 MeasureValidationResults & pResults){
742 bool bFlag = true;
743
744 if(pdSampleResidual > mdSampleResTolerance) {
745 bFlag = false;
746 pResults.addFailure(MeasureValidationResults::SampleResidual, mdSampleResTolerance, "greater");
747 }
748 if(pdLineResidual > mdLineResTolerance) {
749 bFlag = false;
750 pResults.addFailure(MeasureValidationResults::LineResidual, mdLineResTolerance, "greater");
751 }
752 if(pdResidualMagnitude > mdResidualTolerance) {
753 bFlag = false;
754 pResults.addFailure(MeasureValidationResults::ResidualMagnitude, mdResidualTolerance, "greater");
755 }
756
757 return bFlag;
758 }
759
760
773 double sampleShift, double lineShift, double pixelShift,
774 MeasureValidationResults &results) {
775
776 bool valid = true;
777
778 if (sampleShift > m_sampleShiftTolerance) {
779 valid = false;
780 results.addFailure(MeasureValidationResults::SampleShift,
781 m_sampleShiftTolerance, "greater");
782 }
783 if (lineShift > m_lineShiftTolerance) {
784 valid = false;
785 results.addFailure(MeasureValidationResults::LineShift,
786 m_lineShiftTolerance, "greater");
787 }
788 if (pixelShift > m_pixelShiftTolerance) {
789 valid = false;
790 results.addFailure(MeasureValidationResults::PixelShift,
791 m_pixelShiftTolerance, "greater");
792 }
793
794 return valid;
795 }
796
797
809 bool ControlNetValidMeasure::ValidLatLon(Camera *pCamera, int piSample, int piLine) {
810 return true;
811 }
812
824 bool ControlNetValidMeasure::PixelsFromEdge(int piSample, int piLine, Cube *pCube) {
825 if(miPixelsFromEdge <= 0) {
826 return true;
827 }
828
829 int iNumSamples = pCube->sampleCount();
830 int iNumLines = pCube->lineCount();
831
832 // test right
833 if((iNumSamples - piSample) < miPixelsFromEdge) {
834 return false;
835 }
836
837 // test left
838 if((piSample - miPixelsFromEdge) <= 0) {
839 return false;
840 }
841
842 // test down
843 if((iNumLines - piLine) < miPixelsFromEdge) {
844 return false;
845 }
846
847 // test up
848 if((piLine - miPixelsFromEdge) <= 0) {
849 return false;
850 }
851
852 return true;
853 }
854
866 bool ControlNetValidMeasure::MetersFromEdge(int piSample, int piLine, Cube *pCube) {
867 if(mdMetersFromEdge <= 0) {
868 return true;
869 }
870
871 int iNumSamples = pCube->sampleCount();
872 int iNumLines = pCube->lineCount();
873
874 try {
875 // Get the image's camera to get pixel resolution
876 Camera *camera = pCube->camera();
877 double resMetersTotal = 0;
878 bool bMinDistance = false;
879
880 // test top
881 for(int line = piLine - 1; line > 0; line--) {
882 camera->SetImage(piSample, line);
883 double resolution = camera->PixelResolution();
884 resMetersTotal += resolution;
885 if(resMetersTotal >= mdMetersFromEdge) {
886 bMinDistance = true;
887 break;
888 }
889 }
890 if(!bMinDistance) {
891 return false;
892 }
893
894 // test bottom
895 bMinDistance = false;
896 resMetersTotal = 0;
897 for(int line = piLine + 1; line <= iNumLines; line++) {
898 camera->SetImage(piSample, line);
899 double resolution = camera->PixelResolution();
900 resMetersTotal += resolution;
901 if(resMetersTotal >= mdMetersFromEdge) {
902 bMinDistance = true;
903 break;
904 }
905 }
906 if(!bMinDistance) {
907 return false;
908 }
909
910 // test left
911 resMetersTotal = 0;
912 bMinDistance = false;
913 for(int sample = piSample - 1; sample > 0; sample--) {
914 camera->SetImage(sample, piLine);
915 double resolution = camera->PixelResolution();
916 resMetersTotal += resolution;
917 if(resMetersTotal >= mdMetersFromEdge) {
918 bMinDistance = true;
919 break;
920 }
921 }
922 if(!bMinDistance) {
923 return false;
924 }
925
926 // test right
927 resMetersTotal = 0;
928 bMinDistance = false;
929 for(int sample = piSample + 1; sample <= iNumSamples; sample++) {
930 camera->SetImage(sample, piLine);
931 double resolution = camera->PixelResolution();
932 resMetersTotal += resolution;
933 if(resMetersTotal >= mdMetersFromEdge) {
934 return true;
935 }
936 }
937 return false;
938 }
939 catch(IException &e) {
940 QString msg = "Cannot Create Camera for Image [" +
941 pCube->fileName() + "]";
942 throw IException(IException::User, msg, _FILEINFO_);
943 }
944 }
945};
virtual double PixelResolution()
Returns the pixel resolution at the current position in meters/pixel.
Definition Camera.cpp:681
virtual bool SetImage(const double sample, const double line)
Sets the sample/line values of the image to get the lat/lon values.
Definition Camera.cpp:156
a control measurement
double mdMaxResolution
Standard Option MaxResolution.
double m_lineShift
Store current Measure's Line Shift.
void Parse(Pvl &pvlDef)
Parse the DefFile for Standard Options.
bool mbCameraRequired
To improve speed, flag to indicate if Camera needs to be opened.
bool ValidResidualTolerances(double pdSampleResidual, double pdLineResidual, double pdResidualMagnitude, MeasureValidationResults &pResults)
Validate whether the Residuals are within the set Tolerance.
void ValidatePvlDN(void)
Validate PVL Min & Max DN Standard Options.
double m_sampleShift
Store current Measure's Sample Shift.
double mdSampleResTolerance
Standard Option Sample Residual.
double mdMinIncidenceAngle
Standard Option MinIncidenceAngle.
bool PixelsFromEdge(int piSample, int piLine, Cube *pCube)
Test for a point to be user defined number of pixels from the edge.
double m_pixelShift
Store current Measure's Pixel Shift.
double mdMetersFromEdge
Standard Option MeteresFromEdge.
MeasureValidationResults ValidStandardOptions(const ControlMeasure *pMeasure, Cube *pCube, PvlGroup *pMeasureGrp=NULL)
Validate Standard options to pick a reference based on a particular criteria.
double m_sampleShiftTolerance
Standard Option Sample Shift.
double mdResidualMagnitude
Store current Measure's Residual Magnitude.
bool MetersFromEdge(int piSample, int piLine, Cube *pCube)
Test for a point to be user defined number of meters from the edge.
ControlNetValidMeasure(Pvl *pvl=0)
Constructor - Initializes the data members and parses the input Pvl .
bool ValidShiftTolerances(double sampleShift, double lineShift, double pixelShift, MeasureValidationResults &results)
Validate whether the Sample and Line Shifts and Pixel Shift are within the set Tolerances.
PvlGroup mStdOptionsGrp
Pvl Standard Options Group.
bool ValidResolution(double pdResolution)
Validate whether the Resolution is in the set Range.
void ValidatePvlResolution(void)
Validate PVL Min & Max Resolution Standard Options.
void ValidatePvlEmissionAngle(void)
Validate PVL Min & Max EmissionAngle Standard Options.
double mdLineResTolerance
Standard Option Line Residual.
double mdMinDN
Standard Option MinDN.
double mdSampleResidual
Store current Measure's Sample Residual.
double mdLineResidual
Store current Measure's Line Residual.
double mdMaxDN
Standard Option MaxDN.
bool ValidIncidenceAngle(double pdIncidenceAngle)
Validate whether the Incidence Angle is in the set Range.
double mdMinEmissionAngle
Standard Option MinEmissionAngle.
CubeManager mCubeMgr
CubeManager to open and read cubes.
PvlGroup mStatisticsGrp
Pvl output Statistics Group.
double mdEmissionAngle
Store current Measure's Emission Angle.
double mdDnValue
Store current Measure's DN Value.
double mdMaxIncidenceAngle
Standard Option MaxIncidenceAngle.
void ValidatePvlResidualTolerances(void)
Validate Pvl Sample, Line, Residual Magnitude Tolerances.
bool mbValidateFromEdge
Check if Pixels/Meters from edge needs to be Validated.
SerialNumberList mSerialNumbers
Serial numbers list.
double m_pixelShiftTolerance
Standard Option Pixel Shift.
void InitStdOptionsGroup(void)
Initialize the Standard Options Pvl Group with no DefFile.
bool ValidEmissionAngle(double pdEmissionAngle)
Validate whether the Emission Angle is in the set Range.
void ValidatePvlShiftTolerances()
Validate Pvl Sample, Line, Pixel (Sample and Line) Magnitude Shift Tolerances.
double mdResidualTolerance
Standard Option Residual Magnitude.
Pvl mPvlLog
Pvl Log of all the processing.
int miPixelsFromEdge
Standard Option PixelsFromEdge.
double m_lineShiftTolerance
Standard Option Line Shift.
double mdMinResolution
Standard Option MinResolution.
Progress mStatus
Monitor the status of the app.
bool mbValidateDN
Check if DN needs to be Validated.
bool ValidDnValue(double pdDnValue)
Validate whether the DN Value is in the set Range.
virtual ~ControlNetValidMeasure()
Destructor: clean up stuff relevant for this class.
double mdResolution
Store current Measure's Resolution.
PvlGroup mPvlOpGrp
Pvl Operator Group.
void InitStdOptions(void)
Initialize the Standard Options.
void ReadSerialNumbers(QString psSerialNumfile)
Read the Serial Numbers from the file and open assocaited cubes.
bool ValidLatLon(Isis::Camera *pCamera, int piSample, int piLine)
Validate the Lat/Lon.
double mdIncidenceAngle
Store current Measure's Incidence Angle.
void ValidatePvlIncidenceAngle(void)
Validate PVL Min & Max IncidenceAngle Standard Options.
void ValidatePvlFromEdge(void)
Validate and read Pixels and Meters from Edge Standard Options.
double mdMaxEmissionAngle
Standard Option MaxEmissionAngle.
IO Handler for Isis Cubes.
Definition Cube.h:168
void SetNumOpenCubes(unsigned int numCubes)
This sets the maximum number of opened cubes for this instance of CubeManager.
void CleanCubes(const QString &cubeFileName)
This method removes a cube from memory, if it exists.
Isis exception class.
Definition IException.h:91
@ User
A type of error that could only have occurred due to a mistake on the user's part (e....
Definition IException.h:126
MeasureValidationResults class.
Buffer for containing a two dimensional section of an image.
Definition Portal.h:36
bool hasKeyword(const QString &name) const
Check to see if a keyword exists.
Contains multiple PvlContainers.
Definition PvlGroup.h:41
Container for cube-like labels.
Definition Pvl.h:119
A single keyword-value pair.
Definition PvlKeyword.h:87
@ Traverse
Search child objects.
Definition PvlObject.h:158
Serial Number list generator.
This is free and unencumbered software released into the public domain.
Definition Apollo.h:16
QString toString(bool boolToConvert)
Global function to convert a boolean to a string.
Definition IString.cpp:211
const double ValidMaximum
The maximum valid double value for Isis pixels.
const double Null
Value for an Isis Null pixel.
const double ValidMinimum
The minimum valid double value for Isis pixels.
bool IsSpecial(const double d)
Returns if the input pixel is special.