Re: [Matplotlib-users] Radar / Spider Chars
On Jun 15, 2008, at 11:54 AM, Curtis Jensen wrote: > There was recently a post on Radar/Spider plotting > (http://sourceforge.net/mailarchive/message.php?msg_id=4845303A.9050204%40epcc.ed.ac.uk > > ). > I too am interested in creating Radar plots with matplot. Is there a > simple way to do this? Here's a hack to get part of what you want: = from matplotlib.projections.polar import PolarAxes from pylab import * # Create 6 points (plus 7th point that matches the first) with coordinates r, theta N = 6 theta = 2 * pi * linspace(0, 1, N+1) r = rand(N+1) r[N] = r[0] # HACK: force PolarAxes to use 1 line segment to connect specified points PolarAxes.RESOLUTION = 1 ax = subplot(111, polar=True) c = ax.plot(theta, r, 'r-o') show() = I think this only works on matplotlib 0.98. I tried using rgrids and thetagrids to change the labels, but for some reason I was getting a TypeError when I called either of those functions. -Tony - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] Posting to Numpy and Scipy
On Jun 17, 2008, at 9:42 AM, Bryan Fodness wrote: > Has anyone had a problem posting to either of these mailing lists. > I am a member and have sent a few posts to each of them over the > last couple months, but none of them show up in the list. I always > receive a 'awaiting moderator approval' email. I have sent an email > to the owner about this, but have not received a response. > Bryan Hi Bryan, Are you subscribed to those lists? I just searched the membership list and did not see your email address. Non-subscribers get the "awaiting moderator approval" message, but since we get so inundated with spam, none of the admins really go through the "pending approval" queue... -Peter - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] Crash when trying to build docs on windows
John Hunter skrev: > On Tue, Jun 17, 2008 at 3:00 PM, Jörgen Stenarson > <[EMAIL PROTECTED]> wrote: > >> I did a svn up and a clean rebuild but still the same error. The error >> reminded me of the problems a while back when references to the >> fontfiles were not released. So I have tried to look at the filehandles >> using procexp but I cannot say if this is the problem, but I don't see >> any explosion in open file handles. But the crash is so sudden I may not >> be able to see this. >> >> Any thing else I can check at my end? > > I wonder if the reference counting in py_as_array is wrong. The most > likely culprit is the new function in src/ft2font.cpp. Do we need an > incref here? Joergen, does it help to comment out > the PyArray_SimpleNewFromData line and replace it with the commented > out block below it? I need to dig into the ownership and reference > policy of these two funcs but I don't have time to do it now. > I tried this but it still crashes. Below is the change I did. /Jörgen Py::Object FT2Image::py_as_array(const Py::Tuple & args) { _VERBOSE("FT2Image::as_array"); args.verify_length(0); npy_intp dimensions[2]; dimensions[0] = get_height(); //numrows dimensions[1] = get_width(); //numcols /* PyArrayObject *A = (PyArrayObject *) PyArray_SimpleNewFromData(2, dimensions, PyArray_UBYTE, _buffer); */ PyArrayObject *A = (PyArrayObject *) PyArray_FromDims(2, dimensions, PyArray_UBYTE); unsigned char *src = _buffer; unsigned char *src_end = src + (dimensions[0] * dimensions[1]); unsigned char *dst = (unsigned char *)A->data; while (src != src_end) { *dst++ = *src++; } return Py::asObject((PyObject*)A); } - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] Crash when trying to build docs on windows
On Tue, Jun 17, 2008 at 3:00 PM, Jörgen Stenarson <[EMAIL PROTECTED]> wrote: > I did a svn up and a clean rebuild but still the same error. The error > reminded me of the problems a while back when references to the > fontfiles were not released. So I have tried to look at the filehandles > using procexp but I cannot say if this is the problem, but I don't see > any explosion in open file handles. But the crash is so sudden I may not > be able to see this. > > Any thing else I can check at my end? I wonder if the reference counting in py_as_array is wrong. The most likely culprit is the new function in src/ft2font.cpp. Do we need an incref here? Joergen, does it help to comment out the PyArray_SimpleNewFromData line and replace it with the commented out block below it? I need to dig into the ownership and reference policy of these two funcs but I don't have time to do it now. Py::Object FT2Image::py_as_array(const Py::Tuple & args) { _VERBOSE("FT2Image::as_array"); args.verify_length(0); npy_intp dimensions[2]; dimensions[0] = get_height(); //numrows dimensions[1] = get_width(); //numcols PyArrayObject *A = (PyArrayObject *) PyArray_SimpleNewFromData(2, dimensions, PyArray_UBYTE, _buffer); /* PyArrayObject *A = (PyArrayObject *) PyArray_FromDims(2, dimensions, PyArray_UBYTE); unsigned char *src= _buffer; unsigned char *src_end= src + (dimensions[0] * dimensions[1]); unsigned char *dst= (unsigned char *)A->data; while (src != src_end) { *dst++ = *src++; } */ return Py::asObject((PyObject*)A); } - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] Crash when trying to build docs on windows
Michael Droettboom skrev: > I'm not sure these two issues are related. > I don't think so either but I thought I should mention it anyway. > Before I look deeper, have you updated from SVN today? I fixed a bug > earlier today related to using the STIX fonts (which appears to be where > this is crashing) on narrow Unicode Python interpreters (which I believe > Win32 Python is). > > Occasionally I get these ob_refcnt assertions when distutils didn't > decide to rebuild enough things. Try doing a clean rebuild (if you > haven't already). > > Cheers, > Mike > I did a svn up and a clean rebuild but still the same error. The error reminded me of the problems a while back when references to the fontfiles were not released. So I have tried to look at the filehandles using procexp but I cannot say if this is the problem, but I don't see any explosion in open file handles. But the crash is so sudden I may not be able to see this. Any thing else I can check at my end? /Jörgen - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] Crash when trying to build docs on windows
I'm not sure these two issues are related. Before I look deeper, have you updated from SVN today? I fixed a bug earlier today related to using the STIX fonts (which appears to be where this is crashing) on narrow Unicode Python interpreters (which I believe Win32 Python is). Occasionally I get these ob_refcnt assertions when distutils didn't decide to rebuild enough things. Try doing a clean rebuild (if you haven't already). Cheers, Mike Jörgen Stenarson wrote: > Hi, > > I have tried to build the docs of current trunk on windows using > python2.5. But I get a crash with an Assertion failed: ob_refcnt == 0, > file CXX\cxx_extensions.cxx, line 1128 > > There are also some warnings caused by the use of the link mpl_data. Is > it possible to get this link to work on win32? > > versions: > sphinx: 0.3 $Revision: 64324 $ > docutils: 0.5 > matplotlib: 0.98.0 r5583 > numpy: '1.1.0.dev5176' > > /Jörgen > > > > C:\python\external\matplotlib-trunk\doc>make.py > Sphinx v0.3, building html > trying to load pickled env... not found > building [html]: targets for 42 source files that are out of date > updating environment: 42 added, 0 changed, 0 removed > reading... api/artist_api api/axes_api api/axis_api > api/backend_bases_api api/ba > ckend_gtkagg_api api/backend_qt4agg_api api/backend_wxagg_api > api/cbook_api api/ > cm_api api/collections_api api/colorbar_api api/index > api/index_backend_api api/ > matplotlib_configuration_api api/pyplot_api devel/add_new_projection > devel/codin > g_guide devel/documenting_mpl devel/index devel/outline > devel/transformations fa > q/environment_variables_faq faq/howto_faq faq/index faq/installing_faq > faq/troub > leshooting_faq glossary/index index users/annotations already have > pyplots\a > nnotation_basic.py > already have pyplots\annotation_polar.py > users/arraydata users/artists already have > pyplots\fig_axes_labels_simple.py > > already have pyplots\fig_x.py > already have pyplots\fig_axes_customize_simple.py > already have pyplots\dollar_ticks.py > users/customizing users/event_handling users/index users/index_text > users/intro > users/mathtext already have pyplots\pyplot_mathtext.py > users/navigation_toolbar users/pyplot_tutorial already have > pyplots\pyplot_s > imple.py > already have pyplots\pyplot_formatstr.py > already have pyplots\pyplot_three.py > already have pyplots\pyplot_two_subplots.py > already have pyplots\pyplot_text.py > already have pyplots\pyplot_annotate.py > users/text_intro already have pyplots\text_commands.py > users/text_props already have pyplots\text_layout.py > users/usetex already have pyplots\tex_demo.py > already have pyplots\tex_unicode_demo.py > > WARNING: > C:\python\external\matplotlib-trunk\doc\api\backend_qt4agg_api.rst:5: ( > WARNING/2) autodoc can't import/find module > 'matplotlib.backends.backend_qt4agg' > , check your spelling and sys.path > WARNING: > C:\python\external\matplotlib-trunk\doc\api\backend_wxagg_api.rst:5: (W > ARNING/2) autodoc can't import/find module > 'matplotlib.backends.backend_wxagg', > check your spelling and sys.path > WARNING: C:\python\external\matplotlib-trunk\doc\api\cbook_api.rst:9: > (WARNING/2 > ) error while formatting signature for matplotlib.cbook.Xlator: arg is > not a Pyt > hon function > WARNING: > C:\python\external\matplotlib-trunk\doc\users\customizing.rst:66: (WARN > ING/2) Include file u'../mpl_data/matplotlibrc' not found or reading it > failed > WARNING: > C:\python\external\matplotlib-trunk\doc\users\navigation_toolbar.rst:13 > : Image file not readable: mpl_data\images\home.png > WARNING: > C:\python\external\matplotlib-trunk\doc\users\navigation_toolbar.rst:15 > : Image file not readable: mpl_data\images\back.png > WARNING: > C:\python\external\matplotlib-trunk\doc\users\navigation_toolbar.rst:17 > : Image file not readable: mpl_data\images\forward.png > WARNING: > C:\python\external\matplotlib-trunk\doc\users\navigation_toolbar.rst:30 > : Image file not readable: mpl_data\images\move.png > WARNING: > C:\python\external\matplotlib-trunk\doc\users\navigation_toolbar.rst:54 > : Image file not readable: mpl_data\images\zoom_to_rect.png > WARNING: > C:\python\external\matplotlib-trunk\doc\users\navigation_toolbar.rst:65 > : Image file not readable: mpl_data\images\subplots.png > WARNING: > C:\python\external\matplotlib-trunk\doc\users\navigation_toolbar.rst:72 > : Image file not readable: mpl_data\images\filesave.png > pickling the env... done > checking consistency... > WARNING: C:\python\external\matplotlib-trunk\doc\users\arraydata.rst:: > document > isn't included in any toctree > writing output... api/artist_api api/axes_api api/axis_api > api/backend_bases_api > api/backend_gtkagg_api api/backend_qt4agg_api api/backend_wxagg_api > api/cbook_a > pi api/cm_api api/collections_api api/colorbar_api api/index > api/index_backend_a > pi api/matplotlib_configuration
[Matplotlib-users] Crash when trying to build docs on windows
Hi, I have tried to build the docs of current trunk on windows using python2.5. But I get a crash with an Assertion failed: ob_refcnt == 0, file CXX\cxx_extensions.cxx, line 1128 There are also some warnings caused by the use of the link mpl_data. Is it possible to get this link to work on win32? versions: sphinx: 0.3 $Revision: 64324 $ docutils: 0.5 matplotlib: 0.98.0 r5583 numpy: '1.1.0.dev5176' /Jörgen C:\python\external\matplotlib-trunk\doc>make.py Sphinx v0.3, building html trying to load pickled env... not found building [html]: targets for 42 source files that are out of date updating environment: 42 added, 0 changed, 0 removed reading... api/artist_api api/axes_api api/axis_api api/backend_bases_api api/ba ckend_gtkagg_api api/backend_qt4agg_api api/backend_wxagg_api api/cbook_api api/ cm_api api/collections_api api/colorbar_api api/index api/index_backend_api api/ matplotlib_configuration_api api/pyplot_api devel/add_new_projection devel/codin g_guide devel/documenting_mpl devel/index devel/outline devel/transformations fa q/environment_variables_faq faq/howto_faq faq/index faq/installing_faq faq/troub leshooting_faq glossary/index index users/annotations already have pyplots\a nnotation_basic.py already have pyplots\annotation_polar.py users/arraydata users/artists already have pyplots\fig_axes_labels_simple.py already have pyplots\fig_x.py already have pyplots\fig_axes_customize_simple.py already have pyplots\dollar_ticks.py users/customizing users/event_handling users/index users/index_text users/intro users/mathtext already have pyplots\pyplot_mathtext.py users/navigation_toolbar users/pyplot_tutorial already have pyplots\pyplot_s imple.py already have pyplots\pyplot_formatstr.py already have pyplots\pyplot_three.py already have pyplots\pyplot_two_subplots.py already have pyplots\pyplot_text.py already have pyplots\pyplot_annotate.py users/text_intro already have pyplots\text_commands.py users/text_props already have pyplots\text_layout.py users/usetex already have pyplots\tex_demo.py already have pyplots\tex_unicode_demo.py WARNING: C:\python\external\matplotlib-trunk\doc\api\backend_qt4agg_api.rst:5: ( WARNING/2) autodoc can't import/find module 'matplotlib.backends.backend_qt4agg' , check your spelling and sys.path WARNING: C:\python\external\matplotlib-trunk\doc\api\backend_wxagg_api.rst:5: (W ARNING/2) autodoc can't import/find module 'matplotlib.backends.backend_wxagg', check your spelling and sys.path WARNING: C:\python\external\matplotlib-trunk\doc\api\cbook_api.rst:9: (WARNING/2 ) error while formatting signature for matplotlib.cbook.Xlator: arg is not a Pyt hon function WARNING: C:\python\external\matplotlib-trunk\doc\users\customizing.rst:66: (WARN ING/2) Include file u'../mpl_data/matplotlibrc' not found or reading it failed WARNING: C:\python\external\matplotlib-trunk\doc\users\navigation_toolbar.rst:13 : Image file not readable: mpl_data\images\home.png WARNING: C:\python\external\matplotlib-trunk\doc\users\navigation_toolbar.rst:15 : Image file not readable: mpl_data\images\back.png WARNING: C:\python\external\matplotlib-trunk\doc\users\navigation_toolbar.rst:17 : Image file not readable: mpl_data\images\forward.png WARNING: C:\python\external\matplotlib-trunk\doc\users\navigation_toolbar.rst:30 : Image file not readable: mpl_data\images\move.png WARNING: C:\python\external\matplotlib-trunk\doc\users\navigation_toolbar.rst:54 : Image file not readable: mpl_data\images\zoom_to_rect.png WARNING: C:\python\external\matplotlib-trunk\doc\users\navigation_toolbar.rst:65 : Image file not readable: mpl_data\images\subplots.png WARNING: C:\python\external\matplotlib-trunk\doc\users\navigation_toolbar.rst:72 : Image file not readable: mpl_data\images\filesave.png pickling the env... done checking consistency... WARNING: C:\python\external\matplotlib-trunk\doc\users\arraydata.rst:: document isn't included in any toctree writing output... api/artist_api api/axes_api api/axis_api api/backend_bases_api api/backend_gtkagg_api api/backend_qt4agg_api api/backend_wxagg_api api/cbook_a pi api/cm_api api/collections_api api/colorbar_api api/index api/index_backend_a pi api/matplotlib_configuration_api api/pyplot_api devel/add_new_projection deve l/coding_guide devel/documenting_mpl devel/index devel/outline devel/transformat ions faq/environment_variables_faq faq/howto_faq faq/index faq/installing_faq fa q/troubleshooting_faq glossary/index index users/annotations users/arraydata use rs/artists users/customizing users/event_handling users/index users/index_text u sers/intro users/mathtext $\circledR$ Assertion failed: ob_refcnt == 0, file CXX\cxx_extensions.cxx, line 1128 This application has requested the Runtime to terminate it in an unusual way. Please contact the application's support team for more information. Building HTML failed. C:\python\external\matplotlib-trunk
Re: [Matplotlib-users] Matplotlib-users Digest, Vol 25, Issue 30
Where can I find documentation on the new circle collection? And, going back to his comment about "real radius", if I add a circle to a matplotlib plot (not sure how to do this), how can I ensure the radius is, indeed, in meters? I have read the scatter documentation, and it says the radius of the annotations should be in meters, but that doesn't seem like it's the case. Regards, Kurt -- Message: 5 Date: Mon, 16 Jun 2008 23:35:37 -0700 (PDT) From: sidimok <[EMAIL PROTECTED]> Subject: Re: [Matplotlib-users] Drawing filled circles (discs) To: matplotlib-users@lists.sourceforge.net Message-ID: <[EMAIL PROTECTED]> Content-Type: text/plain; charset=us-ascii > Or are you effectively doing a scatter plot? Could you use scatter? > > Eric > Yes, I've already tried doing the trick with a scatter plot, but since the filling colors correspond to a "physical quantity" and the radius of the scatters are the "real" circle radius, using RegularPolygons is more straightforward. Isn't it better to use "Circle" new collection? - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] Circle Collection
Thank you very much indeed guys, you made my day. =) -- View this message in context: http://www.nabble.com/Circle-Collection-tp17866685p17913009.html Sent from the matplotlib - users mailing list archive at Nabble.com. - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
[Matplotlib-users] Posting to Numpy and Scipy
Has anyone had a problem posting to either of these mailing lists. I am a member and have sent a few posts to each of them over the last couple months, but none of them show up in the list. I always receive a 'awaiting moderator approval' email. I have sent an email to the owner about this, but have not received a response. Bryan - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] Circle Collection
My e-mail has been kind of sporadic this morning... but we seem to be in agreement. Just realised get_verts could actually be slightly better -- If we use Path.to_polygons() then any curves in the patch will get converted to line segments. Then even patches like Ellipse and Arc will work and do the expected thing. I've committed this (along with a small bugfix to to_polygons). Cheers, Mike John Hunter wrote: > On Tue, Jun 17, 2008 at 7:34 AM, Michael Droettboom <[EMAIL PROTECTED]> wrote: > > >> Now -- for the other developers on this list: We may want to add a >> .get_verts() function back to patches that does exactly what I recommend >> above. It won't behave identically to 0.91 since it will return a >> transformed copy of the vertices, but that won't matter in all cases >> (such as this one). >> > > Hmm, we are asking each other the same question in different threads :-) > > > http://sourceforge.net/mailarchive/forum.php?thread_name=88e473830806161822u418bad86hada6ed655dee77bc%40mail.gmail.com&forum_name=matplotlib-users > > I committed this method. > > JDH > -- Michael Droettboom Science Software Branch Operations and Engineering Division Space Telescope Science Institute Operated by AURA for NASA - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
[Matplotlib-users] savefig fails under apache on solaris
Hi, I am trying to use matplotlib to generate png image plots to display in web pages using apache on solaris. The problem is that savefig(sys.stdout) fails to generate any output or any error messages. The scripts run ok when run by hand, either by me or by the apache user. They also work when used as cgi scripts on a debian linux system. I am at a bit of a loss as to how to investigate what could be going wrong so any pointers would be helpful. The matplotlib version is 0.98.0 and I am using the Agg backend. John Bovey - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
[Matplotlib-users] savefig fails under apache on solaris
Hi, I am trying to use matplotlib to generate png image plots to display in web pages using apache on solaris. The problem is that savefig(sys.stdout) fails to generate any output or any error messages. The scripts run ok when run by hand, either by me or by the apache user. They also work when used as cgi scripts on a debian linux system. I am at a bit of a loss as to how to investigate what could be going wrong so any pointers would be helpful. The matplotlib version is 0.98.0 and I am using the Agg backend. John Bovey - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] Circle Collection
On Tue, Jun 17, 2008 at 7:34 AM, Michael Droettboom <[EMAIL PROTECTED]> wrote: > Now -- for the other developers on this list: We may want to add a > .get_verts() function back to patches that does exactly what I recommend > above. It won't behave identically to 0.91 since it will return a > transformed copy of the vertices, but that won't matter in all cases > (such as this one). Hmm, we are asking each other the same question in different threads :-) http://sourceforge.net/mailarchive/forum.php?thread_name=88e473830806161822u418bad86hada6ed655dee77bc%40mail.gmail.com&forum_name=matplotlib-users I committed this method. JDH - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] plotting speed
On Tue, Jun 17, 2008 at 7:16 AM, Michael Droettboom <[EMAIL PROTECTED]> wrote: > Christopher Barker wrote: >> If we really think that would help, and we would use it for MPL, we >> could try to get it done -- but I doubt that it's worth it -- we have >> enough trouble keeping the wx back-ends maintained as it is. > Yes --- there is something to be said for keeping the number of backends > to a minimum. Each one needs to have a reason to exist ;) >> If you can come up with an self-contained example of this, a post tot he wxPython list may yield results. >>> It might be worth it just to get to the bottom of this. >> >> so are you working on an example? Or should I? > I'm happy to do it, but may not get to it for a few days. My own test > was to run "simple_plot_fps.py" with "handle_clip_rectangle" (in > backend_wx.py) turned on and off. But obviously the wxPython folks will > want a more standalone example. I am happy to keep backends around if someone cares enough about it to step up and maintain it. Michael you are stretched pretty thin w/ all the other stuff you are doing for matplotlib, and I know you don't use wx yourself or at work, so I suggest we let Ken or Chris or someone who has a vested interest in this backend pursue it. As it stands, wxagg is superior for almost every use case, and we want to encourage people to use it. Any effort we spend optimizing would be much better put into agg, since that would help almost every user, rather than the few who are using native wx. JDH - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] Circle Collection
You've hit one of the changed APIs in 0.98. You can see the list of changed APIs here: http://matplotlib.svn.sourceforge.net/viewvc/*checkout*/matplotlib/trunk/matplotlib/API_CHANGES Patches no longer store lists of vertices, they store Path objects + Affine transforms. So rather than "get_verts()", you can use the admittedly obtuse "circle.get_transform().transform(get_path().vertices)". Note also another change is required in your script for something that probably only worked by accident before. The "ax.add_patch(p)" should be "ax.add_collection(p)", since p is a PolyCollection. Now -- for the other developers on this list: We may want to add a .get_verts() function back to patches that does exactly what I recommend above. It won't behave identically to 0.91 since it will return a transformed copy of the vertices, but that won't matter in all cases (such as this one). We may want to add a PatchCollection class that takes a list of patches, so users don't have to manually take patches apart like this. This is now possible because all patches are basically the same thing. This would also make it easier to use an bezier-approximated Ellipse rather than a polygonal approximated one. Cheers, Mike sidimok wrote: > Hi everyone, > > The code below was working for me as a charm, but since the new matlplotlib > flavor 0.98, I'm getting this error message: > > >>> AttributeError: 'CirclePolygon' object has no attribute 'get_verts' << >>> > > Any idea? > > - - - - - - - - - - - - - - - - - - - > > import matplotlib > from matplotlib.patches import CirclePolygon > from matplotlib.collections import PolyCollection > import pylab > > fig=pylab.figure() > ax=fig.add_subplot(111) > > resolution = 50 # the number of vertices > N = 20 > x = pylab.rand(N) > y = pylab.rand(N) > radii = 0.1*pylab.rand(N) > colors = 100*pylab.rand(N) > verts = [] > for x1,y1,r in zip(x, y, radii): > circle = CirclePolygon((x1,y1), r, resolution) > verts.append(circle.get_verts()) > > p = PolyCollection(verts, cmap=matplotlib.cm.jet) > p.set_array(pylab.array(colors)) > ax.add_patch(p) > pylab.colorbar(p) > > ax.axis('equal') > pylab.show() > > -- Michael Droettboom Science Software Branch Operations and Engineering Division Space Telescope Science Institute Operated by AURA for NASA - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] plotting speed
Christopher Barker wrote: > Michael Droettboom wrote: > >> Creates a wx.GraphicsContext from a native context. This native >> context must be eg a CGContextRef for Core Graphics, a Graphics >> pointer for GDIPlus or a cairo_t pointer for Cairo. NOTE: For >> wxPython we still need a way to make this value usable. > > If we really think that would help, and we would use it for MPL, we > could try to get it done -- but I doubt that it's worth it -- we have > enough trouble keeping the wx back-ends maintained as it is. Yes --- there is something to be said for keeping the number of backends to a minimum. Each one needs to have a reason to exist ;) > >>> If you can come up with an self-contained example of this, a post >>> tot he wxPython list may yield results. >>> >> It might be worth it just to get to the bottom of this. > > so are you working on an example? Or should I? I'm happy to do it, but may not get to it for a few days. My own test was to run "simple_plot_fps.py" with "handle_clip_rectangle" (in backend_wx.py) turned on and off. But obviously the wxPython folks will want a more standalone example. > >> I think the best we'll be able to do performance-wise with >> wx.GraphicsContext is the same as the Cairo backend (since >> wx.GraphicsContext is built on top of Cairo on X11, at least) > > so, does Cairo render a bitmap, and then push that to the X Server? If > so, that would explain why the new wx backend isn't any better than > wxAgg with remote X connections -- and that's was the only reason I > know to use it. I believe it does from what I've read (assuming one isn't using the OpenGL backend), but don't know that first hand. > >> already slower than Agg, so there's no compelling reason for the Wx >> backend to exist, IMHO, *unless* it needs to integrate with other >> code that draws to a wx.GraphicsContext. > > I cant really imagine why anyone would try to do that -- and if you > really wanted to, you could still transfer the Agg buffer to a > wxBitmap, and draw to that with GraphicsContext anyway. True. > > So, like you, I'm curious (and I need GraphicsContext for other > projects), so I'd still like to know what the deal is. > Thanks for all the info so far... Hopefully we can get to the bottom of this. Cheers, Mike -- Michael Droettboom Science Software Branch Operations and Engineering Division Space Telescope Science Institute Operated by AURA for NASA - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] Ubuntu Hardy and matplotlib
Hi The thing is that if you installed the package matplotlib through your package manager, you are not supposed and you don't need to install it manually from the sources with the two commands I gave you. The main interest of using the source of 0.91.3 is to use a debugged version of the 0.91 release. In fact, the package 0.91.2 that you can get from your package manager still have some bugs. But maybe, you are using the 0.91.3 version since you typed "pyhton setup.py build" and "pyhton setup.py install" in the source directory (despite of the fact that you previously installed a matplotlib package). I'm not good enough in Linux to tell what is the behaviour of the system in this case. Anyway, good for you if it's actually working. :) Regards Johan 2008/6/17 Marjolaine Rouault <[EMAIL PROTECTED]>: > Dear Johan, > > I have downloaded the matplotlib 0.91.2 version (the one installed by > default by my package manager) and ran the python setup.py build as you > suggested before running the python setup.py install command. I fixed the > problem! I am so grateful for you helping me sort this out finally. I am > looking forwards to start using matplotlib. > > Cheers, marjolaine. > > >>> "Johan Mazel" <[EMAIL PROTECTED]> 06/17/08 10:15 AM >>> > Hi > I am working with matplotlib 0.91.3 on Hardy. I installed it (with "pyhton > setup.py build" and "pyhton setup.py install") from the source given on > SourceForge. And it's working perfectly. > Are you sure that you installed all the needed packages ? (Check with > "pyhton setup.py build" and see wether there is no missing packages, > especially development packages) > NB : My matplotlib work without development packages from tkinter despite > the fact that there are asked. > Regards > Johan > > 2008/6/17 Marjolaine Rouault <[EMAIL PROTECTED]>: > > > Hi, > > > > I have tried reinstalling python-matplotlib and python-matplotlib-data as > > well as reinstalling python-gtk2 and none of this proposed solutions > work. > > Still stuck unfortunately. I am thinking maybe my ubuntu is not right. > Could > > you guys let me know which repositories you use and I could try and > upgrade > > my ubuntu to one of new repositories lists? > > > > Thank > > > > > > > > -- > > This message is subject to the CSIR's copyright terms and conditions, > > e-mail legal notice, and implemented Open Document Format (ODF) standard. > > The full disclaimer details can be found at > > http://www.csir.co.za/disclaimer.html. > > > > This message has been scanned for viruses and dangerous content by > > MailScanner, > > and is believed to be clean. MailScanner thanks Transtec Computers for > > their support. > > > > > > - > > Check out the new SourceForge.net Marketplace. > > It's the best place to buy or sell services for > > just about anything Open Source. > > http://sourceforge.net/services/buy/index.php > > ___ > > Matplotlib-users mailing list > > Matplotlib-users@lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > > > > -- > This message is subject to the CSIR's copyright terms and conditions, > e-mail legal notice, and implemented Open Document Format (ODF) standard. > The full disclaimer details can be found at > http://www.csir.co.za/disclaimer.html. > > This message has been scanned for viruses and dangerous content by > MailScanner, > and is believed to be clean. MailScanner thanks Transtec Computers for > their support. > > - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] Ubuntu Hardy and matplotlib
Dear Johan, I have downloaded the matplotlib 0.91.2 version (the one installed by default by my package manager) and ran the python setup.py build as you suggested before running the python setup.py install command. I fixed the problem! I am so grateful for you helping me sort this out finally. I am looking forwards to start using matplotlib. Cheers, marjolaine. >>> "Johan Mazel" <[EMAIL PROTECTED]> 06/17/08 10:15 AM >>> Hi I am working with matplotlib 0.91.3 on Hardy. I installed it (with "pyhton setup.py build" and "pyhton setup.py install") from the source given on SourceForge. And it's working perfectly. Are you sure that you installed all the needed packages ? (Check with "pyhton setup.py build" and see wether there is no missing packages, especially development packages) NB : My matplotlib work without development packages from tkinter despite the fact that there are asked. Regards Johan 2008/6/17 Marjolaine Rouault <[EMAIL PROTECTED]>: > Hi, > > I have tried reinstalling python-matplotlib and python-matplotlib-data as > well as reinstalling python-gtk2 and none of this proposed solutions work. > Still stuck unfortunately. I am thinking maybe my ubuntu is not right. Could > you guys let me know which repositories you use and I could try and upgrade > my ubuntu to one of new repositories lists? > > Thank > > > > -- > This message is subject to the CSIR's copyright terms and conditions, > e-mail legal notice, and implemented Open Document Format (ODF) standard. > The full disclaimer details can be found at > http://www.csir.co.za/disclaimer.html. > > This message has been scanned for viruses and dangerous content by > MailScanner, > and is believed to be clean. MailScanner thanks Transtec Computers for > their support. > > > - > Check out the new SourceForge.net Marketplace. > It's the best place to buy or sell services for > just about anything Open Source. > http://sourceforge.net/services/buy/index.php > ___ > Matplotlib-users mailing list > Matplotlib-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > -- This message is subject to the CSIR's copyright terms and conditions, e-mail legal notice, and implemented Open Document Format (ODF) standard. The full disclaimer details can be found at http://www.csir.co.za/disclaimer.html. This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. MailScanner thanks Transtec Computers for their support. - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] Ubuntu Hardy and matplotlib
Don't sure last matplotlib version (and numpy) is in Hardy repositories. Here we do : 1- sudo apt-get --purge remove python-numpy* python-matplotlib* python-scipy* 2- manually remove all related folders under site-packages (with eggs!) 3- download and install manually numpy, scipy and matplotlib (and basemap) Le mardi 17 juin 2008, Marjolaine Rouault a écrit : > Hi, > > I have tried reinstalling python-matplotlib and python-matplotlib-data as > well as reinstalling python-gtk2 and none of this proposed solutions work. > Still stuck unfortunately. I am thinking maybe my ubuntu is not right. > Could you guys let me know which repositories you use and I could try and > upgrade my ubuntu to one of new repositories lists? > > Thank -- Lionel Roubeyrie - [EMAIL PROTECTED] Chargé d'études et de maintenance LIMAIR - la Surveillance de l'Air en Limousin http://www.limair.asso.fr - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] Ubuntu Hardy and matplotlib
Hi I am working with matplotlib 0.91.3 on Hardy. I installed it (with "pyhton setup.py build" and "pyhton setup.py install") from the source given on SourceForge. And it's working perfectly. Are you sure that you installed all the needed packages ? (Check with "pyhton setup.py build" and see wether there is no missing packages, especially development packages) NB : My matplotlib work without development packages from tkinter despite the fact that there are asked. Regards Johan 2008/6/17 Marjolaine Rouault <[EMAIL PROTECTED]>: > Hi, > > I have tried reinstalling python-matplotlib and python-matplotlib-data as > well as reinstalling python-gtk2 and none of this proposed solutions work. > Still stuck unfortunately. I am thinking maybe my ubuntu is not right. Could > you guys let me know which repositories you use and I could try and upgrade > my ubuntu to one of new repositories lists? > > Thank > > > > -- > This message is subject to the CSIR's copyright terms and conditions, > e-mail legal notice, and implemented Open Document Format (ODF) standard. > The full disclaimer details can be found at > http://www.csir.co.za/disclaimer.html. > > This message has been scanned for viruses and dangerous content by > MailScanner, > and is believed to be clean. MailScanner thanks Transtec Computers for > their support. > > > - > Check out the new SourceForge.net Marketplace. > It's the best place to buy or sell services for > just about anything Open Source. > http://sourceforge.net/services/buy/index.php > ___ > Matplotlib-users mailing list > Matplotlib-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
[Matplotlib-users] Ubuntu Hardy and matplotlib
Hi, I have tried reinstalling python-matplotlib and python-matplotlib-data as well as reinstalling python-gtk2 and none of this proposed solutions work. Still stuck unfortunately. I am thinking maybe my ubuntu is not right. Could you guys let me know which repositories you use and I could try and upgrade my ubuntu to one of new repositories lists? Thank -- This message is subject to the CSIR's copyright terms and conditions, e-mail legal notice, and implemented Open Document Format (ODF) standard. The full disclaimer details can be found at http://www.csir.co.za/disclaimer.html. This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. MailScanner thanks Transtec Computers for their support. - Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users