问题描述
我想在Jupyter笔记本中查看图像。这是一个9.9MB的.png文件。
I want to view an image in Jupyter notebook. It's a 9.9MB .png file.
from IPython.display import Image
Image(filename='path_to_image/image.png')
我收到以下错误:
IOPub data rate exceeded.
The notebook server will temporarily stop sending output
to the client in order to avoid crashing it.
有点令人惊讶,):
This works for me in Windows 7 (taken from here):
-
创建一个jupyter_notebook_config.py文件,包含所有默认值已注释掉,您可以使用以下命令行:
To create a jupyter_notebook_config.py file, with all the defaults commented out, you can use the following command line:
$ jupyter notebook --generate-config
打开文件并搜索 c.NotebookApp.iopub_data_rate_limit
注释掉 c.NotebookApp.iopub_data_rate_limit = 1000000
这一行并将其更改为更高的默认费率。 l使用 c.NotebookApp.iopub_data_rate_limit = 10000000
Comment out the line c.NotebookApp.iopub_data_rate_limit = 1000000
and change it to a higher default rate. l used c.NotebookApp.iopub_data_rate_limit = 10000000
这个无法容忍的默认配置在很多地方出现。请参阅git问题:
This unforgiving default config is popping up in a lot of places. See git issues:
看起来可能会解决 5.1发布
Jupyter笔记本是现在在。这个问题应该是。使用conda或pip升级。
Jupyter notebook is now on release 5.2.2
. This problem should have been resolved. Upgrade using conda or pip.
这篇关于Jupyter笔记本中超出IOPub数据速率(查看图像时)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!