| |
2.2.4 File Conversion:
Creating Sof Files
The recognizer processes files using an
AudioFile
interface that accepts files in a number of formats, including an
internal format, Sof, previously described in
Section 2.1.6.
We provide a tool, isip_make_sof, to convert external speech
file formats to Sof. Below we demonstrate use of this tool to convert
raw files to Sof. Other formats can be easily converted in the same
manner using a modified parameter file for isip_make_sof.
Go to the directory:
$ISIP_TUTORIAL/sections/s02/s02_02_p04/
The following command generates an Sof file from the linear 16-bit raw
speech file,
speech.raw:
isip_make_sof speech.raw
By default, this command uses a set of conversion parameters
designed for 16-bit 8kHz data. See
conversion parameter file
to view the default parameter file for this tool. This parameter file
can be configured using
isip_transform_builder,
a general purpose signal processing tool described in detail in
Section 3.
Since the configuration file is a text Sof file, users can also
manually edit this file to modify some of the basic parameters
of the conversion process.
The above command generates a file named
speech.sof
that contains an Sof-formatted version of the data. By default a
binary version of the audio file is created. The following command:
isip_make_sof -type text -suffix _text speech.raw
will generate a text version of the file.
Click here
to view the result of this command.
Further details can be found in our
on-line documentation.
Note that command line arguments for all our utilities follow a uniform
structure implemented using a
command line parser.
Three important features of this interface are (1) partial name completion
(e.g., "-ty" or "-typ") for option names (e.g., "-type"),
(2) help messages can be displayed at any point by simply typing
"-help", and (3) options can be specified in any order.
Other file formats, such as Microsoft WAV, can be converted to Sof
using the same process. However, the
conversion parameter file
which we refer to as a
recipe,
must be modified. This can be done using isip_transform_builder,
or simply changing the line "file_format = RAW" in the FrontEnd
object in the
conversion parameter file
to "file_format = WAV".
|
| |
|