TrainableAligner

class aligner.aligner.TrainableAligner(corpus, dictionary, training_config, align_config, output_directory, temp_directory=None, call_back=None, debug=False, verbose=False)[source]

Aligner that aligns and trains acoustics models on a large dataset

Parameters:
corpus : Corpus

Corpus object for the dataset

dictionary : Dictionary

Dictionary object for the pronunciation dictionary

training_config : TrainingConfig

Configuration to train a model

align_config : AlignConfig

Configuration for alignment

output_directory : str

Path to export aligned TextGrids

temp_directory : str, optional

Specifies the temporary directory root to save files need for Kaldi. If not specified, it will be set to ~/Documents/MFA

num_jobs : int, optional

Number of processes to use, defaults to 3

call_back : callable, optional

Specifies a call back function for alignment

Attributes

meta

Methods

compile_information(model_directory)
export_textgrids() Export a TextGrid file for every sound file in the dataset
save(path) Output an acoustic model and dictionary to the specified path
setup()
train()
export_textgrids()[source]

Export a TextGrid file for every sound file in the dataset

save(path)[source]

Output an acoustic model and dictionary to the specified path

Parameters:
path : str

Path to save acoustic model and dictionary