Skip to content

BF: define expected Series of correct for arch (eg i386) int #15044

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
wants to merge 2 commits into from

Conversation

yarikoptic
Copy link
Contributor

@yarikoptic yarikoptic commented Jan 3, 2017

expected = Series([0, 0])
# Explicit dtype since Series produces int64 for ints, while cut
# (due to numpy.searchsorted) would use int32 on i386, so let's assure
# correct default to the architecture int
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we don't test on 32-bit, but if this works that is ok

specify dtype='intp' here

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

though this works fine on windows now (e.g. 64-bit points on 32-bit systems).

and are you on master? this looks like an older line number.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

now with 'intp'

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

actually I think this is a bug, cut on ints should always be 64-bit regardless of arch.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

https://github.com/pandas-dev/pandas/blob/master/pandas/tools/tile.py#L218

needs an .astype('int64', copy=False) as these can get returned to the user in some paths; and they are 32-bit on 32-bit :< (while 64bit on others)

@jreback jreback added Compat pandas objects compatability with Numpy or Python functions Dtype Conversions Unexpected or buggy dtype conversions Testing pandas testing functions or related to the test suite labels Jan 3, 2017
@codecov-io
Copy link

codecov-io commented Jan 3, 2017

Current coverage is 84.75% (diff: 100%)

Merging #15044 into master will decrease coverage by <.01%

@@             master     #15044   diff @@
==========================================
  Files           145        145          
  Lines         51146      51146          
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
- Hits          43351      43350     -1   
- Misses         7795       7796     +1   
  Partials          0          0          

Powered by Codecov. Last update 4de5cdc...11dccee

# date time is just accidental
if prop in ('itemsize', 'nbytes') \
and values.dtype.name == 'object':
continue
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jreback - I have added one more "skip" which was failing on i386 -- described "incode". Does it make sense? ;)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok this is fine

@jreback
Copy link
Contributor

jreback commented Feb 27, 2017

can you rebase / update

@jreback
Copy link
Contributor

jreback commented Apr 3, 2017

this was closed by / superseded #15766

@jreback jreback closed this Apr 3, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Compat pandas objects compatability with Numpy or Python functions Dtype Conversions Unexpected or buggy dtype conversions Testing pandas testing functions or related to the test suite
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants