ftp.nice.ch/pub/next/science/signal_proc/WPLab.2.5.README

This is the README for WPLab.2.5.N.bd.tar.gz [Download] [Browse] [Up]

           USING THE WAVELET PACKET LABORATORY

			Reading a Signal From a File

WPLab can read text files which have the extension ".asc" appended to their names, and which contain just ASCII floating-point numbers.

Selecting the "Open" item from the application's main menu brings up a browser panel which allows the user to select any single file with the proper extension.  The entire file is read into a double-precision floating-point array in memory, and the array is padded with zeroes up to an integer multiple of the longest available segment length.

The number of samples in the signal is displayed in the "Signal Length" text field.  The signal file name becomes the title for the main window, and also for the miniwindow upon miniaturization.

 
			Displaying a Signal Segment

Segments of the signal file are plotted in the rectangular view near the bottom of the window.

WPLab can display segments whose lengths are a power of 2, and starting at arbitrary offsets.  Use the "Segment Length" radio buttons to select this length, and any combination of the offset form, slider, and buttons to set the index of the first displayed sample.

The buttons "Prev", "Next", "++", and "--" adjust the offset.  Their actions, respectively, are to subtract a segment length, add a segment length, add 1, and subtract 1.  The program does the best it can given the signal length.

If a newly selected segment length is too long for the current offset, the offset is decreased to accommodate it.

 
			Choosing a Quadrature Mirror Filter

There are 17 quadrature mirror filters (QMFs) available for wavelet packet analysis.  They are identified by a letter ("B", "C", "D", or "V"), followed by (finite) impulse response length.  For example, the Haar filters {sqrt(2), sqrt(2)}, {sqrt(2), -sqrt(2)} are designated D2.

Preview a filter by clicking on its radio button.  In the small "Wavelet" window will appear a plot of the mother wavelet associated to that QMF.  This action enables the "Set QMF" and "Revert" buttons.

Roughly speaking, longer filters produce smoother wavelets and wavelet packets with better frequency resolution.

Click on the "Set QMF" button to register your choice and update the Phase Plane.  This disables the "Set QMF" and "Revert" buttons.

Click on the "Revert" button to cancel previewing filters and return to the last registered QMFs.  This will disable the "Set QMF" and "Revert" buttons.


 		   The Phase Plane Representation of a Signal

The large square view contains that portion of the phase plane affected by the plotted segment.  WPLab draws a rectangle in the phase plane for every modulated waveform in the basis chosen to represent the signal.

Each modulated waveform can be assigned 4 attributes: amplitude a, timescale s, frequency f, and position p.  In a musical note, these correspond to loudness, duration, pitch, and the instant it is played.

Suppose that the signal segment has length N = 2^n.  Coefficient (a,s,f,p) is displayed as the rectangle  [p 2^s, (p+1) 2^s] x [f 2^(n-s), (f+1) 2^(n-s)], shaded in proportion to a^2.

Because of the Heisenberg uncertainty principle, position and frequency cannot both be specified to arbitrary precision.  The uncertainty of the frequency is 2^s, and the uncertainty in position is 2^(n-s).  Thus each rectangle or ``Heisenberg box'' has area 2^n = N.  Since the total area of the displayed section of the phase plane is N^2, there are exactly N Heisenberg boxes in a disjoint cover of the section.

A library consists of all possible Heisenberg boxes, and bases from the library consist of certain disjoint covers of the phase plane by such rectangles. 

The ``Toggle Lines Around Box Edges'' button makes it possible to see the shape of the boxes.  The phase plane representation of a basis becomes immediately visible this way.


			Choosing a Basis

Wavelet Basis:  this forces a display of the wavelet basis constructed with the given mother wavelet.

Fixed Level:  this forces a choice of basis in which all of the Heisenberg boxes have the same time scale, determined by the value in the `Level:' form.

Best Level:  this forces all of the Heisenberg boxes to have the same time scale.  The resulting basis consists of congruent boxes. There are (log N) such bases for a segment of length N, and the one displayed has minimum entropy.

Best Basis:  this minimizes entropy over all bases corresponding to disjoint dyadic covers of the segment.  There are more than 2^N such bases for a segment of length N.

			Selecting Coefficients

The simplest way to select a coefficient is to click on its Heisenberg
box.  To unselect it, just click on the box again.  If you drag open a
box, all of the coefficients whose Heisenberg boxes intersect the box
will be selected.

It is possible to automate the coefficient selection process.  To set
a threshold directly, enter a number between 0 and 100 into the
"Threshold(%)" form or manipulate the slider above the form.  All
coefficients whose magnitude (normalized so that the largest
coefficent is unity) squared is greater than the threshold are
selected.  The filled rectangle below the threshold form displays the
grayscale corresponding to the current threshold.

To select a certain number of coefficients, enter a number into the
form labled "N" and press one of the buttons above the form.  The
threshold will be set to the value of the coefficient with the Nth
largest normalized squared magnitude.  The bug-sensitive reader will
notice that no provision for ties has been made---check "Selected
Coefficients" to make sure things have been done correctly.


			Reconstructing a Signal

To view the inverse transform, click the ``Inverse Transform of Selected
Coeffs'' button.  The signal reconstructed from the selected coefficients will be displayed in the bottom signal view.


			Printing the Window

The entire contents of the key window may be printed at full scale with the "Print" menu item. 

by M.V. Wickerhauser, D. Rochberg




These are the contents of the former NiCE NeXT User Group NeXTSTEP/OpenStep software archive, currently hosted by Netfuture.ch.