Two approaches

Two approaches for FST-based forced alignment will be described:

Note that the Kaldi-based approach does not depend on Kaldi at all. That is, you don’t need to install Kaldi in order to use it. Instead, we use kaldi-decoder, which has ported the C++ decoding code from Kaldi without depending on it.

Differences between the two approaches

The following table compares the differences between the two approaches.

Features

Kaldi-based

k2-based

Support CUDA

No

Yes

Support CPU

Yes

Yes

Support batch processing

No

Yes on CUDA; No on CPU

Support streaming models

Yes

No

Support C++ APIs

Yes

Yes

Support Python APIs

Yes

Yes