Skip to content

Commit 42abbe4

Browse files
committed
Try again
1 parent bb96d10 commit 42abbe4

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

torchgeo/datasets/mdas.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
import numpy as np
1212
import rasterio as rio
1313
import torch
14-
from matplotlib.colormaps import get_cmap
1514
from matplotlib.colors import ListedColormap
1615
from matplotlib.figure import Figure
1716
from torch import Tensor
@@ -356,7 +355,7 @@ def plot(
356355
axs[idx].imshow(img)
357356
case 'osm_landuse_mask':
358357
img = data.numpy().squeeze(0)
359-
cmap = ListedColormap([get_cmap('tab20')(i) for i in range(20)])
358+
cmap = ListedColormap([plt.get_cmap('tab20')(i) for i in range(20)])
360359
im = axs[idx].imshow(img, cmap=cmap)
361360
cbar = plt.colorbar(im, ax=axs[idx], ticks=range(19))
362361
cbar.ax.set_yticklabels(

0 commit comments

Comments
 (0)