You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If we remove the lines you mentioned, we could have some issues. For example, if someone warm starts x and not y, osqp would use an uninitialized variable for the first y (unless the osqp_solve function was called before. In that case it would use y from the previous solution). This might also be the desired behavior if we want the user to set only x or only y.
One alternative would be to cold start the variables x, y and z in the osqp_setup function. However, this is usually an unnecessary operation since it happens already in osqp_solve.
I was a bit surprised to discover that
osqp_warm_start_x
clears the dual warm start andosqp_warm_start_y
clears the primal warm start:https://github.com/oxfordcontrol/osqp/blob/370dd33622aa1fec1baae3881d7a5a56bf0ebb19/src/osqp.c#L899-L900
https://github.com/oxfordcontrol/osqp/blob/370dd33622aa1fec1baae3881d7a5a56bf0ebb19/src/osqp.c#L918-L920
This isn't documented, and it's natural to assume that these functions would just act like setters for the primal and dual warm starts.
The text was updated successfully, but these errors were encountered: