我以 numpy pickle 格式存储了一个大字典文件。我可以在较旧的 jupyter notebook 应用程序中打开它。但是,在较新版本中,当我运行此行时,我看到 IOPub 错误。

big_dict = np.load('a_large_dictionary.npy').all()

错误:
IOPub data rate exceeded.
The notebook server will temporarily stop sending output
to the client in order to avoid crashing it.
To change this limit, set the config variable
`--NotebookApp.iopub_data_rate_limit`.

似乎在后台发生了一些我无法控制的事情。这很奇怪,因为我没有尝试在 NotebookApp 中加载/查看此文件的内容!

任何想法?如何在不编辑 Notebookapp 配置的情况下加载大文件? (同样,我不想显示我刚刚从文件中读取到变量中的内容。)

最佳答案

使用

jupyter notebook --NotebookApp.iopub_data_rate_limit=2147483647

启动笔记本时解决了我的问题。资料来源:https://github.com/JuliaLang/IJulia.jl/issues/528

关于python - Jupyter 笔记本中的 Numpy 负载 "IOPub data rate exceeded.",我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/44110174/

10-16 13:09