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
Make Image.__array__ take optional dtype argument #5572
Conversation
This is required by the numpy protocol.
To demystify what is needed by This has been very stable and the reason the bug shows up in Pillow 8.3 is that it implemented only the version without the dtype passed in when switching to providing I looked at numpy's ndarray |
Thank you @radarhere. Co-authored-by: Andrew Murray <3112309+radarhere@users.noreply.github.com>
I'm not entirely sure what to do with the codecov. It seems implausible to me that the line it points out in the |
I expect that was just because some CI jobs had an intermittent failure and were not returning their coverage results - everything looks fine with your latest commit. |
OK, I leave the it to you to take this forward, then. Thank you for your suggestions. |
There's currently a bug that interferes with the .to_tensor() function in torch. see: pytorch/pytorch#61125 (comment) and: python-pillow/Pillow#5572
This is required by the numpy protocol.
Fixes #5571