torcheval.metrics.functional.word_information_lost¶
-
torcheval.metrics.functional.
word_information_lost
(input: Union[str, List[str]], target: Union[str, List[str]]) Tensor [source]¶ Word Information Lost rate is a metric of the performance of an automatic speech recognition system. This value indicates the percentage of characters that were incorrectly predicted. The lower the value, the better the performance of the ASR system with a Word Information Lost rate of 0 being a perfect score.
Its class version is
torcheval.metrics.WordInformationLost
.Parameters: - input – Transcription(s) to score as a string or list of strings
- target – Reference(s) for each speech input as a string or list of strings
Returns: Word Information Lost rate
Examples
>>> from torcheval.metrics.functional import word_information_lost >>> input = ["this is the prediction", "there is an other sample"] >>> target = ["this is the reference", "there is another one"] >>> word_information_lost(input, target) tensor(0.6528)