mirror of
https://github.com/kalmarek/PropertyT.jl.git
synced 2024-11-29 01:40:28 +01:00
fix for solve_in_loop script
This commit is contained in:
parent
9afbccda15
commit
ed832d69fb
@ -81,14 +81,13 @@ function solve_in_loop(model::JuMP.Model, args...; logdir, optimizer, data)
|
|||||||
abs(certified_λ - old_lambda) /
|
abs(certified_λ - old_lambda) /
|
||||||
(abs(certified_λ) + abs(old_lambda))
|
(abs(certified_λ) + abs(old_lambda))
|
||||||
@info "Certification failed with λ = $λ" certified_λ rel_change status
|
@info "Certification failed with λ = $λ" certified_λ rel_change status
|
||||||
|
if rel_change < 1e-9
|
||||||
|
@info "No progress detected, breaking" certified_λ rel_change status
|
||||||
|
break
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
old_lambda = certified_λ
|
old_lambda = certified_λ
|
||||||
|
|
||||||
if rel_change < 1e-9
|
|
||||||
@info "No progress detected, breaking" certified_λ rel_change status
|
|
||||||
break
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
return status == JuMP.OPTIMAL ? old_lambda : NaN
|
return status == JuMP.OPTIMAL ? old_lambda : NaN
|
||||||
|
Loading…
Reference in New Issue
Block a user