Automated approach to improving numerical stability
AnsweredHello,
I solve QCQPs in a statistical context. This means the coefficients in the QCQP problem are not known beforehand. Instead, they must be estimated.
I have been running into stability issues. Gurobi often returns suboptimal results or numerical errors. Following the Gurobi guidebook on numerical issues, I tried to automatically rescale the columns and rows of the linear constraint matrix in order to improve the range of magnitudes. However, this has only worsened the stability.
What I am looking for is an automated way to ensure good computational properties (automation is crucial since I do not know the coefficients beforehand). Is there anything you can suggest? I know this is a hard question, but any thoughts would be much appreciated.
Thanks so much.
Josh
0
-
I am glad you were able to find our Guidelines for Numerical Issues. This was put together because the most effective way to improve model numerics is through upfront reformulation. Because of this, our team keeps this guideline up to date with our latest scaling and reformulation tips.
While it is best to do upfront reformulation of your model to address numerical challenges, there are a few automated gems in Gurobi that may help QCQPs as a workaround:
- Adjust the degree to which Gurobi attempts to detect and manage numerical issues using the NumericFocus parameter.
- Adjust how Gurobi does its internal scaling using the ScaleFlag parameter. We find that for numerically challenging problems, a ScaleFlag of 2 may be effective. It sounds like this may be the most similar to the approach you are implementing.
- Turn off presolve aggregation by setting Aggregate to 0.
You can try each of these on their own, or see how various combinations of them work together. Remember, these parameters are only a workaround; the most reliable fix is to reformulate the model.
0
Please sign in to leave a comment.
Comments
1 comment