Hi,
I can clip a raster using "Extract By Mask" in python window of ArcGIS as follow:
a=arcpy.sa.ExtractByMask("out_raster1","StudyArea")
However, when I use the same code out of ArcGIS (i.e. PyCharm), I get this error:
rcgisscripting.ExecuteError: Failed to execute. Parameters are not valid.
ERROR 000824: The tool is not licensed.
Failed to execute (ExtractByMask).
What is wrong?
Solved! Go to Solution.
Found the solution!
I had to Check Out Spatial Analysis after importing arcpy as follow:
import arcpy
arcpy.CheckOutExtension('Spatial')
Cheers
Found the solution!
I had to Check Out Spatial Analysis after importing arcpy as follow:
import arcpy
arcpy.CheckOutExtension('Spatial')
Cheers