From 90449e017560c8d0acb274313fa8fbea2c84a336 Mon Sep 17 00:00:00 2001 From: AdrianSosic Date: Mon, 20 Apr 2026 10:03:03 +0200 Subject: [PATCH] Replace deprecated torch.jit.script with torch.compile --- linear_operator/utils/linear_cg.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/linear_operator/utils/linear_cg.py b/linear_operator/utils/linear_cg.py index 7bbc5ceb..c4f2cccb 100644 --- a/linear_operator/utils/linear_cg.py +++ b/linear_operator/utils/linear_cg.py @@ -14,7 +14,7 @@ def _default_preconditioner(x): return x.clone() -@torch.jit.script +@torch.compile def _jit_linear_cg_updates( result, alpha, @@ -47,7 +47,7 @@ def _jit_linear_cg_updates( curr_conjugate_vec.mul_(beta).add_(precond_residual) -@torch.jit.script +@torch.compile def _jit_linear_cg_updates_no_precond( mvms, result,