Jupyter中不同的显示结果取决于内核(新用户问题)

我是Jupyter的新手,无法理解如何根据所使用的内核显示某些对象。

这是我的例子。

#sc.install_pypi_package("ipython") <<- to install ipython when using pyspark kernel
from IPython.display import Image
img = Image(url='http://python.org/images/python-logo.gif')
img

当我选择python3内核时,我看到了单元格下面的图像。

当我选择pyspark内核时,看到以下文本: <IPython.core.display.Image object>

我在网上看到人们说要使用的地方:

from IPython.display import display
display(img)

但这具有与上面完全相同的结果。我知道我误会了一些东西,我只是不知道。

请注意,我正在使用ERM笔记本-> JupyterLab在AWS上执行此操作。 Spark在EMR群集上运行。

lidongmei0530 回答:Jupyter中不同的显示结果取决于内核(新用户问题)

暂时没有好的解决方案,如果你有好的解决方案,请发邮件至:iooj@foxmail.com
本文链接:https://www.f2er.com/3135843.html

大家都在问