You can subscribe to this list here.
2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
(33) |
Dec
(20) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2004 |
Jan
(7) |
Feb
(44) |
Mar
(51) |
Apr
(43) |
May
(43) |
Jun
(36) |
Jul
(61) |
Aug
(44) |
Sep
(25) |
Oct
(82) |
Nov
(97) |
Dec
(47) |
2005 |
Jan
(77) |
Feb
(143) |
Mar
(42) |
Apr
(31) |
May
(93) |
Jun
(93) |
Jul
(35) |
Aug
(78) |
Sep
(56) |
Oct
(44) |
Nov
(72) |
Dec
(75) |
2006 |
Jan
(116) |
Feb
(99) |
Mar
(181) |
Apr
(171) |
May
(112) |
Jun
(86) |
Jul
(91) |
Aug
(111) |
Sep
(77) |
Oct
(72) |
Nov
(57) |
Dec
(51) |
2007 |
Jan
(64) |
Feb
(116) |
Mar
(70) |
Apr
(74) |
May
(53) |
Jun
(40) |
Jul
(519) |
Aug
(151) |
Sep
(132) |
Oct
(74) |
Nov
(282) |
Dec
(190) |
2008 |
Jan
(141) |
Feb
(67) |
Mar
(69) |
Apr
(96) |
May
(227) |
Jun
(404) |
Jul
(399) |
Aug
(96) |
Sep
(120) |
Oct
(205) |
Nov
(126) |
Dec
(261) |
2009 |
Jan
(136) |
Feb
(136) |
Mar
(119) |
Apr
(124) |
May
(155) |
Jun
(98) |
Jul
(136) |
Aug
(292) |
Sep
(174) |
Oct
(126) |
Nov
(126) |
Dec
(79) |
2010 |
Jan
(109) |
Feb
(83) |
Mar
(139) |
Apr
(91) |
May
(79) |
Jun
(164) |
Jul
(184) |
Aug
(146) |
Sep
(163) |
Oct
(128) |
Nov
(70) |
Dec
(73) |
2011 |
Jan
(235) |
Feb
(165) |
Mar
(147) |
Apr
(86) |
May
(74) |
Jun
(118) |
Jul
(65) |
Aug
(75) |
Sep
(162) |
Oct
(94) |
Nov
(48) |
Dec
(44) |
2012 |
Jan
(49) |
Feb
(40) |
Mar
(88) |
Apr
(35) |
May
(52) |
Jun
(69) |
Jul
(90) |
Aug
(123) |
Sep
(112) |
Oct
(120) |
Nov
(105) |
Dec
(116) |
2013 |
Jan
(76) |
Feb
(26) |
Mar
(78) |
Apr
(43) |
May
(61) |
Jun
(53) |
Jul
(147) |
Aug
(85) |
Sep
(83) |
Oct
(122) |
Nov
(18) |
Dec
(27) |
2014 |
Jan
(58) |
Feb
(25) |
Mar
(49) |
Apr
(17) |
May
(29) |
Jun
(39) |
Jul
(53) |
Aug
(52) |
Sep
(35) |
Oct
(47) |
Nov
(110) |
Dec
(27) |
2015 |
Jan
(50) |
Feb
(93) |
Mar
(96) |
Apr
(30) |
May
(55) |
Jun
(83) |
Jul
(44) |
Aug
(8) |
Sep
(5) |
Oct
|
Nov
(1) |
Dec
(1) |
2016 |
Jan
|
Feb
|
Mar
(1) |
Apr
|
May
|
Jun
(2) |
Jul
|
Aug
(3) |
Sep
(1) |
Oct
(3) |
Nov
|
Dec
|
2017 |
Jan
|
Feb
(5) |
Mar
|
Apr
|
May
|
Jun
|
Jul
(3) |
Aug
|
Sep
(7) |
Oct
|
Nov
|
Dec
|
2018 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(2) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
S | M | T | W | T | F | S |
---|---|---|---|---|---|---|
|
|
1
(2) |
2
(5) |
3
(1) |
4
(5) |
5
|
6
(2) |
7
(3) |
8
(1) |
9
|
10
(7) |
11
(13) |
12
|
13
|
14
(1) |
15
|
16
(2) |
17
|
18
(6) |
19
(2) |
20
(1) |
21
(14) |
22
(12) |
23
(15) |
24
(11) |
25
(15) |
26
|
27
|
28
(1) |
29
|
30
(1) |
31
(2) |
|
|
From: Benjamin R. <ben...@ou...> - 2013-10-18 18:56:59
|
On Fri, Oct 18, 2013 at 2:13 PM, Chris Barker <chr...@no...> wrote: > On Fri, Oct 4, 2013 at 1:40 PM, Russell E. Owen <ro...@uw...> wrote: > >> Introducing Plotting with Matplotlib > >> > >> Pyplot tutorial > >> Controlling line properties > >> Working with multiple figures and axes > >> Working with text > >> Interactive navigation > >> Navigation Keyboard Shortcuts > >> Working with text > >> Text introduction > >> Basic text commands > >> Text properties and layout > >> Writing mathematical expressions > >> Text rendering With LaTeX > >> Annotating text > > ... > > > - Would you be willing to include a section on using the class API? (I'm > > assuming the above is all based on using pyplot?). > > +inf > > Even better, dump pyplot and use primarily the OO API. Asside from > folks that dont want to change anything when moving from Matlab, we > should all be using teh primarily OO API. > > is it really that hard to type: > > ax.plot() > > rather than > > plot() ? > > And when you move away from interactive use (and we all should fi your > typing more than 4-5 lines of code) teh OO interface is a much better > way to go. > > (I know, iPython notebooks allow you do do a LOT with esentially an > interactive interpreter, but still.....) > > Anyway, I've always thought it was a real shame that most of the > tutorials on MPL out there get people started on what I'm convinced is > the wrong foot. > > - just my opinionated $0.02 worth... > > -Chris > > FWIW, I think my "Anatomy of Matplotlib" tutorial I gave at SciPy 2013 struck a balance between pyplot and the OO interface. I welcome any and all feedback on that tutorial which I plan to give again next year as well as an intermediate "Anatomy of Matplotlib" tutorial. Cheers! Ben Root |
From: Chris B. <chr...@no...> - 2013-10-18 18:19:45
|
Ian, > I am working on a PR to replace the use of matplotlib.delaunay with the > Qhull library. nice! -- ( though I sure wish Qhull did constrained delaunay...) > Installation will be similar to the existing packages LibAgg > and CXX in that if the system already has a sufficiently recent version of > Qhull installed then matplotlib will use that, otherwise it will build the > required library from the source code shipped with matplotlib. Why bother, why not just always build the internal version? (for that matter, same with agg) Wouldn't it be a lot easier and more robust to be sure that everyone is running the exact same code? What are the odds that folks are using qhull for something else, and even more to the point, what are the odds that the duplication of this lib would matter one wit? This isn't like LAPACK, where folks have a compellling reason to run a particular version. -- just my thoughts on how to keep things simpler. -Chris -- Christopher Barker, Ph.D. Oceanographer Emergency Response Division NOAA/NOS/OR&R (206) 526-6959 voice 7600 Sand Point Way NE (206) 526-6329 fax Seattle, WA 98115 (206) 526-6317 main reception Chr...@no... |
From: Chris B. <chr...@no...> - 2013-10-18 18:14:46
|
On Fri, Oct 4, 2013 at 1:40 PM, Russell E. Owen <ro...@uw...> wrote: >> Introducing Plotting with Matplotlib >> >> Pyplot tutorial >> Controlling line properties >> Working with multiple figures and axes >> Working with text >> Interactive navigation >> Navigation Keyboard Shortcuts >> Working with text >> Text introduction >> Basic text commands >> Text properties and layout >> Writing mathematical expressions >> Text rendering With LaTeX >> Annotating text > ... > - Would you be willing to include a section on using the class API? (I'm > assuming the above is all based on using pyplot?). +inf Even better, dump pyplot and use primarily the OO API. Asside from folks that dont want to change anything when moving from Matlab, we should all be using teh primarily OO API. is it really that hard to type: ax.plot() rather than plot() ? And when you move away from interactive use (and we all should fi your typing more than 4-5 lines of code) teh OO interface is a much better way to go. (I know, iPython notebooks allow you do do a LOT with esentially an interactive interpreter, but still.....) Anyway, I've always thought it was a real shame that most of the tutorials on MPL out there get people started on what I'm convinced is the wrong foot. - just my opinionated $0.02 worth... -Chris -- Christopher Barker, Ph.D. Oceanographer Emergency Response Division NOAA/NOS/OR&R (206) 526-6959 voice 7600 Sand Point Way NE (206) 526-6329 fax Seattle, WA 98115 (206) 526-6317 main reception Chr...@no... |
From: Michael D. <md...@st...> - 2013-10-18 11:50:27
|
On 10/18/2013 02:11 AM, Matthew Brett wrote: > Hi, > > I'm testing the binary installer build: > > https://travis-ci.org/matthew-brett/mpl-osx-binaries/builds/12703220 > > and I'm getting a test failure on Python 3.3 (not Python 2.7): > > ====================================================================== > FAIL: matplotlib.tests.test_lines.test_invisible_Line_rendering.test > ---------------------------------------------------------------------- > Traceback (most recent call last): > File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/nose/case.py", > line 198, in runTest > self.test(*self.arg) > File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/matplotlib/testing/decorators.py", > line 73, in test > self._func() > File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/matplotlib/tests/test_lines.py", > line 54, in test_invisible_Line_rendering > assert_true(slowdown_factor < slowdown_threshold) > AssertionError: False is not true > > ---------------------------------------------------------------------- > Ran 1464 tests in 656.822s > > Is this a problem? What should I do to debug further? > I've never seen that failure before... I wonder if Pierre Haessig has any thoughts, as the author of that test... Mike -- _ |\/|o _|_ _. _ | | \.__ __|__|_|_ _ _ ._ _ | ||(_| |(_|(/_| |_/|(_)(/_|_ |_|_)(_)(_)| | | http://www.droettboom.com |
From: Matthew B. <mat...@gm...> - 2013-10-18 06:12:00
|
Hi, I'm testing the binary installer build: https://travis-ci.org/matthew-brett/mpl-osx-binaries/builds/12703220 and I'm getting a test failure on Python 3.3 (not Python 2.7): ====================================================================== FAIL: matplotlib.tests.test_lines.test_invisible_Line_rendering.test ---------------------------------------------------------------------- Traceback (most recent call last): File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/nose/case.py", line 198, in runTest self.test(*self.arg) File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/matplotlib/testing/decorators.py", line 73, in test self._func() File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/matplotlib/tests/test_lines.py", line 54, in test_invisible_Line_rendering assert_true(slowdown_factor < slowdown_threshold) AssertionError: False is not true ---------------------------------------------------------------------- Ran 1464 tests in 656.822s Is this a problem? What should I do to debug further? Cheers, Matthew |
From: Jason G. <jas...@cr...> - 2013-10-16 20:47:09
|
On 10/16/13 1:58 PM, Michael Droettboom wrote: > Sorry to take so long to get to this. This is a nice piece of work. > > The most obvious thing is that this is a copy-and-paste of the existing > WebAgg backend -- and maintaining the two is going to be much harder > than building both out of the same pieces. As of 6389d14f, the WebAgg > backend was refactored so that the transport that it uses to communicate > to the browser is no longer hard coded. This was done in large part to > support working with IPyhton in this way. (That is, it used to only > communicate with the browser through Tornado, but now it can be anything > that can send bits back and forth). There's an example of this in > `examples/user_interfaces/embedding_webagg.py` that shows how to do this > (using Tornado, but again, it doesn't have to be). There's no guarantees > that this interface is sufficient, so it may require some back and forth > on this to make it all work. > > I think the first thing I would do would be to refactor this to use > that. It's a little hard to tell what you've changed from the original > WebAgg backend to get it to support IPython. If it were built on top > of, rather than in addition to, WebAgg, that would be more obvious. Thanks for the feedback. I was thinking that a refactor to pull out the communication layer would be really nice. I didn't change the WebAgg backend because I figured you wanted it around still. I figured a plain old diff with the file would reveal changes. Anyways, thanks for the pointer to the refactor commit. I hope to look at this again sometime soon. Jason |
From: Michael D. <md...@st...> - 2013-10-16 19:00:19
|
Sorry to take so long to get to this. This is a nice piece of work. The most obvious thing is that this is a copy-and-paste of the existing WebAgg backend -- and maintaining the two is going to be much harder than building both out of the same pieces. As of 6389d14f, the WebAgg backend was refactored so that the transport that it uses to communicate to the browser is no longer hard coded. This was done in large part to support working with IPyhton in this way. (That is, it used to only communicate with the browser through Tornado, but now it can be anything that can send bits back and forth). There's an example of this in `examples/user_interfaces/embedding_webagg.py` that shows how to do this (using Tornado, but again, it doesn't have to be). There's no guarantees that this interface is sufficient, so it may require some back and forth on this to make it all work. I think the first thing I would do would be to refactor this to use that. It's a little hard to tell what you've changed from the original WebAgg backend to get it to support IPython. If it were built on top of, rather than in addition to, WebAgg, that would be more obvious. Mike On 10/10/2013 06:08 PM, Jason Grout wrote: > I've been working on a backend based on the webagg backend, but that > uses the IPython Comm architecture at > https://github.com/ipython/ipython/pull/4195 to send messages instead of > starting a server and opening websocket connections. I have an initial > version in my github ipython-comm branch (see > https://github.com/jasongrout/matplotlib/compare/ipython-comm). I'm > getting confused about how the backend infrastructure works, though, > like what the purpose for the FigureManager class is, etc. I'm running > out of time to work on this now, and I'm hoping that someone will take > what work I've done here and get it working properly with the matplotlib > architecture. If not, I'll probably tinker with this more later. > > Thanks, > > Jason > > -- > Jason Grout > > ------------------------------------------------------------------------------ > October Webinars: Code for Performance > Free Intel webinars can help you accelerate application performance. > Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from > the latest Intel processors and coprocessors. See abstracts and register > > http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk > _______________________________________________ > Matplotlib-devel mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-devel -- _ |\/|o _|_ _. _ | | \.__ __|__|_|_ _ _ ._ _ | ||(_| |(_|(/_| |_/|(_)(/_|_ |_|_)(_)(_)| | | http://www.droettboom.com |
From: Michael D. <md...@st...> - 2013-10-14 14:09:21
|
I've created a wiki page to brainstorm agenda ideas for next week's meeting. https://github.com/matplotlib/matplotlib/wiki/Hangout-2013-10-24 -- _ |\/|o _|_ _. _ | | \.__ __|__|_|_ _ _ ._ _ | ||(_| |(_|(/_| |_/|(_)(/_|_ |_|_)(_)(_)| | | http://www.droettboom.com |
From: Federico A. <ari...@gm...> - 2013-10-11 20:49:37
|
Looking through the code I realize that in interactive mode (ipython) there is no call to show() by default. And if you call it, it does not call mailoop because is_interactive==Tr ue So why is there the restriction to call only once Gtk.main in mailoop? if it is not called anyway Why not make that restriction to call Gtk.main in mainloop dependant on is_interactive? as the call Gtk.main_quit is in the destroy method Federico On Fri, Oct 11, 2013 at 4:15 PM, Federico Ariza <ari...@gm...> wrote: > Sorry, the replay-all is not my default. > > In that case it is easier for me to monkey patch just the mainloop to > invoke Gtk.main everytime. > > But again, even if we are talking about interactive (ipython), why is > it unbalanced? > I mean calls Gtk.main vs Gtk.main_quit? > > Federico > > > > On Fri, Oct 11, 2013 at 3:28 PM, Thomas A Caswell <tca...@uc...> wrote: >> Please keep all emails in-band >> >> I was commenting that the issue you are having with getting easy-to-use >> pre-built figures in a non-interactive program without dragging pyplot in is >> the same as what I think the root of 2503 is and the re-factor I proposed to >> make your life easier would also help that case (I think). >> >> The gui backends were (as I understand it, someone please correct me if I am >> wrong) built to play nice with ipython to put together a MATLAB-like >> interface. The fact that you can then embed the gui-framework dependent >> bits of matplotlib in other gui applications is a nice side-effect, but not >> one of the initial design goals. This is why the `figure_manager` code is >> (too-)tightly coupled to _pylab_helpers. >> >> See the examples at http://matplotlib.org/examples/user_interfaces/ making >> a window with a canvas + tool bar is pretty easy. >> >> A quick and dirty solution might be to just monkey patch the >> figure_manager.destroy function when your app starts up to remove the check >> that shuts down the main loop. >> >> Tom >> >> >> On Fri, Oct 11, 2013 at 1:40 PM, Federico Ariza <ari...@gm...> >> wrote: >>> >>> Sorry I don't get it. >>> Are you suggesting to explain this little predicament in the PR to >>> give another point of view? or >>> You want me to check the PR and try to use the solutions proposed there? >>> >>> Federico >>> >>> On Fri, Oct 11, 2013 at 1:32 PM, Thomas A Caswell <tca...@uc...> >>> wrote: >>> > embedding vs launching is a distinction without a difference, you are >>> > integrating matplotlib with your own gui application. >>> > >>> > That said, it would be nice to re-factor the figure_manager classes so >>> > they >>> > they make no reference to `Gcf` or anything associated with pylab and >>> > could >>> > be easily re-used. >>> > >>> > I think that would also help with the issues in >>> > https://github.com/matplotlib/matplotlib/pull/2503 >>> > >>> > Tom >>> > >>> > >>> > On Fri, Oct 11, 2013 at 12:14 PM, Federico Ariza >>> > <ari...@gm...> >>> > wrote: >>> >> >>> >> Again >>> >> >>> >> In the example the plotting is inside the callback (just for >>> >> simplicity), but in reality, the plotting is in another class, >>> >> somewhere else that can be called standalone to produce the plots. >>> >> >>> >> Federico >>> >> >>> >> On Fri, Oct 11, 2013 at 1:12 PM, Federico Ariza >>> >> <ari...@gm...> wrote: >>> >> > I am not embedding, just launching, as the example shows. >>> >> > >>> >> > Federico >>> >> > >>> >> > On Fri, Oct 11, 2013 at 1:11 PM, Thomas A Caswell >>> >> > <tca...@uc...> wrote: >>> >> >> If you are embedding matplotlib, do not import `pyplot`. `pyplot` >>> >> >> sets >>> >> >> up a >>> >> >> bunch of gui-magic (tm) in the background (as you found in >>> >> >> `figure_manager`). >>> >> >> >>> >> >> Tom >>> >> >> >>> >> >> >>> >> >> On Fri, Oct 11, 2013 at 11:57 AM, Federico Ariza >>> >> >> <ari...@gm...> >>> >> >> wrote: >>> >> >>> >>> >> >>> Hello everybody >>> >> >>> >>> >> >>> Working on one GTK3 app, that calls matplotlib to plot some >>> >> >>> figures, I >>> >> >>> found that closing all the figures from matplotlib kills my app >>> >> >>> also. >>> >> >>> The problem.... >>> >> >>> >>> >> >>> Gtk.main() is called only if there is no previous invocation, in my >>> >> >>> case, my Gtk3 app invokes main, so the mainloop won't call it >>> >> >>> again. >>> >> >>> >>> >> >>> #in backend_gtk3.py >>> >> >>> # >>> >> >>> class Show(ShowBase): >>> >> >>> def mainloop(self): >>> >> >>> if Gtk.main_level() == 0: >>> >> >>> Gtk.main() >>> >> >>> >>> >> >>> But in the "destroy" method of the figure manager calls >>> >> >>> Gtk.main_quit >>> >> >>> everytime that there are no more figures >>> >> >>> >>> >> >>> #in backend_gtk3.py inside destroy method of FigureManagerGTK3 >>> >> >>> # >>> >> >>> if Gcf.get_num_fig_managers()==0 and \ >>> >> >>> not matplotlib.is_interactive() and \ >>> >> >>> Gtk.main_level() >= 1: >>> >> >>> Gtk.main_quit() >>> >> >>> >>> >> >>> >>> >> >>> So basically we are not calling Gtk.main but we are Gtk.calling >>> >> >>> main_quit. >>> >> >>> Isn't it more natural to call Gtk.main the same amount of times >>> >> >>> that >>> >> >>> we are going to call Gtk.main_quit? >>> >> >>> >>> >> >>> Adding matplotlib.rcParams['interactive'] = True doesn't help >>> >> >>> >>> >> >>> Here is my little testing code >>> >> >>> >>> >> >>> ############################## >>> >> >>> #file myapp.py >>> >> >>> >>> >> >>> import matplotlib >>> >> >>> matplotlib.rcParams['interactive'] = True >>> >> >>> matplotlib.use('GTK3AGG') >>> >> >>> import matplotlib.pyplot as plt >>> >> >>> >>> >> >>> from gi.repository import Gtk >>> >> >>> >>> >> >>> class MyWindow(Gtk.Window): >>> >> >>> >>> >> >>> def __init__(self): >>> >> >>> Gtk.Window.__init__(self, title="Hello World") >>> >> >>> >>> >> >>> self.button = Gtk.Button(label="Click Here") >>> >> >>> self.button.connect("clicked", self.on_button_clicked) >>> >> >>> self.add(self.button) >>> >> >>> >>> >> >>> def on_button_clicked(self, widget): >>> >> >>> fig = plt.figure() >>> >> >>> ax = fig.add_subplot(111) >>> >> >>> ax.plot([1,2,3]) >>> >> >>> plt.show() >>> >> >>> >>> >> >>> win = MyWindow() >>> >> >>> win.connect("delete-event", Gtk.main_quit) >>> >> >>> win.show_all() >>> >> >>> Gtk.main() >>> >> >>> ######################### >>> >> >>> >>> >> >>> I know this is related to interactive mode, but running from >>> >> >>> console >>> >> >>> >>> python myapp.py >>> >> >>> reproduces the problem >>> >> >>> >>> >> >>> Why hasattr(sys, 'ps1') is False? if I am running it from console? >>> >> >>> how >>> >> >>> do I change this? >>> >> >>> >>> >> >>> >>> >> >>> Thanks >>> >> >>> Federico >>> >> >>> >>> >> >>> P.S. Does anybody had the time to check my PR for >>> >> >>> multi-figure-manager? >>> >> >>> https://github.com/matplotlib/matplotlib/pull/2465 >>> >> >>> >>> >> >>> -- >>> >> >>> Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? >>> >> >>> >>> >> >>> -- Antonio Alducin -- >>> >> >>> >>> >> >>> >>> >> >>> >>> >> >>> >>> >> >>> ------------------------------------------------------------------------------ >>> >> >>> October Webinars: Code for Performance >>> >> >>> Free Intel webinars can help you accelerate application >>> >> >>> performance. >>> >> >>> Explore tips for MPI, OpenMP, advanced profiling, and more. Get the >>> >> >>> most >>> >> >>> from >>> >> >>> the latest Intel processors and coprocessors. See abstracts and >>> >> >>> register > >>> >> >>> >>> >> >>> >>> >> >>> >>> >> >>> http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk >>> >> >>> _______________________________________________ >>> >> >>> Matplotlib-devel mailing list >>> >> >>> Mat...@li... >>> >> >>> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel >>> >> >> >>> >> >> >>> >> >> >>> >> >> >>> >> >> -- >>> >> >> Thomas A Caswell >>> >> >> PhD Candidate University of Chicago >>> >> >> Nagel and Gardel labs >>> >> >> tca...@uc... >>> >> >> jfi.uchicago.edu/~tcaswell >>> >> >> o: 773.702.7204 >>> >> > >>> >> > >>> >> > >>> >> > -- >>> >> > Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? >>> >> > >>> >> > -- Antonio Alducin -- >>> >> >>> >> >>> >> >>> >> -- >>> >> Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? >>> >> >>> >> -- Antonio Alducin -- >>> > >>> > >>> > >>> > >>> > -- >>> > Thomas A Caswell >>> > PhD Candidate University of Chicago >>> > Nagel and Gardel labs >>> > tca...@uc... >>> > jfi.uchicago.edu/~tcaswell >>> > o: 773.702.7204 >>> >>> >>> >>> -- >>> Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? >>> >>> -- Antonio Alducin -- >> >> >> >> >> -- >> Thomas A Caswell >> PhD Candidate University of Chicago >> Nagel and Gardel labs >> tca...@uc... >> jfi.uchicago.edu/~tcaswell >> o: 773.702.7204 > > > > -- > Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? > > -- Antonio Alducin -- -- Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? -- Antonio Alducin -- |
From: Federico A. <ari...@gm...> - 2013-10-11 20:15:52
|
Sorry, the replay-all is not my default. In that case it is easier for me to monkey patch just the mainloop to invoke Gtk.main everytime. But again, even if we are talking about interactive (ipython), why is it unbalanced? I mean calls Gtk.main vs Gtk.main_quit? Federico On Fri, Oct 11, 2013 at 3:28 PM, Thomas A Caswell <tca...@uc...> wrote: > Please keep all emails in-band > > I was commenting that the issue you are having with getting easy-to-use > pre-built figures in a non-interactive program without dragging pyplot in is > the same as what I think the root of 2503 is and the re-factor I proposed to > make your life easier would also help that case (I think). > > The gui backends were (as I understand it, someone please correct me if I am > wrong) built to play nice with ipython to put together a MATLAB-like > interface. The fact that you can then embed the gui-framework dependent > bits of matplotlib in other gui applications is a nice side-effect, but not > one of the initial design goals. This is why the `figure_manager` code is > (too-)tightly coupled to _pylab_helpers. > > See the examples at http://matplotlib.org/examples/user_interfaces/ making > a window with a canvas + tool bar is pretty easy. > > A quick and dirty solution might be to just monkey patch the > figure_manager.destroy function when your app starts up to remove the check > that shuts down the main loop. > > Tom > > > On Fri, Oct 11, 2013 at 1:40 PM, Federico Ariza <ari...@gm...> > wrote: >> >> Sorry I don't get it. >> Are you suggesting to explain this little predicament in the PR to >> give another point of view? or >> You want me to check the PR and try to use the solutions proposed there? >> >> Federico >> >> On Fri, Oct 11, 2013 at 1:32 PM, Thomas A Caswell <tca...@uc...> >> wrote: >> > embedding vs launching is a distinction without a difference, you are >> > integrating matplotlib with your own gui application. >> > >> > That said, it would be nice to re-factor the figure_manager classes so >> > they >> > they make no reference to `Gcf` or anything associated with pylab and >> > could >> > be easily re-used. >> > >> > I think that would also help with the issues in >> > https://github.com/matplotlib/matplotlib/pull/2503 >> > >> > Tom >> > >> > >> > On Fri, Oct 11, 2013 at 12:14 PM, Federico Ariza >> > <ari...@gm...> >> > wrote: >> >> >> >> Again >> >> >> >> In the example the plotting is inside the callback (just for >> >> simplicity), but in reality, the plotting is in another class, >> >> somewhere else that can be called standalone to produce the plots. >> >> >> >> Federico >> >> >> >> On Fri, Oct 11, 2013 at 1:12 PM, Federico Ariza >> >> <ari...@gm...> wrote: >> >> > I am not embedding, just launching, as the example shows. >> >> > >> >> > Federico >> >> > >> >> > On Fri, Oct 11, 2013 at 1:11 PM, Thomas A Caswell >> >> > <tca...@uc...> wrote: >> >> >> If you are embedding matplotlib, do not import `pyplot`. `pyplot` >> >> >> sets >> >> >> up a >> >> >> bunch of gui-magic (tm) in the background (as you found in >> >> >> `figure_manager`). >> >> >> >> >> >> Tom >> >> >> >> >> >> >> >> >> On Fri, Oct 11, 2013 at 11:57 AM, Federico Ariza >> >> >> <ari...@gm...> >> >> >> wrote: >> >> >>> >> >> >>> Hello everybody >> >> >>> >> >> >>> Working on one GTK3 app, that calls matplotlib to plot some >> >> >>> figures, I >> >> >>> found that closing all the figures from matplotlib kills my app >> >> >>> also. >> >> >>> The problem.... >> >> >>> >> >> >>> Gtk.main() is called only if there is no previous invocation, in my >> >> >>> case, my Gtk3 app invokes main, so the mainloop won't call it >> >> >>> again. >> >> >>> >> >> >>> #in backend_gtk3.py >> >> >>> # >> >> >>> class Show(ShowBase): >> >> >>> def mainloop(self): >> >> >>> if Gtk.main_level() == 0: >> >> >>> Gtk.main() >> >> >>> >> >> >>> But in the "destroy" method of the figure manager calls >> >> >>> Gtk.main_quit >> >> >>> everytime that there are no more figures >> >> >>> >> >> >>> #in backend_gtk3.py inside destroy method of FigureManagerGTK3 >> >> >>> # >> >> >>> if Gcf.get_num_fig_managers()==0 and \ >> >> >>> not matplotlib.is_interactive() and \ >> >> >>> Gtk.main_level() >= 1: >> >> >>> Gtk.main_quit() >> >> >>> >> >> >>> >> >> >>> So basically we are not calling Gtk.main but we are Gtk.calling >> >> >>> main_quit. >> >> >>> Isn't it more natural to call Gtk.main the same amount of times >> >> >>> that >> >> >>> we are going to call Gtk.main_quit? >> >> >>> >> >> >>> Adding matplotlib.rcParams['interactive'] = True doesn't help >> >> >>> >> >> >>> Here is my little testing code >> >> >>> >> >> >>> ############################## >> >> >>> #file myapp.py >> >> >>> >> >> >>> import matplotlib >> >> >>> matplotlib.rcParams['interactive'] = True >> >> >>> matplotlib.use('GTK3AGG') >> >> >>> import matplotlib.pyplot as plt >> >> >>> >> >> >>> from gi.repository import Gtk >> >> >>> >> >> >>> class MyWindow(Gtk.Window): >> >> >>> >> >> >>> def __init__(self): >> >> >>> Gtk.Window.__init__(self, title="Hello World") >> >> >>> >> >> >>> self.button = Gtk.Button(label="Click Here") >> >> >>> self.button.connect("clicked", self.on_button_clicked) >> >> >>> self.add(self.button) >> >> >>> >> >> >>> def on_button_clicked(self, widget): >> >> >>> fig = plt.figure() >> >> >>> ax = fig.add_subplot(111) >> >> >>> ax.plot([1,2,3]) >> >> >>> plt.show() >> >> >>> >> >> >>> win = MyWindow() >> >> >>> win.connect("delete-event", Gtk.main_quit) >> >> >>> win.show_all() >> >> >>> Gtk.main() >> >> >>> ######################### >> >> >>> >> >> >>> I know this is related to interactive mode, but running from >> >> >>> console >> >> >>> >>> python myapp.py >> >> >>> reproduces the problem >> >> >>> >> >> >>> Why hasattr(sys, 'ps1') is False? if I am running it from console? >> >> >>> how >> >> >>> do I change this? >> >> >>> >> >> >>> >> >> >>> Thanks >> >> >>> Federico >> >> >>> >> >> >>> P.S. Does anybody had the time to check my PR for >> >> >>> multi-figure-manager? >> >> >>> https://github.com/matplotlib/matplotlib/pull/2465 >> >> >>> >> >> >>> -- >> >> >>> Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? >> >> >>> >> >> >>> -- Antonio Alducin -- >> >> >>> >> >> >>> >> >> >>> >> >> >>> >> >> >>> ------------------------------------------------------------------------------ >> >> >>> October Webinars: Code for Performance >> >> >>> Free Intel webinars can help you accelerate application >> >> >>> performance. >> >> >>> Explore tips for MPI, OpenMP, advanced profiling, and more. Get the >> >> >>> most >> >> >>> from >> >> >>> the latest Intel processors and coprocessors. See abstracts and >> >> >>> register > >> >> >>> >> >> >>> >> >> >>> >> >> >>> http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk >> >> >>> _______________________________________________ >> >> >>> Matplotlib-devel mailing list >> >> >>> Mat...@li... >> >> >>> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel >> >> >> >> >> >> >> >> >> >> >> >> >> >> >> -- >> >> >> Thomas A Caswell >> >> >> PhD Candidate University of Chicago >> >> >> Nagel and Gardel labs >> >> >> tca...@uc... >> >> >> jfi.uchicago.edu/~tcaswell >> >> >> o: 773.702.7204 >> >> > >> >> > >> >> > >> >> > -- >> >> > Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? >> >> > >> >> > -- Antonio Alducin -- >> >> >> >> >> >> >> >> -- >> >> Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? >> >> >> >> -- Antonio Alducin -- >> > >> > >> > >> > >> > -- >> > Thomas A Caswell >> > PhD Candidate University of Chicago >> > Nagel and Gardel labs >> > tca...@uc... >> > jfi.uchicago.edu/~tcaswell >> > o: 773.702.7204 >> >> >> >> -- >> Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? >> >> -- Antonio Alducin -- > > > > > -- > Thomas A Caswell > PhD Candidate University of Chicago > Nagel and Gardel labs > tca...@uc... > jfi.uchicago.edu/~tcaswell > o: 773.702.7204 -- Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? -- Antonio Alducin -- |
From: Thomas A C. <tca...@uc...> - 2013-10-11 19:28:49
|
Please keep all emails in-band I was commenting that the issue you are having with getting easy-to-use pre-built figures in a non-interactive program without dragging pyplot in is the same as what I think the root of 2503 is and the re-factor I proposed to make your life easier would also help that case (I think). The gui backends were (as I understand it, someone please correct me if I am wrong) built to play nice with ipython to put together a MATLAB-like interface. The fact that you can then embed the gui-framework dependent bits of matplotlib in other gui applications is a nice side-effect, but not one of the initial design goals. This is why the `figure_manager` code is (too-)tightly coupled to _pylab_helpers. See the examples at http://matplotlib.org/examples/user_interfaces/ making a window with a canvas + tool bar is pretty easy. A quick and dirty solution might be to just monkey patch the figure_manager.destroy function when your app starts up to remove the check that shuts down the main loop. Tom On Fri, Oct 11, 2013 at 1:40 PM, Federico Ariza <ari...@gm...>wrote: > Sorry I don't get it. > Are you suggesting to explain this little predicament in the PR to > give another point of view? or > You want me to check the PR and try to use the solutions proposed there? > > Federico > > On Fri, Oct 11, 2013 at 1:32 PM, Thomas A Caswell <tca...@uc...> > wrote: > > embedding vs launching is a distinction without a difference, you are > > integrating matplotlib with your own gui application. > > > > That said, it would be nice to re-factor the figure_manager classes so > they > > they make no reference to `Gcf` or anything associated with pylab and > could > > be easily re-used. > > > > I think that would also help with the issues in > > https://github.com/matplotlib/matplotlib/pull/2503 > > > > Tom > > > > > > On Fri, Oct 11, 2013 at 12:14 PM, Federico Ariza < > ari...@gm...> > > wrote: > >> > >> Again > >> > >> In the example the plotting is inside the callback (just for > >> simplicity), but in reality, the plotting is in another class, > >> somewhere else that can be called standalone to produce the plots. > >> > >> Federico > >> > >> On Fri, Oct 11, 2013 at 1:12 PM, Federico Ariza > >> <ari...@gm...> wrote: > >> > I am not embedding, just launching, as the example shows. > >> > > >> > Federico > >> > > >> > On Fri, Oct 11, 2013 at 1:11 PM, Thomas A Caswell > >> > <tca...@uc...> wrote: > >> >> If you are embedding matplotlib, do not import `pyplot`. `pyplot` > sets > >> >> up a > >> >> bunch of gui-magic (tm) in the background (as you found in > >> >> `figure_manager`). > >> >> > >> >> Tom > >> >> > >> >> > >> >> On Fri, Oct 11, 2013 at 11:57 AM, Federico Ariza > >> >> <ari...@gm...> > >> >> wrote: > >> >>> > >> >>> Hello everybody > >> >>> > >> >>> Working on one GTK3 app, that calls matplotlib to plot some > figures, I > >> >>> found that closing all the figures from matplotlib kills my app > also. > >> >>> The problem.... > >> >>> > >> >>> Gtk.main() is called only if there is no previous invocation, in my > >> >>> case, my Gtk3 app invokes main, so the mainloop won't call it again. > >> >>> > >> >>> #in backend_gtk3.py > >> >>> # > >> >>> class Show(ShowBase): > >> >>> def mainloop(self): > >> >>> if Gtk.main_level() == 0: > >> >>> Gtk.main() > >> >>> > >> >>> But in the "destroy" method of the figure manager calls > Gtk.main_quit > >> >>> everytime that there are no more figures > >> >>> > >> >>> #in backend_gtk3.py inside destroy method of FigureManagerGTK3 > >> >>> # > >> >>> if Gcf.get_num_fig_managers()==0 and \ > >> >>> not matplotlib.is_interactive() and \ > >> >>> Gtk.main_level() >= 1: > >> >>> Gtk.main_quit() > >> >>> > >> >>> > >> >>> So basically we are not calling Gtk.main but we are Gtk.calling > >> >>> main_quit. > >> >>> Isn't it more natural to call Gtk.main the same amount of times that > >> >>> we are going to call Gtk.main_quit? > >> >>> > >> >>> Adding matplotlib.rcParams['interactive'] = True doesn't help > >> >>> > >> >>> Here is my little testing code > >> >>> > >> >>> ############################## > >> >>> #file myapp.py > >> >>> > >> >>> import matplotlib > >> >>> matplotlib.rcParams['interactive'] = True > >> >>> matplotlib.use('GTK3AGG') > >> >>> import matplotlib.pyplot as plt > >> >>> > >> >>> from gi.repository import Gtk > >> >>> > >> >>> class MyWindow(Gtk.Window): > >> >>> > >> >>> def __init__(self): > >> >>> Gtk.Window.__init__(self, title="Hello World") > >> >>> > >> >>> self.button = Gtk.Button(label="Click Here") > >> >>> self.button.connect("clicked", self.on_button_clicked) > >> >>> self.add(self.button) > >> >>> > >> >>> def on_button_clicked(self, widget): > >> >>> fig = plt.figure() > >> >>> ax = fig.add_subplot(111) > >> >>> ax.plot([1,2,3]) > >> >>> plt.show() > >> >>> > >> >>> win = MyWindow() > >> >>> win.connect("delete-event", Gtk.main_quit) > >> >>> win.show_all() > >> >>> Gtk.main() > >> >>> ######################### > >> >>> > >> >>> I know this is related to interactive mode, but running from console > >> >>> >>> python myapp.py > >> >>> reproduces the problem > >> >>> > >> >>> Why hasattr(sys, 'ps1') is False? if I am running it from console? > how > >> >>> do I change this? > >> >>> > >> >>> > >> >>> Thanks > >> >>> Federico > >> >>> > >> >>> P.S. Does anybody had the time to check my PR for > >> >>> multi-figure-manager? > >> >>> https://github.com/matplotlib/matplotlib/pull/2465 > >> >>> > >> >>> -- > >> >>> Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? > >> >>> > >> >>> -- Antonio Alducin -- > >> >>> > >> >>> > >> >>> > >> >>> > ------------------------------------------------------------------------------ > >> >>> October Webinars: Code for Performance > >> >>> Free Intel webinars can help you accelerate application performance. > >> >>> Explore tips for MPI, OpenMP, advanced profiling, and more. Get the > >> >>> most > >> >>> from > >> >>> the latest Intel processors and coprocessors. See abstracts and > >> >>> register > > >> >>> > >> >>> > >> >>> > http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk > >> >>> _______________________________________________ > >> >>> Matplotlib-devel mailing list > >> >>> Mat...@li... > >> >>> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel > >> >> > >> >> > >> >> > >> >> > >> >> -- > >> >> Thomas A Caswell > >> >> PhD Candidate University of Chicago > >> >> Nagel and Gardel labs > >> >> tca...@uc... > >> >> jfi.uchicago.edu/~tcaswell > >> >> o: 773.702.7204 > >> > > >> > > >> > > >> > -- > >> > Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? > >> > > >> > -- Antonio Alducin -- > >> > >> > >> > >> -- > >> Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? > >> > >> -- Antonio Alducin -- > > > > > > > > > > -- > > Thomas A Caswell > > PhD Candidate University of Chicago > > Nagel and Gardel labs > > tca...@uc... > > jfi.uchicago.edu/~tcaswell > > o: 773.702.7204 > > > > -- > Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? > > -- Antonio Alducin -- > -- Thomas A Caswell PhD Candidate University of Chicago Nagel and Gardel labs tca...@uc... jfi.uchicago.edu/~tcaswell o: 773.702.7204 |
From: Federico A. <ari...@gm...> - 2013-10-11 18:36:12
|
@Eric But this imposses alot of restrictions? I want to have the GUI backend with the toolbar and everything. If I do it like you propose, I have to create the figures on the side when calling from a ipython session. and when calling from my gtk app, I have to create by hand everything even the toolbars etc... @Tom, I agree that the problem is within the figure manager. That is why I asked about the "unbalanced" ways to call Gtk.main and Gtk.main_quit I was checking https://github.com/matplotlib/matplotlib/pull/2503 but I think the solution proposed there does not help me. As you know I am trying to get the multi-figure-manager accepted or at least reviewed, At the end, if the only way to use a nice GUI backend is without calling it from other GUI, it does not help to have a nice GUI backend, you will have to redoit anyway. Federico On Fri, Oct 11, 2013 at 1:59 PM, Eric Firing <ef...@ha...> wrote: > On 2013/10/11 7:36 AM, Federico Ariza wrote: >> >> Ok, >> for me embedding is more of using the canvas directly and putting >> inside my own window. >> But OK, i give you that. >> >> In that case, >> if I have standalone funcion (or class) that can be run alone something >> like >> do_my_plots().... that if run with python myplots.py will display the >> plots. >> >> How can I add the do_my_plots call to my Gk3 app? and not having to >> worry that closing the plot windows will close my gtk3 app? > > > I think the choices are to rewrite do_my_plots to be consistent with your > embedding, or to run it in a separate process. For the former option, the > key is to keep pyplot out of everything except a top layer which is used > when calling via script or in a pyplot environment (e.g. ipython), but which > is not used in your gtk3 app. As an example (sorry it is rather long and > complex) see > http://currents.soest.hawaii.edu/hg/pycurrents/file/43a9236c62ff/plot/txyselect.py. > Note that pyplot is not even imported except inside a function that is used > to demonstrate the functionality in script mode. Therefore all the > functionality is accessible when embedding by importing the module, so long > as one does not call that one highest-level function. To embed, one simply > includes the contents of that function but without the pyplot parts. > > Eric > > >> >> Federico >> >> On Fri, Oct 11, 2013 at 1:32 PM, Eric Firing <ef...@ha...> wrote: >>> >>> On 2013/10/11 7:12 AM, Federico Ariza wrote: >>>> >>>> I am not embedding, just launching, as the example shows. >>> >>> >>> No, your example shows that you *are* embedding. You are running your >>> own Gtk.main(). That's embedding. >>> >>> >>> ------------------------------------------------------------------------------ >>> October Webinars: Code for Performance >>> Free Intel webinars can help you accelerate application performance. >>> Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most >>> from >>> the latest Intel processors and coprocessors. See abstracts and register >>> > >>> >>> http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk >>> _______________________________________________ >>> Matplotlib-devel mailing list >>> Mat...@li... >>> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel >> >> >> >> > -- Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? -- Antonio Alducin -- |
From: Benjamin R. <ben...@ou...> - 2013-10-11 18:16:54
|
On Tue, Oct 8, 2013 at 12:00 PM, jcskyhawk09 <jcs...@gm...> wrote: > Hi, > > I am trying to use matplotlib to create script files that I can use to > render 3D plots in blender. I have already created the code to create the > file itself. I am currently trying to find the best place to put my code > into. I have tried using top level methods like get_path(), however these > functions do not work because they return the data points after they have > been projected and to render in blender I need the raw data points. > > I have tried editing the axes3d file and was able to create a working file. > However, I am worried there will be too much code recreation at this level. > I have also attempted to edit the art3d file to try to have less code > generation. However, I was unable to find all of the data for the points. > Any help or ideas on where to put the code would be greatly appreciated. > > If anymore information is needed please let me know, this is my first post > so I apologize if I left something out. > > Thanks, > James > > > One of the main limitations that I see is that the top level code in mplot3d still needed to conform with the basic assumptions of matplotlib's rendering engine. That being a 2-D + z-ordering renderer. So, top-level functions like get_path() has to return a 2-D projected form of the internal 3-D data, and then a zorder value is provided to represent the 3rd dimension for all the data for that artist object. It is entirely possible to get at the internal data unmolested, but there is no unified mechanism for doing so. Sometimes the z-data is stored separately. Sometimes the data is stored as a Nx3 numpy array. What might be a useful endeavour is to first look to unify the 3d get/set methods of the art3d classes. Cheers! Ben Root |
From: Eric F. <ef...@ha...> - 2013-10-11 17:59:26
|
On 2013/10/11 7:36 AM, Federico Ariza wrote: > Ok, > for me embedding is more of using the canvas directly and putting > inside my own window. > But OK, i give you that. > > In that case, > if I have standalone funcion (or class) that can be run alone something like > do_my_plots().... that if run with python myplots.py will display the plots. > > How can I add the do_my_plots call to my Gk3 app? and not having to > worry that closing the plot windows will close my gtk3 app? I think the choices are to rewrite do_my_plots to be consistent with your embedding, or to run it in a separate process. For the former option, the key is to keep pyplot out of everything except a top layer which is used when calling via script or in a pyplot environment (e.g. ipython), but which is not used in your gtk3 app. As an example (sorry it is rather long and complex) see http://currents.soest.hawaii.edu/hg/pycurrents/file/43a9236c62ff/plot/txyselect.py. Note that pyplot is not even imported except inside a function that is used to demonstrate the functionality in script mode. Therefore all the functionality is accessible when embedding by importing the module, so long as one does not call that one highest-level function. To embed, one simply includes the contents of that function but without the pyplot parts. Eric > > Federico > > On Fri, Oct 11, 2013 at 1:32 PM, Eric Firing <ef...@ha...> wrote: >> On 2013/10/11 7:12 AM, Federico Ariza wrote: >>> I am not embedding, just launching, as the example shows. >> >> No, your example shows that you *are* embedding. You are running your >> own Gtk.main(). That's embedding. >> >> ------------------------------------------------------------------------------ >> October Webinars: Code for Performance >> Free Intel webinars can help you accelerate application performance. >> Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from >> the latest Intel processors and coprocessors. See abstracts and register > >> http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk >> _______________________________________________ >> Matplotlib-devel mailing list >> Mat...@li... >> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel > > > |
From: Federico A. <ari...@gm...> - 2013-10-11 17:37:15
|
Ok, for me embedding is more of using the canvas directly and putting inside my own window. But OK, i give you that. In that case, if I have standalone funcion (or class) that can be run alone something like do_my_plots().... that if run with python myplots.py will display the plots. How can I add the do_my_plots call to my Gk3 app? and not having to worry that closing the plot windows will close my gtk3 app? Federico On Fri, Oct 11, 2013 at 1:32 PM, Eric Firing <ef...@ha...> wrote: > On 2013/10/11 7:12 AM, Federico Ariza wrote: >> I am not embedding, just launching, as the example shows. > > No, your example shows that you *are* embedding. You are running your > own Gtk.main(). That's embedding. > > ------------------------------------------------------------------------------ > October Webinars: Code for Performance > Free Intel webinars can help you accelerate application performance. > Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from > the latest Intel processors and coprocessors. See abstracts and register > > http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk > _______________________________________________ > Matplotlib-devel mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-devel -- Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? -- Antonio Alducin -- |
From: Thomas A C. <tca...@uc...> - 2013-10-11 17:33:00
|
embedding vs launching is a distinction without a difference, you are integrating matplotlib with your own gui application. That said, it would be nice to re-factor the figure_manager classes so they they make no reference to `Gcf` or anything associated with pylab and could be easily re-used. I think that would also help with the issues in https://github.com/matplotlib/matplotlib/pull/2503 Tom On Fri, Oct 11, 2013 at 12:14 PM, Federico Ariza <ari...@gm...>wrote: > Again > > In the example the plotting is inside the callback (just for > simplicity), but in reality, the plotting is in another class, > somewhere else that can be called standalone to produce the plots. > > Federico > > On Fri, Oct 11, 2013 at 1:12 PM, Federico Ariza > <ari...@gm...> wrote: > > I am not embedding, just launching, as the example shows. > > > > Federico > > > > On Fri, Oct 11, 2013 at 1:11 PM, Thomas A Caswell <tca...@uc...> > wrote: > >> If you are embedding matplotlib, do not import `pyplot`. `pyplot` sets > up a > >> bunch of gui-magic (tm) in the background (as you found in > >> `figure_manager`). > >> > >> Tom > >> > >> > >> On Fri, Oct 11, 2013 at 11:57 AM, Federico Ariza < > ari...@gm...> > >> wrote: > >>> > >>> Hello everybody > >>> > >>> Working on one GTK3 app, that calls matplotlib to plot some figures, I > >>> found that closing all the figures from matplotlib kills my app also. > >>> The problem.... > >>> > >>> Gtk.main() is called only if there is no previous invocation, in my > >>> case, my Gtk3 app invokes main, so the mainloop won't call it again. > >>> > >>> #in backend_gtk3.py > >>> # > >>> class Show(ShowBase): > >>> def mainloop(self): > >>> if Gtk.main_level() == 0: > >>> Gtk.main() > >>> > >>> But in the "destroy" method of the figure manager calls Gtk.main_quit > >>> everytime that there are no more figures > >>> > >>> #in backend_gtk3.py inside destroy method of FigureManagerGTK3 > >>> # > >>> if Gcf.get_num_fig_managers()==0 and \ > >>> not matplotlib.is_interactive() and \ > >>> Gtk.main_level() >= 1: > >>> Gtk.main_quit() > >>> > >>> > >>> So basically we are not calling Gtk.main but we are Gtk.calling > main_quit. > >>> Isn't it more natural to call Gtk.main the same amount of times that > >>> we are going to call Gtk.main_quit? > >>> > >>> Adding matplotlib.rcParams['interactive'] = True doesn't help > >>> > >>> Here is my little testing code > >>> > >>> ############################## > >>> #file myapp.py > >>> > >>> import matplotlib > >>> matplotlib.rcParams['interactive'] = True > >>> matplotlib.use('GTK3AGG') > >>> import matplotlib.pyplot as plt > >>> > >>> from gi.repository import Gtk > >>> > >>> class MyWindow(Gtk.Window): > >>> > >>> def __init__(self): > >>> Gtk.Window.__init__(self, title="Hello World") > >>> > >>> self.button = Gtk.Button(label="Click Here") > >>> self.button.connect("clicked", self.on_button_clicked) > >>> self.add(self.button) > >>> > >>> def on_button_clicked(self, widget): > >>> fig = plt.figure() > >>> ax = fig.add_subplot(111) > >>> ax.plot([1,2,3]) > >>> plt.show() > >>> > >>> win = MyWindow() > >>> win.connect("delete-event", Gtk.main_quit) > >>> win.show_all() > >>> Gtk.main() > >>> ######################### > >>> > >>> I know this is related to interactive mode, but running from console > >>> >>> python myapp.py > >>> reproduces the problem > >>> > >>> Why hasattr(sys, 'ps1') is False? if I am running it from console? how > >>> do I change this? > >>> > >>> > >>> Thanks > >>> Federico > >>> > >>> P.S. Does anybody had the time to check my PR for multi-figure-manager? > >>> https://github.com/matplotlib/matplotlib/pull/2465 > >>> > >>> -- > >>> Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? > >>> > >>> -- Antonio Alducin -- > >>> > >>> > >>> > ------------------------------------------------------------------------------ > >>> October Webinars: Code for Performance > >>> Free Intel webinars can help you accelerate application performance. > >>> Explore tips for MPI, OpenMP, advanced profiling, and more. Get the > most > >>> from > >>> the latest Intel processors and coprocessors. See abstracts and > register > > >>> > >>> > http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk > >>> _______________________________________________ > >>> Matplotlib-devel mailing list > >>> Mat...@li... > >>> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel > >> > >> > >> > >> > >> -- > >> Thomas A Caswell > >> PhD Candidate University of Chicago > >> Nagel and Gardel labs > >> tca...@uc... > >> jfi.uchicago.edu/~tcaswell > >> o: 773.702.7204 > > > > > > > > -- > > Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? > > > > -- Antonio Alducin -- > > > > -- > Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? > > -- Antonio Alducin -- > -- Thomas A Caswell PhD Candidate University of Chicago Nagel and Gardel labs tca...@uc... jfi.uchicago.edu/~tcaswell o: 773.702.7204 |
From: Eric F. <ef...@ha...> - 2013-10-11 17:32:10
|
On 2013/10/11 7:12 AM, Federico Ariza wrote: > I am not embedding, just launching, as the example shows. No, your example shows that you *are* embedding. You are running your own Gtk.main(). That's embedding. |
From: Federico A. <ari...@gm...> - 2013-10-11 17:15:09
|
Again In the example the plotting is inside the callback (just for simplicity), but in reality, the plotting is in another class, somewhere else that can be called standalone to produce the plots. Federico On Fri, Oct 11, 2013 at 1:12 PM, Federico Ariza <ari...@gm...> wrote: > I am not embedding, just launching, as the example shows. > > Federico > > On Fri, Oct 11, 2013 at 1:11 PM, Thomas A Caswell <tca...@uc...> wrote: >> If you are embedding matplotlib, do not import `pyplot`. `pyplot` sets up a >> bunch of gui-magic (tm) in the background (as you found in >> `figure_manager`). >> >> Tom >> >> >> On Fri, Oct 11, 2013 at 11:57 AM, Federico Ariza <ari...@gm...> >> wrote: >>> >>> Hello everybody >>> >>> Working on one GTK3 app, that calls matplotlib to plot some figures, I >>> found that closing all the figures from matplotlib kills my app also. >>> The problem.... >>> >>> Gtk.main() is called only if there is no previous invocation, in my >>> case, my Gtk3 app invokes main, so the mainloop won't call it again. >>> >>> #in backend_gtk3.py >>> # >>> class Show(ShowBase): >>> def mainloop(self): >>> if Gtk.main_level() == 0: >>> Gtk.main() >>> >>> But in the "destroy" method of the figure manager calls Gtk.main_quit >>> everytime that there are no more figures >>> >>> #in backend_gtk3.py inside destroy method of FigureManagerGTK3 >>> # >>> if Gcf.get_num_fig_managers()==0 and \ >>> not matplotlib.is_interactive() and \ >>> Gtk.main_level() >= 1: >>> Gtk.main_quit() >>> >>> >>> So basically we are not calling Gtk.main but we are Gtk.calling main_quit. >>> Isn't it more natural to call Gtk.main the same amount of times that >>> we are going to call Gtk.main_quit? >>> >>> Adding matplotlib.rcParams['interactive'] = True doesn't help >>> >>> Here is my little testing code >>> >>> ############################## >>> #file myapp.py >>> >>> import matplotlib >>> matplotlib.rcParams['interactive'] = True >>> matplotlib.use('GTK3AGG') >>> import matplotlib.pyplot as plt >>> >>> from gi.repository import Gtk >>> >>> class MyWindow(Gtk.Window): >>> >>> def __init__(self): >>> Gtk.Window.__init__(self, title="Hello World") >>> >>> self.button = Gtk.Button(label="Click Here") >>> self.button.connect("clicked", self.on_button_clicked) >>> self.add(self.button) >>> >>> def on_button_clicked(self, widget): >>> fig = plt.figure() >>> ax = fig.add_subplot(111) >>> ax.plot([1,2,3]) >>> plt.show() >>> >>> win = MyWindow() >>> win.connect("delete-event", Gtk.main_quit) >>> win.show_all() >>> Gtk.main() >>> ######################### >>> >>> I know this is related to interactive mode, but running from console >>> >>> python myapp.py >>> reproduces the problem >>> >>> Why hasattr(sys, 'ps1') is False? if I am running it from console? how >>> do I change this? >>> >>> >>> Thanks >>> Federico >>> >>> P.S. Does anybody had the time to check my PR for multi-figure-manager? >>> https://github.com/matplotlib/matplotlib/pull/2465 >>> >>> -- >>> Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? >>> >>> -- Antonio Alducin -- >>> >>> >>> ------------------------------------------------------------------------------ >>> October Webinars: Code for Performance >>> Free Intel webinars can help you accelerate application performance. >>> Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most >>> from >>> the latest Intel processors and coprocessors. See abstracts and register > >>> >>> http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk >>> _______________________________________________ >>> Matplotlib-devel mailing list >>> Mat...@li... >>> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel >> >> >> >> >> -- >> Thomas A Caswell >> PhD Candidate University of Chicago >> Nagel and Gardel labs >> tca...@uc... >> jfi.uchicago.edu/~tcaswell >> o: 773.702.7204 > > > > -- > Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? > > -- Antonio Alducin -- -- Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? -- Antonio Alducin -- |
From: Federico A. <ari...@gm...> - 2013-10-11 17:13:13
|
I am not embedding, just launching, as the example shows. Federico On Fri, Oct 11, 2013 at 1:11 PM, Thomas A Caswell <tca...@uc...> wrote: > If you are embedding matplotlib, do not import `pyplot`. `pyplot` sets up a > bunch of gui-magic (tm) in the background (as you found in > `figure_manager`). > > Tom > > > On Fri, Oct 11, 2013 at 11:57 AM, Federico Ariza <ari...@gm...> > wrote: >> >> Hello everybody >> >> Working on one GTK3 app, that calls matplotlib to plot some figures, I >> found that closing all the figures from matplotlib kills my app also. >> The problem.... >> >> Gtk.main() is called only if there is no previous invocation, in my >> case, my Gtk3 app invokes main, so the mainloop won't call it again. >> >> #in backend_gtk3.py >> # >> class Show(ShowBase): >> def mainloop(self): >> if Gtk.main_level() == 0: >> Gtk.main() >> >> But in the "destroy" method of the figure manager calls Gtk.main_quit >> everytime that there are no more figures >> >> #in backend_gtk3.py inside destroy method of FigureManagerGTK3 >> # >> if Gcf.get_num_fig_managers()==0 and \ >> not matplotlib.is_interactive() and \ >> Gtk.main_level() >= 1: >> Gtk.main_quit() >> >> >> So basically we are not calling Gtk.main but we are Gtk.calling main_quit. >> Isn't it more natural to call Gtk.main the same amount of times that >> we are going to call Gtk.main_quit? >> >> Adding matplotlib.rcParams['interactive'] = True doesn't help >> >> Here is my little testing code >> >> ############################## >> #file myapp.py >> >> import matplotlib >> matplotlib.rcParams['interactive'] = True >> matplotlib.use('GTK3AGG') >> import matplotlib.pyplot as plt >> >> from gi.repository import Gtk >> >> class MyWindow(Gtk.Window): >> >> def __init__(self): >> Gtk.Window.__init__(self, title="Hello World") >> >> self.button = Gtk.Button(label="Click Here") >> self.button.connect("clicked", self.on_button_clicked) >> self.add(self.button) >> >> def on_button_clicked(self, widget): >> fig = plt.figure() >> ax = fig.add_subplot(111) >> ax.plot([1,2,3]) >> plt.show() >> >> win = MyWindow() >> win.connect("delete-event", Gtk.main_quit) >> win.show_all() >> Gtk.main() >> ######################### >> >> I know this is related to interactive mode, but running from console >> >>> python myapp.py >> reproduces the problem >> >> Why hasattr(sys, 'ps1') is False? if I am running it from console? how >> do I change this? >> >> >> Thanks >> Federico >> >> P.S. Does anybody had the time to check my PR for multi-figure-manager? >> https://github.com/matplotlib/matplotlib/pull/2465 >> >> -- >> Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? >> >> -- Antonio Alducin -- >> >> >> ------------------------------------------------------------------------------ >> October Webinars: Code for Performance >> Free Intel webinars can help you accelerate application performance. >> Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most >> from >> the latest Intel processors and coprocessors. See abstracts and register > >> >> http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk >> _______________________________________________ >> Matplotlib-devel mailing list >> Mat...@li... >> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel > > > > > -- > Thomas A Caswell > PhD Candidate University of Chicago > Nagel and Gardel labs > tca...@uc... > jfi.uchicago.edu/~tcaswell > o: 773.702.7204 -- Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? -- Antonio Alducin -- |
From: Thomas A C. <tca...@uc...> - 2013-10-11 17:11:40
|
If you are embedding matplotlib, do not import `pyplot`. `pyplot` sets up a bunch of gui-magic (tm) in the background (as you found in `figure_manager`). Tom On Fri, Oct 11, 2013 at 11:57 AM, Federico Ariza <ari...@gm...>wrote: > Hello everybody > > Working on one GTK3 app, that calls matplotlib to plot some figures, I > found that closing all the figures from matplotlib kills my app also. > The problem.... > > Gtk.main() is called only if there is no previous invocation, in my > case, my Gtk3 app invokes main, so the mainloop won't call it again. > > #in backend_gtk3.py > # > class Show(ShowBase): > def mainloop(self): > if Gtk.main_level() == 0: > Gtk.main() > > But in the "destroy" method of the figure manager calls Gtk.main_quit > everytime that there are no more figures > > #in backend_gtk3.py inside destroy method of FigureManagerGTK3 > # > if Gcf.get_num_fig_managers()==0 and \ > not matplotlib.is_interactive() and \ > Gtk.main_level() >= 1: > Gtk.main_quit() > > > So basically we are not calling Gtk.main but we are Gtk.calling main_quit. > Isn't it more natural to call Gtk.main the same amount of times that > we are going to call Gtk.main_quit? > > Adding matplotlib.rcParams['interactive'] = True doesn't help > > Here is my little testing code > > ############################## > #file myapp.py > > import matplotlib > matplotlib.rcParams['interactive'] = True > matplotlib.use('GTK3AGG') > import matplotlib.pyplot as plt > > from gi.repository import Gtk > > class MyWindow(Gtk.Window): > > def __init__(self): > Gtk.Window.__init__(self, title="Hello World") > > self.button = Gtk.Button(label="Click Here") > self.button.connect("clicked", self.on_button_clicked) > self.add(self.button) > > def on_button_clicked(self, widget): > fig = plt.figure() > ax = fig.add_subplot(111) > ax.plot([1,2,3]) > plt.show() > > win = MyWindow() > win.connect("delete-event", Gtk.main_quit) > win.show_all() > Gtk.main() > ######################### > > I know this is related to interactive mode, but running from console > >>> python myapp.py > reproduces the problem > > Why hasattr(sys, 'ps1') is False? if I am running it from console? how > do I change this? > > > Thanks > Federico > > P.S. Does anybody had the time to check my PR for multi-figure-manager? > https://github.com/matplotlib/matplotlib/pull/2465 > > -- > Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? > > -- Antonio Alducin -- > > > ------------------------------------------------------------------------------ > October Webinars: Code for Performance > Free Intel webinars can help you accelerate application performance. > Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most > from > the latest Intel processors and coprocessors. See abstracts and register > > http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk > _______________________________________________ > Matplotlib-devel mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-devel > -- Thomas A Caswell PhD Candidate University of Chicago Nagel and Gardel labs tca...@uc... jfi.uchicago.edu/~tcaswell o: 773.702.7204 |
From: Federico A. <ari...@gm...> - 2013-10-11 16:57:53
|
Hello everybody Working on one GTK3 app, that calls matplotlib to plot some figures, I found that closing all the figures from matplotlib kills my app also. The problem.... Gtk.main() is called only if there is no previous invocation, in my case, my Gtk3 app invokes main, so the mainloop won't call it again. #in backend_gtk3.py # class Show(ShowBase): def mainloop(self): if Gtk.main_level() == 0: Gtk.main() But in the "destroy" method of the figure manager calls Gtk.main_quit everytime that there are no more figures #in backend_gtk3.py inside destroy method of FigureManagerGTK3 # if Gcf.get_num_fig_managers()==0 and \ not matplotlib.is_interactive() and \ Gtk.main_level() >= 1: Gtk.main_quit() So basically we are not calling Gtk.main but we are Gtk.calling main_quit. Isn't it more natural to call Gtk.main the same amount of times that we are going to call Gtk.main_quit? Adding matplotlib.rcParams['interactive'] = True doesn't help Here is my little testing code ############################## #file myapp.py import matplotlib matplotlib.rcParams['interactive'] = True matplotlib.use('GTK3AGG') import matplotlib.pyplot as plt from gi.repository import Gtk class MyWindow(Gtk.Window): def __init__(self): Gtk.Window.__init__(self, title="Hello World") self.button = Gtk.Button(label="Click Here") self.button.connect("clicked", self.on_button_clicked) self.add(self.button) def on_button_clicked(self, widget): fig = plt.figure() ax = fig.add_subplot(111) ax.plot([1,2,3]) plt.show() win = MyWindow() win.connect("delete-event", Gtk.main_quit) win.show_all() Gtk.main() ######################### I know this is related to interactive mode, but running from console >>> python myapp.py reproduces the problem Why hasattr(sys, 'ps1') is False? if I am running it from console? how do I change this? Thanks Federico P.S. Does anybody had the time to check my PR for multi-figure-manager? https://github.com/matplotlib/matplotlib/pull/2465 -- Y yo que culpa tengo de que ellas se crean todo lo que yo les digo? -- Antonio Alducin -- |
From: Jason G. <jas...@cr...> - 2013-10-10 22:08:45
|
I've been working on a backend based on the webagg backend, but that uses the IPython Comm architecture at https://github.com/ipython/ipython/pull/4195 to send messages instead of starting a server and opening websocket connections. I have an initial version in my github ipython-comm branch (see https://github.com/jasongrout/matplotlib/compare/ipython-comm). I'm getting confused about how the backend infrastructure works, though, like what the purpose for the FigureManager class is, etc. I'm running out of time to work on this now, and I'm hoping that someone will take what work I've done here and get it working properly with the matplotlib architecture. If not, I'll probably tinker with this more later. Thanks, Jason -- Jason Grout |
From: Alexander H. <mat...@2s...> - 2013-10-10 22:04:30
|
I am using Fedora 19, 64 bit, and the distribution's python 3.3.2, and the most recent version of mpl from git there seems to be a bug in the starup routine where proper conversion from bytes to string (as needed for Python 3) is not done the problem is in /matplotlib/__init__.py, line 459 ... 460 459 gs_exec, gs_v = checkdep_ghostscript() 460 if compare_versions(gs_v, gs_sugg): pass ipdb> gs_exec, gs_v ('gs', b'9.07') where clearly gs_v needs to be str Could you please make checkdep_ghostscript() to be python3-save by changing line 334 from v = stdout[:-1] to v = stdout[:-1].decode('ascii') (my apologies not following the bug report procedures; I hope you can consider it anyway) -Alexander ~/python/source3>ip Python 3.3.2 (default, Aug 23 2013, 19:00:04) Type "copyright", "credits" or "license" for more information. IPython 0.13.2 -- An enhanced Interactive Python. ? -> Introduction and overview of IPython's features. %quickref -> Quick reference. help -> Python's own help system. object? -> Details about 'object', use 'object??' for extra details. [TerminalIPythonApp] GUI event loop or pylab initialization failed --------------------------------------------------------------------------- TypeError Traceback (most recent call last) /usr/lib/python3.3/site-packages/IPython/core/pylabtools.py in find_gui_and_backend(gui) 194 """ 195 --> 196 import matplotlib 197 198 if gui and gui != 'auto': /home/alex/mpl/usr/lib64/python3.3/site-packages/matplotlib/__init__.py in <module>() 975 976 rcParams['ps.usedistiller'] = checkdep_ps_distiller(rcParams['ps.usedistiller']) --> 977 rcParams['text.usetex'] = checkdep_usetex(rcParams['text.usetex']) 978 979 if rcParams['axes.formatter.use_locale']: /home/alex/mpl/usr/lib64/python3.3/site-packages/matplotlib/__init__.py in checkdep_usetex(s) 458 459 gs_exec, gs_v = checkdep_ghostscript() --> 460 if compare_versions(gs_v, gs_sugg): pass 461 elif compare_versions(gs_v, gs_req): 462 verbose.report(('ghostscript-%s found. ghostscript-%s or later is ' /home/alex/mpl/usr/lib64/python3.3/site-packages/matplotlib/__init__.py in compare_versions(a, b) 116 "return True if a is greater than or equal to b" 117 if a: --> 118 a = distutils.version.LooseVersion(a) 119 b = distutils.version.LooseVersion(b) 120 if a>=b: return True /usr/lib64/python3.3/distutils/version.py in __init__(self, vstring) 308 def __init__ (self, vstring=None): 309 if vstring: --> 310 self.parse(vstring) 311 312 /usr/lib64/python3.3/distutils/version.py in parse(self, vstring) 316 # use by __str__ 317 self.vstring = vstring --> 318 components = [x for x in self.component_re.split(vstring) 319 if x and x != '.'] 320 for i, obj in enumerate(components): TypeError: can't use a string pattern on a bytes-like object |
From: Todd <tod...@gm...> - 2013-10-10 21:02:55
|
The branch is matplotlib/toddrjen spectral: https://github.com/toddrjen/matplotlib/tree/spectral Specifically the tests that are causing the problem are in test_mlab.py. I tried reorganizing the tests into subclasses and implementing a cleanup class (that is the current HEAD), but the problem exists even without that commit. You can cherry-pick 50c90102a929af5d534e551fd624abffeb9470b8 and 7c1b4db8b2d04826e267781c0de1bcc622f0fdb5. On Thu, Oct 10, 2013 at 3:22 PM, Michael Droettboom <md...@st...> wrote: > Are your tests including the "@cleanup" decorator? (The @cleanup > decorator is run implicitly with the @image_comparison decorator, so you > really only need one or the other). > > Beyond that wild guess, I'm not sure what could be going on. You could > file a pull request with your new code, even if it's not fully ready, so we > could try it out and poke at it. Or just point us to your git branch so we > could check it out. > > Mike > > > On 10/10/2013 07:33 AM, Todd wrote: > > I have been implementing some new plot types, with tests. This code > passes all existing tests. I have also expanded the tests on some existing > plot types and mlab functions. These tests run fine on their own. > > The problem is that, when I run the code with the new tests, I get a lot > of out of memory errors. Further, the errors do not occur in the new > tests, but rather in other, unrelated tests. Further, the tests that fail > work fine when run on their own, they only fail when run as part of the > complete test suite. > > Even stranger, when I run the tests in parallel (even with only one > process) and enable "--process-restartworker", the tests run fine (with a > large enough timeout). But "--process-restartworker" doesn't help if > parallel tests are not turned on. > > So I am not sure exactly what to do here. Even if I leave out my own > tests, I may be running into some limit or memory leak that may very well > result in problems for other people down the road. > > A solution might be to force tests to run in parallel with > "--process-restartworker", but of course it would be better to find out > where the leak is. > > > ------------------------------------------------------------------------------ > October Webinars: Code for Performance > Free Intel webinars can help you accelerate application performance. > Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from > the latest Intel processors and coprocessors. See abstracts and register >http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk > > > > _______________________________________________ > Matplotlib-devel mailing lis...@li...https://lists.sourceforge.net/lists/listinfo/matplotlib-devel > > > > -- > _ > |\/|o _|_ _. _ | | \.__ __|__|_|_ _ _ ._ _ > | ||(_| |(_|(/_| |_/|(_)(/_|_ |_|_)(_)(_)| | | > http://www.droettboom.com > > > > ------------------------------------------------------------------------------ > October Webinars: Code for Performance > Free Intel webinars can help you accelerate application performance. > Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most > from > the latest Intel processors and coprocessors. See abstracts and register > > http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk > _______________________________________________ > Matplotlib-devel mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-devel > > |
From: Michael D. <md...@st...> - 2013-10-10 13:38:21
|
I have tagged and uploaded 1.3.1. It is exactly the same as 1.3.1rc2, with only the version number being different. Once the Windows binaries are ready, I'll make a broader announcement in the usual places. Mike -- _ |\/|o _|_ _. _ | | \.__ __|__|_|_ _ _ ._ _ | ||(_| |(_|(/_| |_/|(_)(/_|_ |_|_)(_)(_)| | | http://www.droettboom.com |