Skip to content

AssertionError description typo #1167

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
goodsuga opened this issue May 28, 2025 · 0 comments
Open

AssertionError description typo #1167

goodsuga opened this issue May 28, 2025 · 0 comments

Comments

@goodsuga
Copy link

Hi! I think there's a typo:

if torch.is_floating_point(output) and threshold is None:
        raise ValueError(
            f"Output should be one of the integer types if ``threshold`` is not None, got {output.dtype}."
        )

in metrics/functional.py:121

Shouldn't it be "when threshold is None"?

if torch.is_floating_point(output) and threshold is None:
        raise ValueError(
            f"Output should be one of the integer types if ``threshold`` is None, got {output.dtype}."
        )
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant