GDAL doesn't include file gcs.csv anymore
I'm using [geemap](https://github.com/giswqs/geemap) to display a raster on a created map.
This lib use `xarray_leaflet` to display the raster and this lib will end up using `rasterio` to manipulate the .tif file.
When I launch my display :
m = geemap.Map()
m.add_raster(clip_map, colormap='terrain', layer_name='gfc')
I get the following error :
> CRSError: Unable to open EPSG support file gcs.csv. Try setting the GDAL_DATA environment variable to point to the directory containing EPSG csv files.
This error is everywhere on SO so I tried to verify if my GDAL_DATA env variable was coorectly set :
gdal_data = os.environ['GDAL_DATA']
print('is dir: ' + str(os.path.isdir(gdal_data)))
gcs_csv = os.path.join(gdal_data, 'gcs.csv')
print('is file: ' + str(os.path.isfile(gcs_csv)))
st = os.stat(gcs_csv)
print('is readable: ' + str(bool(st.st_mode & stat.S_IRGRP)))
# is dir: True
#is file: False
#FileNotFoundError: [Errno 2] No such file or directory: '/usr/share/gdal/gcs.csv'
going to the glad distrib inb the `NEWS` file, I read that they removed lots of file in 3.0 including `gcs.csv`. So it's no longer included in my folder.
Is there a workaround ?
On Mon, Sep 7, 2020 at 8:18 AM <pierrick.rambaud49@...> wrote:
How did you install rasterio? If you got it with `pip install rasterio` you will have installed a wheel file that includes GDAL 2.4.4 and data files and which will be incompatible with the GDAL 3.0.4 installed on your system. If that is the case, you should unset GDAL_DATA. Rasterio in the wheel will detect its own data files and does not need GDAL_DATA to be set.
Thank you for your quick answer,