[matplotlib-devel] Plans for matplotlib py3k/final release (and impact on Debian)

2012-05-12 Thread Sandro Tosi
Hello,
as you may be aware of, in 1 month (more or less) Debian will freeze,
that means that no new upstream releases will be allowed in the
upcoming release, only fixex for important bugs.

Currently in Debian archive we have 1.1.1rc1 . Recent mails have
mentioned that the next release will be py3k enabled. Well, what are
you're plans to release such version? :)

It would be really awesome to have a python3 matplotlib in Debian, and
i'd be happy to test any new RC you'd like to release.

Cheers,
-- 
Sandro Tosi (aka morph, morpheus, matrixhasu)
My website: http://matrixhasu.altervista.org/
Me at Debian: http://wiki.debian.org/SandroTosi

--
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] Plans for matplotlib py3k/final release (and impact on Debian)

2012-05-12 Thread Thomas Kluyver
On 12 May 2012 10:56, Sandro Tosi  wrote:
> It would be really awesome to have a python3 matplotlib in Debian, and
> i'd be happy to test any new RC you'd like to release.

Just to mention: I've set up a daily builds PPA for matplotlib, and
it's been happily producing Python 3 builds for a while, so it looks
like it should be fairly painless:
https://code.launchpad.net/~takluyver/+archive/matplotlib-daily

Thanks,
Thomas

--
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] Plans for matplotlib py3k/final release (and impact on Debian)

2012-05-12 Thread Mark Lawrence
On 12/05/2012 11:01, Thomas Kluyver wrote:
> On 12 May 2012 10:56, Sandro Tosi  wrote:
>> It would be really awesome to have a python3 matplotlib in Debian, and
>> i'd be happy to test any new RC you'd like to release.
>
> Just to mention: I've set up a daily builds PPA for matplotlib, and
> it's been happily producing Python 3 builds for a while, so it looks
> like it should be fairly painless:
> https://code.launchpad.net/~takluyver/+archive/matplotlib-daily
>
> Thanks,
> Thomas
>
> --
> Live Security Virtual Conference
> Exclusive live event will cover all the ways today's security and
> threat landscape has changed and how IT managers can respond. Discussions
> will include endpoint security, mobile security and the latest in malware
> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/

My original offer (made several months ago) to help test this on Windows 
still stands :)

-- 
Cheers.

Mark Lawrence.


--
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] Plans for matplotlib py3k/final release (and impact on Debian)

2012-05-12 Thread Michael Droettboom
On 05/12/2012 07:21 AM, Mark Lawrence wrote:
>
> My original offer (made several months ago) to help test this on Windows
> still stands :)
>
Thanks.  Does git master build and pass the unit tests on Windows?

Mike

--
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] Plans for matplotlib py3k/final release (and impact on Debian)

2012-05-12 Thread Christoph Gohlke



On 5/12/2012 6:16 AM, Michael Droettboom wrote:

On 05/12/2012 07:21 AM, Mark Lawrence wrote:


My original offer (made several months ago) to help test this on Windows
still stands :)


Thanks.  Does git master build and pass the unit tests on Windows?

Mike



git master builds and tests OK on win32-py2.7.

With the attached patch git master builds and works (in practice) OK on 
win-amd64-py3.2 but there are many test errors of type "RuntimeError: 
Could not open facefile X:\Python32\...\ttf\Vera.ttf; 
Cannot_Open_Resource". I do delete the ~\.matplotlib folder before 
running the tests and can verify that 
FT2Font(r"X:\Python32\lib\site-packages\matplotlib\mpl-data\fonts\ttf\Vera.ttf") 
works.


Christoph
diff --git a/lib/matplotlib/backends/backend_tkagg.py 
b/lib/matplotlib/backends/backend_tkagg.py
index f93d7f9..8a78a44 100644
--- a/lib/matplotlib/backends/backend_tkagg.py
+++ b/lib/matplotlib/backends/backend_tkagg.py
@@ -185,7 +185,7 @@ class FigureCanvasTkAgg(FigureCanvasAgg):
 master=master, width=w, height=h, borderwidth=4)
 self._tkphoto = Tk.PhotoImage(
 master=self._tkcanvas, width=w, height=h)
