Utilities for remapping files to new phone set (mfa remap)#

Remap a dictionary to new phone set (mfa remap dictionary)#

If you have a mismatch in the phone sets used in your dictionary file and acoustic model, you can use this command to command to generate pronunciations with the new phone set.

Command reference#

mfa remap dictionary#

Adapt an acoustic model to a new corpus.

mfa remap dictionary [OPTIONS] DICTIONARY_PATH ACOUSTIC_MODEL_PATH
                     PHONE_MAPPING_PATH OUTPUT_DICTIONARY_PATH

Options

-p, --profile <profile>#

Configuration profile to use, defaults to “global”

-t, --temporary_directory <temporary_directory>#

Set the default temporary directory, default is /home/docs/Documents/MFA

-j, --num_jobs <num_jobs>#

Set the number of processes to use by default, defaults to 3

--clean, --no_clean#

Remove files from previous runs, default is True

--final_clean, --no_final_clean#

Remove temporary files at the end of run, default is False

-v, --verbose, -nv, --no_verbose#

Output debug messages, default is False

-q, --quiet, -nq, --no_quiet#

Suppress all output messages (overrides verbose), default is False

--overwrite, --no_overwrite#

Overwrite output files when they exist, default is False

--use_mp, --no_use_mp#

Turn on/off multiprocessing. Multiprocessing is recommended will allow for faster executions.

--use_threading, --no_use_threading#

Use threading library rather than multiprocessing library. Multiprocessing is recommended will allow for faster executions.

-d, --debug, -nd, --no_debug#

Run extra steps for debugging issues, default is False

--use_postgres, --no_use_postgres#

Use postgres instead of sqlite for extra functionality, default is False

--single_speaker#

Single speaker mode creates multiprocessing splits based on utterances rather than speakers. This mode also disables speaker adaptation equivalent to --uses_speaker_adaptation false.

--textgrid_cleanup, --cleanup_textgrids, --no_textgrid_cleanup, --no_cleanup_textgrids#

Turn on/off post-processing of TextGrids that cleans up silences and recombines compound words and clitics.

-h, --help#

Show this message and exit.

Arguments

DICTIONARY_PATH#

Required argument

ACOUSTIC_MODEL_PATH#

Required argument

PHONE_MAPPING_PATH#

Required argument

OUTPUT_DICTIONARY_PATH#

Required argument

Configuration reference#

API reference#

Remap aligned TextGrids to new phone set (mfa remap alignments)#

This command will remap phones in any phone tier to new phones based on a phone mapping yaml file.

Phone mapping yaml files for remapping alignments are more strict than for Remap a dictionary to new phone set (mfa remap dictionary) or Evaluating alignments. For those usages, it is possible to have phones map to more than one option, and extra pronunciations will be generated/allowed. For alignment, as there must be one label interval, the phone mapping yaml files must likewise not have any variation in what phones they map to. If additional phones are supplied as variations, only the first phone will be used in remapping, and the rest ignored.

Mapping files should be of the format SOURCE_PHONE: TARGET PHONE. As an example, consider the case of a file aligned using english_mfa acoustic model and wanting to generate ARPA labels from the alignments, see below:

aj: AY1
aw: AW1
b: B
: B
c: K
: K
: K
d: D
: JH
: D
ej: EY1
f: F
: F
h: HH
i: IY0
: IY1
...

Command reference#

mfa remap alignments#

Adapt an acoustic model to a new corpus.

mfa remap alignments [OPTIONS] CORPUS_DIRECTORY PHONE_MAPPING_PATH
                     OUTPUT_DIRECTORY

Options

--output_format <output_format>#

Format for aligned output files (default is long_textgrid).

Options:

long_textgrid | short_textgrid | json | csv

-p, --profile <profile>#

Configuration profile to use, defaults to “global”

-t, --temporary_directory <temporary_directory>#

Set the default temporary directory, default is /home/docs/Documents/MFA

-j, --num_jobs <num_jobs>#

Set the number of processes to use by default, defaults to 3

--clean, --no_clean#

Remove files from previous runs, default is True

--final_clean, --no_final_clean#

Remove temporary files at the end of run, default is False

-v, --verbose, -nv, --no_verbose#

Output debug messages, default is False

-q, --quiet, -nq, --no_quiet#

Suppress all output messages (overrides verbose), default is False

--overwrite, --no_overwrite#

Overwrite output files when they exist, default is False

--use_mp, --no_use_mp#

Turn on/off multiprocessing. Multiprocessing is recommended will allow for faster executions.

--use_threading, --no_use_threading#

Use threading library rather than multiprocessing library. Multiprocessing is recommended will allow for faster executions.

-d, --debug, -nd, --no_debug#

Run extra steps for debugging issues, default is False

--use_postgres, --no_use_postgres#

Use postgres instead of sqlite for extra functionality, default is False

--single_speaker#

Single speaker mode creates multiprocessing splits based on utterances rather than speakers. This mode also disables speaker adaptation equivalent to --uses_speaker_adaptation false.

--textgrid_cleanup, --cleanup_textgrids, --no_textgrid_cleanup, --no_cleanup_textgrids#

Turn on/off post-processing of TextGrids that cleans up silences and recombines compound words and clitics.

-h, --help#

Show this message and exit.

Arguments

CORPUS_DIRECTORY#

Required argument

PHONE_MAPPING_PATH#

Required argument

OUTPUT_DIRECTORY#

Required argument

Configuration reference#

API reference#