I am trying to reclassify a PixelValue in a 32 bit floating raster and get the following error:
bw_liss-3_spring_mosaick_gk3_ndvi_mask.tif
Traceback (most recent call last): File
"F:\Daten_Soner\CBD06\Test\NDVI\Spring\Extract\Reclassify_Cloudmask_LISS_Summer.py",
line 29, in <module>
remap = RemapValue([-340282346638528860000000000000000000000,000000,2])
File "C:\Program Files
(x86)\ArcGIS\Desktop10.0\arcpy\arcpy\sa\ParameterClasses.py", line
806, in __init__
_Remap.__init__(self, remapTable) File "C:\Program Files (x86)\ArcGIS\Desktop10.0\arcpy\arcpy\sa\ParameterClasses.py", line
751, in __init__
self.remapTable = [list(record) for record in remapTable]
TypeError: 'long' object is not iterable
I use the following script:
Import arcpy module
import arcpy, os, sys
Check out any necessary licenses
arcpy.CheckOutExtension("Spatial")
Set the workspace environment
from arcpy import env
from arcpy.sa import *
env.workspace = "F:\Daten_Soner\CBD06\Test\NDVI\Spring\Extract"
Get a list of TIFFS from the workspace and print
rasterList = arcpy.ListRasters()
for raster in rasterList:
print raster
arcpy.CalculateStatistics_management(raster)
# Process: Reclassify
remap = RemapValue([-340282346638528860000000000000000000000,000000,2])
outReclassify = Reclassify(raster, "Value", remap , "NODATA")
outReclassify.save(raster + "_re.tif")
Thanks for help!