Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Changing the mask without changing the bit type of the output doesn't make sense to me. See #4006. These two keywords have to be in sync with each other. See line 131 in this file. It appears to be setting unsignedword for an 8bit output request. I wonder if the mask would work correctly without the fix below if line 131 was set to unsignedbyte????
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.
Good eye. Changing that output type to unsignedbyte produces correct mask and samples_bits values in the output pvl for BITS=8.
Line 197 is still needed for BITS values 9-15, because the mask always defaults to the full 16 bits. ( #3978 )
Also, I was under the impression that (output pvl) SAMPLE_BITS should be 16 for (user-entered) BITS=[9, 16] and 8 for BITS=8. Is that correct?