From 564b9cefa719d28dd7dee56d69c9f9a3b6e1a9a6 Mon Sep 17 00:00:00 2001 From: lkdvos Date: Tue, 28 Apr 2026 07:07:54 -0400 Subject: [PATCH] attempt to stabilize tests by using `randn` --- test/factorizations/svd.jl | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/test/factorizations/svd.jl b/test/factorizations/svd.jl index d52489e7d..cec5e1dda 100644 --- a/test/factorizations/svd.jl +++ b/test/factorizations/svd.jl @@ -21,9 +21,9 @@ for V in spacelist @testset "Condition number and rank" begin for T in eltypes, t in ( - rand(T, W, W), rand(T, W, W)', - rand(T, (V1 ⊗ V2 ⊗ V3), (V4 ⊗ V5)'), rand(T, (V1 ⊗ V2)', (V3 ⊗ V4 ⊗ V5))', - rand(T, (V1 ⊗ V2), (V3 ⊗ V4 ⊗ V5)'), rand(T, (V1 ⊗ V2 ⊗ V3)', (V4 ⊗ V5))', + randn(T, W, W), randn(T, W, W)', + randn(T, (V1 ⊗ V2 ⊗ V3), (V4 ⊗ V5)'), randn(T, (V1 ⊗ V2)', (V3 ⊗ V4 ⊗ V5))', + randn(T, (V1 ⊗ V2), (V3 ⊗ V4 ⊗ V5)'), randn(T, (V1 ⊗ V2 ⊗ V3)', (V4 ⊗ V5))', DiagonalTensorMap(rand(T, reduceddim(Vd)), Vd), ) @@ -47,7 +47,7 @@ for V in spacelist @test rank(t2) == 0 @test cond(t2) == 0.0 end - for T in eltypes, t in (rand(T, W, W), rand(T, W, W)') + for T in eltypes, t in (randn(T, W, W), randn(T, W, W)') project_hermitian!(t) vals = @constinferred LinearAlgebra.eigvals(t) λmax = maximum(s -> maximum(abs, s), values(vals))