From Gentle Guinea Pig, 5 Years ago, written in Plain Text.
Embed
  1. python3 test.py
  2. 3.314018249511719e-05 Loading substs from  /home/y.kozhevnikov/Desktop/ezhik/dta_1-limitNone-maxexperwordNone/modelcheckpoints_alldata-small-xlmfinetuned_checkpoint36.pt/<mask><mask>-T-2ltr2f_topk150_fixspacesTrue.npz.input
  3. Traceback (most recent call last):
  4.   File "/home/y.kozhevnikov/anaconda3/lib/python3.7/site-packages/pandas/core/indexes/base.py", line 2646, in get_loc
  5.     return self._engine.get_loc(key)
  6.   File "pandas/_libs/index.pyx", line 111, in pandas._libs.index.IndexEngine.get_loc
  7.   File "pandas/_libs/index.pyx", line 138, in pandas._libs.index.IndexEngine.get_loc
  8.   File "pandas/_libs/hashtable_class_helper.pxi", line 1618, in pandas._libs.hashtable.PyObjectHashTable.get_item
  9.   File "pandas/_libs/hashtable_class_helper.pxi", line 1626, in pandas._libs.hashtable.PyObjectHashTable.get_item
  10. KeyError: '0'
  11.  
  12. During handling of the above exception, another exception occurred:
  13.  
  14. Traceback (most recent call last):
  15.   File "test.py", line 3, in <module>
  16.     s = load_substs('/home/y.kozhevnikov/Desktop/ezhik/dta_1-limitNone-maxexperwordNone/modelcheckpoints_alldata-small-xlmfinetuned_checkpoint36.pt/<mask><mask>-T-2ltr2f_topk150_fixspacesTrue.npz.input')
  17.   File "/home/y.kozhevnikov/Desktop/ezhik/substs_stat.py", line 16, in load_substs
  18.     substs_probs = pd.read_csv(p, index_col=0, nrows=limit)['0']
  19.   File "/home/y.kozhevnikov/anaconda3/lib/python3.7/site-packages/pandas/core/frame.py", line 2800, in __getitem__
  20.     indexer = self.columns.get_loc(key)
  21.   File "/home/y.kozhevnikov/anaconda3/lib/python3.7/site-packages/pandas/core/indexes/base.py", line 2648, in get_loc
  22.     return self._engine.get_loc(self._maybe_cast_indexer(key))
  23.   File "pandas/_libs/index.pyx", line 111, in pandas._libs.index.IndexEngine.get_loc
  24.   File "pandas/_libs/index.pyx", line 138, in pandas._libs.index.IndexEngine.get_loc
  25.   File "pandas/_libs/hashtable_class_helper.pxi", line 1618, in pandas._libs.hashtable.PyObjectHashTable.get_item
  26.   File "pandas/_libs/hashtable_class_helper.pxi", line 1626, in pandas._libs.hashtable.PyObjectHashTable.get_item
  27. KeyError: '0'