Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e8d9ea3

Browse files
committed
Remove workaround for numpy<1.16, and update version check.
We now require numpy 1.16 (per setup.py and NEP29).
1 parent 92b4bc3 commit e8d9ea3

File tree

2 files changed

+5
-8
lines changed

2 files changed

+5
-8
lines changed

lib/matplotlib/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ def _check_versions():
145145
("cycler", "0.10"),
146146
("dateutil", "2.1"),
147147
("kiwisolver", "1.0.1"),
148-
("numpy", "1.15"),
148+
("numpy", "1.16"),
149149
("pyparsing", "2.0.1"),
150150
]:
151151
module = importlib.import_module(modname)

lib/matplotlib/transforms.py

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -677,13 +677,10 @@ def union(bboxes):
677677
"""Return a `Bbox` that contains all of the given *bboxes*."""
678678
if not len(bboxes):
679679
raise ValueError("'bboxes' cannot be empty")
680-
# needed for 1.14.4 < numpy_version < 1.16
681-
# can remove once we are at numpy >= 1.16
682-
with np.errstate(invalid='ignore'):
683-
x0 = np.min([bbox.xmin for bbox in bboxes])
684-
x1 = np.max([bbox.xmax for bbox in bboxes])
685-
y0 = np.min([bbox.ymin for bbox in bboxes])
686-
y1 = np.max([bbox.ymax for bbox in bboxes])
680+
x0 = np.min([bbox.xmin for bbox in bboxes])
681+
x1 = np.max([bbox.xmax for bbox in bboxes])
682+
y0 = np.min([bbox.ymin for bbox in bboxes])
683+
y1 = np.max([bbox.ymax for bbox in bboxes])
687684
return Bbox([[x0, y0], [x1, y1]])
688685

689686
@staticmethod

0 commit comments

Comments
 (0)