@@ -101,7 +101,7 @@ function optimize_rigid(fixed, moving, A::AffineMap, maxshift,
101
101
102
102
stat = MathProgBase. status (m)
103
103
p = MathProgBase. getsolution (m)
104
- stat == :Optimal || (@warn (" Solution was not optimal" ); @show p)
104
+ stat == :Optimal || (@warn (" Solution was not optimal 1 " ); @show p)
105
105
fval = MathProgBase. getobjval (m)
106
106
107
107
p2rigid (p, SD), fval
@@ -475,8 +475,9 @@ function find_opt(P::AffineQHessian{AP,M,N,Φ}, b, maxshift, x0) where {AP,M,N,
475
475
MathProgBase. setwarmstart! (m, x0)
476
476
MathProgBase. optimize! (m)
477
477
stat = MathProgBase. status (m)
478
- stat == :Optimal || @warn (" Solution was not optimal" )
479
- MathProgBase. getsolution (m)
478
+ p = MathProgBase. getsolution (m)
479
+ stat == :Optimal || (@warn (" Solution was not optimal 2" ); @show p)
480
+ return p
480
481
end
481
482
482
483
# We omit the constant term ∑_i cs[i]'*Qs[i]*cs[i], since it won't
@@ -608,8 +609,8 @@ function _optimize!(objective, ϕ, dp, mmis, tol, print_level; kwargs...)
608
609
MathProgBase. optimize! (m)
609
610
610
611
stat = MathProgBase. status (m)
611
- stat == :Optimal || @warn (" Solution was not optimal" )
612
612
uopt = MathProgBase. getsolution (m)
613
+ stat == :Optimal || (@warn (" Solution was not optimal 3" ); @show uopt)
613
614
fval = MathProgBase. getobjval (m)
614
615
_copy! (ϕ, uopt)
615
616
ϕ, fval, fval0
@@ -1164,8 +1165,8 @@ function fit_sigmoid(data, bottom, top, center, width)
1164
1165
MathProgBase. optimize! (m)
1165
1166
1166
1167
stat = MathProgBase. status (m)
1167
- stat == :Optimal || @warn (" Solution was not optimal" )
1168
1168
x = MathProgBase. getsolution (m)
1169
+ stat == :Optimal || (@warn (" Solution was not optimal 4" ); @show x)
1169
1170
1170
1171
x[1 ], x[2 ], x[3 ], x[4 ], MathProgBase. getobjval (m)
1171
1172
end
0 commit comments