Skip to content
This repository was archived by the owner on Sep 10, 2025. It is now read-only.
This repository was archived by the owner on Sep 10, 2025. It is now read-only.

Warning/Exception for torchtext.data.metrics.bleu_score #2277

@Rajinish0

Description

@Rajinish0

🚀 Feature

Motivation

I was working on calculating bleu_score, however, due to a bug in my code I did not realize that my references_corpus wasn't a list of list of words.

Pitch

I think it would be helpful for this function to either give a warning or raise an Exception if the references_corpus is not in the desired format.

Thanks!

Alternatives

Additional context

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions