I have written a tool that operates on raster data. When the tool finishes it outputs a raster into a gdb, but the output does not have a NoData value listed under properties (input does, output does not). I've tried myriad tricks to get a NoData value to export, no luck.
ESRI recommends exporting to a tiff to set a NoData value if a raster does not have one, but I would have to do that hundreds of times. I'd like an arcpy command that will get the tool to output a raster with a NoData value.
I need to output a raster with a NoData value listed in the properties.
Can anybody help me?
Here is the end of my .pyt file.
output_raster = arcpy.NumPyArrayToRaster(tempras0, \ arcpy.Point(desc_ras.extent.XMin,desc_ras.extent.YMin), \ desc_ras.meanCellWidth,desc_ras.meanCellHeight) outSetNull=SetNull(output_raster, output_raster, "VALUE < -10000") outSetNull.save(parameters.valueAsText) arcpy.DefineProjection_management(parameters.valueAsText,desc_ras.spatialReference) arcpy.SetRasterProperties_management(parameters.valueAsText, nodata="1 -10.5") return