温馨提示×

温馨提示×

您好,登录后才能下订单哦!

密码登录×
登录注册×
其他方式登录
点击 登录注册 即表示同意《亿速云用户服务条款》

jupyter notebook打开后页面空白怎么办

发布时间:2020-07-24 10:55:43 来源:亿速云 阅读:3143 作者:清晨 栏目:编程语言

小编给大家分享一下jupyter notebook打开后页面空白怎么办,相信大部分人都还不怎么了解,因此分享这边文章给大家学习,希望大家阅读完这篇文章后大所收获,下面让我们一起去学习方法吧!

jupyter notebook打开后页面空白,将域名中的localhost改为127.0.0.1后显示正常。

解决方法:

1、在 C:\Users\用户名.jupyter\ 路径下找到 jupyter_notebook_config.py

若路径下无此文件,则在命令行通过以下命令生成:

jupyter notebook --generate-config

2、右键点击此文件通过IDLE/记事本打开,然后查找,browser,找到如下代码:

## Specify what command to use to invoke a web browser when opening the notebook.
#  If not specified, the default browser will be determined by the `webbrowser`
#  standard library module, which allows setting of the BROWSER environment
#  variable to override it.
#c.NotebookApp.browser = u''

在此代码块后添加如下代码,将chrome设置为jupyter notebook默认浏览器:

import webbrowser
webbrowser.register('chrome', None, webbrowser.GenericBrowser(u'C:\Program Files (x86)\Google\Chrome\Application\chrome.exe'))
c.NotebookApp.browser = 'chrome'

3、网页显示仍为空白,将文件中的

#c.NotebookApp.local_hostnames = [‘localhost’]

 取消注释。

以上是jupyter notebook打开后页面空白怎么办的所有内容,感谢各位的阅读!相信大家都有了一定的了解,希望分享的内容对大家有所帮助,如果还想学习更多知识,欢迎关注亿速云行业资讯频道!

向AI问一下细节

免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。

AI