Hi all,

I've got a question about numpy typing. We have our own internal codebase that heavily depends on numpy, and we're trying to get the number of mypy errors down. Many of the remaining mypy errors are actually numpy false positives. I hoped that with the numpy 1.22.0 release these would be fixed, as there ought to be many typing improvements in that version, but apparently they're not? I'm asking here to check if this is just still a work in progress and we should be patient, or if there's something wrong on our side...?


Some typical false positives are:

"finfo[float32]" has no attribute "tiny"
Module has no attribute "count_nonzero"
Module has no attribute "rot90"
Module has no attribute "asfortranarray"
Module has no attribute "isfinite"
Module has no attribute "any"
Module has no attribute "histogram"; maybe "histogramdd"?
Module has no attribute "bitwise_or"
Module has no attribute "bitwise_and"
Module has no attribute "indices"
Module has no attribute "pad"

versions:
python 3.8.10; numpy 1.22.0; mypy 0.930

--

        

Vincent Schut

Remote Sensing Software Engineer

+31 302272679 ~ Maliebaan 22 | 3581CP | Utrecht | Netherlands

Linkedin <https://www.linkedin.com/company/satelligence/>~
satelligence.com <http://www.satelligence.com><http://www.satelligence.com>

_______________________________________________
NumPy-Discussion mailing list -- numpy-discussion@python.org
To unsubscribe send an email to numpy-discussion-le...@python.org
https://mail.python.org/mailman3/lists/numpy-discussion.python.org/
Member address: arch...@mail-archive.com

Reply via email to