Select to view content in your preferred language

Zonal Statistics as Table Tool - Error 999999 - Expected to find comma, colon or start of array

1002
1
04-19-2023 09:05 AM
Cat1
by
New Contributor

Hi,

I'm running the BRAT tool from Riverscapes (https://brat.riverscapes.net/) and keep getting an error message when running part of their table building script.

There's an error message of "Expected to find comma, colon, or start of array" when running the Zonal Statistics as Table tool. I've attached the script that I'm using, and the Traceback.

Does anyone have any insight as to how to fix this error?

Thanks!

 

Adding "iGeo" attributes to network...
While calculating iGeo_ElMax, the tool ran into an error. The following ReachIDs did not recieve correct values:
32, 33, 38, 69, 70, 84, 85, 86, 105, 107, 110, 111, 112, 115, 116, 127, 136, 143, 170, 171, 173, 193, 196, 210, 213, 214, 215, 228, 233, 246, 256, 257, 259, and 263
While calculating iGeo_ElMin, the tool ran into an error. The following ReachIDs did not recieve correct values:
32, 38, 69, 82, 84, 109, 110, 111, 112, 115, 116, 142, 143, 170, 171, 172, 173, 188, 192, 193, 212, 213, 214, 215, 227, 228, 233, 241, 245, 256, 257, and 259
Calculating drainage area...
While calculating iGeo_DA, the tool ran into an error. The following ReachIDs did not recieve correct values:
32, 33, 38, 69, 84, 107, 109, 110, 111, 112, 115, 116, 143, 145, 146, 172, 173, 213, 214, 215, 228, 233, 245, 256, 257, and 259
Adding "iVeg" attributes to network...
Traceback (most recent call last):
  File "<string>", line 372, in execute
  File "C:\Users\cat30\Documents\ArcGIS\Projects\BRAT_2023\PyCharm\BRAT_table.py", line 148, in main
    iveg_attributes(coded_veg, coded_hist, buf_100m, buf_30m, seg_network_copy, scratch, is_verbose)
  File "C:\Users\cat30\Documents\ArcGIS\Projects\BRAT_2023\PyCharm\BRAT_table.py", line 616, in iveg_attributes
    zonalStatsWithinBuffer(buf_100m, veg_lookup, 'MEAN', 'MEAN', out_network, "iVeg100EX", scratch)
  File "C:\Users\cat30\Documents\ArcGIS\Projects\BRAT_2023\PyCharm\BRAT_table.py", line 433, in zonalStatsWithinBuffer
    stat = arcpy.sa.ZonalStatisticsAsTable(tmp_buff_lyr, 'ReachID', ras, os.path.join(scratch, 'stat'), 'DATA', stat_type)
  File "C:\Program Files\ArcGIS\Pro\Resources\ArcPy\arcpy\sa\Functions.py", line 10975, in ZonalStatisticsAsTable
    return Wrapper(
  File "C:\Program Files\ArcGIS\Pro\Resources\ArcPy\arcpy\sa\Utils.py", line 55, in swapper
    result = wrapper(*args, **kwargs)
  File "C:\Program Files\ArcGIS\Pro\Resources\ArcPy\arcpy\sa\Functions.py", line 10962, in Wrapper
    result = arcpy.gp.ZonalStatisticsAsTable_sa(
  File "C:\Program Files\ArcGIS\Pro\Resources\ArcPy\arcpy\geoprocessing\_base.py", line 512, in <lambda>
    return lambda *args: val(*gp_fixargs(args, True))
arcgisscripting.ExecuteError: ERROR 999999: Something unexpected caused the tool to fail. Contact Esri Technical Support (http://esriurl.com/support) to Report a Bug, and refer to the error help for potential solutions or workarounds.
Expected to find comma, colon or start of array; state : startOfObject; buffer : {45D22CA8-D3F2-4250-85E2-7589E8DE8494}429222016.cr
Failed to execute (ZonalStatisticsAsTable). 

 

0 Kudos
1 Reply
kreed
by
Emerging Contributor

I kept getting the error message when using this tool and writing output to a dBASE table. The only thing that worked for me was to write the tables to a geodatabase, which I then exported to CSV.

0 Kudos