qwerty@

Python Map Algebra error: Failed to execute (output)

Discussion created by qwerty@ on Jul 8, 2015
Latest reply on Oct 15, 2015 by curtvprice
Branched from an earlier discussion

Dear Jake,

 

I have a problem with another equation where I am using minimum and maximum value from my data. I am using the following code:

 

RI_tif = "C:\\output.tif"

 

# Process: Get Raster Properties

arcpy.GetRasterProperties_management(v6_tif, "MINIMUM", "")

 

# Process: Get Raster Properties (2)

arcpy.GetRasterProperties_management(v6_tif, "MAXIMUM", "")

 

# Process: Raster Calculator (3)

outSubt = (Raster("6.tif")-(float(Property))/((float(Property (2))-(float(Property))

outSubt.save("C:\\output_tif")

 

I have an error in the last line "Failed to execute (output)." I think that the problem is with the min, max values which I am using in the equation. Probably I implemented them in a wrong way. However, I could not find at ESRI website some example how to do this. Do you have maybe idea how to implement these values in python?

 

Thanks in advance.

Outcomes