You can subscribe to this list here.
| 2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(3) |
Jun
|
Jul
|
Aug
(12) |
Sep
(12) |
Oct
(56) |
Nov
(65) |
Dec
(37) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2004 |
Jan
(59) |
Feb
(78) |
Mar
(153) |
Apr
(205) |
May
(184) |
Jun
(123) |
Jul
(171) |
Aug
(156) |
Sep
(190) |
Oct
(120) |
Nov
(154) |
Dec
(223) |
| 2005 |
Jan
(184) |
Feb
(267) |
Mar
(214) |
Apr
(286) |
May
(320) |
Jun
(299) |
Jul
(348) |
Aug
(283) |
Sep
(355) |
Oct
(293) |
Nov
(232) |
Dec
(203) |
| 2006 |
Jan
(352) |
Feb
(358) |
Mar
(403) |
Apr
(313) |
May
(165) |
Jun
(281) |
Jul
(316) |
Aug
(228) |
Sep
(279) |
Oct
(243) |
Nov
(315) |
Dec
(345) |
| 2007 |
Jan
(260) |
Feb
(323) |
Mar
(340) |
Apr
(319) |
May
(290) |
Jun
(296) |
Jul
(221) |
Aug
(292) |
Sep
(242) |
Oct
(248) |
Nov
(242) |
Dec
(332) |
| 2008 |
Jan
(312) |
Feb
(359) |
Mar
(454) |
Apr
(287) |
May
(340) |
Jun
(450) |
Jul
(403) |
Aug
(324) |
Sep
(349) |
Oct
(385) |
Nov
(363) |
Dec
(437) |
| 2009 |
Jan
(500) |
Feb
(301) |
Mar
(409) |
Apr
(486) |
May
(545) |
Jun
(391) |
Jul
(518) |
Aug
(497) |
Sep
(492) |
Oct
(429) |
Nov
(357) |
Dec
(310) |
| 2010 |
Jan
(371) |
Feb
(657) |
Mar
(519) |
Apr
(432) |
May
(312) |
Jun
(416) |
Jul
(477) |
Aug
(386) |
Sep
(419) |
Oct
(435) |
Nov
(320) |
Dec
(202) |
| 2011 |
Jan
(321) |
Feb
(413) |
Mar
(299) |
Apr
(215) |
May
(284) |
Jun
(203) |
Jul
(207) |
Aug
(314) |
Sep
(321) |
Oct
(259) |
Nov
(347) |
Dec
(209) |
| 2012 |
Jan
(322) |
Feb
(414) |
Mar
(377) |
Apr
(179) |
May
(173) |
Jun
(234) |
Jul
(295) |
Aug
(239) |
Sep
(276) |
Oct
(355) |
Nov
(144) |
Dec
(108) |
| 2013 |
Jan
(170) |
Feb
(89) |
Mar
(204) |
Apr
(133) |
May
(142) |
Jun
(89) |
Jul
(160) |
Aug
(180) |
Sep
(69) |
Oct
(136) |
Nov
(83) |
Dec
(32) |
| 2014 |
Jan
(71) |
Feb
(90) |
Mar
(161) |
Apr
(117) |
May
(78) |
Jun
(94) |
Jul
(60) |
Aug
(83) |
Sep
(102) |
Oct
(132) |
Nov
(154) |
Dec
(96) |
| 2015 |
Jan
(45) |
Feb
(138) |
Mar
(176) |
Apr
(132) |
May
(119) |
Jun
(124) |
Jul
(77) |
Aug
(31) |
Sep
(34) |
Oct
(22) |
Nov
(23) |
Dec
(9) |
| 2016 |
Jan
(26) |
Feb
(17) |
Mar
(10) |
Apr
(8) |
May
(4) |
Jun
(8) |
Jul
(6) |
Aug
(5) |
Sep
(9) |
Oct
(4) |
Nov
|
Dec
|
| 2017 |
Jan
(5) |
Feb
(7) |
Mar
(1) |
Apr
(5) |
May
|
Jun
(3) |
Jul
(6) |
Aug
(1) |
Sep
|
Oct
(2) |
Nov
(1) |
Dec
|
| 2018 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2020 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2025 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| S | M | T | W | T | F | S |
|---|---|---|---|---|---|---|
|
|
|
|
1
(13) |
2
(11) |
3
|
4
(9) |
|
5
(3) |
6
(17) |
7
(24) |
8
(11) |
9
(26) |
10
(19) |
11
(4) |
|
12
(4) |
13
(14) |
14
(9) |
15
(5) |
16
(18) |
17
(23) |
18
(3) |
|
19
(1) |
20
(7) |
21
(27) |
22
(26) |
23
(6) |
24
(17) |
25
(1) |
|
26
|
27
(7) |
28
(1) |
29
(4) |
30
(5) |
|
|
|
From: Pierre GM <pgm...@gm...> - 2006-11-24 20:34:35
|
On Friday 24 November 2006 15:14, Darren Dale wrote: > Or, you can change the formatter of your yaxis to OldScalarFormatter, which > renders the scientific notation in each tick label, rather than at the top > of the axis. Thinking about it: is there a way to grab this scientific notation ? The idea would be to get the corresponding object as a string, and update the ylabel with it. |
|
From: Darren D. <dd...@co...> - 2006-11-24 20:14:32
|
On Friday 24 November 2006 3:10 pm, Pierre GM wrote: > > How could I avoid this overlapping? > > What about deleting your first tick on ax2, with > > >>> ax2.set_xticks(ax2.get_xticks()[1:]) > > at the end of your code ? Or, you can change the formatter of your yaxis to OldScalarFormatter, which renders the scientific notation in each tick label, rather than at the top of the axis. |
|
From: Pierre GM <pgm...@gm...> - 2006-11-24 20:10:44
|
> How could I avoid this overlapping? What about deleting your first tick on ax2, with >>> ax2.set_xticks(ax2.get_xticks()[1:]) at the end of your code ? |
|
From: David T. <dav...@gm...> - 2006-11-24 19:47:36
|
Hi all,
I use sharey functionality on a regular basis for my plots.
Nice,but ticks are sometime overlapping and are unreadable in the top-left
corner (see figure joined).
Also joined, a small script reproducing the problem.
How could I avoid this overlapping?
Thanks
David
|
|
From: Darren D. <dd...@co...> - 2006-11-24 15:32:39
|
On Friday 24 November 2006 10:19 am, Christian Kristukat wrote: > Darren Dale <dd55@...> writes: > > On Thursday 23 November 2006 1:21 am, Christian Kristukat wrote: > > > I found one more solution which makes use of the sansmath.py style, > > > available at > > > http://www.tug.org/tex-archive/macros/latex/contrib/misc/sansmath.sty. > > > > > > To use it with matplotlib I updated the 'sans-serif' member of the > > > font_info dict: > > > > > > 'sans-serif': ('cmss', '\usepackage{sansmath}'), > > > > > > and to the end of sansmath.py > > > > What is sansmath.py? > > I meant sansmath.sty of course, sorry. > > > sansmath.sty is not distributed with tetex, and it doesnt look like it is > > included in the mac tex distributions. I'm sorry, but I don't think this > > is a viable solution. > > I know. I thought, as sansmath.sty is really short, it could be added to > the tex header for mpl's text generation. Oh, I see. That may be possible, but I think it needs some testing before we try it. There must be a reason that sansmath is not distributed with tetex, maybe because of all the conditions concerning greek symbols listed in the sty file. I don't have as much time to work on mpl these days, and usetex has fortunately not required much attention lately. I'm therefore hesitant to try to add new features, especially those that latex is not really designed to support. Darren |
|
From: Christian K. <ck...@ho...> - 2006-11-24 15:20:27
|
Darren Dale <dd55@...> writes: > On Thursday 23 November 2006 1:21 am, Christian Kristukat wrote: > > I found one more solution which makes use of the sansmath.py style, > > available at > > http://www.tug.org/tex-archive/macros/latex/contrib/misc/sansmath.sty. > > > > To use it with matplotlib I updated the 'sans-serif' member of the > > font_info dict: > > > > 'sans-serif': ('cmss', '\usepackage{sansmath}'), > > > > and to the end of sansmath.py > > What is sansmath.py? I meant sansmath.sty of course, sorry. > sansmath.sty is not distributed with tetex, and it doesnt look like it is > included in the mac tex distributions. I'm sorry, but I don't think this is a > viable solution. I know. I thought, as sansmath.sty is really short, it could be added to the tex header for mpl's text generation. Christian |
|
From: Darren D. <dd...@co...> - 2006-11-24 14:42:29
|
On Thursday 23 November 2006 1:21 am, Christian Kristukat wrote: > I found one more solution which makes use of the sansmath.py style, > available at > http://www.tug.org/tex-archive/macros/latex/contrib/misc/sansmath.sty. > > To use it with matplotlib I updated the 'sans-serif' member of the > font_info dict: > > 'sans-serif': ('cmss', '\usepackage{sansmath}'), > > and to the end of sansmath.py What is sansmath.py? > I added > > \sansmath > > to activate sans math mode upon loading. Then, choosing 'sans-serif' as > first sansserif font in .matplotlibrc you get nice serif free math text. > > It should be easy to add this to the matplotlib distro. sansmath.sty is not distributed with tetex, and it doesnt look like it is included in the mac tex distributions. I'm sorry, but I don't think this is a viable solution. Darren |
|
From: Darren D. <dd...@co...> - 2006-11-24 14:27:42
|
On Thursday 23 November 2006 12:23 am, Christian Kristukat wrote: > Christian Kristukat <ckkart@...> writes: > > Darren Dale <dd55 <at> ...> writes: > > > We tried supporting sans-serif ticklabels with usetex a while back, and > > > it turned out to be a headache. I'll have a look at cmbright, but no > > > promises. > > > > Thanks. Btw., I didn't know about cmbright before looking at this > > problem. It seems to be part of most tex distributions, e.g. tetex, > > miktex. > > I kept on experimenting and now ps output works, too. However it was > necessary to install the type1 version of the cmbright fonts, which are > unfortunately not part of tetex. They are available here: > http://hannes.boehm.org/LaTeX/ > I don't know if it is possible to have them outside the regular tetex tree > and make tex use them so that they could be shipped with matplotlib. > Or is that solution not acceptable at all? I don't think it is possible to accept this as a solution to include in mpl. No license information is listed with the type1 fonts you linked to, but Micropress charges for a version of type1 cmbright fonts. Plus, even if the licensing was not an issue, we'd have to deal with installing them into the localtexmf tree and then run texhash to refresh tex's database of installed fonts, I see lots of potential for problems. Darren |
|
From: Martin R. <law...@gm...> - 2006-11-24 13:12:52
|
Hello everyone,
although I thought this topic had been discussed earlier I wasn't able to find
it in the archives. So please forgive me if I'm repeating something. Here the
question I'm not able to answer on my own:
Is there a possibility to disconnect an event when someone wants to use the
zoom-to-rectangle mechanism so that the code which originally would be
executed on the event isn't actually executed as long as the zooming is
activated? To have an example to talk about:
############
from pylab import *
def click(event):
"""If the left mouse button is pressed: draw a little square. """
if event.button==1 and event.inaxes:
x,y = event.xdata,event.ydata
plot([x],[y],'rs')
draw()
plot((arange(100)/99.0)**3)
gca().set_autoscale_on(False)
connect('button_press_event',click)
show()
############
If one runs this script and tries to use the zooming he will always add such a
little red square to the plot. Can this be prevented somehow?
Thanks for your help,
Martin
|
|
From: Mark B. <ma...@gm...> - 2006-11-24 11:47:22
|
Hello - We seem to be very close to nirvana, with numpy1.0 being out. It is just waiting for a win32 installer for scipy that is compatible with numpy1.0. (DOES ANYBODY KNOW? IS TRAVIS READING THIS MAYBE?) In the meantime, is there an mpl win32 installer around for numpy1.0rc2? Thanks for the help, Mark |
|
From: Eric F. <ef...@ha...> - 2006-11-23 18:12:31
|
Christopher Barker wrote: > giovanni ruggiero wrote: >> Hi All, >> I had problens to use the function quiver with the matplotlib 82-5. Eric >> advice me to upgrade the mpl. I have tried to upgrade the matplotlib but >> i have to upgrade almost all my libs. The case is that i can not upgrade >> these dependences without affect all my configuration wich means that i >> need to install my system again. Am i correct? > > You should be able to have newer version of libs alongside the old ones. > If there are not compatible packages (rpms, debs, whatever) for the > newer libs, you should be able to build them by hand (./configure, make, > etc). Just make sure they are installed in /usr/local/... If John's "apt-get" solution does not work--and it is my impression that there are many circumstances under which it will not work, even if it "should"--and you do not want to do a full install of something like ubuntu Edgy, then I think that the simplest way to have a working up-to-date mpl is to install *only* mpl from svn or from the tarball. As far as I know, current mpl depends on current numpy *if* you use numpy as your numerix choice; but if you use Numeric or numarray then none of the libraries used by mpl has to be very new, so you should not have to build anything other than mpl from source. As Chris says, putting it in /usr/local is a good idea: "python setup.py build; sudo python setup.py install --prefix=/usr/local" should do it. f the build fails, it will almost certainly be because a header file is missing, in which case you can install the corresponding dev package from your *present* version of ubuntu or whatever. This is likely to be an iterative process because several -dev packages will be needed. The nice thing about doing it this way is that updating to any subsequent mpl release or svn version is fast and easy, so you can take advantage of improvements without waiting for a packager to make a binary package for your particular distribution version. Can anyone either confirm that my advice works in practice, or if not, say where it goes wrong? This question of how to have up-to-date mpl on a not-so-up-to-date linux installation keeps coming up. Longer term I would encourage everyone to find a way ASAP to update whatever is necessary to have an up-to-date numpy rather than using old Numeric or numarray, so the advice in my first paragraph is intended as a stopgap. The same basic method can in fact be used to install the latest numpy release. (Does anyone know of a reason this would not work for an older linux distribution version?) It is critical that mpl be built *after* installing whatever numerical package is going to be used, however. Eric |
|
From: Eric F. <ef...@ha...> - 2006-11-23 17:35:47
|
Robert Cimrman wrote: > Eric Firing wrote: >> One more miscellaneous thought: perhaps spy and spy2 should be >> consolidated into a single function with a kwarg to select the marker >> version or the image version? Their purpose is identical (isn't it?), >> and it would reduce namespace clutter. > > one more thing here: usually (e.g. in Matlab) the y axis is reversed, so > that one sees the sparsity pattern in the same position as one would see > on paper when writing down the corresponding system of linear equations. > (I use my own spy, with ax.set_ylim( ax.get_ylim()[::-1] ) for this > purpose.) > > just my 2 cents, in case of the consolidation. Good, I was thinking exactly the same thing, so I will take care of that. Eric |
|
From: Robert C. <cim...@nt...> - 2006-11-23 08:15:24
|
Eric Firing wrote: > One more miscellaneous thought: perhaps spy and spy2 should be > consolidated into a single function with a kwarg to select the marker > version or the image version? Their purpose is identical (isn't it?), > and it would reduce namespace clutter. one more thing here: usually (e.g. in Matlab) the y axis is reversed, so that one sees the sparsity pattern in the same position as one would see on paper when writing down the corresponding system of linear equations. (I use my own spy, with ax.set_ylim( ax.get_ylim()[::-1] ) for this purpose.) just my 2 cents, in case of the consolidation, r. |
|
From: Robert C. <cim...@nt...> - 2006-11-23 08:07:06
|
Eric Firing wrote: > Robert Cimrman wrote: >> John Hunter wrote: >>>>>>>> "Robert" == Robert Cimrman <cim...@nt...> writes: >>> Robert> BTW would you consider changing the definition of spy(2) >>> Robert> as shown below, so that one could specify what 'to be a >>> Robert> zero' means? >>> >>> I added these enhancement, and a couple more, and an >>> examples/spy_demos.py. >>> >>> On reflection, it might be better to allow the user to simply pass a >>> sparsity function rather than a precision >>> >>> def not_zero(Z): >>> return Z!=0. >>> >>> class not_near_zero: >>> def __init__(self, precision): >>> self.precision = precision >>> def __call__(self, Z): >>> return absolute(asarray(Z))>self.precision >>> >>> def spy(Z, element=not_zero): >>> mask = element(Z) >>> >>> Then you could do: >>> >>> spy(Z, issparse=not_near_zero(1e-6)) >>> >>> >>> >>> The precision implementation you suggested is in svn, but if there is >>> any consensus that either of these approaches is better, speak up. >> I was thinking about passing directly a function (or an expression?) >> too. But I would not remove the precision argument, since it's usage is >> simpler, and is usually all one needs. The best would be to have both >> possibilities :) (function, if present, taking precedence?) > > I agree--and in fact my uninformed view is that even the precision > option is taking spy beyond the realm of showing true sparcity. If this > is genuinely useful to people, then fine. But if it (mainly the > function option) is something that merely might be useful to someone > someday, then I suggest it be left out until there is a clear need. (My > 2 cents-worth, or less.) Well, the precision argument is useful mainly because of unsafe comparison of floating point values (what is exactly zero?), so it can be used, in fact, to show the true sparsity, and I for one would use it :) > Curiosity questions about implementation: > > 1) What is the "tocoo" method, and what objects have it? a scipy sparse matrix method, to make spy compatible with the sparse matrix module. > 2) Is there a reason why one shouldn't simply default precision to 0 and > use the condition "absolute(asarray(Z)) <= precision"? just a little (full matrix case) and not so little (sparse matrix case) performance penalty. > One more miscellaneous thought: perhaps spy and spy2 should be > consolidated into a single function with a kwarg to select the marker > version or the image version? Their purpose is identical (isn't it?), > and it would reduce namespace clutter. that would be good! r. |
|
From: Christian K. <ck...@ho...> - 2006-11-23 06:21:59
|
I found one more solution which makes use of the sansmath.py style, available at http://www.tug.org/tex-archive/macros/latex/contrib/misc/sansmath.sty. To use it with matplotlib I updated the 'sans-serif' member of the font_info dict: 'sans-serif': ('cmss', '\usepackage{sansmath}'), and to the end of sansmath.py I added \sansmath to activate sans math mode upon loading. Then, choosing 'sans-serif' as first sansserif font in .matplotlibrc you get nice serif free math text. It should be easy to add this to the matplotlib distro. Christian |
|
From: Christian K. <ck...@ho...> - 2006-11-23 05:24:18
|
Christian Kristukat <ckkart@...> writes: > > Darren Dale <dd55 <at> ...> writes: > > We tried supporting sans-serif ticklabels with usetex a while back, and it > > turned out to be a headache. I'll have a look at cmbright, but no promises. > > Thanks. Btw., I didn't know about cmbright before looking at this problem. It > seems to be part of most tex distributions, e.g. tetex, miktex. I kept on experimenting and now ps output works, too. However it was necessary to install the type1 version of the cmbright fonts, which are unfortunately not part of tetex. They are available here: http://hannes.boehm.org/LaTeX/ I don't know if it is possible to have them outside the regular tetex tree and make tex use them so that they could be shipped with matplotlib. Or is that solution not acceptable at all? Regards, Christian |
|
From: Roman B. <be...@sm...> - 2006-11-22 20:05:10
|
Hello,
i had problems subscribing to the list, maybe the mail below I sent last
week, was not delivered. Hence I send it again:
---------------------------------------------------
Hello,
i try to write a module which evaluates various Data, and occasionally
creates a plot, which is returned to the user. At the discretion of the
user, he should be able to show selected plots. This is an example
module with two approaches for this problem:
-----------------
import pylab
import matplotlib
def makeplot1():
pylab.ioff()
fig = pylab.figure()
spl1 = fig.add_subplot(211)
spl2 = fig.add_subplot(212)
spl1.plot([1,4,9,16])
spl2.plot([1,3,5,7])
pylab.ion()
return fig
def makeplot2():
fig = matplotlib.figure.Figure()
spl1 = fig.add_subplot(211)
spl2 = fig.add_subplot(212)
spl1.plot([1,4,9,16])
spl2.plot([1,3,5,7])
return fig
----------------------
The user fires up ipython and imports my module:
ipython -pylab
>>> import plotgen
After analysizing various data, he wants to look at a particular plot:
>>> fig = plotgen.makeplot1()
Now can one make pop up this plot? I tried to make this figure current:
>>> figure(fig.number)
but nothing to see. Then:
>>> draw()
>>> ion()
Only show() works, but this pops up all figures defined, and this can be
a large number of figures if makeplot1() has been called often, or I
have many figures. I only want to see this particular figure.
So next try with the object oriented interface:
>>> fig = plotgen.makeplot2()
>>> figure(fig.number)
AttributeError: Figure instance has no attribute 'number'
Ok, this does not work. In a cookbook i saw that one needs something
like "canvas = FigureCanvasAgg(fig)". But i cannot use it: As writer of
module "plotgen" i dont know what backend (Agg) is used by the user. And
the user simply uses "ipython -pylab" and should not care about the
backend.
Whats the correct solution for my problem?
Best Regards,
Roman
|
|
From: Christopher B. <Chr...@no...> - 2006-11-22 19:41:21
|
giovanni ruggiero wrote: > Hi All, > I had problens to use the function quiver with the matplotlib 82-5. Eric > advice me to upgrade the mpl. I have tried to upgrade the matplotlib but > i have to upgrade almost all my libs. The case is that i can not upgrade > these dependences without affect all my configuration wich means that i > need to install my system again. Am i correct? You should be able to have newer version of libs alongside the old ones. If there are not compatible packages (rpms, debs, whatever) for the newer libs, you should be able to build them by hand (./configure, make, etc). Just make sure they are installed in /usr/local/... -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: John H. <jdh...@ac...> - 2006-11-22 19:31:36
|
>>>>> "giovanni" == giovanni ruggiero <oc...@ya...> writes:
giovanni> Hi All, I had problens to use the function quiver with
giovanni> the matplotlib 82-5. Eric advice me to upgrade the
giovanni> mpl. I have tried to upgrade the matplotlib but i have
giovanni> to upgrade almost all my libs. The case is that i can
giovanni> not upgrade these dependences without affect all my
giovanni> configuration wich means that i need to install my
giovanni> system again. Am i correct? If yes, What linux do you
giovanni> advice for me? Does anybody see another way to upgrade
giovanni> my mpl? Thanks
With a proper debian configuration, this should be as easy as
> sudo apt-get install python-matplotlib
If can't do this because your debian distro is too old or because you
are not properly using debian package management, you may consider
getting a newer distro (ubuntu is a debian distro that is current and
popular with scientific python users and developers) and/or spending the
time to get a smoothly functioning apt configuration so you can
upgrade painlessly and w/o fear.
JDH
|
|
From: giovanni r. <oc...@ya...> - 2006-11-22 19:24:01
|
Hi All, =0AI had problens to use the function quiver with the matplotlib 82= -5. Eric advice me to upgrade the mpl. I have tried to upgrade the matplotl= ib but i have to upgrade almost all my libs. The case is that i can not upg= rade these dependences without affect all my configuration wich means that = i need to install my system again. Am i correct? If yes, What linux do you = advice for me? Does anybody see another way to upgrade my mpl?=0AThanks=0A= =0A=0A=0A=0A=0A=09=09=0A___________________________________________________= ____ =0AYahoo! Acesso Gr=E1tis - Internet r=E1pida e gr=E1tis. Instale =0Ao= discador agora! =0Ahttp://br.acesso.yahoo.com |
|
From: John H. <jdh...@ac...> - 2006-11-22 18:36:26
|
>>>>> "Samuel" == Samuel M Smith <sm...@sa...> writes:
Samuel> I don't know where the transparency is coming from
Samuel> either. I don't know where I would set the alpha. Could it
Samuel> be in the .rc file? Could it be the way Macs process png
Samuel> files. If you like I can send a copy of the image
I looked at it and yes the alpha channel is zero. Very bizarre.
Please send a free standing script, the rc file you are using, the
output of the script when you run the file with --verbose-helpful and
the generated image file.
JDH
|
|
From: Samuel M. S. <sm...@sa...> - 2006-11-22 18:30:30
|
I don't know where the transparency is coming from either. I don't know where I would set the alpha. Could it be in the .rc file? Could it be the way Macs process png files. If you like I can send a copy of the image On 21 Nov, 2006, at 12:29, John Hunter wrote: >>>>>> "Samuel" == Samuel M Smith <sm...@sa...> writes: > > Samuel> I figured it out. It is saving the outside edge as > Samuel> transparent not gray. I was viewing the images in Apple's > Samuel> preview and it displays transparent as gray (not > Samuel> checkerboard like photoshop or graphic converter). > > I still don't understand where the transparency is coming from (unless > you are setting the alpha explicitly somewhere else). In the example > output I posted previously, the 4th entry in the image RGBAs is 1, > indicating that the alpha channel is 1, fully opaque. > > JDH ********************************************************************** Samuel M. Smith Ph.D. 2966 Fort Hill Road Eagle Mountain, Utah 84005-4108 801-768-2768 voice 801-768-2769 fax ********************************************************************** "The greatest source of failure and unhappiness in the world is giving up what we want most for what we want at the moment" ********************************************************************** |
|
From: John H. <jdh...@ac...> - 2006-11-22 18:26:44
|
>>>>> "Eric" == Eric Firing <ef...@ha...> writes:
Eric> fine. But if it (mainly the function option) is something
Eric> that merely might be useful to someone someday, then I
Eric> suggest it be left out until there is a clear need. (My 2
Eric> cents-worth, or less.)
sounds good
Eric> Curiosity questions about implementation:
Eric> 1) What is the "tocoo" method, and what objects have it? 2)
If someone is already using a sparse matrix from scipy.sparse, it's a
lot more efficient to use the sparse matrix functionality than to do
the sparsity check myself
Help on class coo_matrix in module scipy.sparse.sparse:
class coo_matrix(spmatrix)
| A sparse matrix in coordinate list format.
|
| COO matrices are created either as:
| A = coo_matrix(None, dims=(m, n), [dtype])
| for a zero matrix, or as:
| A = coo_matrix((obj, ij), [dims])
| where the dimensions are optional. If supplied, we set (M, N) =
| dims.
| If not supplied, we infer these from the index arrays
| ij[0][:] and ij[1][:]
|
| The arguments 'obj' and 'ij' represent three arrays:
| 1. obj[:] the entries of the matrix, in any order
| 2. ij[0][:] the row indices of the matrix entries
| 3. ij[1][:] the column indices of the matrix entries
|
| So the following holds:
| A[ij[0][k], ij[1][k] = obj[k]
Eric> Is there a reason why one shouldn't simply default precision
Eric> to 0 and use the condition "absolute(asarray(Z)) <=
Eric> precision"?
Minor performance issue since thisapproach requires two passes
through the data whereas mine takes one when precision=None
Eric> One more miscellaneous thought: perhaps spy and spy2 should
Eric> be consolidated into a single function with a kwarg to
Eric> select the marker version or the image version? Their
Eric> purpose is identical (isn't it?), and it would reduce
Eric> namespace clutter.
Fine by me -- if you want to implement it :-)
JDH
|
|
From: Michael H. <mic...@bc...> - 2006-11-22 18:19:24
|
hi, does anybody know I can show figure legend for 3D plots correctly? I am using Axes3D.scatter3D which returns a Patch3D object, which seems not to work with pylab.figlegend thanks! michael |
|
From: Eric F. <ef...@ha...> - 2006-11-22 18:12:29
|
Robert Cimrman wrote: > John Hunter wrote: >>>>>>> "Robert" == Robert Cimrman <cim...@nt...> writes: >> >> Robert> BTW would you consider changing the definition of spy(2) >> Robert> as shown below, so that one could specify what 'to be a >> Robert> zero' means? >> >> I added these enhancement, and a couple more, and an >> examples/spy_demos.py. >> >> On reflection, it might be better to allow the user to simply pass a >> sparsity function rather than a precision >> >> def not_zero(Z): >> return Z!=0. >> >> class not_near_zero: >> def __init__(self, precision): >> self.precision = precision >> def __call__(self, Z): >> return absolute(asarray(Z))>self.precision >> >> def spy(Z, element=not_zero): >> mask = element(Z) >> >> Then you could do: >> >> spy(Z, issparse=not_near_zero(1e-6)) >> >> >> >> The precision implementation you suggested is in svn, but if there is >> any consensus that either of these approaches is better, speak up. > > I was thinking about passing directly a function (or an expression?) > too. But I would not remove the precision argument, since it's usage is > simpler, and is usually all one needs. The best would be to have both > possibilities :) (function, if present, taking precedence?) I agree--and in fact my uninformed view is that even the precision option is taking spy beyond the realm of showing true sparcity. If this is genuinely useful to people, then fine. But if it (mainly the function option) is something that merely might be useful to someone someday, then I suggest it be left out until there is a clear need. (My 2 cents-worth, or less.) Curiosity questions about implementation: 1) What is the "tocoo" method, and what objects have it? 2) Is there a reason why one shouldn't simply default precision to 0 and use the condition "absolute(asarray(Z)) <= precision"? One more miscellaneous thought: perhaps spy and spy2 should be consolidated into a single function with a kwarg to select the marker version or the image version? Their purpose is identical (isn't it?), and it would reduce namespace clutter. Eric |