-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
msgpack unpack dataframe error: InvalidIndexError #9618
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
Comments
show |
pd.show_versions()INSTALLED VERSIONS commit: None pandas: 0.15.0 df.indexInt64Index([22, 29, 15, 11, 16, 43, 23, 30, 38, 24, 5, 9, 25, 7, 47, 4, 12, 26, 10, 17, 31, 39, 46, 6, 27, 18, 44, 41, 13, 8, 19, 20, 32, 52, 48, 0, 2, 3, 34, 35, 33, 49, 51, 1, 50], dtype='int64') df.index.is_uniqueresult_df.index.is_unique == True Sample dataframe,d-37_id,d-37,m5010,m5010 |
This works in 0.15.2 You can try to upgrade (I do recall this bug getting fixed, but can't find ATM).
|
This does not seem to be fixed and happens when the column index is not unique:
I thought I had reported this error, will try to find it. |
This happen with some Pandas dataframes with indexes.
Full Traceback (most recent call last):
File "/srv/python/venv/local/lib/python2.7/site-packages/pandas/io/packers.py", line 163, in read_msgpack
return read(fh)
File "/srv/python/venv/local/lib/python2.7/site-packages/pandas/io/packers.py", line 141, in read
l = list(unpack(fh))
File "pandas/msgpack.pyx", line 662, in pandas.msgpack.Unpacker.next (pandas/msgpack.cpp:8303)
File "pandas/msgpack.pyx", line 591, in pandas.msgpack.Unpacker._unpack (pandas/msgpack.cpp:7328)
File "/srv/python/venv/local/lib/python2.7/site-packages/pandas/io/packers.py", line 490, in decode
blocks = [create_block(b) for b in obj['blocks']]
File "/srv/python/venv/local/lib/python2.7/site-packages/pandas/io/packers.py", line 488, in create_block
placement=axes[0].get_indexer(b['items']))
File "/srv/python/venv/local/lib/python2.7/site-packages/pandas/core/index.py", line 1488, in get_indexer
raise InvalidIndexError('Reindexing only valid with uniquely'
InvalidIndexError: Reindexing only valid with uniquely valued Index objects
The text was updated successfully, but these errors were encountered: