I can't import the arcpy module from the Python window. It seems to be a problem with the numpy module. What can i do? I have ArcMap 10.2.2
What happens exactly when you type import arcpy from the Python window?
>>> import arcpy
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "c:\program files (x86)\arcgis\desktop10.2\arcpy\arcpy\__init__.py", line 24, in <module>
from arcpy.toolbox import *
File "c:\program files (x86)\arcgis\desktop10.2\arcpy\arcpy\toolbox.py", line 356, in <module>
from management import Graph, GraphTemplate
File "c:\program files (x86)\arcgis\desktop10.2\arcpy\arcpy\management.py", line 22, in <module>
File "c:\program files (x86)\arcgis\desktop10.2\arcpy\arcpy\_management.py", line 14, in <module>
File "c:\program files (x86)\arcgis\desktop10.2\arcpy\arcpy\_graph.py", line 27, in <module>
ImportError: No module named numpy
not installed properly...
Which Python window? The IDE built into arcmap? Pythonwin? PyScripter?
If it is something other than within ArcMap, then you need to import them explicitly,
>>> import arcpy
>>> import numpy # if you want to use the namespace numpy
>>> import numpy as np # the usual nickname for numpy
If neither of these work, your installation is broken and you will need to reinstall. It is recommended that you let ArcMap install where it wants to. Also, if you are not familiar with Python, it would be a good idea to uninstall any previous installations that exist on disk, then install ArcMap and reinstall other installations if you know how to work with Python paths etc. Fixing a Python install can be done, but I don't recommend it. Running a different version on a separate machine is cheaper if you include debug time.
Retrieving data ...