9def69a805132ff7549744b5b30a2fa7531fa405,tmtoolkit/preprocess/_tmpreproc.py,TMPreproc,load_tokens_dataframe,#TMPreproc#Any#,263
Before Change
tokens = {}
for dl, doc_df in tokendf.groupby(level=0):
doc_df = doc_df.reset_index()
doc_df = doc_df.loc[:, doc_df.columns.difference(ind_names)]
tokens[dl] = doc_df
return self.load_tokens(tokens)
After Change
// convert big dataframe to dict of document token dicts to be used in load_tokens
tokens = {}
for dl in dt.unique(tokendf[:, dt .f.doc]).to_list()[0]:
doc_df = tokendf[dt.f.doc == dl, :]
colnames = list(doc_df.names)
colnames.pop(colnames.index("doc"))
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 3
Instances Project Name: WZBSocialScienceCenter/tmtoolkit
Commit Name: 9def69a805132ff7549744b5b30a2fa7531fa405
Time: 2019-06-12
Author: markus.konrad@wzb.eu
File Name: tmtoolkit/preprocess/_tmpreproc.py
Class Name: TMPreproc
Method Name: load_tokens_dataframe
Project Name: kengz/SLM-Lab
Commit Name: 9da4e51da0044cfbdcf3a667187d86f0c35ece8e
Time: 2019-05-25
Author: kengzwl@gmail.com
File Name: slm_lab/experiment/analysis.py
Class Name:
Method Name: analyze_experiment
Project Name: glm-tools/pyglmnet
Commit Name: 8fd4c83eab1067625f6abd28359fe7802267e513
Time: 2020-03-03
Author: my.titipat@gmail.com
File Name: examples/plot_group_lasso.py
Class Name:
Method Name: