8000 FIX: Include 0 when checking lognorm vmin · matplotlib/matplotlib@6b3738e · GitHub
[go: up one dir, main page]

Skip to content

Commit 6b3738e

Browse files
committed
FIX: Include 0 when checking lognorm vmin
Change vmin check to less than or equal to 0 rather than strictly less than.
1 parent 2a3037f commit 6b3738e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/matplotlib/image.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -533,7 +533,7 @@ def _make_image(self, A, in_bbox, out_bbox, clip_bbox, magnification=1.0,
533533
# that may have moved input values in/out of range
534534
s_vmin, s_vmax = vrange
535535
if isinstance(self.norm, mcolors.LogNorm):
536-
if s_vmin < 0:
536+
if s_vmin <= 0:
537537
s_vmin = max(s_vmin, np.finfo(scaled_dtype).eps)
538538
with cbook._setattr_cm(self.norm,
539539
vmin=s_vmin,

0 commit comments

Comments
 (0)
0