Canvas not displaying inline

User 575 | 8/25/2014, 7:14:34 PM

Hello, I'm having trouble having graphs (or anything else) display inline in IPython notebooks. To illustrate the problem, I put together a simple IPython notebook in which I create a dummy SFrame, set the canvas target to 'ipynb', and call 'show'. Nothing happens. When I set the target back to 'browser', a new Canvas tab opens. I've attached screenshots of both the notebook and the canvas. I don't see any WARNING or ERROR messages in the log, so this is a tough one to debug. Perhaps I'm missing some dependencies which are causing a silent failure? I have tried both the Chrome and Firefox browsers.

<img src="" alt="" /> <img src="" alt="" />

I can provide the log file too, if if helps.

Thanks in advance, - Emanuel Strauss


User 6 | 8/26/2014, 7:25:10 AM

Hi Emanuel, Did you run ipython using the command ipython notebook --pylab=inline


User 575 | 8/26/2014, 1:57:17 PM

Hi Danny, Thanks for the suggestion. No, but I have been using the "%matplotlib inline" magic. I just retried with "ipython notebook --pylab=inline" and I have the same issue. Any other ideas?

  • Emanuel

User 9 | 8/26/2014, 4:56:29 PM

Hi Emanuel, thanks for trying out GraphLab Canvas.

I tried, but wasn't able to reproduce this behavior. I assume a kernel restart or exiting and restarting the Python session didn't help?

Can you post a pip freeze so we can see version numbers? Are you running GraphLab in a virtual environment? Let see if we can get you going again.

<img src="" alt="" />

User 4 | 8/26/2014, 6:24:16 PM

Hi @Emanuel‌, are you using an IPython Notebook server over HTTPS (rather than plain HTTP)? If so, this is a bug that will be fixed in the next release. In the meantime you can work around it by using plain HTTP for the IPython Notebook server, or using the interactive browser Canvas target.

User 575 | 8/27/2014, 12:48:48 AM

Hi Zach, I was indeed using HTTPS. I just disabled it, but the problem persists.

Tim, I've attached a copy of the output of pip freeze. I'm not running it in a virtual environment (yes, I know, shame on me).

Thanks for your help guys.

User 4 | 8/27/2014, 1:42:13 AM

Hi @Emanuel‌, looking at the pip log it looks like your IPython version is quite out of date (1.1.0). You could try upgrading IPython to the latest stable release (I believe that is 2.1.0). I don't think GraphLab Canvas with the ipynb target will work on versions of IPython prior to 2.0.

User 575 | 8/27/2014, 2:01:28 AM

Just upgraded to ipython 2.2.0 and psutil to 2.1.1, but I'm still having the same problem. Are there any other packages you can see which might be too antiquated? I've generated a list (attached) of packages which could be upgraded, but I don't want to do any wholesale updating for fear of borking something else.

User 575 | 8/27/2014, 5:07:42 PM

Just a quick update. I've tried to run again inside a virtual environment (the list of packages in the env is attached). I still have the same problem, which I guess points to there being some other cause? Are there known browser or OS conflicts? I'm using OS X 10.9.4, Chrome 37.0.2062.94 and Firefox 22.0.

User 9 | 8/27/2014, 5:21:04 PM

It likely isn't an issue with your versions of OS X, Chrome or Firefox. We will review your sudo installed packages and see if there is something that might be the culprit. Thanks for trying to debug this!

User 4 | 8/28/2014, 6:10:28 PM

Hi @Emanuel‌, I tried in a virtualenv with that set of packages and I am still unable to reproduce the issue using a plain HTTP IPython Notebook server on localhost.

The OS and browser versions look fine to me. Are you using a local or remote server? Possibly any browser plugins that would restrict JavaScript execution?

User 575 | 8/29/2014, 4:28:42 PM

Hi Zach, It's a local server, but there must be something specific to my laptop. I've tried this on another machine with exactly the same packages in the virtualenv and there the canvas displays inline.

User 2293 | 9/23/2015, 1:12:19 AM

I am still facing the same issue .Is there any resolve to this . For now i have set - replaced "graphlab.canvas.settarget('ipynb')" by "graphlab.canvas.settarget('browser')"

which is working fine .

User 4 | 9/23/2015, 5:15:31 AM

Hi @"Anshu Shukla" and @Emanuel, can either of you share your OS/web browser versions? I am curious to see if there may be a pattern of browser and operating system that are exhibiting this behavior. That may help us to track it down and fix it. Thanks!

User 2293 | 9/23/2015, 8:43:50 AM

OS version - OS X Yosemite [Version 10.10.5] Web browser - Google Chrome [Version 45.0.2454.99 (64-bit)]

User 2293 | 9/24/2015, 5:40:05 AM

Is there any option to save Plot image as pdf in place of png file .Image in png is not that clear while zooming if we have dense data point . Thanks .

User 4 | 9/24/2015, 6:27:48 AM

Hi @"Anshu Shukla", there is not currently a way to save as PDF (or any vector format). You can either zoom into the scatter plot using the mouse wheel (I believe this is possible in the "browser" target, at least), or filter your data before calling .show so that the specific area you want to zoom into is shown. The resulting plot can then be saved as .png. Hope that helps!

User 2519 | 10/31/2015, 7:26:58 AM

Hello, same issue here. I am using Windows 10 and Chrome (64 bit).

User 4 | 10/31/2015, 7:37:52 PM

Hi @lelesa, can you check you version of GraphLab Create? 1.6.0 had some bugs related to plot output in IPython Notebook; those bugs have been fixed in 1.6.1, so if you are not on the latest version, please upgrade and give it a try. Thanks!

User 2519 | 11/2/2015, 2:36:43 PM

Hi @Zach, version is 1.6.1. However today I tried the same notebook again and now it works fine... Nothing changed as far as I know.