help-octave
[Top][All Lists]

## Re: loooooong vector difficulties

 From: Robert Leach Subject: Re: loooooong vector difficulties Date: Wed, 13 Aug 2003 11:42:11 -0600

```OK yeah, so what I want to do is this:

%get the signal (vector of zeroes and ones)
signal = load('./signal.txt')   %file of space delimited zeroes and ones

%normalize signal
nsignal = signal - .5

%create the wavelet
[lowpass,highpass,ilowpass,ihighpass] = daub(20)

%Adjust the size of the convolution kernals
alowpass = zeros(1,size(1,nsignal))
ahighpass = zeros (1,size(1,nsignal))

for i=1:10
alowpass(i) = lowpass(i)
ahighpass(i) = highpass(i)
end

startindex = size(1,nsignal) - 10

for i=startindex:size(1,nsignal)
alowpass(i) = lowpass(i)
ahighpass(i) = highpass(i)
end

%Determine the maximum number of scales
```
scales = log(size(1,nsignal)) / log(2) %Note: my signal is of length 2^x
```
%Perform the wavelet transform
coefs = wt(nsignal,alowpass,ahighpass,scales)

```
This is as far as I've gotten, but it keeps crashing because of the size of the signal So, do you think that I can split the signal up without any loss? I'm mostly interested in the low frequency patterns and my gut feeling is that if I split it up, I'll miss it. Also, this is the first time I've done a wavelet analysis, so if you notice any mistakes, let me know.
```
Thanks,
Rob

On Wednesday, August 13, 2003, at 11:02  AM, address@hidden wrote:

```
```
```
There is perhapes an easy solution, but if it's a vector of zeros and ones, what about storing the values on bits instead of a whole 64 double to each value? You could create operations to access an integer vector
```as if it was a bit vector!... It hurts in my heart watching bits being
stored as huge floating-point numbers! :)

Of course, if you are going to operate on the vectors it's out of
question...

Are you going to convolve these vectors with another? If it's simple as
that, you surely can split everything and mix afterwards.

On Wed, Aug 13, 2003 at 10:22:10AM -0600, Robert Leach wrote:
```
```Hi,

I have some data that's huge.  It's a string of zeroes and ones that I
want to split up into a vector as input to a wavelet transform.  I'm
talking 9 million elements.  I have 3 of these vectors.  First of all,
even calling zeros(1,9000000) takes forever.  I do that to initially
populate a convolution kernel and then change the first and last 10
elements with taps.  Even those two, ten-iteration loops take forever.
Second, octave eventually chokes.

Is there anything I can do to

1: improve performance so that operations it does successfully go
faster
2: make octave more amenable to large data structures so it doesn't
crash

?

If that's not possible, then what affect on my results would splitting
up the data have?

Thanks,
Rob

=====================================================================
= Robert W. Leach                                                   =
= Los Alamos National Lab                                           =
= Bioscience Division: Bioinformatics & Computational Biology Group =
= MS M888                                                           =
= Los Alamos, NM 87545                                              =
= 505-667-2307                                                      =
=====================================================================
Work Calendar & To-Do
List:   http://66.93.220.190/phpicalendar/week.php?cal=Work

-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:  http://www.octave.org
How to fund new projects:  http://www.octave.org/funding.html
Subscription information:  http://www.octave.org/archive.html
-------------------------------------------------------------

```
```
--
Nicolau Werneck <address@hidden>         9F99 25AB E47E 8724 2F71
http://cefala.org/~nwerneck                   EA40 DC23 42CE 6B76 B07F
```
"Experience is not what happens to a man; it is what a man does with what happens to him."
```-- Aldous Huxley

```
```=====================================================================
= Robert W. Leach                                                   =
= Los Alamos National Lab                                           =
= Bioscience Division: Bioinformatics & Computational Biology Group =
= MS M888                                                           =
= Los Alamos, NM 87545                                              =
= 505-667-2307                                                      =
=====================================================================
```
Work Calendar & To-Do List: http://66.93.220.190/phpicalendar/week.php?cal=Work
```

-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:  http://www.octave.org
How to fund new projects:  http://www.octave.org/funding.html
Subscription information:  http://www.octave.org/archive.html
-------------------------------------------------------------

```