Loading CHANGELOG.md +1 −0 Original line number Diff line number Diff line Loading @@ -79,6 +79,7 @@ Keywords when running CAMSTATS. [#3605](https://github.com/USGS-Astrogeology/IS - Fixed slow runs of automos when the priority was BAND. [#4793](https://github.com/USGS-Astrogeology/ISIS3/pull/4793) - Fixed qview crashing when attempting to load image DNs. [4818](https://github.com/USGS-Astrogeology/ISIS3/issues/4818) - Modified cnetcheck noLatLonCheck logic to correctly exclude ignored measures. [#4649](https://github.com/USGS-Astrogeology/ISIS3/issues/4649) - Fixed bug where the original label was not attached to stereo HRSC images on import [#4816](https://github.com/USGS-Astrogeology/ISIS3/issues/4816) ## [6.0.0] - 2021-08-27 Loading isis/src/mex/apps/hrsc2isis/hrsc2isis.cpp +8 −47 Original line number Diff line number Diff line Loading @@ -15,12 +15,11 @@ find files of those names at the top level of this repository. **/ #include "LineManager.h" #include "IException.h" #include "Application.h" #include "OriginalLabel.h" using namespace std; namespace Isis{ void ImportHrscStereoImage(ProcessImportPds &p, Pvl &label); void ImportHrscStereoImage(ProcessImportPds &p, Pvl &label, UserInterface &ui); void ImportHrscSrcImage(ProcessImportPds &p, Pvl &label); void ImportHrscStereoImage(ProcessImportPds &p, Pvl &label, UserInterface &ui, Pvl &originalLab); void ImportHrscSrcImage(ProcessImportPds &p, Pvl &label, UserInterface &ui); void IgnoreData(Isis::Buffer &buf); Loading Loading @@ -85,47 +84,12 @@ namespace Isis{ ImportHrscSrcImage(p, label, ui); } else { ImportHrscStereoImage(p, label, ui); ImportHrscStereoImage(p, label, ui, label); } } // Import a PDS3, HRSC, SRC Camera image. void ImportHrscSrcImage(ProcessImportPds &p, Pvl &label) { outCube = p.SetOutputCube("TO"); p.StartProcess(); Pvl otherLabels; TranslateHrscLabels(label, otherLabels); if (otherLabels.hasGroup("Instrument") && (otherLabels.findGroup("Instrument").keywords() > 0)) { outCube->putGroup(otherLabels.findGroup("Instrument")); } if (otherLabels.hasGroup("BandBin") && (otherLabels.findGroup("BandBin").keywords() > 0)) { outCube->putGroup(otherLabels.findGroup("BandBin")); } if (otherLabels.hasGroup("Archive") && (otherLabels.findGroup("Archive").keywords() > 0)) { outCube->putGroup(otherLabels.findGroup("Archive")); } if (otherLabels.hasGroup("Kernels") && (otherLabels.findGroup("Kernels").keywords() > 0)) { outCube->putGroup(otherLabels.findGroup("Kernels")); } p.EndProcess(); } // Import a PDS3, HRSC, SRC Camera image. void ImportHrscSrcImage(ProcessImportPds &p, Pvl &label, UserInterface &ui) { CubeAttributeOutput &att = ui.GetOutputAttribute("TO"); Loading Loading @@ -178,14 +142,7 @@ namespace Isis{ * NOTE: Regardless of the input file's byte order IMAGE-SAMPLE_TYPE, the prefix data byte order * is always LSB. */ void ImportHrscStereoImage(ProcessImportPds &p, Pvl &label) { UserInterface &ui = Application::GetUserInterface(); ImportHrscStereoImage(p, label, ui); } void ImportHrscStereoImage(ProcessImportPds &p, Pvl &label, UserInterface &ui) { void ImportHrscStereoImage(ProcessImportPds &p, Pvl &label, UserInterface &ui, Pvl &originalLab) { lineInFile.clear(); numLinesSkipped = 0; Loading Loading @@ -293,6 +250,10 @@ namespace Isis{ outCube->putGroup(otherLabels.findGroup("Kernels")); } OriginalLabel ol(originalLab); outCube->write(ol); p.EndProcess(); outCube->close(); Loading isis/tests/FunctionalTestsHrsc2isis.cpp +10 −0 Original line number Diff line number Diff line Loading @@ -7,6 +7,7 @@ #include "PvlGroup.h" #include "TestUtilities.h" #include "Histogram.h" #include "OriginalLabel.h" #include "gmock/gmock.h" #include "gtest/gtest.h" Loading Loading @@ -81,6 +82,11 @@ TEST(Hrsc2isis, Hrsc2IsisTestDefault) { ASSERT_DOUBLE_EQ(hist->Sum(), 409993); ASSERT_EQ(hist->ValidPixels(), 6440); ASSERT_NEAR(hist->StandardDeviation(), 6.36599, .00001); // check original label exists Pvl ogLab = cube.readOriginalLabel().ReturnLabels(); ASSERT_EQ(archive["DETECTOR_ID"][0].toStdString(), "MEX_HRSC_RED" ); } Loading Loading @@ -134,6 +140,10 @@ TEST(Hrsc2isis, Hrsc2IsisTestPhobos) { ASSERT_DOUBLE_EQ(hist->Sum(), 2496); ASSERT_EQ(hist->ValidPixels(), 25920); ASSERT_NEAR(hist->StandardDeviation(), 0.52835, .00001); // check original label exists Pvl ogLab = cube.readOriginalLabel().ReturnLabels(); ASSERT_EQ(archive["DETECTOR_ID"][0].toStdString(), "MEX_HRSC_S2" ); } Loading Loading
CHANGELOG.md +1 −0 Original line number Diff line number Diff line Loading @@ -79,6 +79,7 @@ Keywords when running CAMSTATS. [#3605](https://github.com/USGS-Astrogeology/IS - Fixed slow runs of automos when the priority was BAND. [#4793](https://github.com/USGS-Astrogeology/ISIS3/pull/4793) - Fixed qview crashing when attempting to load image DNs. [4818](https://github.com/USGS-Astrogeology/ISIS3/issues/4818) - Modified cnetcheck noLatLonCheck logic to correctly exclude ignored measures. [#4649](https://github.com/USGS-Astrogeology/ISIS3/issues/4649) - Fixed bug where the original label was not attached to stereo HRSC images on import [#4816](https://github.com/USGS-Astrogeology/ISIS3/issues/4816) ## [6.0.0] - 2021-08-27 Loading
isis/src/mex/apps/hrsc2isis/hrsc2isis.cpp +8 −47 Original line number Diff line number Diff line Loading @@ -15,12 +15,11 @@ find files of those names at the top level of this repository. **/ #include "LineManager.h" #include "IException.h" #include "Application.h" #include "OriginalLabel.h" using namespace std; namespace Isis{ void ImportHrscStereoImage(ProcessImportPds &p, Pvl &label); void ImportHrscStereoImage(ProcessImportPds &p, Pvl &label, UserInterface &ui); void ImportHrscSrcImage(ProcessImportPds &p, Pvl &label); void ImportHrscStereoImage(ProcessImportPds &p, Pvl &label, UserInterface &ui, Pvl &originalLab); void ImportHrscSrcImage(ProcessImportPds &p, Pvl &label, UserInterface &ui); void IgnoreData(Isis::Buffer &buf); Loading Loading @@ -85,47 +84,12 @@ namespace Isis{ ImportHrscSrcImage(p, label, ui); } else { ImportHrscStereoImage(p, label, ui); ImportHrscStereoImage(p, label, ui, label); } } // Import a PDS3, HRSC, SRC Camera image. void ImportHrscSrcImage(ProcessImportPds &p, Pvl &label) { outCube = p.SetOutputCube("TO"); p.StartProcess(); Pvl otherLabels; TranslateHrscLabels(label, otherLabels); if (otherLabels.hasGroup("Instrument") && (otherLabels.findGroup("Instrument").keywords() > 0)) { outCube->putGroup(otherLabels.findGroup("Instrument")); } if (otherLabels.hasGroup("BandBin") && (otherLabels.findGroup("BandBin").keywords() > 0)) { outCube->putGroup(otherLabels.findGroup("BandBin")); } if (otherLabels.hasGroup("Archive") && (otherLabels.findGroup("Archive").keywords() > 0)) { outCube->putGroup(otherLabels.findGroup("Archive")); } if (otherLabels.hasGroup("Kernels") && (otherLabels.findGroup("Kernels").keywords() > 0)) { outCube->putGroup(otherLabels.findGroup("Kernels")); } p.EndProcess(); } // Import a PDS3, HRSC, SRC Camera image. void ImportHrscSrcImage(ProcessImportPds &p, Pvl &label, UserInterface &ui) { CubeAttributeOutput &att = ui.GetOutputAttribute("TO"); Loading Loading @@ -178,14 +142,7 @@ namespace Isis{ * NOTE: Regardless of the input file's byte order IMAGE-SAMPLE_TYPE, the prefix data byte order * is always LSB. */ void ImportHrscStereoImage(ProcessImportPds &p, Pvl &label) { UserInterface &ui = Application::GetUserInterface(); ImportHrscStereoImage(p, label, ui); } void ImportHrscStereoImage(ProcessImportPds &p, Pvl &label, UserInterface &ui) { void ImportHrscStereoImage(ProcessImportPds &p, Pvl &label, UserInterface &ui, Pvl &originalLab) { lineInFile.clear(); numLinesSkipped = 0; Loading Loading @@ -293,6 +250,10 @@ namespace Isis{ outCube->putGroup(otherLabels.findGroup("Kernels")); } OriginalLabel ol(originalLab); outCube->write(ol); p.EndProcess(); outCube->close(); Loading
isis/tests/FunctionalTestsHrsc2isis.cpp +10 −0 Original line number Diff line number Diff line Loading @@ -7,6 +7,7 @@ #include "PvlGroup.h" #include "TestUtilities.h" #include "Histogram.h" #include "OriginalLabel.h" #include "gmock/gmock.h" #include "gtest/gtest.h" Loading Loading @@ -81,6 +82,11 @@ TEST(Hrsc2isis, Hrsc2IsisTestDefault) { ASSERT_DOUBLE_EQ(hist->Sum(), 409993); ASSERT_EQ(hist->ValidPixels(), 6440); ASSERT_NEAR(hist->StandardDeviation(), 6.36599, .00001); // check original label exists Pvl ogLab = cube.readOriginalLabel().ReturnLabels(); ASSERT_EQ(archive["DETECTOR_ID"][0].toStdString(), "MEX_HRSC_RED" ); } Loading Loading @@ -134,6 +140,10 @@ TEST(Hrsc2isis, Hrsc2IsisTestPhobos) { ASSERT_DOUBLE_EQ(hist->Sum(), 2496); ASSERT_EQ(hist->ValidPixels(), 25920); ASSERT_NEAR(hist->StandardDeviation(), 0.52835, .00001); // check original label exists Pvl ogLab = cube.readOriginalLabel().ReturnLabels(); ASSERT_EQ(archive["DETECTOR_ID"][0].toStdString(), "MEX_HRSC_S2" ); } Loading