Skip to main content

Package containing one wrapper script over the Allosaurus phoneme recognition library, designed for passing the Allosaurus output data to MATLAB scripts for further analysis.

Project description

phonemeRecognizerWrapper

Package containing one wrapper script over the Allosaurus phoneme recognition library, designed for passing the Allosaurus output data to MATLAB scripts for further analysis.

Usage: phonemeRecognizer.py

This script uses the Allosaurus phoneme recognition package to extract phonemic content from audio files of human speech. This script acts as a wrapper over the allosaurus package for improved formatting and piping of data to MATLAB scripts for analysis (e.g. vowel formant extraction).

Command structure

py -m phonemeRecognizerWrapper.recognize LANGUAGE_CODE FILES EMIT_PROB

Required Arguments:

  1. LANGUAGE_CODE
    • Three characters long language code supported by the Allosaurus library. For the list of available languages, use command:
      py -m allosaurus.bin.list_lang
    • To display the phonetic inventory (list of phonemes) for a specific language, use:
      py -m allosaurus.bin.list_phone [--lang <language name>]
    • See here for more info.
    • Example options:
      • "ipa" - uses the whole available phonetic inventory for recognition (less accurate)
      • "deu" - german
      • "gsw" - swiss german
      • "fra" - french
      • "eng" - english
  2. FILES
    • Semicolon delimited text string containing absolute paths to all files meant for recognition. Surround the string with apostrophes ("") if any of the paths contains spaces.
    • Example:
      "C:\sounds\sound1.wav;C:\sounds\sound2.wav"

Optional Arguments:

  1. EMIT_PROB
    • Allosaurus setting that determines the phoneme emission rate of the underlying model. Higher number tells the model to produce more phonemes, smaller number vice versa.
      Center is at 1.0, and optimal range that produces comprehensive outputs is 0.8 - 1.5. If omitted, default value of 1.5 is used.

Examples

  • Example usage from command line: py -m phonemeRecognizerWrapper.recognize eng "C:\sounds\sound.wav;C:\sounds\sound2.wav" 1.0

  • Example usage from MATLAB via the [status, result] = system(command) function:
    command = 'py -m phonemeRecognizerWrapper.recognize eng "C:\sounds\sound.wav;C:\sounds\sound2.wav" 1.0';

    • It is also recommended to use set PYTHONIOENCODING=utf8 before the python command to ensure proper text formantting via the standard output pipe.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

phonemeRecognizerWrapper-0.1.2.tar.gz (5.1 kB view details)

Uploaded Source

File details

Details for the file phonemeRecognizerWrapper-0.1.2.tar.gz.

File metadata

File hashes

Hashes for phonemeRecognizerWrapper-0.1.2.tar.gz
Algorithm Hash digest
SHA256 c406d24a9634f5f1f65880ffc40e040ab2433ff54e50aef111b9485671443a25
MD5 eb3c5b5d55b52c1485f7cd8b939a23bb
BLAKE2b-256 e22a46fadb76a54ce9a7081cbf794bbece5529c4f6bc9b3506d10e4cd8408ff4

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page