Here is an example of a set of sorted coefficients:

Notice the
glyph along the
bottom of the sorted Wavelet window. This glyph tells you that the data in this
window has been sorted (and can therefore be unsorted).

Truncating coefficients means throwing some of them away (i.e. setting their values to zero, and then resizing the array to eliminate them). The Truncate Coeffs... dialog allows you to truncate wavelet coefficients in 4 ways:
Here is an example of a truncation operation which kept 50% of the previous set of coefficients:

Notice that when data is unsorted:
glyph disappears from
the Wavelet window, indicating that the data is no longer sorted.
Once the coefficient array has been unsorted, it can be used in an inverse wavelet transform to reconstruct the original dataset.
Choosing this item will perform the following steps in sequence:
To perform a compression, first select a Wavelet window containing 1-d data. Then, choose the Compress... item of the Wavelets menu, and one of the filter items of the attached submenu. Whatever filter set you choose from the submenu will be used to perform the wavelet transform as part of the compression operation. You can also perform compression using a custom filter by choosing the Custom... item of the submenu.
Here is an example of an input dataset and its compressed coefficients, based on keeping 50% of the sorted coefficients:

To perform an expansion, first select a Wavelet window containing truncated wavelet coefficients. Then, choose the Expand... item of the Wavelets menu, and one of the filter items of the attached submenu. Whatever filter set you choose from the submenu will be used to perform the inverse wavelet transform as part of the expansion operation. You can also perform expansion using a custom filter by choosing the Custom... item of the submenu.
Here is an example of an expansion of the previously compressed dataset:

Note that this dataset appears very similar to the original dataset, even though 50% of the intermediate wavelet coefficients were eliminated.

To compare the reconstructed data to the original, you can subtract the original dataset from the reconstructed one. To do this, first select the window containing the reconstructed dataset. Then, choose the Subtract Datasets... item from the Wavelets menu. You will see the following dialog:

From the pop-up menu of windows (every 1d window in the current document), choose the Original window. When performing subtraction and other math operations, you may want to name your windows first, so that you can distinguish one from another in the pop-up menu. The result of subtracting the original dataset from the reconstruction looks like the following:

Note that the magnitude of the difference is at most about 0.1% of the original.
One way to measure the accuracy of reconstruction of the data is to look at the average sum of squared differences between the original and the reconstruction. This information is available from the Data Stats... item of the Edit menu. To see this infomation, select the window showing the subtracted dataset, and then choose the Data Stats... menu item. You should see the following:

When compressing data, you may want to try different wavelet filter sets and different truncation options, until you find the method that eliminates the most coefficients, while minimizing the average sum of squares difference between the original data and its reconstruction.

You may select either the Text or Binary Data type: button. The format of a text file of sorted/truncated coefficients is the following:
Original number of points in data: Text value
Each data point: Text value
Index of each data point: Text value
The format of a binary file of sorted/truncated coefficients is the following:
Original number of points in data: 4-byte integer value
Current number of points in data: 4-byte integer value
Each data point: 4-byte real value
Index of each data point: 4-byte integer value
The original number of points is the length of the unsorted array. The index of
each point is the position (0-based) that the point occupied in the unsorted
array.
Contents | Previous Section | Next Section
MacWavelets 2.00 User's Manual.
"MacWavelets" is a trademark of Intergalactic Reality.
© Copyright Intergalactic Reality, 1996.
All rights reserved.