ttslearn.util

General utility

Example files

example_audio_file

Get the path to an included audio example file.

example_label_file

Get the path to an included label file.

example_qst_file

Get the path to an included question set file.

Mask

make_pad_mask

Make mask for padding frames

make_non_pad_mask

Make mask for non-padding frames

Padding

pad_1d

Pad a 1d-tensor.

pad_2d

Pad a 2d-tensor.

Path

load_utt_list

Load a list of utterances.

find_lab

Find label for a given utterance.

find_feats

Find features for a given utterance.

Misc

init_seed

Initialize random seed.

dynamic_import

Dynamic import

lab2phonemes

Convert labels to phonemes.

optional_tqdm

Get a tqdm object.

trim_silence

Trim silence from input features.