From d11ccaf8a71afa9f77af8c5283852d2802a6c87e Mon Sep 17 00:00:00 2001 From: dpo Date: Fri, 6 Oct 2023 18:18:05 +0000 Subject: [PATCH] :robot: Format .jl files --- src/TRDH_alg.jl | 4 +++- test/runtests.jl | 6 ++++-- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/src/TRDH_alg.jl b/src/TRDH_alg.jl index ed822092..459050a7 100644 --- a/src/TRDH_alg.jl +++ b/src/TRDH_alg.jl @@ -342,7 +342,9 @@ function TRDH( #! format: on @info "TRDH: terminating with √(ξ1/ν) = $(sqrt_ξ_νInv)" else - @info @sprintf "%6d %8.1e %8.1e %7.1e %8s %7.1e %7.1e %7.1e %7.1e" k fk hk sqrt_ξ_νInv "" Δk χ(xk) χ(s) norm(Dk.d) + @info @sprintf "%6d %8.1e %8.1e %7.1e %8s %7.1e %7.1e %7.1e %7.1e" k fk hk sqrt_ξ_νInv "" Δk χ( + xk, + ) χ(s) norm(Dk.d) @info "TRDH: terminating with √(ξ/ν) = $(sqrt_ξ_νInv)" end end diff --git a/test/runtests.jl b/test/runtests.jl index a288cbb6..70892408 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -84,7 +84,8 @@ for (h, h_name) ∈ ((NormL0(λ), "l0"), (NormL1(λ), "l1"), (IndBallL0(10 * com @test length(out.solver_specific[:Fhist]) == length(out.solver_specific[:Hhist]) @test length(out.solver_specific[:Fhist]) == length(out.solver_specific[:SubsolverCounter]) @test length(out.solver_specific[:Fhist]) == length(out.solver_specific[:NLSGradHist]) - @test out.solver_specific[:NLSGradHist][end] == bpdn_nls.counters.neval_jprod_residual + bpdn_nls.counters.neval_jtprod_residual - 1 + @test out.solver_specific[:NLSGradHist][end] == + bpdn_nls.counters.neval_jprod_residual + bpdn_nls.counters.neval_jtprod_residual - 1 @test obj(bpdn_nls, out.solution) == out.solver_specific[:Fhist][end] @test h(out.solution) == out.solver_specific[:Hhist][end] @test out.status == :first_order @@ -109,7 +110,8 @@ for (h, h_name) ∈ ((NormL1(λ), "l1"),) @test length(LMTR_out.solver_specific[:Fhist]) == length(LMTR_out.solver_specific[:SubsolverCounter]) @test length(LMTR_out.solver_specific[:Fhist]) == length(LMTR_out.solver_specific[:NLSGradHist]) - @test LMTR_out.solver_specific[:NLSGradHist][end] == bpdn_nls.counters.neval_jprod_residual + bpdn_nls.counters.neval_jtprod_residual - 1 + @test LMTR_out.solver_specific[:NLSGradHist][end] == + bpdn_nls.counters.neval_jprod_residual + bpdn_nls.counters.neval_jtprod_residual - 1 @test obj(bpdn_nls, LMTR_out.solution) == LMTR_out.solver_specific[:Fhist][end] @test h(LMTR_out.solution) == LMTR_out.solver_specific[:Hhist][end] @test LMTR_out.status == :first_order