Jupyter Notebook中没有显示名称并且没有$ DISPLAY环境变量 [英] no display name and no $DISPLAY environment variable in Jupyter Notebook
本文介绍了Jupyter Notebook中没有显示名称并且没有$ DISPLAY环境变量的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想为孩子们教Python.我希望他们使用Jupyter Notebook.为避免安装麻烦,我希望他们使用免费的在线Jupyter Notebook.我认为Google的合作伙伴(链接)和jupyter.org(
I want to teach Python for kids. I want them to use Jupyter Notebook. To avoid the hassle of installation, I want them to use a free online Jupyter Notebook. I thought google's colab (link) and jupyter.org (link) could be best solutions. However, I tried them both and got the error message below:
from turtle import *
colors = ['red', 'purple', 'blue', 'green', 'yellow', 'orange']
for x in range(360):
pencolor(colors[x % 6])
width(x / 100 + 1)
forward(x)
left(59)
TclError:没有显示名称,也没有$ DISPLAY环境变量
TclError: no display name and no $DISPLAY environment variable
推荐答案
您是否看过此问题:
如果您之前运行过,则可能会解决您的问题:
Your problem might be solved if you run before:
%matplotlib inline
这篇关于Jupyter Notebook中没有显示名称并且没有$ DISPLAY环境变量的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文