Re: [Numpy-discussion] Question about numpy.random.choice with probabilties

2017-01-23 Thread Robert Kern
On Mon, Jan 23, 2017 at 9:41 AM, Nadav Har'El <n...@scylladb.com> wrote: > > On Mon, Jan 23, 2017 at 4:52 PM, aleba...@gmail.com <aleba...@gmail.com> wrote: >> >> 2017-01-23 15:33 GMT+01:00 Robert Kern <robert.k...@gmail.com>: >>> >>> I d

Re: [Numpy-discussion] Question about numpy.random.choice with probabilties

2017-01-23 Thread Robert Kern
On Mon, Jan 23, 2017 at 9:22 AM, Anne Archibald <peridot.face...@gmail.com> wrote: > > > On Mon, Jan 23, 2017 at 3:34 PM Robert Kern <robert.k...@gmail.com> wrote: >> >> I don't object to some Notes, but I would probably phrase it more like we are providing the

Re: [Numpy-discussion] Question about numpy.random.choice with probabilties

2017-01-23 Thread Robert Kern
uot;replace=False" obviously picks out the implemented procedure, and I would have been incredibly surprised if it did anything else. If the option were named "unique=True", then I would have needed some more documentation to let me know exactly how it was implemented. -- Robert Kern ___

Re: [Numpy-discussion] Fwd: Backslash operator A\b and np/sp.linalg.solve

2017-01-09 Thread Robert Kern
instead. You would only use a generic dense matrix if you know that there isn't structure in the matrix. So there are no routines for detecting that structure in generic dense matrices. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@sci

Re: [Numpy-discussion] Fwd: Backslash operator A\b and np/sp.linalg.solve

2017-01-09 Thread Robert Kern
st checks. In Fortran LAPACK, if you have a special structured matrix, you usually explicitly use packed storage and call the appropriate function type on it. It's only when you go to a system that only has a generic, unstructured dense matrix data type that it makes sense to do those kinds of checks. -

Re: [Numpy-discussion] array comprehension

2016-11-04 Thread Robert Kern
g like: > > > > np.fromiter((i for i in range(x))) # use xrange for Python 2 > > > > > Does this generalize to >1 dimensions? No. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] missing from contributor list?

2016-11-02 Thread Robert Kern
ob/master/numpy/_ > build_utils/src/apple_sgemv_fix.c > > > Sturla > > ___ > NumPy-Discussion mailing list > NumPy-Discussion@scipy.org > https://mail.scipy.org/mailman/listinfo/numpy-discussion > -- Robert Kern ___

Re: [Numpy-discussion] Intel random number package

2016-10-27 Thread Robert Kern
think we've exhausted the relevance of this tangent to Oleksander's contributions. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] Intel random number package

2016-10-26 Thread Robert Kern
like that: https://github.com/numpy/numpy/blob/master/numpy/random/mtrand/distributions.c#L262-L397 > > Perhaps the point should be that the numpy devs won't want to maintain two nearly identical versions of that code. Indeed. That's how the algorith

Re: [Numpy-discussion] Intel random number package

2016-10-26 Thread Robert Kern
On Wed, Oct 26, 2016 at 9:36 AM, Sebastian Berg <sebast...@sipsolutions.net> wrote: > > On Mi, 2016-10-26 at 09:29 -0700, Robert Kern wrote: > > On Wed, Oct 26, 2016 at 9:10 AM, Julian Taylor <jtaylor.debian@google > > mail.com> wrote: > > > > >

Re: [Numpy-discussion] Intel random number package

2016-10-26 Thread Robert Kern
d drop-in like np.linalg being built against an optimized BLAS, just a separate module that is inoperative without MKL. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] Intel random number package

