Skip to content

Commit 2e546f0

Browse files
committed
Merge branch 'main' into pre-commit-ci-update-config
2 parents 6b01266 + f06c511 commit 2e546f0

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ and this project adheres to [Semantic Versioning][].
2626
- Changes to support for dask-expr (#283)
2727
- Added error handling for non-existent elements (#305)
2828
- Specifying vmin and vmax properly clips image data (#307)
29+
- import bug `get_cmap()` (8fd969c)
2930

3031
## [0.2.3] - 2024-07-03
3132

src/spatialdata_plot/pl/utils.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
from typing import Any, Literal, Union
1111

1212
import matplotlib
13-
import matplotlib.cm as cm
1413
import matplotlib.patches as mpatches
1514
import matplotlib.patches as mplp
1615
import matplotlib.path as mpath
@@ -1994,7 +1993,7 @@ def set_zero_in_cmap_to_transparent(cmap: Colormap | str, steps: int | None = No
19941993
ListedColormap: A new colormap instance with modified alpha values.
19951994
"""
19961995
if isinstance(cmap, str):
1997-
cmap = cm.get_cmap(cmap)
1996+
cmap = plt.get_cmap(cmap)
19981997

19991998
colors = cmap(np.arange(steps or cmap.N))
20001999
colors[0, :] = [1.0, 1.0, 1.0, 0.0]

0 commit comments

Comments
 (0)