Is it possible to downcast an array in-place?
For example:
x = np.random.random(10) # Placeholder for "real" data
x -= x.min()
x /= x.ptp() / 255
x = x.astype(np.uint8) <-- returns a copy
First off, a bit of background to the question... At the moment, I'm trying
to downcast a large (>10GB) arra
Assuming no typos
Relationship between Pareto, Pareto(II)/Lomax and Generalized Pareto,GPD
>>> import sympy as sy
>>> x = sy.Symbol('x')
>>> k = sy.Symbol('k')
>>> c = sy.Symbol('c')
>>> a = sy.Symbol('a')
>>> m = sy.Symbol('m')
>>> mgpd = sy.Symbol('mgpd')
>>> gpd0 = (1 - c*x/k)**(1/c - 1)/k #
On Tue, May 11, 2010 at 8:11 AM, Kevin Jacobs
wrote:
> On Tue, May 11, 2010 at 4:14 AM, Pauli Virtanen wrote:
>>
>> A third option would be just to silently fix the bug. In any case the
>> change should be mentioned noticeably in the release notes.
>>
>
> I see this as two bugs: the Lomax distri
On Tue, May 11, 2010 at 4:14 AM, Pauli Virtanen wrote:
> A third option would be just to silently fix the bug. In any case the
> change should be mentioned noticeably in the release notes.
>
>
I see this as two bugs: the Lomax distribution was named incorrectly and the
Parato distribution was inc
Tue, 11 May 2010 00:23:52 -0700, T J wrote:
[clip]
> It seems reasonable that we might have to follow the deprecation route,
> but I'd be happier with a "faster" fix.
>
> 1.5
> - Provide numpy.random.lomax. Make numpy.random.pareto raise a
> DeprecationWarning and then call lomax.
>
> 2.0 (
On Tue, May 11, 2010 at 12:23 AM, T J wrote:
> On Mon, May 10, 2010 at 8:37 PM, wrote:
> >
> > I went googling and found a new interpretation
> >
> > numpy.random.pareto is actually the Lomax distribution also known as
> Pareto 2,
> > Pareto (II) or Pareto Second Kind distribution
> >
>
> Great
On Mon, May 10, 2010 at 8:37 PM, wrote:
>
> I went googling and found a new interpretation
>
> numpy.random.pareto is actually the Lomax distribution also known as Pareto 2,
> Pareto (II) or Pareto Second Kind distribution
>
Great!
>
> So, from this it looks like numpy.random does not have a Pa