The following line in PyCharm is flagged by on-the-fly inspection with unresolved reference errors for each import. (They are underlined red.)
from numpy import tan, arcsin, arccos, arctan
However the following imports do not cause any error/warning:
from numpy import sin, cos, arctan2, sqrt, cross, pi
The code in which I use these imports runs fine without any errors or warnings. I generally rely on PyCharm's red errors as a warning that my code is broken and will not run, but in this case PyCharm is wrong.
Why are some of numpy's functions recognized by PyCharm's introspection and others aren't?
Current Versions:
- Windows 7 64-bit
- Python 2.7.5
- PyCharm 3.1.2
- Numpy 1.8
Thanks!
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…