Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-07-26 Thread Stéfan van der Walt
On Mon, Jul 25, 2011 at 2:29 PM, Charles R Harris wrote: >> Why?  Users can simply do >> >> import numpy.io as npyio ? >> > > It caused problems with 2to3 for one thing because it was getting imported > as io in the package. It is just a bad idea to shadow python modules and > best avoided. Call

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-07-25 Thread Charles R Harris
2011/7/25 Stéfan van der Walt > On Mon, Jul 25, 2011 at 2:11 PM, Charles R Harris > wrote: > > It's just asking for import problems and general confusion to shadow a > > Python module, that's why we renamed io to npyio. > > Why? Users can simply do > > import numpy.io as npyio ? > > It caused p

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-07-25 Thread Skipper Seabold
2011/7/25 Stéfan van der Walt : > On Mon, Jul 25, 2011 at 2:11 PM, Charles R Harris > wrote: >> It's just asking for import problems and general confusion to shadow a >> Python module, that's why we renamed io to npyio. > > Why?  Users can simply do > > import numpy.io as npyio ? > IIRC this was

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-07-25 Thread Benjamin Root
On Monday, July 25, 2011, Gael Varoquaux wrote: > On Mon, Jul 25, 2011 at 03:52:48PM -0500, Mark Wiebe wrote: >>Can't use numpy.datetime, since that conflicts with Python's datetime >>library, especially in pylab. > > I don't understand that: isn't the point of namespaces to avoid those >

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-07-25 Thread Stéfan van der Walt
On Mon, Jul 25, 2011 at 1:52 PM, Mark Wiebe wrote: > Can't use numpy.datetime, since that conflicts with Python's datetime > library, especially in pylab. We're allowed to name the modules under numpy whatever we like--people know that doing "from numpy import *" can (and already does) cause havo

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-07-25 Thread Stéfan van der Walt
On Mon, Jul 25, 2011 at 2:11 PM, Charles R Harris wrote: > It's just asking for import problems and general confusion to shadow a > Python module, that's why we renamed io to npyio. Why? Users can simply do import numpy.io as npyio ? Stéfan ___ NumPy

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-07-25 Thread Charles R Harris
On Mon, Jul 25, 2011 at 3:00 PM, Gael Varoquaux < gael.varoqu...@normalesup.org> wrote: > On Mon, Jul 25, 2011 at 03:52:48PM -0500, Mark Wiebe wrote: > >Can't use numpy.datetime, since that conflicts with Python's datetime > >library, especially in pylab. > > I don't understand that: isn't

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-07-25 Thread Gael Varoquaux
On Mon, Jul 25, 2011 at 03:52:48PM -0500, Mark Wiebe wrote: >Can't use numpy.datetime, since that conflicts with Python's datetime >library, especially in pylab. I don't understand that: isn't the point of namespaces to avoid those naming conflicts. To me that's just like saying that numpy

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-07-25 Thread Mark Wiebe
2011/7/25 Stéfan van der Walt > On Mon, Jul 25, 2011 at 1:02 PM, Mark Wiebe wrote: > >> Probably should have! Either way, it's something to consider: if we > >> introduce those functions now, people will start to use them where > >> they are (np.xyz), introducing another change in usage comes 2

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-07-25 Thread Stéfan van der Walt
On Mon, Jul 25, 2011 at 1:02 PM, Mark Wiebe wrote: >> Probably should have!  Either way, it's something to consider: if we >> introduce those functions now, people will start to use them where >> they are (np.xyz), introducing another change in usage comes 2.0 (or >> 3.0 or whichever). > > Absolut

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-07-25 Thread Charles R Harris
2011/7/25 Stéfan van der Walt > Hey all, > > On Tue, Jun 14, 2011 at 4:34 PM, Mark Wiebe wrote: > > These functions are now fully implemented and documented. As always, code > > reviews are welcome here: > > https://github.com/numpy/numpy/pull/87 > > I haven't been keeping up with the datetime d

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-07-25 Thread Mark Wiebe
2011/7/25 Stéfan van der Walt > On Mon, Jul 25, 2011 at 12:35 PM, Mark Wiebe wrote: > > I'm trying to make things fit into the existing system as naturally as > > possible. The discussion you're talking about ideally should have > resulted > > in some guideline documentation about namespaces, bu

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-07-25 Thread Stéfan van der Walt
On Mon, Jul 25, 2011 at 12:35 PM, Mark Wiebe wrote: > I'm trying to make things fit into the existing system as naturally as > possible. The discussion you're talking about ideally should have resulted > in some guideline documentation about namespaces, but I don't recall seeing > something like t

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-07-25 Thread Mark Wiebe
2011/7/25 Stéfan van der Walt > Hey all, > > On Tue, Jun 14, 2011 at 4:34 PM, Mark Wiebe wrote: > > These functions are now fully implemented and documented. As always, code > > reviews are welcome here: > > https://github.com/numpy/numpy/pull/87 > > I haven't been keeping up with the datetime d

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-07-25 Thread Stéfan van der Walt
Hey all, On Tue, Jun 14, 2011 at 4:34 PM, Mark Wiebe wrote: > These functions are now fully implemented and documented. As always, code > reviews are welcome here: > https://github.com/numpy/numpy/pull/87 I haven't been keeping up with the datetime developments, but I noticed the introduction of

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-06-17 Thread Mark Wiebe
On Fri, Jun 17, 2011 at 2:46 PM, Derek Homeier < de...@astro.physik.uni-goettingen.de> wrote: > On 17.06.2011, at 8:05PM, Mark Wiebe wrote: > > > On Thu, Jun 16, 2011 at 8:18 PM, Derek Homeier < > de...@astro.physik.uni-goettingen.de> wrote: > >> On 17.06.2011, at 2:02AM, Mark Wiebe wrote: > >> >

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-06-17 Thread Derek Homeier
On 17.06.2011, at 8:05PM, Mark Wiebe wrote: > On Thu, Jun 16, 2011 at 8:18 PM, Derek Homeier > wrote: >> On 17.06.2011, at 2:02AM, Mark Wiebe wrote: >> >> >> ok, that was a lengthy hunt, but it's in printing the string in >> >> make_iso_8601_date: >> >> >> >>tmplen = snprintf(substr, suble

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-06-17 Thread Mark Wiebe
On Thu, Jun 16, 2011 at 8:18 PM, Derek Homeier < de...@astro.physik.uni-goettingen.de> wrote: > On 17.06.2011, at 2:02AM, Mark Wiebe wrote: > > >> ok, that was a lengthy hunt, but it's in printing the string in > make_iso_8601_date: > >> > >>tmplen = snprintf(substr, sublen, "%04" NPY_INT64_FM

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-06-16 Thread Derek Homeier
On 17.06.2011, at 2:02AM, Mark Wiebe wrote: >> ok, that was a lengthy hunt, but it's in printing the string in >> make_iso_8601_date: >> >>tmplen = snprintf(substr, sublen, "%04" NPY_INT64_FMT, dts->year); >>fprintf(stderr, "printed %d[%d]: dts->year=%lld: %s\n", tmplen, sublen, >> dts-

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-06-16 Thread Mark Wiebe
On Thu, Jun 16, 2011 at 5:52 PM, Derek Homeier < de...@astro.physik.uni-goettingen.de> wrote: > Hi Mark, > > On 16.06.2011, at 5:40PM, Mark Wiebe wrote: > > >> >>> np.datetime64('2011-06-16 02:03:04Z', 'D') > >> np.datetime64('-06-16','D') > >> > >> I've tried to track this down in datetime.c,

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-06-16 Thread Derek Homeier
Hi Mark, On 16.06.2011, at 5:40PM, Mark Wiebe wrote: >> >>> np.datetime64('2011-06-16 02:03:04Z', 'D') >> np.datetime64('-06-16','D') >> >> I've tried to track this down in datetime.c, but unsuccessfully so (i.e. I >> could not connect it >> to any of the dts->year assignments therein). >>

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-06-16 Thread Charles R Harris
On Thu, Jun 16, 2011 at 2:00 PM, Mark Wiebe wrote: > I've received some good feedback from Chuck and Ralf on the code and > documentation, respectively, and build testing with proposed fixes for > issues from the previous merge from Derek. I believe the current set of > changes are in good shape

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-06-16 Thread Mark Wiebe
I've received some good feedback from Chuck and Ralf on the code and documentation, respectively, and build testing with proposed fixes for issues from the previous merge from Derek. I believe the current set of changes are in good shape to merge, so would like to proceed with that later today. Ch

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-06-16 Thread Mark Wiebe
On Wed, Jun 15, 2011 at 5:16 PM, Derek Homeier < de...@astro.physik.uni-goettingen.de> wrote: > On 15.06.2011, at 1:34AM, Mark Wiebe wrote: > > > These functions are now fully implemented and documented. As always, code > reviews are welcome here: > > > > https://github.com/numpy/numpy/pull/87 > >

Re: [Numpy-discussion] code review/build & test for datetime business day API

2011-06-15 Thread Derek Homeier
On 15.06.2011, at 1:34AM, Mark Wiebe wrote: > These functions are now fully implemented and documented. As always, code > reviews are welcome here: > > https://github.com/numpy/numpy/pull/87 > > and for those that don't want to dig into review C code, the commit for the > documentation is here

[Numpy-discussion] code review/build & test for datetime business day API

2011-06-14 Thread Mark Wiebe
These functions are now fully implemented and documented. As always, code reviews are welcome here: https://github.com/numpy/numpy/pull/87 and for those that don't want to dig into review C code, the commit for the documentation is here: https://github.com/m-paradox/numpy/commit/6b5a42a777b16812