laptop and a wrench

Bug

A model with the Raster Calculator tool referencing a variable fails with Ukrainian region and language settings.

Last Published: August 25, 2014 ArcGIS for Desktop
Bug ID Number NIM083013
SubmittedJuly 23, 2012
Last ModifiedJune 5, 2024
Applies toArcGIS for Desktop
Version found10.0
Operating SystemWindows OS
Operating System Version7
Version Fixed10.1
StatusFixed

Additional Information

Fixed in 10.1

Workaround

The following Python script worked as it uses the locale module:# Import locale moduleimport localelocale.setlocale(locale.LC_NUMERIC, 'Ukrainian_Ukraine')import arcpyfrom <a href="http://arcpy.sa" target="_blank">arcpy.sa</a> import *# Check out any necessary licensesarcpy.CheckOutExtension("spatial")#Variables:hrsm2t = "<a href="file:////csc-hales7d//Incidents//1056521_RC//UA_Model//hrsm2t.tif" target="_blank">\\\\csc-hales7d\\Incidents\\1056521_RC\\UA_Model\\hrsm2t.tif</a>"output = "<a href="file:////csc-hales7d//Incidents//1056521_RC//PythonOutput.tif" target="_blank">\\\\csc-hales7d\\Incidents\\1056521_RC\\PythonOutput.tif</a>"#Calculate Statisticsarcpy.CalculateStatistics_management(hrsm2t, "1", "1", "")#Get Raster PropertiescalcMean = arcpy.GetRasterProperties_management(hrsm2t, "MEAN")meanValue = calcMean.getOutput(0)strValue = str(meanValue)locValue = locale.atof(strValue)#GreaterThantempOutput = GreaterThan(hrsm2t, locValue)tempOutput.save(output)print "done"

Steps to Reproduce

Bug ID: NIM083013

Software:

  • ArcGIS for Desktop

Get notified when the status of a bug changes

Download the Esri Support App

Discover more on this topic

Get help from ArcGIS experts

Contact technical support

Download the Esri Support App

Go to download options