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

Skip to content

Commit e7664d6

Browse files
committed
Revert "WIP: add explicit test of conversion to float"
This reverts commit aaefde4.
1 parent a7cacc7 commit e7664d6

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

lib/matplotlib/axes/_base.py

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -211,11 +211,6 @@ def set_patchprops(self, fill_poly, **kwargs):
211211
fill_poly.set(**kwargs)
212212

213213
def _xy_from_xy(self, x, y):
214-
def _check_numeric(inp):
215-
if inp.dtype.kind not in set('biufc'):
216-
raise TypeError('input must be numeric after unit conversion')
217-
return inp
218-
219214
if self.axes.xaxis is not None and self.axes.yaxis is not None:
220215
bx = self.axes.xaxis.update_units(x)
221216
by = self.axes.yaxis.update_units(y)
@@ -226,9 +221,8 @@ def _check_numeric(inp):
226221

227222
# like asanyarray, but converts scalar to array, and doesn't change
228223
# existing compatible sequences
229-
x = _check_numeric(_check_1d(x))
230-
y = _check_numeric(_check_1d(y))
231-
224+
x = _check_1d(x)
225+
y = _check_1d(y)
232226
if x.shape[0] != y.shape[0]:
233227
raise ValueError("x and y must have same first dimension, but "
234228
"have shapes {} and {}".format(x.shape, y.shape))

0 commit comments

Comments
 (0)