Update matrices, vectors and rho all at once #639
Replies: 2 comments 2 replies
-
Right now, there isn't a way to update those as one, you need to do the update of the matrices followed by the rho value and they will each do a numerical factorization (note the vector update doesn't do a numerical refactorization). We can look into adding a merged operation that allows updating both the matrices and rho at once, it has just been that so far on one has asked for it. |
Beta Was this translation helpful? Give feedback.
-
I think the more useful use case here would be to allow for multiple (partial) data updates of the problem data so that a user could incrementally modify their problem, e.g. if it is naturally formed of blocks that can be individually reasoned about. We could add a data "staleness" type flag somewhere that is set every time there is such an update, and then only refactor right at the start of a new solve if the flag is set. This would then cover the case where rho and the problem data are updated in succession without getting multiple factorisations. |
Beta Was this translation helpful? Give feedback.
-
In the current API in the master branch, it seems like the matrices, vectors and rho can only be updated through separate function calls, (
osqp_update_data_mat
,osqp_update_data_vec
,osqp_update_rho
). Each of those function calls can trigger a new factorization separately, which can slowdown the solver for not much reason. Is there another interface that can update everything all at once and perform a single factorization ?Beta Was this translation helpful? Give feedback.
All reactions