-
Notifications
You must be signed in to change notification settings - Fork 6
Description
For vectorized functions, the way we represent data (N.n_x ) with each line corresponding to an observation is not well suited to the computation we made given that arrays are F-ordered.
It would be good, if we could have the option of using the opposite convention and use input/output as (n_x . N) matrices (with the jacobian J: n_x.n_x.N without switching the two first dimensions).
Given the way the library is structured, this option could be provided at low cost, by introducing an option to the generated functions so that g(s,x,p,Forder) (resp g(s,x,p,Corder)) would assume the arguments are in the new (resp the old). It seems to me all that would be required would be to add this option to _unpack_var (and the generated functions). We could keep Corder as default, so as to not break everything (even better raise a warning if no order is given) and later change the convention.