2016-10-25 Thread Robert Kern
On Tue, Oct 25, 2016 at 10:22 PM, Charles R Harris < charlesr.har...@gmail.com> wrote: > > On Tue, Oct 25, 2016 at 10:41 PM, Robert Kern <robert.k...@gmail.com> wrote: >> >> On Tue, Oct 25, 2016 at 9:34 PM, Charles R Harris < charlesr.har...@g

Re: [Numpy-discussion] Intel random number package

2016-10-25 Thread Robert Kern
This is what ng-numpy-randomstate is for. https://github.com/bashtage/ng-numpy-randomstate -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] Preserving NumPy views when pickling

2016-10-25 Thread Robert Kern
tain it, though (for example, if .T is contiguous then we might well serialize the transposed data linearly and return a view on that data upon deserialization). I don't believe that we guarantee that the unpickled result is contiguous. -- Robert Kern ___ NumPy-Dis

Re: [Numpy-discussion] Preserving NumPy views when pickling

2016-10-25 Thread Robert Kern
gt; [[1,2]] > > Numpy arrays are different but references are forgotten after pickle/unpickle. Shared objects do not remain shared. Based on the quote below it could be considered bug with numpy/pickle. Not a bug, but an explicit design decision on numpy's part. -- Robert Kern

Re: [Numpy-discussion] Preserving NumPy views when pickling

2016-10-25 Thread Robert Kern
handle [base, view] okay but not [view, base], so it's probably not going to be all that useful outside of special situations. It would make a neat recipe, but I probably would not provide it in numpy itself. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] Using library-specific headers

2016-09-29 Thread Robert Kern
tting to backwards compatibility. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] New Indexing Methods Revival #N (subclasses!)

2016-09-06 Thread Robert Kern
hing I am not quite sure about: > > > > 1. Is `__getitem__` in some way special to make this difficult (also > > considering some new ideas like allowing object[a=4]? > > OK; I think the C-side slot cannot get the kwarg likely, but probably > you can find a solution for

Re: [Numpy-discussion] Reading in a mesh file

2016-09-01 Thread Robert Kern
e problems, e.g. if you had "0.3001 0.0 20.0" as a row, but all of the other "x=0.3" rows had "0.3", then that row would get sorted out of order. You would have to clean up the grid coordinates a bit first. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] Reading in a mesh file

2016-08-31 Thread Robert Kern
alues = reshaped[..., 2] [~/scratch] |10> x array([[ 0. , 0. , 0. ], [ 0.3, 0.3, 0.3], [ 0.6, 0.6, 0.6]]) [~/scratch] |11> y array([[ 0. , 0.3, 0.6], [ 0. , 0.3, 0.6], [ 0. , 0.3, 0.6]]) [~/scratch] |12> value

Re: [Numpy-discussion] Include last element when subindexing numpy arrays?

2016-08-31 Thread Robert Kern
On Wed, Aug 31, 2016 at 1:34 PM, Matti Viljamaa <mvilja...@kapsi.fi> wrote: > > On 31 Aug 2016, at 15:22, Robert Kern <robert.k...@gmail.com> wrote: > > On Wed, Aug 31, 2016 at 12:28 PM, Matti Viljamaa <mvilja...@kapsi.fi> wrote: > > > > Is there a

Re: [Numpy-discussion] State-of-the-art to use a C/C++ library from Python

2016-08-31 Thread Robert Kern
he computation, then hand over some pointers to existing buffers containing vector data, then start the computation, and finally read back the data. The library also can use MPI to parallelize. I usually reach for Cython: http://cython.org/ http://docs.cython.org/en/latest/src/userguide/me

Re: [Numpy-discussion] Why np.fft.rfftfreq only returns up to Nyqvist?

2016-08-31 Thread Robert Kern
putes values for frequencies only up to Nyquist, so np.fft.rfftfreq() must give you the frequencies to match. I'm not sure if there is another misunderstanding lurking that needs to be clarified. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussi

Re: [Numpy-discussion] Include last element when subindexing numpy arrays?

