Skip to content

Commit 8c17212

Browse files
Relax type of alg in ensemble solve for optimization
1 parent 6b0a385 commit 8c17212

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/ensemble/basic_ensemble_solve.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,10 +57,10 @@ function __solve(prob::EnsembleProblem{<:AbstractVector{<:AbstractSciMLProblem}}
5757
end
5858

5959
function __solve(prob::AbstractEnsembleProblem,
60-
alg::Union{AbstractDEAlgorithm, Nothing},
60+
alg::A,
6161
ensemblealg::BasicEnsembleAlgorithm;
6262
trajectories, batch_size = trajectories,
63-
pmap_batch_size = batch_size ÷ 100 > 0 ? batch_size ÷ 100 : 1, kwargs...)
63+
pmap_batch_size = batch_size ÷ 100 > 0 ? batch_size ÷ 100 : 1, kwargs...) where {A}
6464
num_batches = trajectories ÷ batch_size
6565
num_batches < 1 &&
6666
error("trajectories ÷ batch_size cannot be less than 1, got $num_batches")

0 commit comments

Comments
 (0)