A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/pandas-dev/pandas/issues/7357 below:

nanops._has_infs doesn't work with many dtypes · Issue #7357 · pandas-dev/pandas · GitHub

nanops._has_infs, which is used in determining whether to employ bottleneck optimizations, fails on dtypes which should otherwise be supported, including 'f2', complex, and multidimensional 'f4' and 'f8'.

>>> from pandas.core import nanops
>>> import numpy as np
>>> 
>>> val0 = np.ones(10)*np.inf
>>> val1 = val0.astype('f2')
>>> val2 = val0+val0*1j
>>> val3 = np.tile(val0, (1, 10))
>>> 
>>> nanops._has_infs(val0)
True
>>> nanops._has_infs(val1)
False
>>> nanops._has_infs(val2)
False
>>> nanops._has_infs(val3)
ValueError: Buffer has wrong number of dimensions (expected 1, got 2)

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4