2016-08-31 Thread Robert Kern
gt; array([0, 1, 2, 3, 4, 5, 6, 7, 8, 9]) > >>> A[0:5] > array([0, 1, 2, 3, 4]) A[5:] -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] coordinate bounds

2016-08-20 Thread Robert Kern
ords.min(axis=0), coords.max(axis=0)]) -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] Numpy set_printoptions, silent failure, bug?

2016-07-19 Thread Robert Kern
alidation to the arguments to np.set_printoptions(). -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] Design feedback solicitation

2016-07-14 Thread Robert Kern
made at a run-time, That's what happens. You instantiate the RandomState class that you want. > as far as I understood, and the only provided interface to query random variates is one at a time, just like it is currently the case > in numpy.random. -- Robert Kern ___

Re: [Numpy-discussion] Design feedback solicitation

2016-06-17 Thread Robert Kern
e: https://github.com/numpy/numpy/issues/6967 And the current effort for adding new core PRNGs here: https://github.com/bashtage/ng-numpy-randomstate -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] Indexing with floats

2016-06-10 Thread Robert Kern
l.scipy.org/pipermail/numpy-discussion/2015-July/073125.html Note that the future is coming in the next numpy release: https://github.com/numpy/numpy/pull/6271 -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] Proposal: numpy.random.random_seed

2016-05-23 Thread Robert Kern
On Mon, May 23, 2016 at 5:41 PM, Chris Barker <chris.bar...@noaa.gov> wrote: > > On Sun, May 22, 2016 at 2:35 AM, Robert Kern <robert.k...@gmail.com> wrote: >> >> Well, I mean, engineers want lots of things. I suspect that most engineers *really* just want to c

Re: [Numpy-discussion] Proposal: numpy.random.random_seed

2016-05-22 Thread Robert Kern
On Wed, May 18, 2016 at 7:56 PM, Nathaniel Smith <n...@pobox.com> wrote: > > On Wed, May 18, 2016 at 5:07 AM, Robert Kern <robert.k...@gmail.com> wrote: > > On Wed, May 18, 2016 at 1:14 AM, Nathaniel Smith <n...@pobox.com> wrote: > >> ...anyway, the

Re: [Numpy-discussion] Proposal: numpy.random.random_seed

2016-05-18 Thread Robert Kern
On Wed, May 18, 2016 at 6:20 PM, <josef.p...@gmail.com> wrote: > > On Wed, May 18, 2016 at 12:01 PM, Robert Kern <robert.k...@gmail.com> wrote: >> >> On Wed, May 18, 2016 at 4:50 PM, Chris Barker <chris.bar...@noaa.gov> wrote: >> >> >> >&

Re: [Numpy-discussion] Proposal: numpy.random.random_seed

2016-05-18 Thread Robert Kern
ut coordination between processes? The necessity for multiple independent streams per se is not contentious. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] Proposal: numpy.random.random_seed

2016-05-18 Thread Robert Kern
On Wed, May 18, 2016 at 1:14 AM, Nathaniel Smith <n...@pobox.com> wrote: > > On Tue, May 17, 2016 at 10:41 AM, Robert Kern <robert.k...@gmail.com> wrote: > > On Tue, May 17, 2016 at 6:24 PM, Nathaniel Smith <n...@pobox.com> wrote: > >> > >>

Re: [Numpy-discussion] Proposal: numpy.random.random_seed

2016-05-17 Thread Robert Kern
On Tue, May 17, 2016 at 6:24 PM, Nathaniel Smith <n...@pobox.com> wrote: > > On May 17, 2016 1:50 AM, "Robert Kern" <robert.k...@gmail.com> wrote: > > > [...] > > What you want is a function that returns many RandomState objects that are hopef

Re: [Numpy-discussion] Proposal: numpy.random.random_seed

2016-05-17 Thread Robert Kern
ices? Then we get two functions, numpy.random.push_seed and > numpy.random.pop_seed. I don't think that addresses the issues brought up here. It's just more global state to worry about. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] Proposal: numpy.random.random_seed

