【发布时间】:2016-08-14 10:43:46
【问题描述】:
如何在 IPython 笔记本输出单元格内显示带有滚动条的大图像?下面的示例将图像缩小以适合单元格,width 没有任何效果。
from IPython.core.display import Image, display
display(Image('https://i.ytimg.com/vi/j22DmsZEv30/maxresdefault.jpg', width=1900))
【问题讨论】:
如何在 IPython 笔记本输出单元格内显示带有滚动条的大图像?下面的示例将图像缩小以适合单元格,width 没有任何效果。
from IPython.core.display import Image, display
display(Image('https://i.ytimg.com/vi/j22DmsZEv30/maxresdefault.jpg', width=1900))
【问题讨论】:
使用unconfined=True 禁用图像的最大宽度限制:
from IPython.core.display import Image, display
display(Image('https://i.ytimg.com/vi/j22DmsZEv30/maxresdefault.jpg', width=1900, unconfined=True))
【讨论】: