Getting Abstract Method Error using Spatially Enabled Dataframes

10-13-2022 11:40 AM
New Contributor III

I've been seeing some inconsistencies using the SEDF with some of the more basic pandas functions where I get the following error:

Exception has occurred: AbstractMethodError
This method must be defined in the concrete class GeoArray


An example with the latest conda environment:

  • arcgis 2.0.1
  • pandas 1.3.5
  • arcpy 3.0
SDF = FeatureSet.from_geojson(Data).sdf
# The following line throws the error
SDF.replace({True: 1, False: 0}, inplace=True)
# AbstractMethod Error...

 Interesting enough when I did a merge with a standard dataframe it works...

SDF = FeatureSet.from_geojson(Data).sdf
# Merge with some Tabular Data
SDF = pd.merge(SDF, TableDataframe, how="left", on=["id"])
SDF.replace({True: 1, False: 0}, inplace=True)
# All Good!

I've seen this error a few times with some of the more "generic" pandas functions but I am just wondering if anyone has any insights or suggestions when you are using the GeoAccessor class to run some analysis? 


0 Replies