2016-05-17 Thread Robert Kern
On Tue, May 17, 2016 at 9:09 AM, Stephan Hoyer <sho...@gmail.com> wrote: > > On Tue, May 17, 2016 at 12:18 AM, Robert Kern <robert.k...@gmail.com> wrote: >> >> On Tue, May 17, 2016 at 4:54 AM, Stephan Hoyer <sho...@gmail.com> wrote: >> > 1. When writin

Re: [Numpy-discussion] Proposal: numpy.random.random_seed

2016-05-17 Thread Robert Kern
ere to be *some* barrier to entry, but just grabbing it to use as a default RandomState object is definitely an intended use of it. It's not going to disappear. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.or

Re: [Numpy-discussion] Floor divison on int returns float

2016-04-13 Thread Robert Kern
off half of the range of uint64. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] mtrand.c update 1.11 breaks my crappy code

2016-04-06 Thread Robert Kern
pler approaches - but > I'm a purist. Consider using PRNGs that actually expose truly independent streams instead of a single shared stream: https://github.com/bashtage/ng-numpy-randomstate -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussi

Re: [Numpy-discussion] mtrand.c update 1.11 breaks my crappy code

2016-04-06 Thread Robert Kern
one using PyCapsules to expose the underlying rk_state* pointer. https://docs.python.org/2.7/c-api/capsule.html -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] proposal: new logspace without the log in the argument

2016-02-19 Thread Robert Kern
to calculate the exact number of points needed. At the risk of extending the twisty little maze of names, all alike, I would probably call a function with this signature geomrange() instead. It is more akin to arange(start, stop, step) than linspace(start, sto

Re: [Numpy-discussion] proposal: new logspace without the log in the argument

2016-02-18 Thread Robert Kern
On Thu, Feb 18, 2016 at 10:19 PM, Alan Isaac <alan.is...@gmail.com> wrote: > > On 2/18/2016 2:44 PM, Robert Kern wrote: >> >> In a new function not named `linspace()`, I think that might be fine. I do occasionally want to swap between linear and logarithmic/geometric spac

Re: [Numpy-discussion] proposal: new logspace without the log in the argument

2016-02-18 Thread Robert Kern
p between linear and logarithmic/geometric spacing based on a parameter, so this doesn't violate the van Rossum Rule of Function Signatures. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] making "low" optional in numpy.randint

2016-02-17 Thread Robert Kern
alan.is...@gmail.com >> <javascript:_e(%7B%7D,'cvml','alan.is...@gmail.com');>> wrote: >> >>> On 2/17/2016 3:42 PM, Robert Kern wrote: >>> >>>> random.randint() was the one big exception, and it was considered a >>>> mistake for that ver

Re: [Numpy-discussion] making "low" optional in numpy.randint

2016-02-17 Thread Robert Kern
he code's reader in mind, not the code's writer. As a reader of other people's code (and I count 6-months-ago-me as one such "other people"), I am sure to eventually encounter all of the different variants, so I will need to know all of th

Re: [Numpy-discussion] making "low" optional in numpy.randint

2016-02-17 Thread Robert Kern
random.randrange(), ...), particularly those that end up related to indexing; e.g. `x[np.random.randint(0, len(x))]` to pull a random sample from an array. random.randint() was the one big exception, and it was considered a mistake for that very reason

Re: [Numpy-discussion] making "low" optional in numpy.randint

2016-02-17 Thread Robert Kern
ady days of numpy 1.0. > So I suggest further work on this function is > not called for, and use of `random_integers` > should be encouraged. Probably NumPy's `randint` > should be deprecated. Not while I'm here. Instead, `random_integers()` is discoura

Re: [Numpy-discussion] Suggestion: special-case np.array(range(...)) to be faster

