PyTorch 2.14.0 always validates sparse-tensor invariants under weights_only=True and drops eval() from Flight Recorder rank parsing
Released 2026-09-02T17:40Z, PyTorch 2.14.0's security section makes `torch.load(..., weights_only=True)` always validate sparse-tensor invariants so malformed checkpoints cannot create tensors whose indices cause out-of-bounds reads, an O(nnz) scan that runs regardless of the global `torch.sparse.check_sparse_tensor_invariants` setting; the notes explicitly say not to use `weights_only=False` as a workaround for untrusted files. Flight Recorder rank expressions are now parsed with `ast.literal_eval()` instead of being executed with `eval()`, and distributed object collectives gain an opt-in `weights_only=True` restricted-deserialization mode with the default unchanged. Headline features are NVGEMM CuTeDSL-generated CUTLASS kernels in Inductor, `torch.switch` for multi-way branching, and native Apple Silicon linear algebra including Jacobi-kernel SVD, eigh, QR and Cholesky.
Source
↳ Follow the thread