Advisory

PYSEC-2025-198

Also known as: BIT-pytorch-2025-46148, CVE-2025-46148

Summary

The record has no summary.

Details

In PyTorch through 2.6.0, when eager is used, nn.PairwiseDistance(p=2) produces incorrect results.

Severity

Medium Basis: CVSS v3 score 5.3, vector CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N

Dates

Published
2025-09-25 15:16 UTC
Modified
2026-05-20 09:19 UTC

Affected packages and fixes

torch

PyPI · All systems

Affected

  • introduced 0, fixed 2.7.0 (ecosystem)

Fixed versions

2.7.0

Fix

  • Fixed version 2.7.0
    pip install --upgrade torch==2.7.0

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: PyPA Advisory Database · CC BY 4.0

Sources & licences