其实就是内存不够了,我加载的数据是800多万,数据量太大出错 下面试错误提示
C:\Users\souwayai\Miniconda3\python.exe D:/www/use_pandas/pd7.py
Traceback (most recent call last): File "D:/www/use_pandas/pd7.py", line 14, in <module> df = pd.DataFrame(list(chapters.find())) File "C:\Users\souwayai\Miniconda3\lib\site-packages\pandas\core\frame.py", line 369, in __init__ arrays, columns = _to_arrays(data, columns, dtype=dtype) File "C:\Users\souwayai\Miniconda3\lib\site-packages\pandas\core\frame.py", line 6254, in _to_arrays coerce_float=coerce_float, dtype=dtype) File "C:\Users\souwayai\Miniconda3\lib\site-packages\pandas\core\frame.py", line 6375, in _list_of_dict_to_arrays content = list(lib.dicts_to_array(data, list(columns)).T) File "pandas\_libs\lib.pyx", line 441, in pandas._libs.lib.dicts_to_arrayMemoryError