2016-02-15 Thread Robert Kern
ex won't be adversely impacted by retaining the status quo. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] Hook in __init__.py to let distributors patch numpy

2016-02-12 Thread Robert Kern
ble approach to y'all? > > Cheers, > > Matthew > _______ > NumPy-Discussion mailing list > NumPy-Discussion@scipy.org > https://mail.scipy.org/mailman/listinfo/numpy-discussion > -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] Behavior of np.random.uniform

2016-01-21 Thread Robert Kern
On Thu, Jan 21, 2016 at 7:06 AM, Jaime Fernández del Río < jaime.f...@gmail.com> wrote: > > There doesn't seem to be much of a consensus on the way to go, so leaving things as they are and have been seems the wisest choice for now, thanks for all the feedback. I will work with Greg on documenting

Re: [Numpy-discussion] Behavior of np.random.uniform

2016-01-21 Thread Robert Kern
tion only gets worse > > with floats. > > > > Well, actually random.uniform docstring says: > > Get a random number in the range [a, b) or [a, b] depending on > rounding. Which docstring are you looking at? The current one says [low, high) http://docs.scipy.org/doc/n

Re: [Numpy-discussion] Behavior of np.random.uniform

2016-01-19 Thread Robert Kern
On Tue, Jan 19, 2016 at 5:40 PM, Charles R Harris <charlesr.har...@gmail.com> wrote: > > On Tue, Jan 19, 2016 at 10:36 AM, Robert Kern <robert.k...@gmail.com> wrote: >> >> On Tue, Jan 19, 2016 at 5:27 PM, Charles R Harris < charlesr.har...@gmail.com> wrote: &g

Re: [Numpy-discussion] Behavior of np.random.uniform

2016-01-19 Thread Robert Kern
finitely not intended to be used as `uniform(closed_end, open_end)`. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] Behavior of np.random.uniform

2016-01-19 Thread Robert Kern
On Tue, Jan 19, 2016 at 5:36 PM, Robert Kern <robert.k...@gmail.com> wrote: > > On Tue, Jan 19, 2016 at 5:27 PM, Charles R Harris < charlesr.har...@gmail.com> wrote: > > > > > On Tue, Jan 19, 2016 at 9:23 AM, Chris Barker - NOAA Federal < chris.bar...@

Re: [Numpy-discussion] Software Capabilities of NumPy in Our Tensor Survey Paper

2016-01-15 Thread Robert Kern
ose operations than you have marked, just under different names/notation, but really can't tell either way for sure without knowing what exactly they are. In particular check if your operations can be expressed with einsum() http://docs.scipy.org/doc/numpy-1.10.1/reference/generated/numpy.einsum.html -- Robert Kern

Re: [Numpy-discussion] Get rid of special scalar arithmetic

2016-01-13 Thread Robert Kern
r under numpy and were reluctant to migrate. I was forever responding on comp.lang.python, "It's because scalar arithmetic hasn't been optimized yet. We know how to do it, we just need a volunteer to do the work. Contributions gratefully accepted!" The most critical areas tended to be optimi

Re: [Numpy-discussion] deprecate random.random_integers

2016-01-04 Thread Robert Kern
h the introduction and promotion of random.randrange() instead. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] Numpy funding update

2015-12-31 Thread Robert Kern
table gift! That sounds great! Do we have any concrete plans for spending that money, yet? -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] FeatureRequest: support for array construction from iterators

2015-12-14 Thread Robert Kern
tation rather than being a generic container. >>> len(xrange(10)) 10 >>> xrange(10)[5] 5 -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] FeatureRequest: support for array construction from iterators

2015-12-14 Thread Robert Kern
On Mon, Dec 14, 2015 at 5:41 PM, Benjamin Root <ben.v.r...@gmail.com> wrote: > > Heh, never noticed that. Was it implemented more like a generator/iterator in older versions of Python? No, it predates generators and iterators so it has always had to be implemented like that. --

