Skip to content

Commit 26637c7

Browse files
test with adnlpproblmems
1 parent 97ccbd5 commit 26637c7

File tree

4 files changed

+13
-8
lines changed

4 files changed

+13
-8
lines changed

Project.toml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,40 +4,44 @@ author = ["Robert Baraldi <rbaraldi@uw.edu> and Dominique Orban <dominique.orban
44
version = "0.1.0"
55

66
[deps]
7+
ADNLPModels = "54578032-b7ea-4c30-94aa-7cbd1cce6c9a"
78
Arpack = "7d9fca2a-8960-54d3-9f78-7d1dccf2cb97"
89
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
910
LinearOperators = "5c8ed15e-5a4c-59e4-a42b-c7e8811fb125"
1011
Logging = "56ddb016-857b-54e1-b83d-db4d58db5568"
1112
ManualNLPModels = "30dfa513-9b2f-4fb3-9796-781eabac1617"
1213
NLPModels = "a4795742-8479-5a88-8948-cc11e1c8c1a6"
1314
NLPModelsModifiers = "e01155f1-5c6f-4375-a9d8-616dd036575f"
15+
OptimizationProblems = "5049e819-d29b-5fba-b941-0eee7e64c1c6"
1416
Percival = "01435c0c-c90d-11e9-3788-63660f8fbccc"
1517
Printf = "de0858da-6303-5e67-8744-51eddeeeb8d7"
1618
ProximalOperators = "a725b495-10eb-56fe-b38b-717eba820537"
1719
RegularizedProblems = "ea076b23-609f-44d2-bb12-a4ae45328278"
20+
ReverseDiff = "37e2e3b7-166d-5795-8a7a-e32c996b4267"
1821
ShiftedProximalOperators = "d4fd37fa-580c-4e43-9b30-361c21aae263"
1922
SolverCore = "ff4d7338-4cf1-434d-91df-b86cb86fb843"
2023

2124
[compat]
25+
ADNLPModels = "0.8.13"
2226
Arpack = "0.5"
23-
CUTEst = "1.3.4"
2427
LinearOperators = "2.10.0"
2528
ManualNLPModels = "0.2.0"
2629
NLPModels = "0.19, 0.20, 0.21"
2730
NLPModelsModifiers = "0.7"
31+
OptimizationProblems = "0.9.2"
2832
Percival = "0.7.2"
2933
ProximalOperators = "0.15"
3034
RegularizedProblems = "0.1.1"
35+
ReverseDiff = "1.16.1"
3136
ShiftedProximalOperators = "0.2"
3237
SolverCore = "0.3.0"
3338
julia = "^1.6.0"
3439

3540
[extras]
36-
CUTEst = "1b53aba6-35b6-5f92-a507-53c67d53f819"
3741
Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
3842
RegularizedProblems = "ea076b23-609f-44d2-bb12-a4ae45328278"
3943
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
4044
TestSetExtensions = "98d24dd4-01ad-11ea-1b02-c9a08f80db04"
4145

4246
[targets]
43-
test = ["CUTEst", "Random", "RegularizedProblems", "Test", "TestSetExtensions"]
47+
test = ["Random", "RegularizedProblems", "Test", "TestSetExtensions"]

test/runtests.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
using LinearAlgebra: length
22
using LinearAlgebra, Random, Test
33
using ProximalOperators
4-
using CUTEst, NLPModels, NLPModelsModifiers, RegularizedProblems, RegularizedOptimization, SolverCore
4+
using ADNLPModels, OptimizationProblems, OptimizationProblems.ADNLPProblems, NLPModels, NLPModelsModifiers, RegularizedProblems, RegularizedOptimization, SolverCore
55

66
const global compound = 1
77
const global nz = 10 * compound
@@ -10,6 +10,7 @@ const global bpdn, bpdn_nls, sol = bpdn_model(compound)
1010
const global bpdn2, bpdn_nls2, sol2 = bpdn_model(compound, bounds = true)
1111
const global λ = norm(grad(bpdn, zeros(bpdn.meta.nvar)), Inf) / 10
1212

13+
include("test_allocs.jl")
1314
include("test_AL.jl")
1415

1516
for (mod, mod_name) ((x -> x, "exact"), (LSR1Model, "lsr1"), (LBFGSModel, "lbfgs"))

test/test_AL.jl

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
1-
problem_list = ["HS8",]
21

32
@testset "Augmented Lagrangian" begin
4-
for problem_name in problem_list
5-
nlp = CUTEstModel(problem_name)
3+
for problem in problem_list
4+
nlp = eval(problem)(backend = :optimized)
65
for h in (NormL1(1.0), NormL2(1.0))
76
stats = AL(nlp, h, atol = 1e-3, verbose = 1)
87
@test stats.status == :first_order

test/test_allocs.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,8 @@ end
6666
end
6767
end
6868
@testset "Augmented Lagrangian" begin
69-
reg_nlp = RegularizedNLPModel(CUTEstModel("HS8"), h)
69+
continue # FIXME : fails due to type instabilities in ADNLPModels...
70+
reg_nlp = RegularizedNLPModel(hs8(backend = :generic), h)
7071
solver = ALSolver(reg_nlp)
7172
stats = RegularizedExecutionStats(reg_nlp)
7273
@test @wrappedallocs(solve!(solver, reg_nlp, stats, atol = 1e-3)) == 0

0 commit comments

Comments
 (0)