I am running Pylint on a Python project. Pylint makes many complaints about being unable to find NumPy members. How can I avoid this while avoiding skipping membership checks?
From the code:
import numpy as np
print np.zeros([1, 4])
Which, when ran, I get the expected:
[[ 0. 0. 0. 0.]]
However, Pylint gives me this error:
E: 3, 6: Module 'numpy' has no 'zeros' member (no-member)
For versions, I am using Pylint 1.0.0 (astroid 1.0.1, common 0.60.0) and trying to work with NumPy 1.8.0.
Probably, it's confused with NumPy's abstruse method of methods import. Namely,
zerosis in factnumpy.core.multiarray.zeros, imported in NumPy with the statementin turn imported with
and in numeric you'll find
I guess I would be confused in place of Pylint!
See this bug for the Pylint side of view.