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
|
From: Thomas C. <tca...@gm...> - 2015-06-01 02:34:24
|
Please keep discussion on the list. That warning means some thing is importing pyplot before your file. You need to make sure that you use `matplotlib.use` before anything in your process import `pyplot`. You may need to change your `matplotlibrc` file. Tom On Sun, May 31, 2015, 00:30 Peter Rowat <pe...@pe...> wrote: > My file starts: > import numpy as np > import matplotlib > matplotlib.use('TKAgg') > import matplotlib.pyplot as plt > import matplotlib.animation as animation > > > and the animation works, with blit=False, but with this message: > ====== > /System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/matplotlib/__init__.py:1155: > UserWarning: This call to matplotlib.use() has no effect > because the backend has already been chosen; > matplotlib.use() must be called *before* pylab, matplotlib.pyplot, > or matplotlib.backends is imported for the first time. > > warnings.warn(_use_error_msg) > ======= > So I can live with this, but seems there is something not quite right > about the __init__.py code > Should I use a different backed than the OS X backend? > > — Peter > > On May 30, 2015, at 8:43 PM, Thomas Caswell <tca...@gm...> wrote: > > Blitting not working for the osx backend is a long standing issue due to > differences between what is allowed in the different gui frame works. > > You have to change the backend via `use` before you import pyplot. If you > are still getting the error it is likely you tried to change the backend > _after_ pyplot was imported, in which case the `use` command does nothing. > > Tom > > On Sat, May 30, 2015 at 11:03 PM Peter Rowat <pe...@pe...> > wrote: > >> I’m on OS X, trying to write a multi-slider-controlled animation. If I >> have blit=True in the call to matplotlib.animation, >> I get this message >> >> matplotlib.animation.BackendError: The current backend is 'MacOSX' >> and may go into an infinite loop with blit turned on. Either >> turn off blit or use an alternate backend, for example, like >> 'TKAgg', using the following prepended to your source code: >> >> import matplotlib >> matplotlib.use('TKAgg’) >> ===== >> >> When I make this change I still get the same error message, whether blit >> is set True or False. >> At least when blit=False the animation runs, which I can live with for >> the moment. >> >> ------------------------------------------------------------------------------ >> _______________________________________________ >> Matplotlib-users mailing list >> Mat...@li... >> https://lists.sourceforge.net/lists/listinfo/matplotlib-users >> > > |
From: Thomas C. <tca...@gm...> - 2015-05-31 03:43:36
|
Blitting not working for the osx backend is a long standing issue due to differences between what is allowed in the different gui frame works. You have to change the backend via `use` before you import pyplot. If you are still getting the error it is likely you tried to change the backend _after_ pyplot was imported, in which case the `use` command does nothing. Tom On Sat, May 30, 2015 at 11:03 PM Peter Rowat <pe...@pe...> wrote: > I’m on OS X, trying to write a multi-slider-controlled animation. If I > have blit=True in the call to matplotlib.animation, > I get this message > > matplotlib.animation.BackendError: The current backend is 'MacOSX' > and may go into an infinite loop with blit turned on. Either > turn off blit or use an alternate backend, for example, like > 'TKAgg', using the following prepended to your source code: > > import matplotlib > matplotlib.use('TKAgg’) > ===== > > When I make this change I still get the same error message, whether blit > is set True or False. > At least when blit=False the animation runs, which I can live with for the > moment. > > ------------------------------------------------------------------------------ > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > |
From: Peter R. <pe...@pe...> - 2015-05-31 03:01:01
|
I’m on OS X, trying to write a multi-slider-controlled animation. If I have blit=True in the call to matplotlib.animation, I get this message matplotlib.animation.BackendError: The current backend is 'MacOSX' and may go into an infinite loop with blit turned on. Either turn off blit or use an alternate backend, for example, like 'TKAgg', using the following prepended to your source code: import matplotlib matplotlib.use('TKAgg’) ===== When I make this change I still get the same error message, whether blit is set True or False. At least when blit=False the animation runs, which I can live with for the moment. |
From: Prahas D. N. <pra...@gm...> - 2015-05-31 01:49:32
|
Hello, My latest fractal music video, made with MatPlotLib. Enjoy! --Prahas https://www.youtube.com/watch?v=kh6ZLvpWr5k&feature=youtu.be |
From: Joy m. m. <joy...@gm...> - 2015-05-31 00:48:21
|
You could define the overlay data for the whole length and mask out the irrelevant part using numpy.ma. You could also just plot the two parts separately using the appropriate length of the x coordinate. Xa = range (1,10) Xb = range (100, 110) plot (Xa, data1) plot (Xb, data2) On 31 May 2015 00:42, "peter" <com...@ya...> wrote: > hi, > > > ive got a graph which should be overlayed with something, but the > overlay graph isnt defined for all x > values. > > for example, overlay goes from x=1 to 1=10, then pauses for 100 and then > continues with 10 values. > how do you do that? > > > greetings > > > ------------------------------------------------------------------------------ > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > |
From: peter <com...@ya...> - 2015-05-30 19:10:32
|
hi, ive got a graph which should be overlayed with something, but the overlay graph isnt defined for all x values. for example, overlay goes from x=1 to 1=10, then pauses for 100 and then continues with 10 values. how do you do that? greetings |
From: Thomas C. <tca...@gm...> - 2015-05-30 16:04:55
|
Jan, Please keep discussions on the list. See below for forwarded email ---------- Forwarded message --------- From: Albrecht, Jan <Jan...@en...> Date: Tue, May 26, 2015 at 2:58 AM Subject: AW: [Matplotlib-users] Error on gridspec.py To: Thomas Caswell <tca...@gm...> Dear Thomas, sorry for the last slapdashed E-Mail. I am using Python-Version 2.6.2 . This version is necessary, because I work additional with the finite element simulation program ABAQUSTM. The examples I wanted to test are from the matplot website. Installed packages : MatPlot: matplotlib-1.4.3 Numpy 1.6.2 PIL 1.1.7 Dateutil 1.4.1 Six 1.9.0 Pyparsing 2.0.3 I hope this will help to help me. Mit freundlichen Grüßen/ kind regards *Jan Albrecht* Micro Materials Center Chemnitz at Fraunhofer Institute for Electronic Nano Systems (ENAS) Technologie Campus 3 09126 Chemnitz Tel: 0371 / 45001 424 Fax: 0371 / 45001 524 Email: jan...@en... http://www.enas.fraunhofer.de/de/Abteilungen/MMC.html ____________________________________________________________________ Diese E-Mail kann Betriebs- und Geschäftsgeheimnisse, dem Anwaltsgeheimnis unterliegende oder sonstige vertrauliche Informationen enthalten. Sollten Sie diese E-Mail irrtümlich erhalten haben, ist Ihnen die Kenntnisnahme des Inhalts, eine Vervielfältigung oder Weitergabe der E-Mail ausdrücklich untersagt. Bitte benachrichtigen Sie den Absender der E-Mail und vernichten die empfangene E-Mail. Vielen Dank. Since this e-mail contains confidential information, it must be treated with utmost confidentiality. Any person who may get in contact with this information by mistake should not take any notice of the topic and should not pass on or duplicate any part of this information. The e-mail has to be destroyed and the sender of the e-mail has to be informed immediately. Thank you. *Von:* Thomas Caswell [mailto:tca...@gm...] *Gesendet:* Sonntag, 24. Mai 2015 19:45 *An:* Albrecht, Jan; mat...@li... *Betreff:* Re: [Matplotlib-users] Error on gridspec.py Jan, If you subscribe to the user list you will be able to post with out moderation. Can you point us to which example you are running? From what you have sent is is very hard to sort out what is going wrong as we have to guess what you are doing. Tom On Sun, May 24, 2015 at 1:38 PM Albrecht, Jan < Jan...@en...> wrote: Hi dear all, I have installed matplot and also six.py and so on. If i start an example from matplot i get the following eror message: File "C:\Python26\lib\site-packages\matplotlib\pyplot.py", line 1087, in subplots ax0 = fig.add_subplot(gs[0, 0], **subplot_kw) File "C:\Python26\lib\site-packages\matplotlib\figure.py", line 964, in add_subplot a = subplot_class_factory(projection_class)(self, *args, **kwargs) File "C:\Python26\lib\site-packages\matplotlib\axes\_subplots.py", line 75, in __init__ self.update_params() File "C:\Python26\lib\site-packages\matplotlib\axes\_subplots.py", line 115, in update_params return_all=True) File "C:\Python26\lib\site-packages\matplotlib\gridspec.py", line 425, in get_position gridspec.get_grid_positions(fig) File "C:\Python26\lib\site-packages\matplotlib\gridspec.py", line 86, in get_grid_positions subplot_params = self.get_subplot_params(fig) File "C:\Python26\lib\site-packages\matplotlib\gridspec.py", line 271, in get_subplot_params subplotpars.update(**update_kw) TypeError: update() keywords must be strings Maybe someone can help me, thanks a lot JAn ------------------------------------------------------------------------------ One dashboard for servers and applications across Physical-Virtual-Cloud Widest out-of-the-box monitoring support with 50+ applications Performance metrics, stats and reports that give you Actionable Insights Deep dive visibility with transaction tracing using APM Insight. http://ad.doubleclick.net/ddm/clk/290420510;117567292;y _______________________________________________ Matplotlib-users mailing list Mat...@li... https://lists.sourceforge.net/lists/listinfo/matplotlib-users |
From: cph <ch...@pr...> - 2015-05-30 05:18:42
|
I fixed this problem by including the following line in my source code file: from matplotlib.backends import backend_tkagg -- View this message in context: http://matplotlib.1069221.n5.nabble.com/cx-freeze-ing-tp41780p45639.html Sent from the matplotlib - users mailing list archive at Nabble.com. |
From: Paul H. <pmh...@gm...> - 2015-05-29 15:50:33
|
imshow is for displaying arrays as images/rasters. plot is for showing data/functions as points and lines. See the gallery for imshow: http://matplotlib.org/gallery.html#images_contours_and_fields On Fri, May 29, 2015 at 4:12 AM, Amit Saha <ami...@gm...> wrote: > Hi all, > > I am trying to understand if there is a way to compare how plot() and > imshow() works for the case where I am not using imshow() to display > an image. > > Via the plot() function, I am specifying the points that I want to > plot and also optionally the color that i want the points to be in. > For example, plot([1, 2, 3], [2, 3, 4], 'ro') will create a plot with > those points colored "red". Via the imshow() function, we specify the > color (or intensity) of each point and a figure is created with the > points colored accordingly. Sure, imshow() allows me to color each > point differently. > > Is there a way to relate them? > > Also asked on StackOverflow: > http://stackoverflow.com/questions/30527811/plot-and-imshow-relationship > > Thanks, > Amit. > > > -- > http://echorand.me > > > ------------------------------------------------------------------------------ > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > |
From: Bryan W. <bry...@gm...> - 2015-05-29 12:55:07
|
It seems like it is a conflict of libraries...I've zeroed in to these two errors: /usr/include/unistd.h:496:75: error: conflicting declaration of C function 'void swab(const void*, void*, ssize_t)' and /usr/include/stdlib.h:144:13: note: previous declaration 'void swab(const char*, char*, ssize_t)' I executed a find command and here's what came up: ~>sudo find / -name stdlib.h */opt/csw/include/c++/4.9.2/tr1/stdlib.h* /opt/solarisstudio12.4/lib/compilers/include/CC/gnu/stdlib.h /opt/solarisstudio12.4/lib/compilers/include/CC/stlport4/stdlib.h /opt/solarisstudio12.4/lib/compilers/CC-gcc/include/c++/4.8.2/tr1/stdlib.h */usr/include/stdlib.h* >From what it seems, it's calling stdlib.h from the /usr/include folder when it should be calling it from /opt/csw/include. I'm going to look into setup.cfg (that or perhaps hack setup.py) and see if it's at all possible to change it so that it looks in the right one, and then I'll try building it again. On Thu, May 28, 2015 at 1:50 PM, Eric Firing <ef...@ha...> wrote: > On 2015/05/28 3:13 AM, Bryan Williams wrote: > > I have gcc on the box. I also installed the C compiler for Solaris (cc), > > but I couldn't seem to find an option to switch it so that it uses cc > > rather than gcc. > > Maybe you can do this with an environment variable? > > export CC=/usr/bin/cc > > It does look like there is a problem with scrambled environments. The > redefinition warning looks potentially troublesome; and the error looks > like a conflict between two versions of the standard C library. > > From "man swab" on Solaris: > > NAME > swab - swap bytes > > SYNOPSIS > #include <stdlib.h> > > void swab(const char *src, char *dest, ssize_t nbytes); > > XPG4, SUS, SUSv2, SUSv3 > #include <unistd.h> > > void swab(const void *restrict src, void *restrict dest, > ssize_t nbytes); > > I think you want the second version, consistently, but something is also > hitting the first version. > > Maybe "XPG4" or one of the other 4 options needs to be defined when each > library is compiled with /usr/bin/cc? I think the stdlib declaration is > old; the unistd version is more modern. > > That's all very vague, I know. Obviously, I don't actually know how to > solve the problem. > > Eric > > > > > ------------------------------------------------------------------------------ > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > |
From: Amit S. <ami...@gm...> - 2015-05-29 11:12:55
|
Hi all, I am trying to understand if there is a way to compare how plot() and imshow() works for the case where I am not using imshow() to display an image. Via the plot() function, I am specifying the points that I want to plot and also optionally the color that i want the points to be in. For example, plot([1, 2, 3], [2, 3, 4], 'ro') will create a plot with those points colored "red". Via the imshow() function, we specify the color (or intensity) of each point and a figure is created with the points colored accordingly. Sure, imshow() allows me to color each point differently. Is there a way to relate them? Also asked on StackOverflow: http://stackoverflow.com/questions/30527811/plot-and-imshow-relationship Thanks, Amit. -- http://echorand.me |
From: Thomas C. <tca...@gm...> - 2015-05-28 20:02:41
|
How to do that is dependent on which gui frame work you are using and may be globally controlled at the desktop environment level. Tom On Thu, May 28, 2015, 12:13 Blingo <pet...@ho...> wrote: > Hi there > > Just want to disable the X at the top right. It's the default frame used by > matplotlib when plotting. > Windows. > > Thanks > > Peter > > > > -- > View this message in context: > http://matplotlib.1069221.n5.nabble.com/Disable-the-Close-Button-from-the-plot-dialogue-tp45633.html > Sent from the matplotlib - users mailing list archive at Nabble.com. > > > ------------------------------------------------------------------------------ > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > |
From: Eric F. <ef...@ha...> - 2015-05-28 17:50:56
|
On 2015/05/28 3:13 AM, Bryan Williams wrote: > I have gcc on the box. I also installed the C compiler for Solaris (cc), > but I couldn't seem to find an option to switch it so that it uses cc > rather than gcc. Maybe you can do this with an environment variable? export CC=/usr/bin/cc It does look like there is a problem with scrambled environments. The redefinition warning looks potentially troublesome; and the error looks like a conflict between two versions of the standard C library. From "man swab" on Solaris: NAME swab - swap bytes SYNOPSIS #include <stdlib.h> void swab(const char *src, char *dest, ssize_t nbytes); XPG4, SUS, SUSv2, SUSv3 #include <unistd.h> void swab(const void *restrict src, void *restrict dest, ssize_t nbytes); I think you want the second version, consistently, but something is also hitting the first version. Maybe "XPG4" or one of the other 4 options needs to be defined when each library is compiled with /usr/bin/cc? I think the stdlib declaration is old; the unistd version is more modern. That's all very vague, I know. Obviously, I don't actually know how to solve the problem. Eric |
From: Blingo <pet...@ho...> - 2015-05-28 16:12:38
|
Hi there Just want to disable the X at the top right. It's the default frame used by matplotlib when plotting. Windows. Thanks Peter -- View this message in context: http://matplotlib.1069221.n5.nabble.com/Disable-the-Close-Button-from-the-plot-dialogue-tp45633.html Sent from the matplotlib - users mailing list archive at Nabble.com. |
From: Thomas C. <tca...@gm...> - 2015-05-28 13:55:05
|
I think there is on open bug about compilation failures on Solaris which we never sorted out due to not having access to a test machine. On Thu, May 28, 2015, 09:13 Bryan Williams <bry...@gm...> wrote: > Thanks to the both of you. > > First off, apologies for getting back to you several days late. I was out > of town for the holiday weekend, and I didn't get a chance to work on this > for the last two days as I had other business to tend to on Tuesday, and > was out of the office all day Wednesday. > > I tried to install from the master build on Github, and it seemed to run > fine, until I ended up with this error (and verbose details, text wall > incoming): > > > ============================================================================ > Edit setup.cfg to change the build options > > BUILDING MATPLOTLIB > matplotlib: yes [1.5.dev1] > python: yes [3.4.3 (default, May 15 2015, 13:52:23) [GCC > 4.9.2]] > platform: yes [sunos5] > > REQUIRED DEPENDENCIES AND EXTENSIONS > numpy: yes [version 1.9.2] > six: yes [using six version 1.9.0] > dateutil: yes [using dateutil version 2.4.2] > pytz: yes [using pytz version 2015.4] > tornado: yes [tornado was not found. It is required for the > WebAgg backend. pip/easy_install may attempt to > install it after matplotlib.] > pyparsing: yes [using pyparsing version 2.0.3] > libagg: yes [pkg-config information for 'libagg' could not > be found. Using local copy.] > freetype: yes [version 2.4.8] > png: yes [version 1.2.35] > qhull: yes [pkg-config information for 'qhull' could not > be > found. Using local copy.] > > OPTIONAL SUBPACKAGES > sample_data: yes [installing] > toolkits: yes [installing] > tests: yes [using nose version 1.3.6 / using > unittest.mock] > toolkits_tests: yes [using nose version 1.3.6 / using > unittest.mock] > > OPTIONAL BACKEND EXTENSIONS > macosx: no [Mac OS-X only] > qt5agg: no [PyQt5 not found] > qt4agg: no [PySide not found; PyQt4 not found] > gtk3agg: no [Requires pygobject to be installed.] > gtk3cairo: no [Requires cairocffi or pycairo to be > installed.] > gtkagg: no [Requires pygtk] > tkagg: yes [installing, version not identified] > wxagg: no [requires wxPython] > gtk: no [Requires pygtk] > agg: yes [installing] > cairo: no [cairocffi or pycairo not found] > windowing: no [Microsoft Windows only] > > OPTIONAL LATEX DEPENDENCIES > dvipng: no > ghostscript: no > latex: no > pdftops: no > > running build > running build_py > copying lib/matplotlib/mpl-data/matplotlibrc -> > build/lib.solaris-2.10-sun4v.32bit-3.4/matplotlib/mpl-data > running build_ext > building 'matplotlib.ft2font' extension > gcc -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -fPIC > -DPY_ARRAY_UNIQUE_SYMBOL=MPL_matplotlib_ft2font_ARRAY_API > -DNPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION > -I/usr/local/lib/python3.4/site-packages/numpy/core/include > -I/usr/local/include -I/usr/local/include/freetype2 -I/usr/local/include > -I. -I/usr/local/include/python3.4m -c src/ft2font.cpp -o > build/temp.solaris-2.10-sun4v.32bit-3.4/src/ft2font.o > In file included from /usr/local/include/python3.4m/Python.h:8:0, > from src/mplutils.h:21, > from src/ft2font.cpp:8: > /usr/local/include/python3.4m/pyconfig.h:1387:0: warning: > "_FILE_OFFSET_BITS" redefined > #define _FILE_OFFSET_BITS 64 > ^ > In file included from > /opt/csw/lib/gcc/sparc-sun-solaris2.10/4.9.2/include-fixed/wchar.h:20:0, > from /opt/csw/include/c++/4.9.2/cwchar:44, > from /opt/csw/include/c++/4.9.2/bits/postypes.h:40, > from /opt/csw/include/c++/4.9.2/bits/char_traits.h:40, > from /opt/csw/include/c++/4.9.2/string:40, > from src/ft2font.cpp:5: > /opt/csw/lib/gcc/sparc-sun-solaris2.10/4.9.2/include-fixed/sys/feature_tests.h:196:0: > note: this is the location of the previous definition > #define _FILE_OFFSET_BITS 32 > ^ > gcc -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -fPIC > -DPY_ARRAY_UNIQUE_SYMBOL=MPL_matplotlib_ft2font_ARRAY_API > -DNPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION > -I/usr/local/lib/python3.4/site-packages/numpy/core/include > -I/usr/local/include -I/usr/local/include/freetype2 -I/usr/local/include > -I. -I/usr/local/include/python3.4m -c src/ft2font_wrapper.cpp -o > build/temp.solaris-2.10-sun4v.32bit-3.4/src/ft2font_wrapper.o > In file included from /usr/local/include/python3.4m/Python.h:8:0, > from src/mplutils.h:21, > from src/ft2font_wrapper.cpp:1: > /usr/local/include/python3.4m/pyconfig.h:1387:0: warning: > "_FILE_OFFSET_BITS" redefined > #define _FILE_OFFSET_BITS 64 > ^ > In file included from /usr/include/sys/int_types.h:34:0, > from /usr/include/sys/stdint.h:17, > from /usr/include/stdint.h:17, > from > /opt/csw/lib/gcc/sparc-sun-solaris2.10/4.9.2/include/stdint.h:9, > from src/mplutils.h:11, > from src/ft2font_wrapper.cpp:1: > /opt/csw/lib/gcc/sparc-sun-solaris2.10/4.9.2/include-fixed/sys/feature_tests.h:196:0: > note: this is the location of the previous definition > #define _FILE_OFFSET_BITS 32 > ^ > In file included from /usr/local/include/python3.4m/Python.h:36:0, > from src/mplutils.h:21, > from src/ft2font_wrapper.cpp:1: > /usr/include/unistd.h:496:75: error: conflicting declaration of C function > 'void swab(const void*, void*, ssize_t)' > extern void swab(const void *_RESTRICT_KYWD, void *_RESTRICT_KYWD, > ssize_t); > > ^ > In file included from /usr/local/include/python3.4m/Python.h:34:0, > from src/mplutils.h:21, > from src/ft2font_wrapper.cpp:1: > /usr/include/stdlib.h:144:13: note: previous declaration 'void swab(const > char*, char*, ssize_t)' > extern void swab(const char *, char *, ssize_t); > ^ > error: command 'gcc' failed with exit status 1 > > > I have gcc on the box. I also installed the C compiler for Solaris (cc), > but I couldn't seem to find an option to switch it so that it uses cc > rather than gcc. > > Thanks again for all you do, and thanks for the help. > > -- BMW > > On Sun, May 24, 2015 at 2:05 PM, Thomas Caswell <tca...@gm...> > wrote: > >> Bryan, >> >> If you subscribe to the list you will be able to post with out moderation. >> >> Does this happen with any of the other sample data? >> >> I don't think that `get_sample_data` is doing you any good here as you >> are passing it an absolute path (from `os.getcwd()`) which is passed into >> `os.path.join` which when it encounters and absolute path discards >> everything to the left so that line is just returning back your input. >> >> Does it work to open any other png or does _only_ this png have issues? >> >> You are reaching into the nominally private parts of the mpl api here, I >> would suggest using `mpl.image.imread` instead. >> >> It might be worth using something like PIL/pillow, imread ( >> https://pypi.python.org/pypi/imread), imageio (https://imageio.github.io/) >> or scikit-image for alternate implementations of png readers. >> >> None of the core developers have access to a Solaris machine so it is >> very difficult for us to provide much better help on this. >> >> Tom >> >> On Sun, May 24, 2015 at 1:38 PM Bryan Williams < >> bry...@gm...> wrote: >> >>> Good afternoon, >>> >>> >>> >>> My name is Bryan Williams. I work for the Florida Forest Service in >>> their Forest Logistics and Support Bureau. >>> >>> >>> >>> I’m working on a program that takes weather data and visualizes it using >>> matplotlib and Basemap. I’m currently having an issue with matplotlib 1.4.3 >>> for Python 3.4.3 running under Solaris 5.10. I am getting a Runtime Error >>> whenever I try calling the read_png file from matplotlib._png. (I’m using >>> this to add a small .png file of the Forest Service’s sheld to the >>> picture). The error is the following: >>> >>> >>> >>> Traceback (most recent call last): >>> >>> File "drawmaps.py", line 845, in <module> >>> >>> arr_lena = read_png(fn) >>> >>> RuntimeError: Error closing dupe file handle >>> >>> >>> >>> I don’t quite understand the error I’m getting, and as you can see, the >>> traceback gives very little information. I also tried Google for help, but >>> to no avail; entering the error message as is into Google doesn’t return >>> anything relating to the problem, and putting quotes around “Error closing >>> dupe file handle” yields about 10 results, with one of them being an >>> unanswered question from 2014 regarding the same issue. >>> >>> >>> >>> As per your request on the website, here’s what I get from uname –a: >>> >>> >>> >>> SunOS [server name withheld] 5.10 Generic_141444-09 sun4v sparc >>> SUNW,SPARC-Enterprise-T5220 >>> >>> >>> >>> I built Python 3.4.3 from source and installed matplotlib through pip, >>> and didn’t make any changes to the matplotlibrc file. >>> >>> >>> >>> I was able to reproduce the problem again running these commands in the >>> Python interactive prompt, which emulates the snippet of script that causes >>> the error: >>> >>> >>> >>> Python 3.4.3 (default, May 15 2015, 13:52:23) >>> >>> [GCC 4.9.2] on sunos5 >>> >>> Type "help", "copyright", "credits" or "license" for more information. >>> >>> >>> from matplotlib._png import read_png >>> >>> >>> from matplotlib.cbook import get_sample_data >>> >>> >>> import os; path=os.getcwd() >>> >>> >>> fn = get_sample_data(path + '/resources/shield.png', asfileobj=False) >>> >>> >>> arr_lena = read_png(fn) >>> >>> Traceback (most recent call last): >>> >>> File "<stdin>", line 1, in <module> >>> >>> RuntimeError: Error closing dupe file handle >>> >>> >>> >>> >>> >>> If you’d like a copy of the problem script, please let me know. Any and >>> all help is greatly appreciated. >>> >>> >>> >>> Thank you in advance! >>> >>> >>> >>> -- BMW >>> >>> ------------------------------------------------------------------------------ >>> One dashboard for servers and applications across Physical-Virtual-Cloud >>> Widest out-of-the-box monitoring support with 50+ applications >>> Performance metrics, stats and reports that give you Actionable Insights >>> Deep dive visibility with transaction tracing using APM Insight. >>> http://ad.doubleclick.net/ddm/clk/290420510;117567292;y >>> _______________________________________________ >>> Matplotlib-users mailing list >>> Mat...@li... >>> https://lists.sourceforge.net/lists/listinfo/matplotlib-users >>> >> > |
From: Bryan W. <bry...@gm...> - 2015-05-28 13:13:40
|
Thanks to the both of you. First off, apologies for getting back to you several days late. I was out of town for the holiday weekend, and I didn't get a chance to work on this for the last two days as I had other business to tend to on Tuesday, and was out of the office all day Wednesday. I tried to install from the master build on Github, and it seemed to run fine, until I ended up with this error (and verbose details, text wall incoming): ============================================================================ Edit setup.cfg to change the build options BUILDING MATPLOTLIB matplotlib: yes [1.5.dev1] python: yes [3.4.3 (default, May 15 2015, 13:52:23) [GCC 4.9.2]] platform: yes [sunos5] REQUIRED DEPENDENCIES AND EXTENSIONS numpy: yes [version 1.9.2] six: yes [using six version 1.9.0] dateutil: yes [using dateutil version 2.4.2] pytz: yes [using pytz version 2015.4] tornado: yes [tornado was not found. It is required for the WebAgg backend. pip/easy_install may attempt to install it after matplotlib.] pyparsing: yes [using pyparsing version 2.0.3] libagg: yes [pkg-config information for 'libagg' could not be found. Using local copy.] freetype: yes [version 2.4.8] png: yes [version 1.2.35] qhull: yes [pkg-config information for 'qhull' could not be found. Using local copy.] OPTIONAL SUBPACKAGES sample_data: yes [installing] toolkits: yes [installing] tests: yes [using nose version 1.3.6 / using unittest.mock] toolkits_tests: yes [using nose version 1.3.6 / using unittest.mock] OPTIONAL BACKEND EXTENSIONS macosx: no [Mac OS-X only] qt5agg: no [PyQt5 not found] qt4agg: no [PySide not found; PyQt4 not found] gtk3agg: no [Requires pygobject to be installed.] gtk3cairo: no [Requires cairocffi or pycairo to be installed.] gtkagg: no [Requires pygtk] tkagg: yes [installing, version not identified] wxagg: no [requires wxPython] gtk: no [Requires pygtk] agg: yes [installing] cairo: no [cairocffi or pycairo not found] windowing: no [Microsoft Windows only] OPTIONAL LATEX DEPENDENCIES dvipng: no ghostscript: no latex: no pdftops: no running build running build_py copying lib/matplotlib/mpl-data/matplotlibrc -> build/lib.solaris-2.10-sun4v.32bit-3.4/matplotlib/mpl-data running build_ext building 'matplotlib.ft2font' extension gcc -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -DPY_ARRAY_UNIQUE_SYMBOL=MPL_matplotlib_ft2font_ARRAY_API -DNPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION -I/usr/local/lib/python3.4/site-packages/numpy/core/include -I/usr/local/include -I/usr/local/include/freetype2 -I/usr/local/include -I. -I/usr/local/include/python3.4m -c src/ft2font.cpp -o build/temp.solaris-2.10-sun4v.32bit-3.4/src/ft2font.o In file included from /usr/local/include/python3.4m/Python.h:8:0, from src/mplutils.h:21, from src/ft2font.cpp:8: /usr/local/include/python3.4m/pyconfig.h:1387:0: warning: "_FILE_OFFSET_BITS" redefined #define _FILE_OFFSET_BITS 64 ^ In file included from /opt/csw/lib/gcc/sparc-sun-solaris2.10/4.9.2/include-fixed/wchar.h:20:0, from /opt/csw/include/c++/4.9.2/cwchar:44, from /opt/csw/include/c++/4.9.2/bits/postypes.h:40, from /opt/csw/include/c++/4.9.2/bits/char_traits.h:40, from /opt/csw/include/c++/4.9.2/string:40, from src/ft2font.cpp:5: /opt/csw/lib/gcc/sparc-sun-solaris2.10/4.9.2/include-fixed/sys/feature_tests.h:196:0: note: this is the location of the previous definition #define _FILE_OFFSET_BITS 32 ^ gcc -Wno-unused-result -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -DPY_ARRAY_UNIQUE_SYMBOL=MPL_matplotlib_ft2font_ARRAY_API -DNPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION -I/usr/local/lib/python3.4/site-packages/numpy/core/include -I/usr/local/include -I/usr/local/include/freetype2 -I/usr/local/include -I. -I/usr/local/include/python3.4m -c src/ft2font_wrapper.cpp -o build/temp.solaris-2.10-sun4v.32bit-3.4/src/ft2font_wrapper.o In file included from /usr/local/include/python3.4m/Python.h:8:0, from src/mplutils.h:21, from src/ft2font_wrapper.cpp:1: /usr/local/include/python3.4m/pyconfig.h:1387:0: warning: "_FILE_OFFSET_BITS" redefined #define _FILE_OFFSET_BITS 64 ^ In file included from /usr/include/sys/int_types.h:34:0, from /usr/include/sys/stdint.h:17, from /usr/include/stdint.h:17, from /opt/csw/lib/gcc/sparc-sun-solaris2.10/4.9.2/include/stdint.h:9, from src/mplutils.h:11, from src/ft2font_wrapper.cpp:1: /opt/csw/lib/gcc/sparc-sun-solaris2.10/4.9.2/include-fixed/sys/feature_tests.h:196:0: note: this is the location of the previous definition #define _FILE_OFFSET_BITS 32 ^ In file included from /usr/local/include/python3.4m/Python.h:36:0, from src/mplutils.h:21, from src/ft2font_wrapper.cpp:1: /usr/include/unistd.h:496:75: error: conflicting declaration of C function 'void swab(const void*, void*, ssize_t)' extern void swab(const void *_RESTRICT_KYWD, void *_RESTRICT_KYWD, ssize_t); ^ In file included from /usr/local/include/python3.4m/Python.h:34:0, from src/mplutils.h:21, from src/ft2font_wrapper.cpp:1: /usr/include/stdlib.h:144:13: note: previous declaration 'void swab(const char*, char*, ssize_t)' extern void swab(const char *, char *, ssize_t); ^ error: command 'gcc' failed with exit status 1 I have gcc on the box. I also installed the C compiler for Solaris (cc), but I couldn't seem to find an option to switch it so that it uses cc rather than gcc. Thanks again for all you do, and thanks for the help. -- BMW On Sun, May 24, 2015 at 2:05 PM, Thomas Caswell <tca...@gm...> wrote: > Bryan, > > If you subscribe to the list you will be able to post with out moderation. > > Does this happen with any of the other sample data? > > I don't think that `get_sample_data` is doing you any good here as you are > passing it an absolute path (from `os.getcwd()`) which is passed into > `os.path.join` which when it encounters and absolute path discards > everything to the left so that line is just returning back your input. > > Does it work to open any other png or does _only_ this png have issues? > > You are reaching into the nominally private parts of the mpl api here, I > would suggest using `mpl.image.imread` instead. > > It might be worth using something like PIL/pillow, imread ( > https://pypi.python.org/pypi/imread), imageio (https://imageio.github.io/) > or scikit-image for alternate implementations of png readers. > > None of the core developers have access to a Solaris machine so it is very > difficult for us to provide much better help on this. > > Tom > > On Sun, May 24, 2015 at 1:38 PM Bryan Williams < > bry...@gm...> wrote: > >> Good afternoon, >> >> >> >> My name is Bryan Williams. I work for the Florida Forest Service in their >> Forest Logistics and Support Bureau. >> >> >> >> I’m working on a program that takes weather data and visualizes it using >> matplotlib and Basemap. I’m currently having an issue with matplotlib 1.4.3 >> for Python 3.4.3 running under Solaris 5.10. I am getting a Runtime Error >> whenever I try calling the read_png file from matplotlib._png. (I’m using >> this to add a small .png file of the Forest Service’s sheld to the >> picture). The error is the following: >> >> >> >> Traceback (most recent call last): >> >> File "drawmaps.py", line 845, in <module> >> >> arr_lena = read_png(fn) >> >> RuntimeError: Error closing dupe file handle >> >> >> >> I don’t quite understand the error I’m getting, and as you can see, the >> traceback gives very little information. I also tried Google for help, but >> to no avail; entering the error message as is into Google doesn’t return >> anything relating to the problem, and putting quotes around “Error closing >> dupe file handle” yields about 10 results, with one of them being an >> unanswered question from 2014 regarding the same issue. >> >> >> >> As per your request on the website, here’s what I get from uname –a: >> >> >> >> SunOS [server name withheld] 5.10 Generic_141444-09 sun4v sparc >> SUNW,SPARC-Enterprise-T5220 >> >> >> >> I built Python 3.4.3 from source and installed matplotlib through pip, >> and didn’t make any changes to the matplotlibrc file. >> >> >> >> I was able to reproduce the problem again running these commands in the >> Python interactive prompt, which emulates the snippet of script that causes >> the error: >> >> >> >> Python 3.4.3 (default, May 15 2015, 13:52:23) >> >> [GCC 4.9.2] on sunos5 >> >> Type "help", "copyright", "credits" or "license" for more information. >> >> >>> from matplotlib._png import read_png >> >> >>> from matplotlib.cbook import get_sample_data >> >> >>> import os; path=os.getcwd() >> >> >>> fn = get_sample_data(path + '/resources/shield.png', asfileobj=False) >> >> >>> arr_lena = read_png(fn) >> >> Traceback (most recent call last): >> >> File "<stdin>", line 1, in <module> >> >> RuntimeError: Error closing dupe file handle >> >> >> >> >> >> If you’d like a copy of the problem script, please let me know. Any and >> all help is greatly appreciated. >> >> >> >> Thank you in advance! >> >> >> >> -- BMW >> >> ------------------------------------------------------------------------------ >> One dashboard for servers and applications across Physical-Virtual-Cloud >> Widest out-of-the-box monitoring support with 50+ applications >> Performance metrics, stats and reports that give you Actionable Insights >> Deep dive visibility with transaction tracing using APM Insight. >> http://ad.doubleclick.net/ddm/clk/290420510;117567292;y >> _______________________________________________ >> Matplotlib-users mailing list >> Mat...@li... >> https://lists.sourceforge.net/lists/listinfo/matplotlib-users >> > |
From: David <dh...@ra...> - 2015-05-27 15:45:56
|
To clarify, this fixes the memory leak issue. -- View this message in context: http://matplotlib.1069221.n5.nabble.com/matplotlib-backends-backend-gtk3cairo-memory-leak-tp45614p45629.html Sent from the matplotlib - users mailing list archive at Nabble.com. |
From: David <dh...@ra...> - 2015-05-27 15:45:11
|
>IGtk3Agg should work in you use cairocffi instead of py(2/3)cairo. AFAIK py(2/3)cairo is more or less > unmaintained these days and that function has never been implemented in a > released version. Yes you're right. This does work. However you need to do the following steps: Run: pip install cairocffi Copy: C:\Python34\Lib\site-packages\gnome\libcairo-gobject-2.dll to C:\Python34 Rename: libcairo-gobject-2.dll to libcairo-2.dll Then in the python code, change the back-ends line to: from matplotlib.backends.backend_gtk3agg import FigureCanvasGTK3Agg as FigureCanvas Incidentally, if you're trying the script, modify the line from the first script example I sent -- the second has a horrible threads issue (due to the missing call to threads_init). Regards David -- View this message in context: http://matplotlib.1069221.n5.nabble.com/matplotlib-backends-backend-gtk3cairo-memory-leak-tp45614p45628.html Sent from the matplotlib - users mailing list archive at Nabble.com. |
From: Eric F. <ef...@ha...> - 2015-05-26 19:55:23
|
On 2015/05/26 9:10 AM, Benjamin Root wrote: > I think this is a feature/bug that got reverted in the master branch. > Perhaps you could try building matplotlib from source and seeing if the > problem goes away? Ben, it looks familiar, and related to a bizarre feature that I thought we had eliminated--but I just tried it with master, and it's still there. Maybe the change is still languishing in an open PR. Sean, I think you are understandably misunderstanding the confusing annotation API. ax.annotate( r"$\mathbf{" + label + ")}$", xy=(0.9, 0.9), xycoords="axes fraction", fontsize=14 ) If you change your annotation call to the simpler version above, I think it will do what you intended. Eric > > Cheers! > Ben Root > > On Tue, May 26, 2015 at 3:00 PM, Sean Lake <ody...@gm... > <mailto:ody...@gm...>> wrote: > > Sterling, > > Thanks for the pointer. I've already used a workaround where I used > "data" coordinates and put it at: > 0.9 * (xmax - xmin) + xmin, and similar for y. > > I'm really only reporting this so that it can be fixed if there is > someone who does need to annotate something in a grid. > > Sean > > > On May 26, 2015, at 11:54, Sterling Smith <sm...@fu... > <mailto:sm...@fu...>> wrote: > > > > Sean, > > > > Do you need an `annotate`, or just a `text`? `text` has the > `transform` keyword, to which you can pass `ax.transAxes`. > > > > ax.text(.9,.9, r"$\mathbf{" + lab + > ")}$”,transform=ax.transAxes,ha=‘right’,va=‘center’) > > > > -Sterling > > > > On May 26, 2015, at 10:06AM, Sean Lake <ody...@gm... > <mailto:ody...@gm...>> wrote: > > > >> Hello all, > >> > >> I'm using matplotlib 1.4.3 installed using fink with python 2.7. > >> > >> I'm trying to produce a grid of plots using gridspec that has > annotations to label each plot. > >> > >> Here is the call to annotate the current axes: > >> ax.annotate( r"$\mathbf{" + lab + ")}$", > >> xy=(0.5*(xmin+xmax), 0.5*(ymin+ymax)), > >> xytext=(0.9, 0.9), > >> textcoords="axes fraction", fontsize=14 ) > >> > >> Where ax is initialized by: > >> ax = plt.subplot(gs[ coords[0], coords[1] ]) > >> > >> and gs by: > >> gs = mpgs.GridSpec( 3, 2, wspace=0.0, hspace=0.0 ) > >> > >> The trouble comes in when abs(ymax) < abs(ymin). When that is > true, the labels are offset upward by one row, for some reason. > >> > >> I've attached a script that demonstrates the problem, and an > example of the output. I can work around this problem by using > "data" coordinates, but even so this reveals a bug somewhere. > >> > >> Thanks, > >> Sean Lake > >> > >> > <BugDemo.py><BugDemo.pdf>------------------------------------------------------------------------------ > >> One dashboard for servers and applications across > Physical-Virtual-Cloud > >> Widest out-of-the-box monitoring support with 50+ applications > >> Performance metrics, stats and reports that give you Actionable > Insights > >> Deep dive visibility with transaction tracing using APM Insight. > >> > http://ad.doubleclick.net/ddm/clk/290420510;117567292;y_______________________________________________ > >> Matplotlib-users mailing list > >> Mat...@li... > <mailto:Mat...@li...> > >> https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > > > > ------------------------------------------------------------------------------ > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > <mailto:Mat...@li...> > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > > > > ------------------------------------------------------------------------------ > > > > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > |
From: Sterling S. <sm...@fu...> - 2015-05-26 19:32:28
|
Sean, Do you need an `annotate`, or just a `text`? `text` has the `transform` keyword, to which you can pass `ax.transAxes`. ax.text(.9,.9, r"$\mathbf{" + lab + ")}$”,transform=ax.transAxes,ha=‘right’,va=‘center’) -Sterling On May 26, 2015, at 10:06AM, Sean Lake <ody...@gm...> wrote: > Hello all, > > I'm using matplotlib 1.4.3 installed using fink with python 2.7. > > I'm trying to produce a grid of plots using gridspec that has annotations to label each plot. > > Here is the call to annotate the current axes: > ax.annotate( r"$\mathbf{" + lab + ")}$", > xy=(0.5*(xmin+xmax), 0.5*(ymin+ymax)), > xytext=(0.9, 0.9), > textcoords="axes fraction", fontsize=14 ) > > Where ax is initialized by: > ax = plt.subplot(gs[ coords[0], coords[1] ]) > > and gs by: > gs = mpgs.GridSpec( 3, 2, wspace=0.0, hspace=0.0 ) > > The trouble comes in when abs(ymax) < abs(ymin). When that is true, the labels are offset upward by one row, for some reason. > > I've attached a script that demonstrates the problem, and an example of the output. I can work around this problem by using "data" coordinates, but even so this reveals a bug somewhere. > > Thanks, > Sean Lake > > <BugDemo.py><BugDemo.pdf>------------------------------------------------------------------------------ > One dashboard for servers and applications across Physical-Virtual-Cloud > Widest out-of-the-box monitoring support with 50+ applications > Performance metrics, stats and reports that give you Actionable Insights > Deep dive visibility with transaction tracing using APM Insight. > http://ad.doubleclick.net/ddm/clk/290420510;117567292;y_______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users |
From: Neal B. <ndb...@gm...> - 2015-05-26 19:25:15
|
I'm plotting 1 figure with 8 subplots. They are 8 channels, and I want to see if there is some interaction. I wish that the 'configure subplots' menu allowed me to choose just some subplots to display (resizing when I turn some off), so I could get a better view at the selected subplots. -- Those who fail to understand recursion are doomed to repeat it |
From: Benjamin R. <ben...@ou...> - 2015-05-26 19:10:36
|
I think this is a feature/bug that got reverted in the master branch. Perhaps you could try building matplotlib from source and seeing if the problem goes away? Cheers! Ben Root On Tue, May 26, 2015 at 3:00 PM, Sean Lake <ody...@gm...> wrote: > Sterling, > > Thanks for the pointer. I've already used a workaround where I used "data" > coordinates and put it at: > 0.9 * (xmax - xmin) + xmin, and similar for y. > > I'm really only reporting this so that it can be fixed if there is someone > who does need to annotate something in a grid. > > Sean > > > On May 26, 2015, at 11:54, Sterling Smith <sm...@fu...> > wrote: > > > > Sean, > > > > Do you need an `annotate`, or just a `text`? `text` has the `transform` > keyword, to which you can pass `ax.transAxes`. > > > > ax.text(.9,.9, r"$\mathbf{" + lab + > ")}$”,transform=ax.transAxes,ha=‘right’,va=‘center’) > > > > -Sterling > > > > On May 26, 2015, at 10:06AM, Sean Lake <ody...@gm...> wrote: > > > >> Hello all, > >> > >> I'm using matplotlib 1.4.3 installed using fink with python 2.7. > >> > >> I'm trying to produce a grid of plots using gridspec that has > annotations to label each plot. > >> > >> Here is the call to annotate the current axes: > >> ax.annotate( r"$\mathbf{" + lab + ")}$", > >> xy=(0.5*(xmin+xmax), 0.5*(ymin+ymax)), > >> xytext=(0.9, 0.9), > >> textcoords="axes fraction", fontsize=14 ) > >> > >> Where ax is initialized by: > >> ax = plt.subplot(gs[ coords[0], coords[1] ]) > >> > >> and gs by: > >> gs = mpgs.GridSpec( 3, 2, wspace=0.0, hspace=0.0 ) > >> > >> The trouble comes in when abs(ymax) < abs(ymin). When that is true, the > labels are offset upward by one row, for some reason. > >> > >> I've attached a script that demonstrates the problem, and an example of > the output. I can work around this problem by using "data" coordinates, but > even so this reveals a bug somewhere. > >> > >> Thanks, > >> Sean Lake > >> > >> > <BugDemo.py><BugDemo.pdf>------------------------------------------------------------------------------ > >> One dashboard for servers and applications across Physical-Virtual-Cloud > >> Widest out-of-the-box monitoring support with 50+ applications > >> Performance metrics, stats and reports that give you Actionable Insights > >> Deep dive visibility with transaction tracing using APM Insight. > >> > http://ad.doubleclick.net/ddm/clk/290420510;117567292;y_______________________________________________ > >> Matplotlib-users mailing list > >> Mat...@li... > >> https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > > > > > ------------------------------------------------------------------------------ > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > |
From: Sean L. <ody...@gm...> - 2015-05-26 19:00:22
|
Sterling, Thanks for the pointer. I've already used a workaround where I used "data" coordinates and put it at: 0.9 * (xmax - xmin) + xmin, and similar for y. I'm really only reporting this so that it can be fixed if there is someone who does need to annotate something in a grid. Sean > On May 26, 2015, at 11:54, Sterling Smith <sm...@fu...> wrote: > > Sean, > > Do you need an `annotate`, or just a `text`? `text` has the `transform` keyword, to which you can pass `ax.transAxes`. > > ax.text(.9,.9, r"$\mathbf{" + lab + ")}$”,transform=ax.transAxes,ha=‘right’,va=‘center’) > > -Sterling > > On May 26, 2015, at 10:06AM, Sean Lake <ody...@gm...> wrote: > >> Hello all, >> >> I'm using matplotlib 1.4.3 installed using fink with python 2.7. >> >> I'm trying to produce a grid of plots using gridspec that has annotations to label each plot. >> >> Here is the call to annotate the current axes: >> ax.annotate( r"$\mathbf{" + lab + ")}$", >> xy=(0.5*(xmin+xmax), 0.5*(ymin+ymax)), >> xytext=(0.9, 0.9), >> textcoords="axes fraction", fontsize=14 ) >> >> Where ax is initialized by: >> ax = plt.subplot(gs[ coords[0], coords[1] ]) >> >> and gs by: >> gs = mpgs.GridSpec( 3, 2, wspace=0.0, hspace=0.0 ) >> >> The trouble comes in when abs(ymax) < abs(ymin). When that is true, the labels are offset upward by one row, for some reason. >> >> I've attached a script that demonstrates the problem, and an example of the output. I can work around this problem by using "data" coordinates, but even so this reveals a bug somewhere. >> >> Thanks, >> Sean Lake >> >> <BugDemo.py><BugDemo.pdf>------------------------------------------------------------------------------ >> One dashboard for servers and applications across Physical-Virtual-Cloud >> Widest out-of-the-box monitoring support with 50+ applications >> Performance metrics, stats and reports that give you Actionable Insights >> Deep dive visibility with transaction tracing using APM Insight. >> http://ad.doubleclick.net/ddm/clk/290420510;117567292;y_______________________________________________ >> Matplotlib-users mailing list >> Mat...@li... >> https://lists.sourceforge.net/lists/listinfo/matplotlib-users > |
From: Sean L. <ody...@gm...> - 2015-05-26 17:07:08
|
Hello all, I'm using matplotlib 1.4.3 installed using fink with python 2.7. I'm trying to produce a grid of plots using gridspec that has annotations to label each plot. Here is the call to annotate the current axes: ax.annotate( r"$\mathbf{" + lab + ")}$", xy=(0.5*(xmin+xmax), 0.5*(ymin+ymax)), xytext=(0.9, 0.9), textcoords="axes fraction", fontsize=14 ) Where ax is initialized by: ax = plt.subplot(gs[ coords[0], coords[1] ]) and gs by: gs = mpgs.GridSpec( 3, 2, wspace=0.0, hspace=0.0 ) The trouble comes in when abs(ymax) < abs(ymin). When that is true, the labels are offset upward by one row, for some reason. I've attached a script that demonstrates the problem, and an example of the output. I can work around this problem by using "data" coordinates, but even so this reveals a bug somewhere. Thanks, Sean Lake |
From: Benjamin R. <ben...@ou...> - 2015-05-26 16:49:29
|
On Tue, May 26, 2015 at 12:36 PM, Raj Kumar Manna <raj...@gm...> wrote: > import matplotlib.pyplot as plt > from mpl_toolkits.mplot3d import Axes3D > import numpy as np > > # create a 21 x 21 vertex mesh > xx, yy = np.meshgrid(np.linspace(0,1,21), np.linspace(0,1,21)) > > # create vertices for a rotated mesh (3D rotation matrix) > X = xx > Y = yy > Z = 10*np.ones(X.shape) > > # create some dummy data (20 x 20) for the image > data = np.cos(xx) * np.cos(xx) + np.sin(yy) * np.sin(yy) > > # create the figure > fig = plt.figure() > > # show the reference image > ax1 = fig.add_subplot(121) > ax1.imshow(data, cmap=plt.cm.BrBG, interpolation='nearest', > origin='lower', extent=[0,1,0,1]) > > # show the 3D rotated projection > ax2 = fig.add_subplot(122, projection='3d') > ax2.plot_surface(X, Y, Z, rstride=1, cstride=1, > facecolors=plt.cm.BrBG(data), shade=False) > The call to imshow() without vmin/vmax arguments will automatically scale the colormap to cover the entire range of values. Meanwhile, when you did plt.cm.BrBG(data), it assumed that the vmin/vmax is 0 and 1, respectively. The min and max of your data is actually 0.292 and 1.708. If you normalize your data, it should look much more correct. Cheers! Ben Root |