Re: [Numpy-discussion] reshaping array question

2015-11-17 Thread Robert Kern
se I just want to stack them > > [0,0,0,0] -> [0,0,0] > [0,0,0,1] -> [0,0,1] > [0,0,0,2] -> [0,0,2] > ... > [0,0,1,0] -> [0,0,1024] > [0,0,1,1] -> [0,0,1025] > [0,0,1,2] -> [0,0,1026] > ... A.reshape(A.shape[:-2] + (-1,)) -- Robert Kern ___

Re: [Numpy-discussion] reshaping array question

2015-11-17 Thread Robert Kern
On Nov 17, 2015 6:53 PM, "Sebastian Berg" <sebast...@sipsolutions.net> wrote: > > On Di, 2015-11-17 at 13:49 -0500, Neal Becker wrote: > > Robert Kern wrote: > > > > > On Tue, Nov 17, 2015 at 3:48 PM, Neal Becker <ndbeck...@gmail.com> wrote: > &

Re: [Numpy-discussion] Nansum function behavior

2015-10-23 Thread Robert Kern
d counterintuitive. What change are you referring to? -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] [Feature Suggestion]More comparison functions for floating point numbers

2015-10-19 Thread Robert Kern
lative error tolerance. This is how isclose(a, b) better than abs(a-b)<=atol. You just adjust the value by whichever tolerance is greatest in magnitude. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/m

Re: [Numpy-discussion] Cython-based OpenMP-accelerated quartic polynomial solver

2015-09-30 Thread Robert Kern
On Wed, Sep 30, 2015 at 10:35 AM, Matthieu Brucher < matthieu.bruc...@gmail.com> wrote: > > Yes, obviously, the code has NR parts, so it can't be licensed as BSD > as it is... It's not obvious to me, especially after Juha's further clarifications.

Re: [Numpy-discussion] interpretation of the draft governance document (was Re: Governance model request)

2015-09-24 Thread Robert Kern
lor, and Pauli Virtanen (assuming everyone on that list is interested/willing to serve).] > > I would ask to be on this initial council by having the rule include "original contributors of the code" which would basically include Robert Kern and Pearu Peterson in addition to C

Re: [Numpy-discussion] [Python-ideas] Should our default random number generator be secure?

2015-09-19 Thread Robert Kern
dependently without > too much effort. The author has agreed in principle to relicense the code as MIT, though has not yet merged the PR that accomplishes this yet. That said, we'd probably end up doing a significant amount of rewriting so that we will have a C implementation of software-uint128 ar

Re: [Numpy-discussion] [Python-ideas] Should our default random number generator be secure?

2015-09-14 Thread Robert Kern
[Tim, ping me if you want to get dropped from the reply chain, as we are liable to get more into numpy decision-making. I've dropped python-ideas.] On Mon, Sep 14, 2015 at 4:34 AM, Tim Peters <tim.pet...@gmail.com> wrote: > > [Robert Kern <robert.k...@gmail.com>] > >> .

Re: [Numpy-discussion] OK to upload patched 1.9.2 for Python 3.5?

2015-09-14 Thread Robert Kern
wheels, at least. I think it's highly desirable that we also have a *source* release that builds on Python 3.5, irrespective of whether or not we have binary wheels for a couple of platforms up for Python 3.5. So I would encourage a quick 1.9.3 release that incorporates this patch. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] strange casting rules

2015-07-29 Thread Robert Kern
this thread: http://mail.scipy.org/pipermail/numpy-discussion/2015-July/073196.html Cast your 0 to a uint64 or other unsigned int type to avoid this. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman

Re: [Numpy-discussion] difference between dtypes

2015-07-24 Thread Robert Kern
, and the underscored aliases are convenient for that. Never use the aliases to the Python builtin types. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] difference between dtypes

