-
Notifications
You must be signed in to change notification settings - Fork 173
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ciss2isis - Set validmax global to input label value #4589
Conversation
How bad does the test conversion look on this? We should have a simple test for this case. |
Simple to convert, difficult to crop data. There's no existing script for cropping cassis edr and it's nontrivial for me to write one during this sprint. Also - a test for this may not be valuable. This bug was the result of some faulty logic that has been removed, the same faulty logic would have to be rewritten for this to become an issue again in the future. |
@jessemapel are we still waiting on a test here or can this be merged? |
|
||
// initialize global variables | ||
dataConversionType = (QString) inst.findKeyword("DataConversionType"); | ||
validMax = inputLabel.findKeyword("ValidMaximum")[1].toInt(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated line, see the first commit on this PR
EXPECT_NEAR(hist->StandardDeviation(), 0.84419124016427105, .0001); | ||
} | ||
|
||
TEST(Ciss2Isis, Ciss2isisCustomMax) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Conversion to gtest necessary to accommodate this test
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Conversion and new tests look good, just one small change to more directly check what the test is actually doing.
Description
Set the value for validMax along with the other globals by reading from the input label. Previously was set according to faulty logic, leading some images to be ingested with an incorrect valid maximum DN. The helper function FixDns() replaces all DN's == validMax with Hrs. This was spoiling pixels when validMax was set incorrectly.
Related Issue
#672
Motivation and Context
Isis Support
How Has This Been Tested?
Screenshots (if appropriate):
Types of changes
Checklist:
Licensing
This project is mostly composed of free and unencumbered software released into the public domain, and we are unlikely to accept contributions that are not also released into the public domain. Somewhere near the top of each file should have these words: