You can subscribe to this list here.
2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(3) |
Jun
|
Jul
|
Aug
(12) |
Sep
(12) |
Oct
(56) |
Nov
(65) |
Dec
(37) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2004 |
Jan
(59) |
Feb
(78) |
Mar
(153) |
Apr
(205) |
May
(184) |
Jun
(123) |
Jul
(171) |
Aug
(156) |
Sep
(190) |
Oct
(120) |
Nov
(154) |
Dec
(223) |
2005 |
Jan
(184) |
Feb
(267) |
Mar
(214) |
Apr
(286) |
May
(320) |
Jun
(299) |
Jul
(348) |
Aug
(283) |
Sep
(355) |
Oct
(293) |
Nov
(232) |
Dec
(203) |
2006 |
Jan
(352) |
Feb
(358) |
Mar
(403) |
Apr
(313) |
May
(165) |
Jun
(281) |
Jul
(316) |
Aug
(228) |
Sep
(279) |
Oct
(243) |
Nov
(315) |
Dec
(345) |
2007 |
Jan
(260) |
Feb
(323) |
Mar
(340) |
Apr
(319) |
May
(290) |
Jun
(296) |
Jul
(221) |
Aug
(292) |
Sep
(242) |
Oct
(248) |
Nov
(242) |
Dec
(332) |
2008 |
Jan
(312) |
Feb
(359) |
Mar
(454) |
Apr
(287) |
May
(340) |
Jun
(450) |
Jul
(403) |
Aug
(324) |
Sep
(349) |
Oct
(385) |
Nov
(363) |
Dec
(437) |
2009 |
Jan
(500) |
Feb
(301) |
Mar
(409) |
Apr
(486) |
May
(545) |
Jun
(391) |
Jul
(518) |
Aug
(497) |
Sep
(492) |
Oct
(429) |
Nov
(357) |
Dec
(310) |
2010 |
Jan
(371) |
Feb
(657) |
Mar
(519) |
Apr
(432) |
May
(312) |
Jun
(416) |
Jul
(477) |
Aug
(386) |
Sep
(419) |
Oct
(435) |
Nov
(320) |
Dec
(202) |
2011 |
Jan
(321) |
Feb
(413) |
Mar
(299) |
Apr
(215) |
May
(284) |
Jun
(203) |
Jul
(207) |
Aug
(314) |
Sep
(321) |
Oct
(259) |
Nov
(347) |
Dec
(209) |
2012 |
Jan
(322) |
Feb
(414) |
Mar
(377) |
Apr
(179) |
May
(173) |
Jun
(234) |
Jul
(295) |
Aug
(239) |
Sep
(276) |
Oct
(355) |
Nov
(144) |
Dec
(108) |
2013 |
Jan
(170) |
Feb
(89) |
Mar
(204) |
Apr
(133) |
May
(142) |
Jun
(89) |
Jul
(160) |
Aug
(180) |
Sep
(69) |
Oct
(136) |
Nov
(83) |
Dec
(32) |
2014 |
Jan
(71) |
Feb
(90) |
Mar
(161) |
Apr
(117) |
May
(78) |
Jun
(94) |
Jul
(60) |
Aug
(83) |
Sep
(102) |
Oct
(132) |
Nov
(154) |
Dec
(96) |
2015 |
Jan
(45) |
Feb
(138) |
Mar
(176) |
Apr
(132) |
May
(119) |
Jun
(124) |
Jul
(77) |
Aug
(31) |
Sep
(34) |
Oct
(22) |
Nov
(23) |
Dec
(9) |
2016 |
Jan
(26) |
Feb
(17) |
Mar
(10) |
Apr
(8) |
May
(4) |
Jun
(8) |
Jul
(6) |
Aug
(5) |
Sep
(9) |
Oct
(4) |
Nov
|
Dec
|
2017 |
Jan
(5) |
Feb
(7) |
Mar
(1) |
Apr
(5) |
May
|
Jun
(3) |
Jul
(6) |
Aug
(1) |
Sep
|
Oct
(2) |
Nov
(1) |
Dec
|
2018 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2020 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2025 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
S | M | T | W | T | F | S |
---|---|---|---|---|---|---|
|
|
|
1
(22) |
2
(17) |
3
(21) |
4
(7) |
5
(7) |
6
(17) |
7
(8) |
8
(8) |
9
(33) |
10
(11) |
11
|
12
(2) |
13
(11) |
14
(29) |
15
(13) |
16
(13) |
17
(3) |
18
(2) |
19
(3) |
20
(7) |
21
(17) |
22
(12) |
23
(19) |
24
(19) |
25
(14) |
26
(5) |
27
(25) |
28
(13) |
|
|
|
|
From: John H. <jdh...@ac...> - 2006-02-22 14:30:14
|
>>>>> "George" == George Nurser <ag...@no...> writes: George> I've had various versions of matplotlib from CVS installed George> on an Opteron (Red Hat LInux) here for a few weeks now. I George> had to modify setupext.py to look for various libraries in George> ../lib64 instead of /lib but matplotlib works very nicely George> most of the time, and I have started using it for real George> work. George> One cosmetic problem: the buttons at the bottom of the George> plot window have their graphics messed up. They just look George> like red crosses. The floating xml works, so I know what George> the buttons do, and it doesn't inconvenience me --- but it George> looks bad. George> Presumably some library is either out of date, incomplete, George> or not linked correctly. I am using the default TkAgg George> backend. Any thoughts on what I should look for would be George> appreciated. We used to see something like this on OSX with the WX backend. What version of Tk are you using? Could this be a byte order or byte size problem? The code that loads the buttons is in matplotlib.backends.backend_tkagg def _Button(self, text, file, command): file = os.path.join(rcParams['datapath'], file) im = Tk.PhotoImage(master=self, file=file) b = Tk.Button( master=self, text=text, padx=2, pady=2, image=im, command=command) b._ntimage = im b.pack(side=Tk.LEFT) return b you may want to read up on the tk PhotoImage and Button classes and see if there is some option that makes this work. I don't have access to the opteron platform to test on. The tk backend uses the ppm files for the icons (eg home.ppm). Do any of the other icon image formats that ship with matplotlib (xpm, png, svg) work for you? You can test this by editing the _init_toolbar code in backend_tkagg.py self.bHome = self._Button( text="Home", file="home.ppm", command=self.home) and trying different extensions. Thanks, JDH |
From: Darren D. <dd...@co...> - 2006-02-22 12:42:36
|
On Wednesday 22 February 2006 7:32 am, Bruce wrote: > Hi group, > > I wanted to try to usetex for my matplotlib plots, and thought that I > had everything neccessary installed, but it doesn`t work. Perhaps > someone in the group have some idea what is wrong here? Im using > MikTex on xp and have the dvipng-miktex pakage installed. thx Have you read the wiki? http://www.scipy.org/Wiki/Cookbook/Matplotlib/UsingTex An intermediate dvi file is missing, probably because the latex executable is not on your path. Darren |
From: Bruce <ep...@gm...> - 2006-02-22 12:32:15
|
Hi group, I wanted to try to usetex for my matplotlib plots, and thought that I had everything neccessary installed, but it doesn`t work. Perhaps someone in the group have some idea what is wrong here? Im using MikTex on xp and have the dvipng-miktex pakage installed. thx File "C:\\Python23\\lib\\site-packages\\matplotlib\\text.py", line 334, in draw bbox, info =3D self._get_layout(renderer) File "C:\\Python23\\lib\\site-packages\\matplotlib\\text.py", line 179, in _get_layout w,h =3D renderer.get_text_width_height( File "C:\\Python23\\lib\\site-packages\\matplotlib\\backends\\backend_agg= .py", line 237, in get_text_width_height Z =3D self.texmanager.get_rgba(s, size, dpi, rgb) File "C:\\Python23\\lib\\site-packages\\matplotlib\\texmanager.py", line 276, in get_rgba pngfile =3D self.make_png(tex, dpi, force=3DFalse) File "C:\\Python23\\lib\\site-packages\\matplotlib\\texmanager.py", line 113, in make_png dvifile =3D self.make_dvi(tex) File "C:\\Python23\\lib\\site-packages\\matplotlib\\texmanager.py", line 105, in make_dvi shutil.move(dvitmp, dvifile) File "C:\\Python23\\lib\\shutil.py", line 174, in move copy2(src,dst) File "C:\\Python23\\lib\\shutil.py", line 83, in copy2 copyfile(src, dst) File "C:\\Python23\\lib\\shutil.py", line 38, in copyfile fsrc =3D open(src, 'rb') IOError: [Errno 2] No such file or directory: 'a8cf192be8520ffec23612a6a3a0ee29.dvi >>> |
From: Steve S. <el...@gm...> - 2006-02-22 12:08:05
|
Christopher Barker wrote: > John Hunter wrote: > >> This is an annoyance that is caused by the fact that the GTK install >> needs an X11 connection, > > > Is it really necessary to import GTK when installing MPL? why? I think > getting rid of that requirement would be the best fix. > >> Basically, you need to be able to >> make sure you can launch an X11 app (eg xterm) in the environment that >> you are running matplotlib install. >> >> Perhaps some UNIX guru can give the proper incantation. > > > I've done it, but I'm not sure I remember how at the moment. But try > something like: > > xhost +root > > or even: > > xhost + > > which I think lets anyone have access to the Xserver. > > -Chris > I've replied to only to John, not the list. Here is the mail again: ================================================================================================ John Hunter wrote: >>>>>> "Steve" == Steve Schmerler <el...@gm...> writes: > > > > Steve> ------------------------------------------------------------------------ > Steve> elcorto@ramrod:~/Install/Matplotlib/matplotlib-0.86.2$ sudo > Steve> python setup.py install installing data to > Steve> lib/python2.3/site-packages/matplotlib/mpl-data pygtk > Steve> present but import failed Using default library and include > Steve> directories for Tcl and Tk because a Tk window failed to > Steve> open. You may need to define DISPLAY for Tk to work so > Steve> that setup can determine where your libraries are located. > > Steve> Gtk-WARNING **: cannot open display: > Steve> ------------------------------------------------------------------------ > > This is an annoyance that is caused by the fact that the GTK install > needs an X11 connection, and in some setups when you install as root > the root user does not have access to your display. Exactly this was the problem. I was logged in from machine A on machine B as user (ssh -X B) and wanted to install on B. So what I did on B was: (as user): user@B:<mpl_path>$ python setup.py build # this works (via sudo): user@B:<mpl_path>$ sudo python setup.py install python setup.py install installing data to lib/python2.3/site-packages/matplotlib/mpl-data pygtk present but import failed Using default library and include directories for Tcl and Tk because a Tk window failed to open. You may need to define DISPLAY for Tk to work so that setup can determine where your libraries are located. Gtk-WARNING **: cannot open display: (becoming su): user@B:<mpl_path>$ su user@B:<mpl_path># python setup.py install X11 connection rejected because of wrong authentication. The application 'setup.py' lost its connection to the display localhost:10.0; most likely the X server was shut down or you killed/destroyed the application. > I usually install > as suso: do you have sudo setup? Basically, you need to be able to > make sure you can launch an X11 app (eg xterm) in the environment that > you are running matplotlib install. Right, I can't open an X app on B via sudo or beeing su. Unfortunalelly I don't understand enough of the X-permission/xhost stuff to get this right :) > Perhaps some UNIX guru can give the proper incantation. He did. Finally I logged in as root (ssh -X root@B) and then everthing went fine. ================================================================================================ Additionally, if you want to install directly on A or B (not beeing logged in via ssh) just open a root terminal and install as usual. sudo and su won't do it. cheers, steve -- Random number generation is the art of producing pure gibberish as quickly as possible. |
From: Steve S. <el...@gm...> - 2006-02-22 12:01:14
|
Darren Dale wrote: > Hi Steve, > > On Tuesday 21 February 2006 13:00, Steve Schmerler wrote: > >>1) Trying to export an .eps with using usetex = True: >> >>rcParams['text.usetex']=True; plot([1,2,3]); savefig("image.eps") >> >>I get an .eps where the axis numbers (are they called so?) are missing >>(looks like a bounding box problem). Only the axes and what's inside the >>plot box is there. > > > What mpl version are you using, and have you tried setting > verbose=debug-annoying in your rc settings to see if any of the usetex > external dependencies are complaining about anything? > I'm using 0.86.2 (from sourceforge). This script -------------------------------------- from pylab import * from matplotlib import verbose, use use('GTKAgg') verbose.level = 'debug-annoying' rcParams['text.usetex']=True plot([1,2,3]) savefig("image.eps") -------------------------------------- produces --------------------------------------------------------------------------- schmerler@bach:~$ python test.py FigureCanvasAgg.print_figure FigureCanvasAgg.draw RendererAgg.__init__ RendererAgg._get_agg_font findfont failed Lucida Grande findfont failed Verdana findfont failed Geneva findfont failed Lucida findfont found Bitstream Vera Sans, normal, normal 500, normal, 12.0 findfont returning /usr/lib/python2.3/site-packages/matplotlib/mpl-data/Vera.ttf RendererAgg.points_to_pixels RendererAgg.points_to_pixels RendererAgg._get_agg_font RendererAgg.points_to_pixels RendererAgg.points_to_pixels RendererAgg._get_agg_font RendererAgg.points_to_pixels RendererAgg.points_to_pixels RendererAgg._get_agg_font RendererAgg._get_agg_font RendererAgg._get_agg_font RendererAgg.points_to_pixels RendererAgg.points_to_pixels RendererAgg._get_agg_font RendererAgg.points_to_pixels RendererAgg.points_to_pixels RendererAgg._get_agg_font RendererAgg.points_to_pixels RendererAgg.points_to_pixels RendererAgg._get_agg_font RendererAgg._get_agg_font matplotlib data path /usr/lib/python2.3/site-packages/matplotlib/mpl-data latex -interaction=nonstopmode "/tmp/15f8552d172b5a41c557b4ad371e3782.tex" This is e-TeX, Version 3.14159-2.1 (Web2C 7.4.5) entering extended mode (/tmp/15f8552d172b5a41c557b4ad371e3782.tex LaTeX2e <2001/06/01> Babel <v3.7h> and hyphenation patterns for american, french, german, ngerman, b ahasa, basque, catalan, croatian, czech, danish, dutch, finnish, greek, iceland ic, irish, italian, latin, magyar, norsk, norsk, portuges, romanian, russian, s lovak, slovene, spanish, swedish, turkish, ukrainian, nohyphenation, loaded. (/usr/share/texmf/tex/latex/koma-script/scrartcl.cls Document Class: scrartcl 2003/01/31 v2.9n LaTeX2e KOMA document class (/usr/share/texmf/tex/latex/koma-script/scrlfile.sty Package scrlfile, 2003/01/31 v2.9n LaTeX2e KOMA package Copyright (C) Markus Kohm ) (/usr/share/texmf/tex/latex/base/size11.clo) (/usr/share/texmf/tex/latex/koma-script/typearea.sty Package typearea, 2003/01/31 v2.9n LaTeX2e KOMA package Copyright (C) Frank Neukam, 1992-1994 Copyright (C) Markus Kohm, 1994-2002 )) (/usr/share/texmf/tex/latex/misc/type1cm.sty) (/usr/share/texmf/tex/latex/misc/psfrag.sty (/usr/share/texmf/tex/latex/graphics/graphics.sty (/usr/share/texmf/tex/latex/graphics/trig.sty) (/usr/share/texmf/tex/latex/config/graphics.cfg) (/usr/share/texmf/tex/latex/graphics/dvips.def))) (/usr/share/texmf/tex/latex/graphics/graphicx.sty (/usr/share/texmf/tex/latex/graphics/keyval.sty)) (/usr/share/texmf/tex/latex/graphics/color.sty (/usr/share/texmf/tex/latex/config/color.cfg) (/usr/share/texmf/tex/latex/graphics/dvipsnam.def)) No file 15f8552d172b5a41c557b4ad371e3782.aux. <15f8552d172b5a41c557b4ad371e3782.eps> [1] (./15f8552d172b5a41c557b4ad371e3782.aux) ) Output written on 15f8552d172b5a41c557b4ad371e3782.dvi (1 page, 2352 bytes). Transcript written on 15f8552d172b5a41c557b4ad371e3782.log. dvips -R -T 12.750000in,18.030000in -o "/tmp/15f8552d172b5a41c557b4ad371e3782.ps" "/tmp/15f8552d172b5a41c557b4ad371e3782.dvi" This is dvips(k) 5.92b Copyright 2002 Radical Eye Software (www.radicaleye.com) ' TeX output 2006.02.22:1254' -> /tmp/15f8552d172b5a41c557b4ad371e3782.ps <texc.pro><psfrag.pro><f7b6d320.enc><texps.pro><special.pro><color.pro>. <cmr10.pfb>[1<15f8552d172b5a41c557b4ad371e3782.eps>] gs -dBATCH -dNOPAUSE -dSAFER -r6000 -sDEVICE=epswrite -dLanguageLevel=2 -dEPSFitPage -sOutputFile="/tmp/15f8552d172b5a41c557b4ad371e3782.eps" "/tmp/15f8552d172b5a41c557b4ad371e3782.ps" GPL Ghostscript 8.01 (2004-01-30) Copyright (C) 2004 artofcode LLC, Benicia, CA. All rights reserved. This software comes with NO WARRANTY: see the file PUBLIC for details. --------------------------------------------------------------------------- It complains about not finding some Agg fonts, could this be it?? Trying to export an .ps rather than an .eps produces a .ps where everything is visible but the image is a whole A4 page. >>2) Exporting .svg fails > > > There is no svg support for the usetex option. Oh too bad, would have been nice. cheers, steve -- Random number generation is the art of producing pure gibberish as quickly as possible. |
From: Eric F. <ef...@ha...> - 2006-02-22 08:31:14
|
Ray, You tripped over a bug in cm.py: when I added masked array support, I put the "x = ma.asarray(x)" too early in the to_rgba() method of ScalarMappable. It is fixed now in CVS. Thanks for finding the problem. If you want to try the fix in your version, in place of your workaround, here is the revised method: def to_rgba(self, x, alpha=1.0): # assume normalized rgb, rgba if len(x.shape)>2: return x x = ma.asarray(x) x = self.norm(x) x = self.cmap(x, alpha) return x Eric Thouis (Ray) Jones wrote: > Greetings, > > I searched the mail archive for information on this question, and > didn't find anything. Hopefully this hasn't been addressed elsewhere. > > I just spent a few hours tracking down a huge performance hit in > imshow(). I'm loading some image data via numarray's fromfile(), > stacking three imgaes to make an RGB, and showing it with imshow. > > My image loading code looks like this: > > def read_dib(filename): > f = open(filename, "rb") > fromfile(f, "UInt8", shape=(52, 1)) > im = fromfile(f, "UInt16", shape=(512, 512)) > if sys.byteorder == "big": > im.byteswap() > return im.astype('Float') / (2**12 - 1) > > I load three images, and put them into a NxMx3 float numarray, and > pass that to imshow. > > The performance drop is at this line in image.py: > im = _image.fromarray(x, 0) > > in AxesImage.make_image() > > I eventually tracked it down to x's type being <class > 'numarray.ma.MA.MaskedArray'>, which gets passed off to numarray's > NA_InputArray function, which chokes and calls setArrayFromSequence > (i.e., it's not using the fact that the input data is a numarray, and > is instead iterating over each element). This is taking around 30 > seconds to convert a 512x512x3 image on a new Intel iMac. > > I sped it up significantly by using this line instead: > > im = _image.fromarray(numerix.ma.filled(x,0), 0) > > Not that that's a good idea (but it works for me for now). > > There is no invalid data in my image. I'm not sure why it's ever > being turned into a masked array. > > I'm using matplotlib 0.86.2 and numarray-1.5.1, on OS X 10.3.5 on an Intel iMac. > > Any advice would be appreciated. > > Thanks, > Ray Jones > > > ------------------------------------------------------- > This SF.net email is sponsored by: Splunk Inc. Do you grep through log files > for problems? Stop! Download the new AJAX search engine that makes > searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! > http://sel.as-us.falkag.net/sel?cmd=k&kid3432&bid#0486&dat1642 > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users |
From: Darren D. <dd...@co...> - 2006-02-21 22:11:06
|
Hi Steve, On Tuesday 21 February 2006 13:00, Steve Schmerler wrote: > 1) Trying to export an .eps with using usetex = True: > > rcParams['text.usetex']=True; plot([1,2,3]); savefig("image.eps") > > I get an .eps where the axis numbers (are they called so?) are missing > (looks like a bounding box problem). Only the axes and what's inside the > plot box is there. What mpl version are you using, and have you tried setting verbose=debug-annoying in your rc settings to see if any of the usetex external dependencies are complaining about anything? > 2) Exporting .svg fails There is no svg support for the usetex option. Darren |
From: Thouis (R. J. <th...@cs...> - 2006-02-21 22:04:37
|
Greetings, I searched the mail archive for information on this question, and didn't find anything. Hopefully this hasn't been addressed elsewhere. I just spent a few hours tracking down a huge performance hit in imshow(). I'm loading some image data via numarray's fromfile(), stacking three imgaes to make an RGB, and showing it with imshow. My image loading code looks like this: def read_dib(filename): f =3D open(filename, "rb") fromfile(f, "UInt8", shape=3D(52, 1)) im =3D fromfile(f, "UInt16", shape=3D(512, 512)) if sys.byteorder =3D=3D "big": =09im.byteswap() return im.astype('Float') / (2**12 - 1) I load three images, and put them into a NxMx3 float numarray, and pass that to imshow. The performance drop is at this line in image.py: im =3D _image.fromarray(x, 0) in AxesImage.make_image() I eventually tracked it down to x's type being <class 'numarray.ma.MA.MaskedArray'>, which gets passed off to numarray's NA_InputArray function, which chokes and calls setArrayFromSequence (i.e., it's not using the fact that the input data is a numarray, and is instead iterating over each element). This is taking around 30 seconds to convert a 512x512x3 image on a new Intel iMac. I sped it up significantly by using this line instead: im =3D _image.fromarray(numerix.ma.filled(x,0), 0) Not that that's a good idea (but it works for me for now). There is no invalid data in my image. I'm not sure why it's ever being turned into a masked array. I'm using matplotlib 0.86.2 and numarray-1.5.1, on OS X 10.3.5 on an Intel = iMac. Any advice would be appreciated. Thanks, Ray Jones |
From: Charlie M. <cw...@gm...> - 2006-02-21 20:43:27
|
The latest release of matplotlib was built against numpy 0.9.4.=20 Hopefully we will have a release soon to match up with the latest numpy. On 2/21/06, Gary <pa...@in...> wrote: > John Hunter wrote: > > > > > Humufr> This morning I install the cvs version of matplotlib and > > Humufr> numpy and now I have a segfault when numpy is the > > Humufr> numerical package define in matplotlibrc. It's seems to > > Humufr> work fine with numarray. > > > >Make sure you have a clean install of both packages (rm -rf build > >subdir in both and reinstall) and if you still get the segfault post a > >minimum script run with --verbose-helpful ; this will give us the exact > >version numbers of both the matplotlib and numpy packages. > > > >JDH > > > > > > > > I just updated numpy to the latest version: 0.9.5, from the Windows > binary installer. I have MPL 0.86.2, also binary installer. > > import pylab crashes python > import matplotlib is ok > backing up to numpy 0.9.4 works ok. > does this issue belong to a numpy list? > > > How exactly does one run a script with --verbose-helpful ? This does > not seem to be a valid python switch. > > Here are the last lines prior to crash of > python -v test.py > where test.py contains one line: import pylab > > import matplotlib.axes # precompiled from > c:\python24\lib\site-packages\matplotl > ib\axes.pyc > # c:\python24\lib\site-packages\matplotlib\artist.pyc matches > c:\python24\lib\si > te-packages\matplotlib\artist.py > import matplotlib.artist # precompiled from > c:\python24\lib\site-packages\matplo > tlib\artist.pyc > # c:\python24\lib\site-packages\matplotlib\transforms.pyc matches > c:\python24\li > b\site-packages\matplotlib\transforms.py > import matplotlib.transforms # precompiled from > c:\python24\lib\site-packages\ma > tplotlib\transforms.pyc > # c:\python24\lib\site-packages\matplotlib\_transforms.pyc matches > c:\python24\l > ib\site-packages\matplotlib\_transforms.py > import matplotlib._transforms # precompiled from > c:\python24\lib\site-packages\m > atplotlib\_transforms.pyc > > > -gary > > > ------------------------------------------------------- > This SF.net email is sponsored by: Splunk Inc. Do you grep through log fi= les > for problems? Stop! Download the new AJAX search engine that makes > searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! > http://sel.as-us.falkag.net/sel?cmd=3Dlnk&kid=3D103432&bid=3D230486&dat= =3D121642 > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > |
From: Christopher B. <Chr...@no...> - 2006-02-21 20:14:34
|
John Hunter wrote: > This is an annoyance that is caused by the fact that the GTK install > needs an X11 connection, Is it really necessary to import GTK when installing MPL? why? I think getting rid of that requirement would be the best fix. >Basically, you need to be able to > make sure you can launch an X11 app (eg xterm) in the environment that > you are running matplotlib install. > > Perhaps some UNIX guru can give the proper incantation. I've done it, but I'm not sure I remember how at the moment. But try something like: xhost +root or even: xhost + which I think lets anyone have access to the Xserver. -Chris -- Christopher Barker, Ph.D. Oceanographer NOAA/OR&R/HAZMAT (206) 526-6959 voice 7600 Sand Point Way NE (206) 526-6329 fax Seattle, WA 98115 (206) 526-6317 main reception Chr...@no... |
From: John H. <jdh...@ac...> - 2006-02-21 19:46:21
|
>>>>> "Jason" == Jason C Leach <jas...@gm...> writes: Jason> hi, I'm having trouble figuring out how to add a few more Jason> layers to a stacked bar graph. What I have so far is: Jason> p1 = axes.bar(ind, data['n'], width, color='r') p2 Jason> = axes.bar(ind, data['l'], width, color='y', Jason> bottom=data['n']) p3 = axes.bar(ind, data['m'], width, Jason> color='b', bottom=data['l']) p4 = axes.bar(ind, data['h'], Jason> width, color='g', bottom=data['m']) Jason> But I don't think this is correct. I only get two layers Jason> (red and green). Does anyone know the proper method? See examples/table_demo.py -- you need to keep a cumulative sum of the bottom positions, eg yoff = array([0.0] * len(colLabels)) # the bottom values for stacked bar chart for row in xrange(rows): bar(ind, data[row], width, bottom=yoff, color=colours[row]) yoff = yoff + data[row] cellText.append(['%1.1f' % (x/1000.0) for x in yoff]) JDH |
From: Jason C. L. <jas...@gm...> - 2006-02-21 19:40:06
|
hi, I'm having trouble figuring out how to add a few more layers to a stacked bar graph. What I have so far is: p1 =3D axes.bar(ind, data['n'], width, color=3D'r') p2 =3D axes.bar(ind, data['l'], width, color=3D'y', bottom=3Ddata['= n']) p3 =3D axes.bar(ind, data['m'], width, color=3D'b', bottom=3Ddata['= l']) p4 =3D axes.bar(ind, data['h'], width, color=3D'g', bottom=3Ddata['= m']) But I don't think this is correct. I only get two layers (red and green). Does anyone know the proper method? Thanks, Jason. -- ........................................ .... Jason C. Leach .... PGP Key: 0x62DDDF75 .... Keyserver: gpg.mit.edu |
From: Gary <pa...@in...> - 2006-02-21 18:20:52
|
John Hunter wrote: > > Humufr> This morning I install the cvs version of matplotlib and > Humufr> numpy and now I have a segfault when numpy is the > Humufr> numerical package define in matplotlibrc. It's seems to > Humufr> work fine with numarray. > >Make sure you have a clean install of both packages (rm -rf build >subdir in both and reinstall) and if you still get the segfault post a >minimum script run with --verbose-helpful ; this will give us the exact >version numbers of both the matplotlib and numpy packages. > >JDH > > > I just updated numpy to the latest version: 0.9.5, from the Windows binary installer. I have MPL 0.86.2, also binary installer. import pylab crashes python import matplotlib is ok backing up to numpy 0.9.4 works ok. does this issue belong to a numpy list? How exactly does one run a script with --verbose-helpful ? This does not seem to be a valid python switch. Here are the last lines prior to crash of python -v test.py where test.py contains one line: import pylab import matplotlib.axes # precompiled from c:\python24\lib\site-packages\matplotl ib\axes.pyc # c:\python24\lib\site-packages\matplotlib\artist.pyc matches c:\python24\lib\si te-packages\matplotlib\artist.py import matplotlib.artist # precompiled from c:\python24\lib\site-packages\matplo tlib\artist.pyc # c:\python24\lib\site-packages\matplotlib\transforms.pyc matches c:\python24\li b\site-packages\matplotlib\transforms.py import matplotlib.transforms # precompiled from c:\python24\lib\site-packages\ma tplotlib\transforms.pyc # c:\python24\lib\site-packages\matplotlib\_transforms.pyc matches c:\python24\l ib\site-packages\matplotlib\_transforms.py import matplotlib._transforms # precompiled from c:\python24\lib\site-packages\m atplotlib\_transforms.pyc -gary |
From: Steve S. <el...@gm...> - 2006-02-21 18:00:28
|
1) Trying to export an .eps with using usetex = True: rcParams['text.usetex']=True; plot([1,2,3]); savefig("image.eps") I get an .eps where the axis numbers (are they called so?) are missing (looks like a bounding box problem). Only the axes and what's inside the plot box is there. 2) Exporting .svg fails: In [9]: rcParams['text.usetex']=True; plot([1,2,3]); savefig("image.svg") Out[9]: [<matplotlib.lines.Line2D instance at 0xb61d202c>] --------------------------------------------------------------------------- exceptions.NotImplementedError Traceback (most recent call last) /home/schmerler/<console> /usr/lib/python2.3/site-packages/matplotlib/pylab.py in savefig(*args, **kwargs) 813 def savefig(*args, **kwargs): 814 fig = gcf() --> 815 return fig.savefig(*args, **kwargs) 816 if Figure.savefig.__doc__ is not None: 817 savefig.__doc__ = _shift_string(Figure.savefig.__doc__) /usr/lib/python2.3/site-packages/matplotlib/figure.py in savefig(self, *args, **kwargs) 647 kwargs[key] = rcParams['savefig.%s'%key] 648 --> 649 self.canvas.print_figure(*args, **kwargs) 650 651 def colorbar(self, mappable, cax=None, /usr/lib/python2.3/site-packages/matplotlib/backends/backend_gtkagg.py in print_figure(self, filename, dpi, facecolor, edgecolor, orientation) 109 agg = self.switch_backends(FigureCanvasAgg) 110 try: --> 111 agg.print_figure(filename, dpi, facecolor, edgecolor, orientation) 112 except IOError, msg: 113 error_msg_gtk('Failed to save\nError message: %s'%(msg,), self) /usr/lib/python2.3/site-packages/matplotlib/backends/backend_agg.py in print_figure(self, filename, dpi, facecolor, edgecolor, orientation) 473 from backend_svg import FigureCanvasSVG 474 svg = self.switch_backends(FigureCanvasSVG) --> 475 svg.print_figure(filename, dpi, facecolor, edgecolor, orientation) 476 elif ext.find('ps')>=0 or ext.find('ep')>=0: 477 from backend_ps import FigureCanvasPS # lazy import /usr/lib/python2.3/site-packages/matplotlib/backends/backend_svg.py in print_figure(self, filename, dpi, facecolor, edgecolor, orientation) 282 svgwriter = codecs.open( filename, 'w', 'utf-8' ) 283 renderer = RendererSVG(w, h, svgwriter) --> 284 self.figure.draw(renderer) 285 renderer.finish() 286 /usr/lib/python2.3/site-packages/matplotlib/figure.py in draw(self, renderer) 522 523 # render the axes --> 524 for a in self.axes: a.draw(renderer) 525 526 # render the figure text /usr/lib/python2.3/site-packages/matplotlib/axes.py in draw(self, renderer, inframe) 1436 if not self._axisbelow: 1437 if self.axison and not inframe: -> 1438 self.xaxis.draw(renderer) 1439 self.yaxis.draw(renderer) 1440 /usr/lib/python2.3/site-packages/matplotlib/axis.py in draw(self, renderer, *args, **kwargs) 560 tick.set_label1(label) 561 tick.set_label2(label) --> 562 tick.draw(renderer) 563 if tick.label1On: 564 extent = tick.label1.get_window_extent(renderer) /usr/lib/python2.3/site-packages/matplotlib/axis.py in draw(self, renderer) 159 if self.tick2On: self.tick2line.draw(renderer) 160 --> 161 if self.label1On: self.label1.draw(renderer) 162 if self.label2On: self.label2.draw(renderer) 163 /usr/lib/python2.3/site-packages/matplotlib/text.py in draw(self, renderer) 856 if not self.get_visible(): return 857 self.update_coords(renderer) --> 858 self._mytext.draw(renderer) 859 #bbox_artist(self._mytext, renderer, props={'pad':0}, fill=False) 860 if self.get_dashlength() > 0.0: /usr/lib/python2.3/site-packages/matplotlib/text.py in draw(self, renderer) 346 347 renderer.draw_tex(gc, x, y, line, --> 348 self._fontproperties, angle) 349 return 350 /usr/lib/python2.3/site-packages/matplotlib/backend_bases.py in draw_tex(self, gc, x, y, s, prop, angle, ismath) 320 321 def draw_tex(self, gc, x, y, s, prop, angle, ismath='TeX!'): --> 322 raise NotImplementedError 323 324 def draw_text(self, gc, x, y, s, prop, angle, ismath=False): NotImplementedError: cheers, steve -- Random number generation is the art of producing pure gibberish as quickly as possible. |
From: Julius L. <jul...@gm...> - 2006-02-21 16:54:58
|
For the benefit of the list, below is a working script that makes a simple plot with a patch element, outputs the plot to a png, and outputs an html file that contains an image map so that the patch element is clickable. Thanks for all the help, Julius #!/usr/bin/env python from pylab import * dots =3D 150 fig =3D figure(num=3D1,figsize=3D(6,4),dpi=3Ddots,facecolor=3D'w') ax =3D fig.add_subplot(111) pl =3D ax.plot(range(0,10),range(0,10),'b-') box =3D ax.axvspan(3,6,fc=3D'm',alpha=3D0.5) fig.savefig('test.png',dpi=3Ddots) img_height =3D fig.get_figheight() * dots b_verts =3D box.get_verts() #image maps use left-x,left-y,right-x,right-y verts =3D [(b_verts[1][0],b_verts[1][1]),(b_verts[3][0],b_verts[3][1])] tverts =3D box.get_transform().seq_xy_tups(verts) #image maps have y=3D0 on top tverts =3D (tverts[0][0],img_height-tverts[0][1],tverts[1][0],img_height-tv= erts[1][1]) file =3D open('test.html','w') file.write('''<HTML> <HEAD> <TITLE>Image Map Test</TITLE> </HEAD> <BODY> <map name=3D"map"> <area shape=3D"rect" coords=3D"%d,%d,%d,%d" href=3D"http://www.google.com= "> </map> <img border=3D2 src=3D"./test.png" usemap=3D"#map"> </BODY> </HTML> ''' % tverts ) file.close() |
From: John H. <jdh...@ac...> - 2006-02-21 15:56:14
|
>>>>> "Humufr" == Humufr <hu...@ya...> writes: Humufr> This morning I install the cvs version of matplotlib and Humufr> numpy and now I have a segfault when numpy is the Humufr> numerical package define in matplotlibrc. It's seems to Humufr> work fine with numarray. Make sure you have a clean install of both packages (rm -rf build subdir in both and reinstall) and if you still get the segfault post a minimum script run with --verbose-helpful ; this will give us the exact version numbers of both the matplotlib and numpy packages. JDH |
From: Humufr <hu...@ya...> - 2006-02-21 15:08:40
|
This morning I install the cvs version of matplotlib and numpy and now I have a segfault when numpy is the numerical package define in matplotlibrc. It's seems to work fine with numarray. |
From: John H. <jdh...@ac...> - 2006-02-21 14:51:07
|
>>>>> "Julius" == Julius Lucks <jul...@gm...> writes: Julius> my question is what transform do I use to convert verts to Julius> pixel coordinates? ax.get_transform() does not work. Julius> Should I use pl.get_transform? "Does not work" is not very descriptive :-( Yes, you should use the polygon transform You might want to look at the "draw" method of the matplotlib.patches.Polygon class to see how it gets the data into pixel coords verts = self.get_verts() tverts = self._transform.seq_xy_tups(verts) Thus all you need to do outside the class is trans = pl.get_transform() verts = pl.get_verts() tverts = trans.seq_xy_tups(verts) Should work... The documentation for the matplotlib.transforms module is decent, if you want to take a look http://matplotlib.sourceforge.net/matplotlib.transforms.html JDH |
From: John H. <jdh...@ac...> - 2006-02-21 14:46:20
|
>>>>> "Stephen" == Stephen English <st...@se...> writes: Stephen> All, I am trying to render a set of data/date points with Stephen> plot_date. How can I get matplotlib to only plot the y Stephen> axis of this graph? I can turn both off with axis("off"), Stephen> but I can't seem to find more detailed instructions Stephen> anywhere. Also, although this is unimportant, it grates You have to make the individual elements invisible. Something like for label in ax.get_xticklabels(): label.set_visible(False) For more refined control, for each tick there are a host of visibility properties you can set gridOn : a boolean which determines whether to draw the tickline tick1On : a boolean which determines whether to draw the 1st tickline tick2On : a boolean which determines whether to draw the 2nd tickline label1On : a boolean which determines whether to draw tick label label2On : a boolean which determines whether to draw tick label for tick in ax.xaxis.get_major_ticks(): tick.tick2On = False and likewise for the minor ticks Stephen> somewhat to use matplotlib with the procedural (matlab Stephen> esque) instructions within my OO python code. Are there Stephen> any tutorials or other docs on plotting graphs through Stephen> the more pythonic libraries? As the code above illustrates, matplotlib is an OO library. There is no requirement to use it through the procedural pylab interface. Most of my personal use, except for quick scripts and interactive sessions, is OO. See this FAQ http://matplotlib.sourceforge.net/faq.html#OO and this tutorial http://matplotlib.sourceforge.net/leftwich_tut.txt A nice hybrid approach is to use a minimum of pylab for figure management only, and do everything else through OO import matplotlib.numerix as nx from pylab import figure, close, show # all you need x = nx.arange(0, 2.0, 0.01) y = nx.sin(2*nx.pi*x) fig1 = figure(1) fig2 = figure(2) ax1 = fig1.add_subplot(211) ax1.plot(x,y) ax1.set_xlabel('time (s)') ax1.set_ylabel('volts') ax1.set_title('a sinusoid') ax1.grid(True) # and more with fig2, etc.... show() Most of the action is in the Axes instance, and too a lesser extent the Figure and Axis instances, so see the class documentation for the figure, axes, and axis methods http://matplotlib.sourceforge.net/classdocs.html Hope this helps, JDH |
From: John H. <jdh...@ac...> - 2006-02-21 14:33:35
|
>>>>> "Steve" == Steve Schmerler <el...@gm...> writes: Steve> ------------------------------------------------------------------------ Steve> elcorto@ramrod:~/Install/Matplotlib/matplotlib-0.86.2$ sudo Steve> python setup.py install installing data to Steve> lib/python2.3/site-packages/matplotlib/mpl-data pygtk Steve> present but import failed Using default library and include Steve> directories for Tcl and Tk because a Tk window failed to Steve> open. You may need to define DISPLAY for Tk to work so Steve> that setup can determine where your libraries are located. Steve> Gtk-WARNING **: cannot open display: Steve> ------------------------------------------------------------------------ This is an annoyance that is caused by the fact that the GTK install needs an X11 connection, and in some setups when you install as root the root user does not have access to your display. I usually install as suso: do you have sudo setup? Basically, you need to be able to make sure you can launch an X11 app (eg xterm) in the environment that you are running matplotlib install. Perhaps some UNIX guru can give the proper incantation. In addition to setting the DISPLAY as root, you may need to check your xhost settings. JDH |
From: John H. <jdh...@ac...> - 2006-02-21 14:28:01
|
>>>>> "Tom" == Tom Denniston <tom...@al...> writes: Tom> I am generating a few hundred graphs and doing so takes on Tom> the order of about 10-15 minutes. Which seems to me rather Tom> slow. When I profile my code it identifies the calls to Tom> get_yticklabels and get_xticklabels as taking over 90% of the Tom> time. This seems strange but my calls to these functions are Tom> merely a sort round about way of setting the font size of the Tom> axis tick labels and suppressing the text for the Tom> xticklabels. Is there a more efficient and cleaner way to do Tom> this? artist.setp(axes.get_yticklabels(), visible=True, Tom> fontsize=7) artist.setp(axes.get_xticklabels(), Tom> visible=False) This is a known performance bottleneck. There are two reasons it is slow. Every tick label is handled as an independent object, when they in most cases share most of their properties (font size, orientation) and so could be better handled as a TextCollection, which does not exist yet. The second reason is that the text layout engine is doing layout for newline separated strings with an arbitrary rotation for every tick label, which is almost never used. So some special case optimizations to handle the no rotation, no newline text instances (basically just bypass the layout machinery) would help a lot here. Are you using matplotlib mathtext also, by chance? This slows things down a bit too, though is better in recent versions. JDH |
From: George N. <ag...@no...> - 2006-02-21 11:45:00
|
I've had various versions of matplotlib from CVS installed on an Opteron (Red Hat LInux) here for a few weeks now. I had to modify setupext.py to look for various libraries in ../lib64 instead of /lib but matplotlib works very nicely most of the time, and I have started using it for real work. One cosmetic problem: the buttons at the bottom of the plot window have their graphics messed up. They just look like red crosses. The floating xml works, so I know what the buttons do, and it doesn't inconvenience me --- but it looks bad. Presumably some library is either out of date, incomplete, or not linked correctly. I am using the default TkAgg backend. Any thoughts on what I should look for would be appreciated. BTW the matplotlib users_guide_0.83.2.pdf seems to be unreadable from my Mac. It appears blank in (Tiger) Safari, and preview cannot open the file: it gives 'File error'. Regards, George Nurser. |
From: Jeff P. <jef...@ya...> - 2006-02-21 05:09:28
|
Hi thanks for the help. I have a related problem. i had been using py2exe with matplotlib and it was working well. upgraded to 0.86 and now it doesn't work. I know this is because the installation directory is different now (no longer the share folder). So I thought I fixed it correctly but I get an error that indicates py2exe "can't find lib/site-packages/matplotlib/backends or it is not a regular file". I am assuming that it doesn't like 'backends' because it is a folder and not a file. I changed my setup code to this: data_files=[ ("matplotlibdata", glob.glob(os.path.join(distutils.sysconfig.PREFIX, 'lib', 'site-packages','matplotlib', "*")))] setup( options = options, # The lib directory contains everything except the executables and the python dll. windows = [app], data_files = data_files, # use out build_installer class as extended py2exe build command cmdclass = {"py2exe": build_installer}, ) how might I change this to get it working properly? thanks!! Jeff Charlie Moad <cw...@gm...> wrote: Recently the matplotlib data files have been moved into the matplotlib module. You should be able to safely remove share/matplotlib. On 2/19/06, Jeff Peery wrote: > hello, I just upgraded from 0.84 to 0.86 on windows xp. I noticed that I > have a couple different locations on my computere where it is installed. > there is something in the python24/share and also > python24/Lib/site-packages/ > > what do I gotta do to make sure I am using the newest version. can I just > delete all the matplot lib folders and reinstall the newest version? > > thakns! > > > ________________________________ > Yahoo! Mail > Use Photomail to share photos without annoying attachments. > > --------------------------------- What are the most popular cars? Find out at Yahoo! Autos |
From: Julius L. <jul...@gm...> - 2006-02-20 23:01:14
|
On 2/15/06, John Hunter <jdh...@ac...> wrote: > >>>>> "Charlie" =3D=3D Charlie Moad <cw...@gm...> writes: > > Charlie> You could use html image maps to accomplish this. > Charlie> Obviously this would be in the context of a web page. I > Charlie> think frontpage or dreamweaver has some nice tools for > Charlie> creating these. Just google "html image maps" for more > Charlie> info. > > Andrew Dalke has a tutorial on creating html image maps with > matplotlib > > http://www.dalkescientific.com/writings/diary/archive/2005/04/24/interact= ive_html.html > > JDH > This tutorial was a start. I want to do a similar thing, but use rectangle objects for the image map, whose coordinates are derived from matplotlib polygon objects. I was wondering if anyone knew how to do this, or could point me to some documentation. Basically I have a simple figure: > from pylab import * clf() fig =3D figure(1,(4,4)) ax =3D axis() pl =3D plot(range(0,10),range(0,10),'b-') box =3D axvspan(3,5,fc=3D'm',alpha=3D0.5) #get vertices [(ul.x,ul.y),(lr.x,lr.y)] #ul =3D upper left #lr =3D lower right #have to multiply ul.y by the upper ylim since for axvspan, ul.y=3D1 spans the range b_verts =3D box.get_verts() verts =3D [(b_verts[1][0],b_verts[1][1]*ax.get_ylim()[1]),(b_verts[3][0],b_= verts[3][1])] > my question is what transform do I use to convert verts to pixel coordinate= s? ax.get_transform() does not work. Should I use pl.get_transform? Thanks for your help! Cheers, Julius |
From: Stephen E. <st...@se...> - 2006-02-20 09:18:51
|
All, I am trying to render a set of data/date points with plot_date. How can I get matplotlib to only plot the y axis of this graph? I can turn both off with axis("off"), but I can't seem to find more detailed instructions anywhere. Also, although this is unimportant, it grates somewhat to use matplotlib with the procedural (matlab esque) instructions within my OO python code. Are there any tutorials or other docs on plotting graphs through the more pythonic libraries? Many thanks, Stephen English |