A sonogram applet

A sonogram is a time-frequency representation of a sound signal, generaly computed using a Fourier transform, with time in x-coordinate and frequency in y-coordinate. The aim of this page is to offer an interactive sonogram, where the user sees the representation sliding on screen. The signal used is from the soundcard's microphone port.

Sound recording by an applet is forbidden by default. To allow it, one has to copy the file java.policy under C:\WINNT\Profiles\username\.java.policy on Windows and ~username/.java.policy on Unix, and reload the browser's virtual machine policy configuration (just re-launch the browser).

Here is a heavy version of the sonogram, which requires at least a 1GHz Pentium. On a slower processor, rather use the light version below. Both applets cannot run together, and it is convenient to stop the processing before leaving the web page ; the best is to monitor the processor load with the ad hoc utility.

To launch the processing, press the "Microphone" button.

Trouble instantiating applet Sonogram!!

Here is the light version of the sonogram, which should run on a 200MHz processor.

To launch the processing, press the "Microphone" button.

Trouble instantiating applet TinySonogram!!

The processing used by the heavy (resp. light) version is as follow:

Here are some considerations about performance : the challenge was to get a real time display with a java program ; the above applets were designed using spoke, a library of javabeans components for signal processing. Perhaps a lower level language would allow for processing at the full capacity of the soundcard (CD quality) but for now this is out of reach with java, and frequencies are displayed only up to 4KHz on the sonograms.

Which is the interest of such an interactive sonogram ? Apart from just for fun, there is a didactic aspect : this applet allows for analyzing for instance animal singing, without aiming at too high a scientific level, which would require broader capabilities (specially in frequency : see the paragraph above) and quantitative data : graduations, adjustable numerical parameters, etc. These capabilities, independant from real time capability, exist in other software products.

But the most interesting application is for deaf persons support. While it is not possible today to recognize speach using a sonogram, such a representation could simply allow for knowing if there is sound at all, and for distinguishing among different sounds. Development of PocketPC-like digital personal assistants that are powerful enough to run the software can give a boost to its applications : for instance, to connect the device to a wireless phone in the case of persons with partial disability, etc. Real speach recognition would demand at least analysis of high frequencies, for distinguishing among consonants like 's' and 'f', and finding a representation better suited for speach analysis than Fourier transform, possibly based on wavelets or other techniques. To offer a graphical representation is an alternative to the capabilities of modern speech recognition software products (also based on time-frequency analysis) which are single-speaker and which, for that reason, aren't of great help to deaf persons. The problem is to find a representation where it is easy to recognize speach.

Here is the source code of the applets.


created on Thu Aug  1 2002