You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I get a MethodErrorwhen constructing the result Optim.MultivariateOptimizationResults when solving a interior point minimization problem using Float32s. The reason is that, by default, the Optim.Options are constructed using Float64 and in the optimize function for the constrained problem the types are inferred as
T =typeof(options.f_reltol)
Tf =typeof(value(d))
In my case T = Float64 and Tf = Float32 and this is not consistent with MultivariateOptimizationResults.
Yes, a type conversion the correct place is probably the solution. Are you open of having a stab at it? Otherwise I may have time here in December to look at it. OF course you can work around it even if it's annoying to set them all.
Issue
I get a
MethodError
when constructing the resultOptim.MultivariateOptimizationResults
when solving a interior point minimization problem usingFloat32
s. The reason is that, by default, theOptim.Options
are constructed usingFloat64
and in theoptimize
function for the constrained problem the types are inferred asIn my case
T = Float64
andTf = Float32
and this is not consistent withMultivariateOptimizationResults
.MWE
Just adapting the Rosenberk function example as
One straight forward solution is of course to do
Solution
Would it be fine to just promote the
options
in theMultivariateOptimizationResults
construction usingTf
instead ofT
?Version and stacktrace of error for MWE
The version is
Optim v1.7.8
.The text was updated successfully, but these errors were encountered: