mac-theobio / McMasterPandemic

SEIR+ model
GNU General Public License v3.0
20 stars 5 forks source link

c++ index misalignment occurs when updated time-variation adds new rates to the simulation history after convolutions and/or lagged differences have been specified #226

Closed stevencarlislewalker closed 2 years ago

stevencarlislewalker commented 2 years ago

Steps:

Actual result: c++ indices pointing to convolutions and/or lagged differences are misaligned, causing bad simulations and fits

Expected results: indices are appropriately updated when params_timevar is updated

Fix: added regen_sim_report_expr function, which is similar to regen_rates. The need for this fix is further evidence that the model definition steps involve too much processing of user input.

Discovered by @papsti on https://github.com/wzmli/ontario_tmb_condense

stevencarlislewalker commented 2 years ago

Fixed by https://github.com/mac-theobio/McMasterPandemic/commit/aa35dc942be9308eaa8c0daada9f78b46731fab9