2015-07-24 Thread Robert Kern
On Fri, Jul 24, 2015 at 10:05 AM, josef.p...@gmail.com wrote: On Fri, Jul 24, 2015 at 3:46 AM, Robert Kern robert.k...@gmail.com wrote: On Wed, Jul 22, 2015 at 7:45 PM, josef.p...@gmail.com wrote: Is there an explanation somewhere of what different basic dtypes mean, across platforms

Re: [Numpy-discussion] Rationale for integer promotion rules

2015-07-16 Thread Robert Kern
the rules are concerned with. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] dimension independent copy of corner of array

2015-07-13 Thread Robert Kern
...) is oldarray.shape? ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion

Re: [Numpy-discussion] Backwards-incompatible improvements to numpy.random.RandomState

2015-05-24 Thread Robert Kern
to the entropy source, and hence the whole sequence will be affected, even if you do set a random seed. Please reread the proposal at the top of the thread. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org

Re: [Numpy-discussion] Backwards-incompatible improvements to numpy.random.RandomState

2015-05-24 Thread Robert Kern
. allowing b==0 where before we only allowed b0), but we will not make other enhancements that would change existing good output. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] binary wheels for numpy?

2015-05-17 Thread Robert Kern
PyPI is out. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] performance of numpy.array()

2015-04-29 Thread Robert Kern
top` to see what C functions in user space and kernel space are taking up the most time in your process. If you see anything like `do_page_fault()`, this, or a similar issue, is your problem. -- Robert Kern ___ NumPy-Discussion mailing list NumPy

Re: [Numpy-discussion] Non-meta indexing improvements discussion

2015-04-09 Thread Robert Kern
this scenario goes down). If we have to answer it depends; is there an @ortho_indexing decorator at the top of the function?, that's probably a cure worse than the disease. The properties are a good way to provide googleable signposts right where the tricky semantics are being used. -- Robert Kern

Re: [Numpy-discussion] On responding to dubious ideas (was: Re: Advanced indexing: fancy vs. orthogonal)

2015-04-08 Thread Robert Kern
On Wed, Apr 8, 2015 at 2:06 AM, Nathaniel Smith n...@pobox.com wrote: On Apr 5, 2015 7:04 AM, Robert Kern robert.k...@gmail.com wrote: On Sat, Apr 4, 2015 at 10:38 PM, Nathaniel Smith n...@pobox.com wrote: On Apr 4, 2015 4:12 AM, Todd toddr...@gmail.com wrote

Re: [Numpy-discussion] On responding to dubious ideas (was: Re: Advanced indexing: fancy vs. orthogonal)

2015-04-08 Thread Robert Kern
On Wed, Apr 8, 2015 at 8:05 PM, Eric Firing efir...@hawaii.edu wrote: Now, can we please get back to consideration of reasonable options? Sure, but I recommend going back to the actually topical thread (or a new one), as this one is meta. -- Robert Kern

Re: [Numpy-discussion] On responding to dubious ideas (was: Re: Advanced indexing: fancy vs. orthogonal)

2015-04-08 Thread Robert Kern
is a googleable term so you can look up what this means. I almost always use the default fancy indexing, but I'd use the arr.fancy_ix property for the nontrivial cases just for this alone. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org

Re: [Numpy-discussion] Advanced indexing: fancy vs. orthogonal

2015-04-05 Thread Robert Kern
can compare those consequences to approaches like Jaime's that achieve a majority of the benefits of such a change without any of the negative consequences. That comparison does not bode well for any proposal. -- Robert Kern ___ NumPy-Discussion mailing

Re: [Numpy-discussion] Advanced indexing: fancy vs. orthogonal

2015-04-04 Thread Robert Kern
them). Basically, I think saying one thing and doing another is not a good way to build people's trust. There is a difference between politely considering what proposals people send us uninvited and inviting people to work on specific proposals. That is what Ralf was getting at. -- Robert Kern

Re: [Numpy-discussion] Mathematical functions in Numpy

2015-03-17 Thread Robert Kern
/ ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] random.RandomState and deepcopy

2015-03-13 Thread Robert Kern
On Fri, Mar 13, 2015 at 5:59 PM, Neal Becker ndbeck...@gmail.com wrote: Robert Kern wrote: On Fri, Mar 13, 2015 at 5:34 PM, Neal Becker ndbeck...@gmail.com wrote: It is common that to guarantee good statistical independence between various random generators, a singleton instance

Re: [Numpy-discussion] random.RandomState and deepcopy

2015-03-13 Thread Robert Kern
__deepcopy__. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] argument handling by uniform

2015-03-13 Thread Robert Kern
interpreted? Broadcast against each other. Roughly equivalent to: uni = np.array([ np.random.uniform(-0.5, 201), np.random.uniform(0.5, 201), ]) -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman

Re: [Numpy-discussion] tie breaking for max, min, argmax, argmin

2015-03-12 Thread Robert Kern
would be identical, so returning the first one is just as good as any other. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] numpy pickling problem - python 2 vs. python 3

2015-03-07 Thread Robert Kern
pickle when it otherwise wouldn't, which is not the intention. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] One-byte string dtype: third time's the charm?

2015-02-22 Thread Robert Kern
. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] unpacking data values into array of bits

2015-02-12 Thread Robert Kern
is correct) Also, I don't know how to reverse this process You already had your string ready for transmission with `struct.pack('d', pi)`. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo

Re: [Numpy-discussion] unpacking data values into array of bits

2015-02-12 Thread Robert Kern
On Thu, Feb 12, 2015 at 3:00 PM, Neal Becker ndbeck...@gmail.com wrote: Robert Kern wrote: On Thu, Feb 12, 2015 at 2:21 PM, Neal Becker ndbeck...@gmail.com wrote: I need to transmit some data values. These values will be float and long values. I need them encoded into a string of bits

Re: [Numpy-discussion] unpacking data values into array of bits

2015-02-12 Thread Robert Kern
On Thu, Feb 12, 2015 at 3:22 PM, Neal Becker ndbeck...@gmail.com wrote: Robert Kern wrote: On Thu, Feb 12, 2015 at 3:00 PM, Neal Becker ndbeck...@gmail.com wrote: Robert Kern wrote: On Thu, Feb 12, 2015 at 2:21 PM, Neal Becker ndbeck...@gmail.com wrote: I need to transmit

Re: [Numpy-discussion] Why am I getting a FutureWarning with this code?

2014-12-22 Thread Robert Kern
comparison with None rather than an equality comparison. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] Add a function to broadcast arrays to a given shape to numpy's stride_tricks?

2014-12-11 Thread Robert Kern
/numpy.broadcast.html -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] FFTS for numpy's FFTs (was: Re: Choosing between NumPy and SciPy functions)

2014-12-11 Thread Robert Kern
don't know much beyond that, but it is probably worth looking in AFAICT the cpu backend is a FFTW wrapper. Indeed. https://github.com/arrayfire/arrayfire/blob/devel/src/backend/cpu/fft.cpp#L16 -- Robert Kern ___ NumPy-Discussion mailing list NumPy

Re: [Numpy-discussion] Add a function to broadcast arrays to a given shape to numpy's stride_tricks?

2014-12-11 Thread Robert Kern
On Thu, Dec 11, 2014 at 4:17 PM, Sebastian Berg sebast...@sipsolutions.net wrote: On Do, 2014-12-11 at 16:56 +0100, Pierre Haessig wrote: Le 11/12/2014 16:52, Robert Kern a écrit : And we already have a numpy.broadcast() function. http://docs.scipy.org/doc/numpy/reference/generated

Re: [Numpy-discussion] Should ndarray be a context manager?

2014-12-09 Thread Robert Kern
behind generic syntax. -- Robert Kern ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion

  1   2   3   4   5   6   7   8   9   10   >