-self._tkcanvas.create_image(w/2, h/2, image=self._tkphoto)
+self._tkcanvas.create_image(w//2, h//2, image=self._tkphoto)
 self._resize_callback = resize_callback
 self._tkcanvas.bind("", self.resize)
 self._tkcanvas.bind("", self.key_press)
diff --git a/lib/matplotlib/cbook.py b/lib/matplotlib/cbook.py
index c9f2053..08a5247 100644
--- a/lib/matplotlib/cbook.py
+++ b/lib/matplotlib/cbook.py
@@ -639,7 +639,7 @@ def _get_data_server(cache_dir, baseurl):
 else:
 data = response.read()
 self.cache_file(req.get_full_url(), data, response.headers)
-result = addinfourl(StringIO.StringIO(data),
+result = addinfourl(data,
 response.headers,
 req.get_full_url())
 result.code = response.code
--
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] switching rc files (and discussion of styles)

2012-05-12 Thread Gökhan Sever
Hello,

This is a good idea indeed. Especially, when one creates plots for
presentations and papers. Usually, I make ticks, ticklabels, axes labels,
line widths, marker sizes as large as possible (within reasonable limits)
to make them more readable for presentation purposes. However, the same
element sizes don't look very pretty when I create the same plots for paper
or vice versa. The solution is either keep modify two rc files or adjust
one rc file accordingly for each plotting style.

Could the syntax be simplfied a bit? Say rather than using that with
statement and the extra 4 spaces, can it be just a one simple liner like
matplotlib.rcuse(mpl_paper.rc) or matplotlib.rcuse(mpl_presentation.rc)?


On Fri, May 11, 2012 at 2:17 PM, Paul Ivanov  wrote:

> Hey everyone,
>
> I wanted to highlight Matthew Emmett's (memmett) PR in progress [1] that
> brings the ability to switch between rcParams.
>
> Matthew's implementation started with just being able to read in and use
> an rcParam file, and I suggested the idea of having a context manager,
> that would allow you to do something like:
>
>  with rc_context(fname):
>  plt.plot()
>  ...
>
> and have the rcParams restored outside of the context.
>
> I know there have been a few threads (can't find links now for some
> reason) and in-person discussions in the past about having this kind of
> ability in matplotlib, and having an idea of "styles", and Tony Yu
> implemented a variant of this on top of matplotlib in mpltools [2], but
> I wanted to ping the list here for other ideas and feelings about such
> functionality (if anyone can find pointers to previous discussions, that
> would be very welcome).
>
> 1. https://github.com/matplotlib/matplotlib/pull/861
> 2. https://github.com/tonysyu/mpltools
>
> best,
> --
> Paul Ivanov
> 314 address only used for lists,  off-list direct email at:
> http://pirsquared.org | GPG/PGP key id: 0x0F3E28F7
>
>
> --
> Live Security Virtual Conference
> Exclusive live event will cover all the ways today's security and
> threat landscape has changed and how IT managers can respond. Discussions
> will include endpoint security, mobile security and the latest in malware
> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
> ___
> Matplotlib-devel mailing list
> Matplotlib-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel
>



-- 
Gökhan
--
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] switching rc files (and discussion of styles)

2012-05-12 Thread Tony Yu
On Sat, May 12, 2012 at 3:11 PM, Gökhan Sever  wrote:

> Hello,
>
> This is a good idea indeed. Especially, when one creates plots for
> presentations and papers. Usually, I make ticks, ticklabels, axes labels,
> line widths, marker sizes as large as possible (within reasonable limits)
> to make them more readable for presentation purposes. However, the same
> element sizes don't look very pretty when I create the same plots for paper
> or vice versa. The solution is either keep modify two rc files or adjust
> one rc file accordingly for each plotting style.
>
> Could the syntax be simplfied a bit? Say rather than using that with
> statement and the extra 4 spaces, can it be just a one simple liner like
> matplotlib.rcuse(mpl_paper.rc) or matplotlib.rcuse(mpl_presentation.rc)?
>

I believe that's what the `rc_file` function does in the
PR,
so both use cases are possible. I think it makes sense to allow both.

Cheers,
-Tony


On Fri, May 11, 2012 at 2:17 PM, Paul Ivanov  wrote:
>
>> Hey everyone,
>>
>> I wanted to highlight Matthew Emmett's (memmett) PR in progress [1] that
>> brings the ability to switch between rcParams.
>>
>> Matthew's implementation started with just being able to read in and use
>> an rcParam file, and I suggested the idea of having a context manager,
>> that would allow you to do something like:
>>
>>  with rc_context(fname):
>>  plt.plot()
>>  ...
>>
>> and have the rcParams restored outside of the context.
>>
>> I know there have been a few threads (can't find links now for some
>> reason) and in-person discussions in the past about having this kind of
>> ability in matplotlib, and having an idea of "styles", and Tony Yu
>> implemented a variant of this on top of matplotlib in mpltools [2], but
>> I wanted to ping the list here for other ideas and feelings about such
>> functionality (if anyone can find pointers to previous discussions, that
>> would be very welcome).
>>
>> 1. https://github.com/matplotlib/matplotlib/pull/861
>> 2. https://github.com/tonysyu/mpltools
>>
>> best,
>> --
>> Paul Ivanov
>> 314 address only used for lists,  off-list direct email at:
>> http://pirsquared.org | GPG/PGP key id: 0x0F3E28F7
>>
>>
>> --
>> Live Security Virtual Conference
>> Exclusive live event will cover all the ways today's security and
>> threat landscape has changed and how IT managers can respond. Discussions
>> will include endpoint security, mobile security and the latest in malware
>> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
>> ___
>> Matplotlib-devel mailing list
>> Matplotlib-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel
>>
>
>
>
> --
> Gökhan
>
>
> --
> Live Security Virtual Conference
> Exclusive live event will cover all the ways today's security and
> threat landscape has changed and how IT managers can respond. Discussions
> will include endpoint security, mobile security and the latest in malware
> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
> ___
> Matplotlib-devel mailing list
> Matplotlib-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel
>
>
--
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel