Allow mean pixel value inference from int arrays, not just float#220
Merged
Allow mean pixel value inference from int arrays, not just float#220
Conversation
Contributor
TimMonko
commented
Oct 28, 2023
- Now only passes None to self.pixel_values i ncsr.py if subdtype is np.bool_ rather than only collecting pixel_values when subdtype is np.float_ allowing for pixel_values to be obtained from int and uint images.
- add skeletonlabel to _testdata.py to have an example int array
- add test_skeletonlabel to test_csr.py to confirm int array behaves as expected with csr.summarize
* only pass None to self.pixel_values i ncsr.py if subdtype is np.bool_ rather than only collecting pixel_values when subdtype is np.float_ allowing for pixel_values to be obtained from int and uint images. * add skeletonlabel to _testdata.py to have an example int array * add test_skeletonlabel to test_csr.py to confirm int array behaves as expected with csr.summarize
Contributor
Author
|
Good news,: I figured out how to run pytest independently of whatever cookie cutter has helped me in the past. Bad news: I realize my changes don't pass. So I'll work on this some more to sort it out! |
passes new tests, all other tests pass
…ing underlying values and not 1
Contributor
Author
|
Should be good to go now. Old tests pass, as does the new test. |
Owner
|
Brilliant, thank you! I had to push some dependency fixes because of pydantic v2 so that the tests would run on CI, but this is ready as far as I'm concerned, will merge! Thanks! 🚀 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.