-
-
Notifications
You must be signed in to change notification settings - Fork 7.9k
Initial, very rough, comm-based backend #2524
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Any comments on setting this up for testing etc. @jasongrout? |
It doesn't work just yet (I was able to get an image to display, but not the interactive tools to load). You'll need IPython with ipython/ipython#4195 applied. And actually, there were some changes in the IPython pull request that may necessitate changes in this pull request. Also, I was testing against the Sage Cell Server---the IPython notebook will be very similar, but I didn't have time to test against it yet. Probably the first thing to do would be to set up IPython with that pull request mentioned above and get familiar with the Comm API (there are some simple examples on the ticket). Then updating this to use the refactored communication framework that Michael pointed out on the mailing list. |
I updated this and it works now with IPython master. Execute this in an IPython notebook cell
and then you can do something like:
|
Here are a few points to still be cleaned up:
|
This is looking really good. Obviously there are a couple of trivial UI enhancements to add (the button icons, resize, download button doesn't work etc.) and it 'feels' like there is a latency issue which I didn't have with the WebAgg backend (perhaps that is the cost of using base 64 vs binary) but generally this is and absolutely huge step towards the feature that we all want to see in matplotlib/IPython. I think the next steps are to look at some of the issues above, and to thrash out whether we need to consider compressing the data payload (and decompressing in JS on the other side). It'd also be nice if server side rendering errors (which I got because I didn't build mpl properly after updating) were tracebacked on the client, and another nice to have would be to have some sort of debug panel, which can tell us the FPS etc. Awesome stuff. What are your plans from here @jasongrout? |
… the webagg backend This is so that the javascript generation works before any plots have been initialized.
On 11/15/13 4:01 AM, Phil Elson wrote:
The image data is already compressed (png). I agree that it still feels
+1
Get it working in the Sage cell server. ... Done! http://sagecell.sagemath.org/?q=ilpajg (for a sage plotting example) http://sagecell.sagemath.org/?q=spadja (for one of the examples from the |
@jasongrout - is it worth merging the machinery that you've had to add even if we don't actually have the CommFigure class? |
I think probably not. Let's wait to get a commfigure class. I've been working a ton with the IPython folks on their widget infrastructure, and it's helping me understand how best to approach things. |
Closing this as I this was the base of nbagg which has sense been merged. |
DO NOT MERGE. This is a rough draft. I'm creating a pull request just to make commenting on it easier.