Adjoint ODE behaviour

Thanks.

We should definitely now start with a model which runs ok - but slow - with one of the existing forward solvers (bdf or rk45)… and then switch to adjoint.

Cool! Posterior outputs for the single-type SIR model with a time-varying effective contact rate (trapezoidal rule) are available. It’s slow, but it is indeed working nicely. Aiming to extend to a multi-type SIR, we take a step back and wish to examine the performance of the single-type SIR with the adjoint solver first. This implementation fails, with the errors reported earlier in this thread.

For now, I do think that the changes made in the branch are an improvement and I’d hope that @stevebronder finds the time to review them so that it is included in 2.28.1 for now. It seems we need to investigate further apparently.

… and this is great news! At this stage, I am trying to cross out possible reasons from my list as to why the single-type SIR model implementation with the adjoint solver fails. I.e. is it the solver itself that struggles for this model, etc. Or it might be the case that the route proposed by @Funko_Unko should be followed, see also the CoDatMo thread.