On Mon, May 10, 2010 at 2:14 PM, T J wrote:
> On Sun, May 9, 2010 at 4:49 AM, wrote:
>>
>> I think this is the same point, I was trying to make last year.
>>
>> Instead of renormalizing, my conclusion was the following,
>> (copied from the mailinglist August last year)
>>
>> """
>> my conclusion
On 10 May 2010 21:56, Dr. Phillip M. Feldman wrote:
>
>
> Anne Archibald-2 wrote:
>>
>> on a 32-bit machine,
>> the space overhead is roughly a 32-bit object pointer or two for each
>> float, plus about twice the number of floats times 32-bit pointers for
>> the table.
>>
>
> Hello Anne,
>
> I'm a
Dr. Phillip M. Feldman wrote:
> Anne Archibald-2 wrote:
>
>> on a 32-bit machine,
>> the space overhead is roughly a 32-bit object pointer or two for each
>> float, plus about twice the number of floats times 32-bit pointers for
>> the table.
>>
>>
>
> Hello Anne,
>
> I'm a bit confused by
Anne Archibald-2 wrote:
>
> on a 32-bit machine,
> the space overhead is roughly a 32-bit object pointer or two for each
> float, plus about twice the number of floats times 32-bit pointers for
> the table.
>
Hello Anne,
I'm a bit confused by the above. It sounds as though the hash table
app
On 10 May 2010 18:53, Dr. Phillip M. Feldman wrote:
>
> I have an application that involves managing sets of floats. I can use
> Python's built-in set type, but a data structure that is optimized for
> fixed-size objects that can be compared without hashing should be more
> efficient than a more
I have an application that involves managing sets of floats. I can use
Python's built-in set type, but a data structure that is optimized for
fixed-size objects that can be compared without hashing should be more
efficient than a more general set construct. Is something like this
available?
--
> This inconsistency is fixed in Numpy 1.4 (which included a major
> overhaul of chararrays). in1d will perform the auto
> whitespace-stripping on chararrays, but not on regular ndarrays of strings.
Great, thanks.
> Pyfits continues to use chararray since not doing so would break
> existing c
On 5/10/2010 5:42 PM, gerardob wrote:
> I would like to check whether lower_bound[i]<= x[i]<= upper_bound[i] for
> all i in range(len(x))
>>> import numpy as np
>>> l, m, u = np.arange(12).reshape((3,4))
>>> (l <= m) & (m <= u)
array([ True, True, True, True], dtype=bool)
>>> l[3]=9
>>> (l <=
I have three lists of floats of equal lenght: upper_bound, lower_bound and x.
I would like to check whether lower_bound[i]<= x[i] <= upper_bound[i] for
all i in range(len(x))
Which is the best way to do this?
Thanks.
--
View this message in context:
http://old.nabble.com/check-for-inequalit
On Mon, May 10, 2010 at 11:14 AM, T J wrote:
> On Sun, May 9, 2010 at 4:49 AM, wrote:
> >
> > I think this is the same point, I was trying to make last year.
> >
> > Instead of renormalizing, my conclusion was the following,
> > (copied from the mailinglist August last year)
> >
> > """
> > my
Also from the docstring:
"""
.. note::
The `chararray` class exists for backwards compatibility with
Numarray, it is not recommended for new development. Starting from numpy
1.4, if one needs arrays of strings, it is recommended to use arrays of
`dtype` `object_`, `string_` or `unicode
On May 8, 2010, at 9:51 PM, Gökhan Sever wrote:
>
>
>
> On Sat, May 8, 2010 at 9:29 PM, Eric Firing wrote:
> On 05/08/2010 04:16 PM, Ryan May wrote:
> > On Sat, May 8, 2010 at 7:52 PM, Gökhan Sever wrote:
> >>
> >> AttributeError: can't set attribute
> >>
> >> Why this assignment fails? I want
On Sun, May 9, 2010 at 4:49 AM, wrote:
>
> I think this is the same point, I was trying to make last year.
>
> Instead of renormalizing, my conclusion was the following,
> (copied from the mailinglist August last year)
>
> """
> my conclusion:
> -
> What numpy.random.pareto ac
>
> This is an intentional "feature", not a bug.
>
> Chris
>
Ah, ok, thanks. I missed the explanation in the doc string because I'm using
version 1.3 and forgot to check the web docs.
For the record, this was my bug: I read a fits binary table with pyfits. One of
the table fields was a chara
On Sun, May 9, 2010 at 2:42 PM, Eric Firing wrote:
>
> The mask attribute can be a full array, or it can be a scalar to
> indicate that nothing is masked. This is an optimization in masked
> arrays; it adds complexity, but it can save space and/or processing
> time. You can always access a full
On Mon, May 10, 2010 at 11:23 AM, Neil Crighton wrote:
> I've been working with pyfits, which uses numpy chararrays. I've discovered
> the
> hard way that chararrays silently remove trailing whitespace:
>
a = np.array(['a '])
b = a.view(np.chararray)
a[0]
> 'a '
b[0]
> 'a'
>
>
From the chararray docstring:
Versus a regular Numpy array of type `str` or `unicode`, this
class adds the following functionality:
1) values automatically have whitespace removed from the end
when indexed
So I guess it is a feature, not a bug. :)
Warren
Neil Crig
I've been working with pyfits, which uses numpy chararrays. I've discovered the
hard way that chararrays silently remove trailing whitespace:
>>> a = np.array(['a '])
>>> b = a.view(np.chararray)
>>> a[0]
'a '
>>> b[0]
'a'
Note the string values stored in memory are unchanged. This behaviour ca
18 matches
Mail list logo