Skip to content

Commit

Permalink
Merge pull request #460 from sathvikbhagavan/sb/cleanup
Browse files Browse the repository at this point in the history
Few cleanups related to julia version, compats and tests of SurrogatesMOE
  • Loading branch information
ChrisRackauckas authored Dec 29, 2023
2 parents 1cff140 + 4320779 commit 25d95f1
Show file tree
Hide file tree
Showing 9 changed files with 18 additions and 17 deletions.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ Aqua = "0.8"
Cubature = "1.5"
Distributions = "0.25.71"
ExtendableSparse = "1"
Flux = "0.13"
Flux = "0.14"
ForwardDiff = "0.10.19"
GLM = "1.5"
IterativeSolvers = "0.9"
Expand Down
4 changes: 2 additions & 2 deletions lib/SurrogatesAbstractGPs/Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ Surrogates = "6fc51010-71bc-11e9-0e15-a3fcc6593c49"

[compat]
AbstractGPs = "0.5"
Surrogates = "6.0"
julia = "1.6"
Surrogates = "6"
julia = "1.10"

[extras]
SafeTestsets = "1bc83da4-3b8d-516f-aca4-4fe02f6d838f"
Expand Down
6 changes: 3 additions & 3 deletions lib/SurrogatesFlux/Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ Flux = "587475ba-b771-5e3f-ad9e-33799f191a9c"
Surrogates = "6fc51010-71bc-11e9-0e15-a3fcc6593c49"

[compat]
Flux = "0.13, 0.14"
Surrogates = "6.0.0"
julia = "1.6"
Flux = "0.14"
Surrogates = "6"
julia = "1.10"

[extras]
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
Expand Down
8 changes: 4 additions & 4 deletions lib/SurrogatesMOE/Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,27 +8,27 @@ Distributions = "31c24e10-a181-5473-b8eb-7969acd0382f"
GaussianMixtures = "cc18c42c-b769-54ff-9e2a-b28141a64aae"
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
Surrogates = "6fc51010-71bc-11e9-0e15-a3fcc6593c49"
SurrogatesFlux = "4f55584b-dac4-4b1c-802a-b7c47b72cb4c"
SurrogatesPolyChaos = "50679fc6-c85c-4a6e-ac63-dc3c8bd8cb1c"
SurrogatesRandomForest = "3fee2672-df33-422b-aa65-d915eeac013a"
Surrogates = "6fc51010-71bc-11e9-0e15-a3fcc6593c49"
XGBoost = "009559a3-9522-5dbb-924b-0b6ed2b22bb9"

[compat]
Distributions = "0.25.71"
GaussianMixtures = "0.3.6"
julia = "1.6"
Surrogates = "6.0"
Surrogates = "6"
SurrogatesFlux = "0.1.0"
SurrogatesPolyChaos = "0.1.0"
SurrogatesRandomForest = "0.1.0"
XGBoost = "2"
julia = "1.10"

[extras]
Flux = "587475ba-b771-5e3f-ad9e-33799f191a9c"
SafeTestsets = "1bc83da4-3b8d-516f-aca4-4fe02f6d838f"
StableRNGs = "860ef19b-820b-49d6-a774-d7a799459cd3"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
SafeTestsets = "1bc83da4-3b8d-516f-aca4-4fe02f6d838f"

[targets]
test = ["Flux", "Test", "SafeTestsets", "StableRNGs"]
4 changes: 2 additions & 2 deletions lib/SurrogatesMOE/test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ end
lb = [-1.0, -1.0]
ub = [1.0, 1.0]
n = 120
x = sample(n, lb, ub, RandomSample())
x = sample(n, lb, ub, LatinHypercubeSample())
y = discont_NDIM.(x)
x_test = sample(10, lb, ub, GoldenSample())

Expand Down Expand Up @@ -184,7 +184,7 @@ end
lb = [-1.0, -1.0]
ub = [1.0, 1.0]
n = 110
x = sample(n, lb, ub, RandomSample())
x = sample(n, lb, ub, LatinHypercubeSample())
y = discont_NDIM.(x)
expert_types = [InverseDistanceStructure(p = 1.0),
RadialBasisStructure(radial_function = linearRadial(), scale_factor = 1.0,
Expand Down
4 changes: 2 additions & 2 deletions lib/SurrogatesPolyChaos/Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ Surrogates = "6fc51010-71bc-11e9-0e15-a3fcc6593c49"

[compat]
PolyChaos = "0.2"
Surrogates = "6.0"
julia = "1.6"
Surrogates = "6"
julia = "1.10"

[extras]
SafeTestsets = "1bc83da4-3b8d-516f-aca4-4fe02f6d838f"
Expand Down
2 changes: 1 addition & 1 deletion lib/SurrogatesRandomForest/Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ XGBoost = "009559a3-9522-5dbb-924b-0b6ed2b22bb9"
[compat]
Surrogates = "6"
XGBoost = "2"
julia = "1.6"
julia = "1.10"

[extras]
SafeTestsets = "1bc83da4-3b8d-516f-aca4-4fe02f6d838f"
Expand Down
2 changes: 1 addition & 1 deletion lib/SurrogatesSVM/Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Surrogates = "6fc51010-71bc-11e9-0e15-a3fcc6593c49"
[compat]
LIBSVM = "0.8"
Surrogates = "6"
julia = "1.6"
julia = "1.10"

[extras]
SafeTestsets = "1bc83da4-3b8d-516f-aca4-4fe02f6d838f"
Expand Down
3 changes: 2 additions & 1 deletion src/Optimization.jl
Original file line number Diff line number Diff line change
Expand Up @@ -2045,7 +2045,8 @@ function surrogate_optimize(obj, rtea::RTEA, lb, ub, surrRTEAND::AbstractSurroga
return pareto_set, pareto_front
end

function surrogate_optimize(obj::Function, ::EI, lb::AbstractArray, ub::AbstractArray, krig, sample_type::SectionSample;
function surrogate_optimize(obj::Function, ::EI, lb::AbstractArray, ub::AbstractArray, krig,
sample_type::SectionSample;
maxiters = 100, num_new_samples = 100)
dtol = 1e-3 * norm(ub - lb)
eps = 0.01
Expand Down

0 comments on commit 25d95f1

Please sign in to comment.