On 06/06/2011 02:06 PM, Brian Refsdal wrote: > Hello, > > I've been following the updates to mplh5canvas for some time now, since > its debut at SciPy 2010. I am interested in working to extend > mplh5canvas into a cloud-based web service as a thesis project. I have > not found anybody whose is currently working on this path. Are there > any active projects working on this? Specifically, I am referring to > Michael Droettboom's comments of a possible web application and Simon > Ratcliffe's comments about using Flex. If anyone is interested I would > be happy to talk in person at SciPy next month. I did a little exploratory work with this at the Sage Days sprint in Seattle back in March.
My (humble) assessment is that HTML 5 Canvas doesn't make much sense for any of the use cases I could dream up, and that in fact SVG is a more appropriate choice for interactive graphics. The browser support for each technology is fairly equivalent at this point, with IE9 finally getting on the SVG bandwagon. The main problem with Canvas (from the point of view of matplotlib) is that it doesn't support persistence, (without building such a layer on top in JavaScript), so if you want to update the figure, you have to send the whole thing over the wire each time. SVG, on the other hand, maintains a tree of objects that can be tweaked at any time (and the performance in the current generation of browsers is stunning). One could send all of the large data objects as SVG from matplotlib to the browser and using XML ids to maintain relationships between the client and the server. Then, do scale the data (in many common cases), it is just a matter of updating the affiine transform on that object, (as well as updating the ticks etc, but that's peanuts), which requires very little bandwidth. I have some hackish "proof of concept" code doing this kind of thing, but it's a long way from there to something that truly works. This all glosses over the path simplification stuff that matplotlib does -- the assumption here is that the browser would have access to *all* of the data, and there are probably practical limits on how big that data can be. I recently did a lot of cleanup to the SVG backend to pave the way for having persistent objects etc. -- though there is no client/server code at all in master at the moment. All of that is "to be written", perhaps by you if you're interested. Cheers, Mike -- Michael Droettboom Science Software Branch Space Telescope Science Institute Baltimore, Maryland, USA ------------------------------------------------------------------------------ EditLive Enterprise is the world's most technically advanced content authoring tool. Experience the power of Track Changes, Inline Image Editing and ensure content is compliant with Accessibility Checking. http://p.sf.net/sfu/ephox-dev2dev _______________________________________________ Matplotlib-devel mailing list Matplotlib-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-devel