sbi-dev / pyknos

conditional density estimation with neural networks

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

deprecation of torch.linalg.solve_triangular

janfb opened this issue · comments

commented

We need to update the use of torch.linalg.solve_triangular here:

https://github.com/mackelab/pyknos/blob/5ea3d5b81ecc0f72110d3d03d4a6148c919f3c7c/pyknos/mdn/mdn.py#L277-L287

see

pyknos/mdn/mdn.py:279: UserWarning: torch.triangular_solve is deprecated in favor of torch.linalg.solve_triangularand will be removed in a future PyTorch release.
  torch.linalg.solve_triangular has its arguments reversed and does not return a copy of one of the inputs.
  X = torch.triangular_solve(B, A).solution
  should be replaced with
  X = torch.linalg.solve_triangular(A, B). (Triggered internally at  /Users/distiller/project/pytorch/aten/src/ATen/native/BatchLinearAlgebra.cpp:1672.)
    zero_mean_samples, _ = torch.triangular_solve(

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html