[IPython-User] ipython notebook - how to display image (not from pylab)

Zoltán Vörös zvoros@gmail....
Thu Feb 23 12:05:59 CST 2012

Hi Antony,

Your question was addressed to Brian, but perhaps, you won't mind, if I 
answer. You could do something like this

from IPython.core.display import HTML
HTML('<img src="files/python-logo.svg" width=100 height=20/>')

I hope this helps.

On 02/23/2012 05:14 PM, Anthony Tanbakuchi wrote:
> Brian,
> Thanks, using Image(filename='myimage.png') works well.
> One additional question that I couldn't find from the documents. Is
> there a way that I can specify the html image width / height
> properties for the displayed image?
> Annoyingly, the package I'm using generates very large PNG files that
> display way to large to view in the notebook without lots of
> scrolling. I'm trying to figure out how to change the output in the
> package, but in the mean time, can I just use HTML tags to scale the
> image? I'd rather not have to down size the images via post processing
> before displaying.
> Thanks,
> Anthony

More information about the IPython-User mailing list