Skip to content

Commit d28113e

Browse files
author
Thomas Vogt
committed
util.coords: fix add_shapes for matplotlib>=3.3
1 parent 4d0d14e commit d28113e

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

climada/entity/exposures/gpw_import.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
import logging
88
import subprocess
99

10-
import gdal
10+
from osgeo import gdal
1111
import pandas as pd
1212
from scipy import ndimage as nd
1313
import numpy as np

climada/entity/exposures/litpop.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
import shapefile
3131
from matplotlib import pyplot as plt
3232
from iso3166 import countries as iso_cntry
33-
import gdal
33+
from osgeo import gdal
3434
from cartopy.io import shapereader
3535

3636
from climada import CONFIG
@@ -1892,7 +1892,7 @@ def to_sparse_dataframe(ndarr):
18921892
----------
18931893
ndarr : numpy.ndarray
18941894
2 dimensional
1895-
1895+
18961896
Returns
18971897
-------
18981898
sparse dataframe : pandas.DataFrame

climada/util/plot.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -343,7 +343,7 @@ def add_shapes(axis):
343343
name='admin_0_countries')
344344
shp = shapereader.Reader(shp_file)
345345
for geometry in shp.geometries():
346-
axis.add_geometries([geometry], crs=ccrs.PlateCarree(), facecolor='',
346+
axis.add_geometries([geometry], crs=ccrs.PlateCarree(), facecolor='none',
347347
edgecolor='black')
348348

349349
def add_populated_places(axis, extent, proj=ccrs.PlateCarree()):

0 commit comments

Comments
 (0)