Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 67b5f92

Browse filesBrowse files
committed
DOC: add line note
1 parent ba76f9c commit 67b5f92
Copy full SHA for 67b5f92

File tree

Expand file treeCollapse file tree

1 file changed

+2
-0
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+2
-0
lines changed

‎lib/matplotlib/image.py

Copy file name to clipboardExpand all lines: lib/matplotlib/image.py
+2Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -368,6 +368,8 @@ def _make_image(self, A, in_bbox, out_bbox, clip_bbox, magnification=1.0,
368368
# values to carry the over/under/bad information
369369
rgba = np.empty((A.shape[0], A.shape[1], 4), dtype=A.dtype)
370370
rgba[..., 0] = A # normalized data
371+
# this is to work around spurious warnings coming
372+
# out of masked arrays.
371373
with np.errstate(invalid='ignore'):
372374
rgba[..., 1] = A < 0 # under data
373375
rgba[..., 2] = A > 1 # over data

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.