List of Functions

1D DWT/IDWT Functions

1. DWT [dwtop,length,flag]=wavepy.dwt.dwt(x,J,nm,ext)

x - 1D Input Signal Array

J- Decomposition levels

nm- Wavelet Name (see filtcoef for list of names)

ext- Extension. Either 'sym' for symmetric or 'per' for periodic extension.

The function requires all four input fields.

dwtop- DWT Coefficients with approximation and detail coefficients arranged as {A(J),D(J),D(J-1),....D(1)}.

D(n) corresponds to detail coefficient at the nth level of decomposition

length- Length vector which corresponds to lengths of approximation and detail coefficients arranged as above. First value corresponds to length of approximation coefficient at level J, second value to length of detail coefficients at level J and so on.

flag- Vector to store values of J, padding etc.

2. IDWT idwt_output=wavepy.dwt.idwt(dwtop,nm,length,flag)

(dwtop,length,flag)- Outputs of DWT stage.

nm- Wavelet name

idwt_output - IDWT Output

1D DWT/IDWT Example IPython Demo Python Source Code

1D SWT/ISWT Functions

3. SWT [swtop,length]=wavepy.dwt.swt(x,J,nm)

x - 1D Input Signal Array (Dyadic Length)

J- Decomposition levels

nm- Wavelet Name (see filtcoef for list of names)

swtop- SWT Coefficients with approximation and detail coefficients arranged as {A(J),D(J),D(J-1),....D(1)}.

D(n) corresponds to detail coefficient at the nth level of decomposition

length- length of each approximation and decomposition vector. All vectors are of same length.

4. ISWT iswtop=wavepy.dwt.iswt(swtop,J,nm)

swtop- SWT Output

J- Decomposition Levels

nm- Wavelet Name

iswtop- ISWT Output

1D SWT/ISWT Example IPython Demo Python Source Code

2D DWT/IDWT Functions

5. 2D-DWT [dwtop,length,flag]=wavepy.dwt.dwt2(x,J,nm,ext)

x- Input 2D Array

J- Decomposition levels

nm- Wavelet Name (see filtcoef for list of names)

ext- Extension. Either 'sym' for symmetric or 'per' for periodic extension.

dwtop- DWT Coefficients with approximation and detail coefficients arranged as {A(J),D(J),D(J-1),....D(1)}.

D(n) corresponds to detail coefficient at the nth level of decomposition

length- Length vector which corresponds to rows and columns length of approximation and detail coefficients arranged as above. {See def dwt2 in dwt.py}-

flag- Vector to store values of J, padding etc.

6. 2D-IDWT idwt_output=wavepy.dwt.idwt2(dwtop,nm,length,flag)

(dwtop,length,flag)- Outputs of DWT stage.

nm- Wavelet name

idwt_output - IDWT Output

2D DWT/IDWT Example IPython Demo Python Source Code

2D SWT Function

7. 2D SWT [swtop,length]=wavepy.dwt.swt2(x,J,nm)

x - 2D Input Signal Array (Dyadic dimensions)

J- Decomposition levels

nm- Wavelet Name (see filtcoef for list of names)

swtop- SWT Coefficients with approximation and detail coefficients arranged as {A(J),D(J),D(J-1),....D(1)}.

D(n) corresponds to detail coefficient at the nth level of decomposition

length- Row and column lengths of each approximation and decomposition array. All 2D coefficient arrays have same dimensions so length contains only two elements {row,column}

2D ISWT function has not been implemented.

2D SWT/ISWT Example IPython Demo Python Source Code

Convolution

8. FFT-based c=wavepy.convol.convfft(b,a)

Recommended This function uses numpy's inbuilt FFT function to compute the convolution.a and b are input functions while c is the output.The output isn't strictly real but can be made real by using numpy.real(c)

9. Direct c=wavepy.convol.convol(b,a)

For small 1D direct vectors, direct convolution may be the way to go. a and b are input functions while c is the output.

Convolution Example IPython Demo Python Source Code

Wavelet Filter

10. Filters [lpd,hpd,lpr,hpr]=wavepy.filter.filtcoef(nm)

nm: Wavelet name.

lpd: Low Pass Decomposition Filter Coefficients.

hpd: High Pass Decomposition Filter Coefficients.

lpr: Low Pass Reconstruction Filter Coefficients.

hpr: High Pass Reconstruction Filter Coefficients.

Currently, following Wavelets are available:

Daubechies : db1,db2,.., ,db15

Biorthogonal: bior1.1 ,bior1.3 ,bior1.5 ,bior2.2 ,bior2.4 ,bior2.6 ,bior2.8 ,bior3.1 ,bior3.3 ,bior3.5 , bior3.7 ,bior3.9 ,bior4.4 ,bior5.5 ,bior6.8

Coiflets: coif1,coif2,coif3,coif4,coif5

Symmlets: sym2,........, sym10

Filter Display Example IPython Demo Python Source Code

Signal Extension

11. 1D Periodic y=wavepy.misc.per_ext(x,a)

x Input Signal

a Signal Extension in both directions

y Extended signal of length len(x)+2*a

12. 1D Symmetric y=wavepy.misc.symm_ext(x,a)

x Input Signal

a Signal Extension in both directions

y Extended signal of length len(x)+2*a

1D Signal Extension Example IPython Demo Python Source Code

Image Extension

13. 2D Periodic y=wavepy.misc.per_ext2d(x,a)

x Input Image of Dimension (row,col)

a Signal Extension in all four directions

y Extended Image of Dimension(row+2*a,col+2*a)

14. 2D Symmetric y=wavepy.misc.symm_ext2d(x,a)

x Input Image of Dimension (row,col)

a Signal Extension in all four directions

y Extended Image of Dimension(row+2*a,col+2*a)

2D Image Extension Example IPython Demo Python Source Code