質問編集履歴

1

依頼に基づきtracebackを追記。

2020/10/23 06:45

投稿

iwase13
iwase13

スコア11

test CHANGED
File without changes
test CHANGED
@@ -35,3 +35,13 @@
35
35
  df=pd.read_pickle("./LSWMD.pkl")
36
36
 
37
37
  df.info()
38
+
39
+
40
+
41
+
42
+
43
+ tracebackは下記。
44
+
45
+
46
+
47
+ ModuleNotFoundError Traceback (most recent call last) ~\Anaconda3\lib\site-packages\pandas\io\pickle.py in read_pickle(filepath_or_buffer, compression) 180 warnings.simplefilter("ignore", Warning) --> 181 return pickle.load(f) 182 except excs_to_catch: ModuleNotFoundError: No module named 'pandas.indexes' During handling of the above exception, another exception occurred: UnicodeDecodeError Traceback (most recent call last) <ipython-input-3-94b7b4cc29e5> in <module> ----> 1 df=pd.read_pickle("./LSWMD.pkl") 2 df.info() ~\Anaconda3\lib\site-packages\pandas\io\pickle.py in read_pickle(filepath_or_buffer, compression) 184 # "No module named 'pandas.core.sparse.series'" 185 # "Can't get attribute '__nat_unpickle' on <module 'pandas._libs.tslib" --> 186 return pc.load(f, encoding=None) 187 except UnicodeDecodeError: 188 # e.g. can occur for files written in py27; see GH#28645 ~\Anaconda3\lib\site-packages\pandas\compat\pickle_compat.py in load(fh, encoding, is_verbose) 239 up.is_verbose = is_verbose 240 --> 241 return up.load() 242 except (ValueError, TypeError): 243 raise ~\Anaconda3\lib\pickle.py in load(self) 1086 raise EOFError 1087 assert isinstance(key, bytes_types) -> 1088 dispatch[key[0]](self) 1089 except _Stop as stopinst: 1090 return stopinst.value ~\Anaconda3\lib\pickle.py in load_binstring(self) 1220 raise UnpicklingError("BINSTRING pickle has negative byte count") 1221 data = self.read(len) -> 1222 self.append(self._decode_string(data)) 1223 dispatch[BINSTRING[0]] = load_binstring 1224 ~\Anaconda3\lib\pickle.py in _decode_string(self, value) 1202 return value 1203 else: -> 1204 return value.decode(self.encoding, self.errors) 1205 1206 def load_string(self): UnicodeDecodeError: 'ascii' codec can't decode byte 0x9a in position 6: ordinal not in range(128)