mirror of
https://github.com/kalmarek/PropertyT.jl.git
synced 2024-11-26 00:55:27 +01:00
update check_property_T
This commit is contained in:
parent
c9b226f550
commit
6c247e73fc
@ -182,22 +182,29 @@ function check_property_T(sett::Settings)
|
|||||||
|
|
||||||
files_exist = ex.([:Uπs, :orbits, :preps])
|
files_exist = ex.([:Uπs, :orbits, :preps])
|
||||||
|
|
||||||
if !all(files_exists)
|
if !all(files_exist)
|
||||||
compute_orbit_data(prepath(sett), sett.S, sett.autS, radius=sett.radius)
|
compute_orbit_data(prepath(sett), parent(Δ), sett.autS)
|
||||||
end
|
end
|
||||||
|
|
||||||
cond1 = exists(filename(fullpath(sett), :λ))
|
files_exist = exists(filename(fullpath(sett), :λ)) &&
|
||||||
cond2 = exists(filename(fullpath(sett), :P))
|
exists(filename(fullpath(sett), :P))
|
||||||
|
|
||||||
if !sett.warmstart && cond1 && cond2
|
if !sett.warmstart && files_exist
|
||||||
λ, P = λandP(fullpath(sett))
|
λ, P = loadλandP(fullpath(sett))
|
||||||
else
|
else
|
||||||
info("Creating SDP problem...")
|
warmfile = filename(fullpath(sett), :warm)
|
||||||
SDP_problem, orb_data = create_SDP_problem(sett)
|
if sett.warmstart && exists(warmfile)
|
||||||
JuMP.setsolver(SDP_problem, sett.solver)
|
ws = load(warmfile, "warmstart")
|
||||||
info(Base.repr(SDP_problem))
|
else
|
||||||
|
ws = nothing
|
||||||
|
end
|
||||||
|
λ, P, ws = computeλandP(Δ, sett, ws,
|
||||||
|
solverlog=filename(fullpath(sett), :solverlog))
|
||||||
|
saveλandP(fullpath(sett), λ, P, ws)
|
||||||
|
|
||||||
λ, P = λandP(SDP_problem, orb_data, sett)
|
if λ < 0
|
||||||
|
warn("Solver did not produce a valid solution!")
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
info("λ = $λ")
|
info("λ = $λ")
|
||||||
|
Loading…
Reference in New Issue
Block a user