Jupyter Notebook中的Google合作实验室出现IOPub错误 [英] IOPub Error on Google Colaboratory in Jupyter Notebook

查看:156
本文介绍了Jupyter Notebook中的Google合作实验室出现IOPub错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我了解以下命令

jupyter notebook --NotebookApp.iopub_data_rate_limit=1.0e10 

请允许我设置数据速率.但是在Colab上,由于笔记本已经打开,因此我无法运行此命令.

would let me set the data rate. But on Colab, I cannot run this command since the notebook is already open.

有什么方法可以避免在Colab上的活动笔记本中出现IOPub错误?

Is there any way I can avoid getting the IOPub error in an active notebook on Colab?

我正在运行keras代码,并且在训练神经网络时遇到此错误.我真的需要查看输出,因为它可以让我知道已经完成了多少个纪元以及准确性.

I am running keras code and I get this error when I train my neural network. I really need to see the output since it lets me know how many epochs have been completed and the accuracy.

推荐答案

IoPub在Colab中发生错误,因为您试图在控制台本身(例如print()语句)上显示很大的输出.

IoPub Error is occurring in Colab because you are trying to display the output on the console itself(Eg. print() statements) which is very large.

解决方法是,将输出写入文件(而不是打印语句),然后从Colab下载文件

So the work around would be, Write the output to the file(instead of print statements) and download the file from the Colab

注意:在使用大型数据集进行训练时,请避免编写简单的打印语句(只是为了在数据集中打印内容)

Note: Please do avoid writing simple print statements(just to print your contents in datasets) when you are training with large dataset

这篇关于Jupyter Notebook中的Google合作实验室出现IOPub错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