Skip to content

ubuntu 12.04: test_nanargmin failure #7520

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
yarikoptic opened this issue Jun 20, 2014 · 2 comments
Closed

ubuntu 12.04: test_nanargmin failure #7520

yarikoptic opened this issue Jun 20, 2014 · 2 comments
Labels
Testing pandas testing functions or related to the test suite
Milestone

Comments

@yarikoptic
Copy link
Contributor

======================================================================
ERROR: test_nanargmin (pandas.tests.test_nanops.TestnanopsDataFrame)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/tmp/buildd/pandas-0.14.0+git213-g741b2fa/debian/tmp/usr/lib/python2.7/dist-packages/pandas/tests/test_nanops.py", line 346, in test_nanargmin
    allow_str=False, allow_obj=False)
  File "/tmp/buildd/pandas-0.14.0+git213-g741b2fa/debian/tmp/usr/lib/python2.7/dist-packages/pandas/tests/test_nanops.py", line 240, in check_funs
    self.check_fun(testfunc, targfunc, 'arr_date', **kwargs)
  File "/tmp/buildd/pandas-0.14.0+git213-g741b2fa/debian/tmp/usr/lib/python2.7/dist-packages/pandas/tests/test_nanops.py", line 202, in check_fun
    testarval, targarval, targarnanval, **kwargs)
  File "/tmp/buildd/pandas-0.14.0+git213-g741b2fa/debian/tmp/usr/lib/python2.7/dist-packages/pandas/tests/test_nanops.py", line 158, in check_fun_data
    targ = targfunc(targartempval, axis=axis, **kwargs)
  File "/tmp/buildd/pandas-0.14.0+git213-g741b2fa/debian/tmp/usr/lib/python2.7/dist-packages/pandas/tests/test_nanops.py", line 323, in _argminmax_wrap
    res = func(value, axis)
  File "/usr/lib/python2.7/dist-packages/numpy/core/fromnumeric.py", line 754, in argmin
    return argmin(axis)
TypeError: ("ufunc 'subtract' not supported for the input types, and the inputs could not be safely coerced to any supported types according to the casting rule 'safe'", 'axis: 0 of 2', 'skipna: False', 'kwargs: {}', 'testar: arr_date', 'targar: arr_date', 'targarnan: arr_date')

that was while building 0.14.0+git213-g741b2fa

INSTALLED VERSIONS
------------------
commit: None
python: 2.7.3.final.0
python-bits: 64
OS: Linux
OS-release: 3.2.0-4-amd64
machine: x86_64
processor: x86_64
byteorder: little
LC_ALL: C
LANG: C

pandas: 0.14.0.dev
nose: 1.1.2
Cython: 0.15.1
numpy: 1.6.1
scipy: 0.9.0
statsmodels: 0.5.0
IPython: None
sphinx: 1.1.3
patsy: 0.2.1
scikits.timeseries: None
dateutil: 1.5
pytz: 2012c
bottleneck: None
tables: 2.3.1
numexpr: 1.4.2
matplotlib: 1.1.1rc
openpyxl: 1.7.0
xlrd: 0.6.1
xlwt: 0.7.2
xlsxwriter: None
lxml: None
bs4: 4.0.2
html5lib: 0.90
bq: None
apiclient: None
rpy2: None
sqlalchemy: None
pymysql: None
psycopg2: None
@jreback jreback added this to the 0.14.1 milestone Jun 20, 2014
@toddrjen
Copy link
Contributor

@jreback: can you change the title of the bug to be:

"numpy1.6.1: test_nanargmin failure with datetime64 dtype".

This name is more specific about what is going on.

It seems this a problem with older versions of numpy (probably older than 1.7.0). I have made a workaround to test whether numpy can handle datetime64 dtypes the way nanops needs, and if not it skips them. I can't test it myself, though.

jreback added a commit that referenced this issue Jun 21, 2014
should fix issue #7520, test_nanargmin fails with datetime64 objects
@jreback
Copy link
Contributor

jreback commented Jun 21, 2014

closed by #7535

@jreback jreback closed this as completed Jun 21, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Testing pandas testing functions or related to the test suite
Projects
None yet
Development

No branches or pull requests

3 participants