We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
It says to load Symbolics but I have loaded it already.
Julia 1.10.3 ⌃ [a0c0ee7d] DifferentiationInterface v0.5.11 [f6369f11] ForwardDiff v0.10.36 [7f7a1694] Optimization v3.27.0 [36348300] OptimizationOptimJL v0.3.2 ⌅ [0c5d862f] Symbolics v5.36.0 julia> using DifferentiationInterface, Symbolics, Optimization, OptimizationOptimJL, ForwardDiff julia> let f(x,_) = x'x optfunc = OptimizationFunction(f, DifferentiationInterface.AutoForwardDiff()) optprob = OptimizationProblem(optfunc, [4.0]) solve(optprob, LBFGS()) end retcode: Success u: 1-element Vector{Float64}: 0.0 julia> let f(x,_) = x'x optfunc = OptimizationFunction(f, DifferentiationInterface.AutoSymbolics()) optprob = OptimizationProblem(optfunc, [4.0]) solve(optprob, LBFGS()) end ERROR: ArgumentError: The passed automatic differentiation backend choice is not available. Please load the corresponding AD package Symbolics. Stacktrace: [1] instantiate_function(f::Function, x::OptimizationBase.ReInitCache{…}, adtype::AutoSymbolics, p::Int64, num_cons::Int64) @ OptimizationBase ~/.julia/packages/OptimizationBase/mGHPN/src/function.jl:114 [2] instantiate_function(f::Function, x::OptimizationBase.ReInitCache{…}, adtype::AutoSymbolics, p::Int64) @ OptimizationBase ~/.julia/packages/OptimizationBase/mGHPN/src/function.jl:106 [3] OptimizationCache(prob::OptimizationProblem{…}, opt::LBFGS{…}, data::Base.Iterators.Cycle{…}; callback::Function, maxiters::Nothing, maxtime::Nothing, abstol::Nothing, reltol::Nothing, progress::Bool, structural_analysis::Bool, manifold::Nothing, kwargs::@Kwargs{}) @ OptimizationBase ~/.julia/packages/OptimizationBase/mGHPN/src/cache.jl:38 [4] __init(prob::OptimizationProblem{…}, opt::LBFGS{…}, data::Base.Iterators.Cycle{…}; callback::Function, maxiters::Nothing, maxtime::Nothing, abstol::Nothing, reltol::Nothing, progress::Bool, kwargs::@Kwargs{}) @ OptimizationOptimJL ~/.julia/packages/OptimizationOptimJL/hDX5k/src/OptimizationOptimJL.jl:112 [5] __init(prob::OptimizationProblem{…}, opt::LBFGS{…}, data::Base.Iterators.Cycle{…}) @ OptimizationOptimJL ~/.julia/packages/OptimizationOptimJL/hDX5k/src/OptimizationOptimJL.jl:77 [6] init(::OptimizationProblem{…}, ::LBFGS{…}; kwargs::@Kwargs{}) @ SciMLBase ~/.julia/packages/SciMLBase/vhP5T/src/solve.jl:174 [7] init(::OptimizationProblem{…}, ::LBFGS{…}) @ SciMLBase ~/.julia/packages/SciMLBase/vhP5T/src/solve.jl:172 [8] solve(::OptimizationProblem{…}, ::LBFGS{…}; kwargs::@Kwargs{}) @ SciMLBase ~/.julia/packages/SciMLBase/vhP5T/src/solve.jl:96 [9] solve(::OptimizationProblem{…}, ::LBFGS{…}) @ SciMLBase ~/.julia/packages/SciMLBase/vhP5T/src/solve.jl:93 [10] top-level scope
The text was updated successfully, but these errors were encountered:
Maybe this is linked to the fact that the corresponding backend was called AutoModelingToolkit before? @Vaibhavdixit02
Sorry, something went wrong.
The error message is too naive sorry about that. You need to load ModelingToolkit to be able to use this since the extension is for MTK
Yep that works, thanks.
No branches or pull requests
It says to load Symbolics but I have loaded it already.
The text was updated successfully, but these errors were encountered: