Skip to content

Commit

Permalink
Dont compare against MINPACK for the most part
Browse files Browse the repository at this point in the history
  • Loading branch information
avik-pal committed Dec 14, 2023
1 parent 9422d0b commit aa47ee2
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 22 deletions.
29 changes: 14 additions & 15 deletions benchmarks/NonlinearProblem/Manifest.toml
Original file line number Diff line number Diff line change
Expand Up @@ -1025,9 +1025,9 @@ version = "0.15.1"

[[deps.LazyArrays]]
deps = ["ArrayLayouts", "FillArrays", "LinearAlgebra", "MacroTools", "MatrixFactorizations", "SparseArrays"]
git-tree-sha1 = "08d56555410b0683cd7b48bff37aa59cbb0ea908"
git-tree-sha1 = "9cfca23ab83b0dfac93cb1a1ef3331ab9fe596a5"
uuid = "5078a376-72f3-5289-bfd5-ec5146d43c02"
version = "1.8.2"
version = "1.8.3"
weakdeps = ["StaticArrays"]

[deps.LazyArrays.extensions]
Expand Down Expand Up @@ -1683,9 +1683,9 @@ version = "1.3.4"

[[deps.RecursiveArrayTools]]
deps = ["Adapt", "ArrayInterface", "DocStringExtensions", "GPUArraysCore", "IteratorInterfaceExtensions", "LinearAlgebra", "RecipesBase", "Requires", "StaticArraysCore", "Statistics", "SymbolicIndexingInterface", "Tables"]
git-tree-sha1 = "d7087c013e8a496ff396bae843b1e16d9a30ede8"
git-tree-sha1 = "3f40e61c93a7c46b85df57b770bc360988f9ca36"
uuid = "731186ca-8d62-57ce-b412-fbd966d074cd"
version = "2.38.10"
version = "3.0.0"

[deps.RecursiveArrayTools.extensions]
RecursiveArrayToolsMeasurementsExt = "Measurements"
Expand Down Expand Up @@ -1792,9 +1792,9 @@ version = "0.6.42"

[[deps.SciMLBase]]
deps = ["ADTypes", "ArrayInterface", "CommonSolve", "ConstructionBase", "Distributed", "DocStringExtensions", "EnumX", "FillArrays", "FunctionWrappersWrappers", "IteratorInterfaceExtensions", "LinearAlgebra", "Logging", "Markdown", "PrecompileTools", "Preferences", "Printf", "QuasiMonteCarlo", "RecipesBase", "RecursiveArrayTools", "Reexport", "RuntimeGeneratedFunctions", "SciMLOperators", "StaticArraysCore", "Statistics", "SymbolicIndexingInterface", "Tables", "TruncatedStacktraces"]
git-tree-sha1 = "32ea825941f7b58a6f48268f4b76971ae8eb9eec"
git-tree-sha1 = "2c5cb9fcae1db5ce71ded89cb9314ad09f6c89bc"
uuid = "0bca4576-84f4-4d90-8ffe-ffa030f20462"
version = "2.10.0"
version = "2.11.0"

[deps.SciMLBase.extensions]
SciMLBaseChainRulesCoreExt = "ChainRulesCore"
Expand Down Expand Up @@ -2084,22 +2084,21 @@ uuid = "fb77eaff-e24c-56d4-86b1-d163f2edb164"
version = "5.2.1+0"

[[deps.SymbolicIndexingInterface]]
deps = ["DocStringExtensions"]
git-tree-sha1 = "f8ab052bfcbdb9b48fad2c80c873aa0d0344dfe5"
git-tree-sha1 = "65f4ed0f9e3125e0836df12c231cea3dd98bb165"
uuid = "2efcf032-c050-4f8e-a9bb-153293bab1f5"
version = "0.2.2"
version = "0.3.0"

[[deps.SymbolicUtils]]
deps = ["AbstractTrees", "Bijections", "ChainRulesCore", "Combinatorics", "ConstructionBase", "DataStructures", "DocStringExtensions", "DynamicPolynomials", "IfElse", "LabelledArrays", "LinearAlgebra", "MultivariatePolynomials", "NaNMath", "Setfield", "SparseArrays", "SpecialFunctions", "StaticArrays", "TimerOutputs", "Unityper"]
git-tree-sha1 = "2f3fa844bcd33e40d8c29de5ee8dded7a0a70422"
deps = ["AbstractTrees", "Bijections", "ChainRulesCore", "Combinatorics", "ConstructionBase", "DataStructures", "DocStringExtensions", "DynamicPolynomials", "IfElse", "LabelledArrays", "LinearAlgebra", "MultivariatePolynomials", "NaNMath", "Setfield", "SparseArrays", "SpecialFunctions", "StaticArrays", "SymbolicIndexingInterface", "TimerOutputs", "Unityper"]
git-tree-sha1 = "849b1dfb1680a9e9f2c6023f79a49b694fb6d0da"
uuid = "d1185830-fcd6-423d-90d6-eec64667417b"
version = "1.4.0"
version = "1.5.0"

[[deps.Symbolics]]
deps = ["ArrayInterface", "Bijections", "ConstructionBase", "DataStructures", "DiffRules", "Distributions", "DocStringExtensions", "DomainSets", "DynamicPolynomials", "Groebner", "IfElse", "LaTeXStrings", "LambertW", "Latexify", "Libdl", "LinearAlgebra", "LogExpFunctions", "MacroTools", "Markdown", "NaNMath", "PrecompileTools", "RecipesBase", "RecursiveArrayTools", "Reexport", "Requires", "RuntimeGeneratedFunctions", "SciMLBase", "Setfield", "SparseArrays", "SpecialFunctions", "StaticArrays", "SymbolicUtils"]
git-tree-sha1 = "28f55dcd865e4a97f262fc476306cee14e8d4651"
deps = ["ArrayInterface", "Bijections", "ConstructionBase", "DataStructures", "DiffRules", "Distributions", "DocStringExtensions", "DomainSets", "DynamicPolynomials", "Groebner", "IfElse", "LaTeXStrings", "LambertW", "Latexify", "Libdl", "LinearAlgebra", "LogExpFunctions", "MacroTools", "Markdown", "NaNMath", "PrecompileTools", "RecipesBase", "Reexport", "Requires", "RuntimeGeneratedFunctions", "SciMLBase", "Setfield", "SparseArrays", "SpecialFunctions", "StaticArrays", "SymbolicIndexingInterface", "SymbolicUtils"]
git-tree-sha1 = "80e67b76699b1ec130ac60946b3d06017f58141f"
uuid = "0c5d862f-8b57-4792-8d23-62f2024744c7"
version = "5.11.0"
version = "5.13.0"

[deps.Symbolics.extensions]
SymbolicsSymPyExt = "SymPy"
Expand Down
14 changes: 7 additions & 7 deletions benchmarks/NonlinearProblem/bruss.jmd
Original file line number Diff line number Diff line change
Expand Up @@ -95,18 +95,18 @@ end
First, let us experiment the scaling of each algorithm with the problem size.

```julia
Ns = 2 .^ (2:7)
Ns = 2 .^ (2:6)
solver_names = ["NewtonRaphson (Dense)", "NewtonRaphson (Approximate Sparse)",
"NewtonRaphson (Exact Sparse)", "TrustRegion (Dense)",
"TrustRegion (Approximate Sparse)", "TrustRegion (Exact Sparse)",
"KINSOL", "CMINPACK", "NLsolveJL (Trust Region)", "SimpleNewtonRaphson",
"SimpleTrustRegion"]
"KINSOL", "NLsolveJL (Trust Region)", "SimpleNewtonRaphson",
"SimpleTrustRegion", "CMINPACK"]
runtimes_scaling = zeros(length(solver_names), length(Ns)) .- 1
prob_alg_mapping = [
(:dense, NewtonRaphson()), (:approx, NewtonRaphson()), (:exact, NewtonRaphson()),
(:dense, TrustRegion()), (:approx, TrustRegion()), (:exact, TrustRegion()),
(:dense, KINSOL()), (:dense, CMINPACK()), (:dense, NLsolveJL()),
(:dense, SimpleNewtonRaphson()), (:dense, SimpleTrustRegion())]
(:dense, KINSOL()), (:dense, NLsolveJL()), (:dense, SimpleNewtonRaphson()),
(:dense, SimpleTrustRegion()), (:dense, CMINPACK())]

for (i, N) in enumerate(Ns)
prob_dense = generate_brusselator_problem(N; abstol=1e-6, reltol=1e-6)
Expand All @@ -126,12 +126,12 @@ for (i, N) in enumerate(Ns)
prob = prob_exact_sparse
end

if j > 1 && runtimes_scaling[j - 1, i] == -1
if (j > 1 && runtimes_scaling[j - 1, i] == -1) || (N > 32 && alg isa CMINPACK) # CMINPACK is pretty worthless and our macro doesn't work with it
# The last benchmark failed so skip this too
runtimes_scaling[j, i] = NaN
println(" $(solver_names[j]): Would Have Timed out")
else
@timeout 1000 begin
@timeout 600 begin
sol = solve(prob, alg)
runtimes_scaling[j, i] = @belapsed solve($prob, $alg)
println(" $(solver_names[j]): ", runtimes_scaling[j, i],
Expand Down

0 comments on commit aa47ee2

Please sign in to comment.