Hello,
I work with numarray.zeros(n, numarray.Float64) as sound mixers ;
there are huge number of datas : 44 000 .. 192 000 /second
Operations : add, append, add & append (if the mixing begins
on the existing part of the array + append if the array has to
be prolonged)
I do never use list-append
Growing an array by appending it is the slow way in matlab. The
suggested way to do things there is preallocate the array by saying
x=zeros() and then referencing the elements in the array and
inserting the correct value.
--Chad Kidder
On Oct 17, 2007, at 7:16 AM, mark wrote:
So i
So it seems like lists are the way to grow an array.
Interestingly enough, it is very easy to grown an array in Matlab.
Any idea how they do that (or are they slow as well?).
Mark
On Oct 11, 8:53 pm, "Adam Mercer" <[EMAIL PROTECTED]> wrote:
> On 11/10/2007, Mark Janikas <[EMAIL PROTECTED]> wrote
On 11/10/2007, Mark Janikas <[EMAIL PROTECTED]> wrote:
> If you do not know the size of your array before you finalize it, then
> you should use lists whenever you can. I just cooked up a short
> example:
> # Result #
> Total Time with array: 2.12951189331
> Total Time with list: 0.0469
:[EMAIL PROTECTED] On Behalf Of Adam Mercer
Sent: Thursday, October 11, 2007 7:42 AM
To: Discussion of Numerical Python
Subject: Re: [Numpy-discussion] appending extra items to arrays
On 11/10/2007, Robert Kern <[EMAIL PROTECTED]> wrote:
> Appending to a list then converting the list to
On 11/10/2007, Robert Kern <[EMAIL PROTECTED]> wrote:
> Appending to a list then converting the list to an array is the most
> straightforward way to do it. If the performance of this isn't a problem, I
> recommend leaving it alone.
Thanks, I'll leave it as is - I was just wondering if there was
On 10/10/07, Anne Archibald <[EMAIL PROTECTED]> wrote:
>
> On 11/10/2007, Robert Kern <[EMAIL PROTECTED]> wrote:
>
> > Appending to a list then converting the list to an array is the most
> > straightforward way to do it. If the performance of this isn't a
> problem, I
> > recommend leaving it alon
Anne Archibald wrote:
> On 11/10/2007, Robert Kern <[EMAIL PROTECTED]> wrote:
>
>> Appending to a list then converting the list to an array is the most
>> straightforward way to do it. If the performance of this isn't a problem, I
>> recommend leaving it alone.
>
> Just a speculation:
>
> Python
On 11/10/2007, Robert Kern <[EMAIL PROTECTED]> wrote:
> Appending to a list then converting the list to an array is the most
> straightforward way to do it. If the performance of this isn't a problem, I
> recommend leaving it alone.
Just a speculation:
Python strings have a similar problem - the
Adam Mercer wrote:
> Hi
>
> In some code I have, I need to append some extra data to a given
> array. At the moment I construct the data in a list, append the extra
> information I need and then convert the final list to an array. Is
> there a way that I can append extra information to an existi
Adam Mercer wrote:
> Hi
>
> In some code I have, I need to append some extra data to a given
> array. At the moment I construct the data in a list, append the extra
> information I need and then convert the final list to an array. Is
> there a way that I can append extra information to an existin
Adam Mercer wrote:
> Hi
>
> In some code I have, I need to append some extra data to a given
> array. At the moment I construct the data in a list, append the extra
> information I need and then convert the final list to an array. Is
> there a way that I can append extra information to an existin
Hi
In some code I have, I need to append some extra data to a given
array. At the moment I construct the data in a list, append the extra
information I need and then convert the final list to an array. Is
there a way that I can append extra information to an existing array
thereby negating the n
13 matches
Mail list logo