We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
concat
>>> pd.concat(scores_per_document) Traceback (most recent call last): File "<console>", line 1, in <module> File "/Users/berquist/.anaconda/envs/event-extraction-3.6/lib/python3.6/site-packages/pandas/core/reshape/concat.py", line 255, in concat sort=sort, File "/Users/berquist/.anaconda/envs/event-extraction-3.6/lib/python3.6/site-packages/pandas/core/reshape/concat.py", line 332, in __init__ raise TypeError(msg) TypeError: cannot concatenate object of type '<class 'str'>'; only Series and DataFrame objs are valid >>> type(scores_per_document) immutablecollections._immutabledict.RegularDictBackedImmutableDict >>> type(dict(scores_per_document)) <class 'dict'> >>> pd.concat(dict(scores_per_document)) tp fp fn precision recall f1 AFP_ENG_20030323.0020 Personnel.Start-Position 0.0 0.0 0.0 0.0 0.0 0.0 Personnel.End-Position 0.0 0.0 0.0 0.0 0.0 0.0 Personnel.Nominate 0.0 0.0 0.0 0.0 0.0 0.0 Personnel.Elect 0.0 0.0 0.0 0.0 0.0 0.0 Movement.Transport 3.0 0.0 0.0 100.0 100.0 100.0 ... ... ... ... ... ... ... AGGRESSIVEVOICEDAILY_20050124.1354 Justice.Execute 0.0 0.0 0.0 0.0 0.0 0.0 Justice.Extradite 0.0 0.0 0.0 0.0 0.0 0.0 Justice.Appeal 0.0 0.0 0.0 0.0 0.0 0.0 Justice.Pardon 0.0 0.0 0.0 0.0 0.0 0.0 __ALL_EVENTS_COMBINED__ 2.0 0.0 0.0 100.0 100.0 100.0 [660 rows x 6 columns]
The text was updated successfully, but these errors were encountered:
@berquist : I don't think this is something we can do anything about. The problem is here: https://github.com/pandas-dev/pandas/blob/83812e1ba93b7857b8222e6651c823a88223472f/pandas/core/reshape/concat.py#L293 . You could file an issue+PR with pandas requesting it become isinstance(objs, Mapping).
pandas
isinstance(objs, Mapping)
Sorry, something went wrong.
There is a Pandas issue corresponding to this: pandas-dev/pandas#6792
No branches or pull requests
The text was updated successfully, but these errors were encountered: