BLEU Score¶ Module Interface¶ torchmetrics.BLEUScore[source] alias of torchmetrics.text._deprecated._BLEUScore Functional Interface¶ torchmetrics.functional.bleu_score(preds, target, n_gram=4, smooth=False, weights=None)[source] Wrapper for deprecated import. >>> preds = ['the cat is on the mat'] >>> target = [['there is a cat on the mat', 'a cat is on the mat']] >>> _bleu_score(preds, target) tensor(0.7598) Return type Tensor