Skip to content

Commit

Permalink
Update cost_functions.jl
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisRackauckas authored Jul 21, 2022
1 parent d999522 commit ff5e092
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/cost_functions.jl
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ function (f::L2Loss)(sol::DiffEqBase.AbstractNoTimeSolution)
sumsq
end

function (f::L2Loss)(sol::DiffEqBase.AbstractDESolution)
function (f::L2Loss)(sol::DiffEqBase.AbstractSciMLSolution)
data = f.data
weight = f.data_weight
diff_weight = f.differ_weight
Expand Down Expand Up @@ -168,7 +168,7 @@ function LogLikeLoss(t, data_distributions, diff_distributions)
LogLikeLoss(t, matrixize(data_distributions), matrixize(diff_distributions), 1)
end

function (f::LogLikeLoss)(sol::SciMLBase.AbstractDESolution)
function (f::LogLikeLoss)(sol::SciMLBase.AbstractSciMLSolution)
distributions = f.data_distributions
if sol isa DiffEqBase.AbstractEnsembleSolution
failure = any(s.retcode !== :Success && s.retcode !== :Terminated for s in sol)
Expand Down

0 comments on commit ff5e092

Please sign in to comment.