Learning to Scale Mixed-Integer Programs

Learning to Scale Mixed-Integer Programs

The Thirty-Fifth AAAI Conference on Artificial Intelligence (AAAI-21) Learning To Scale Mixed-Integer Programs Timo Berthold, Gregor Hendel FICO Xpress Optimization, Fair Isaac Germany GmbH, Takustr. 7, 14195 Berlin, Germany timoberthold@fico.com, gregorhendel@fico.com Abstract tral changes in the model, like changing the order of con- straints, might lead to different optimal solutions being re- Many practical applications require the solution of numeri- ported (Lodi and Tramontani 2013). Since the two stan- cally challenging linear programs (LPs) and mixed integer dard methods to solve MIPs, namely LP-based branch-and- programs (MIPs). Scaling is a widely used preconditioning technique that aims at reducing the error propagation of the bound and cutting plane algorithms, both rely heavily on the involved linear systems, thereby improving the numerical be- dual simplex algorithm as a subroutine, they directly inherit havior of the dual simplex algorithm and, consequently, LP- its numerical properties and issues. To make things worse, based branch-and-bound. A reliable scaling method often tableau-based cuts like Gomory cuts (Gomory 1958) can makes the difference whether these problems can be solved amplify numerical issues, unless these cuts are carefully fil- correctly or not. In this paper, we investigate the use of ma- tered and selected (Balas et al. 1996). chine learning to choose at the beginning of the solution pro- Obviously, cycling, residual errors and other numerical cess between two common scaling methods: Standard scal- problems are undesirable and various methods exist to mit- ing and Curtis-Reid scaling. The latter often, but not always, igate them, see, e.g., Gleixner, Steffy, and Wolter (2016), leads to a more robust solution process, but may suffer from Cheung, Gleixner, and Steffy (2017), or Espinoza (2006). longer solution times. One of the earliest and to date still most effective way to pre- Rather than training for overall solution time, we propose to vent numerical issues from occuring in LP and MIP solvers use the attention level of a MIP solution process as a learning label. We evaluate the predictive power of a random forest is the use of various scaling algorithms. Scaling methods approach and a linear regressor that learns the (square-root of for linear programming have first been suggested in the the) difference in attention level. It turns out that the result- early 1960’s (Fulkerson and Wolfe 1962). In 1972, Curtis ing classification not only reduces various types of numerical and Reid introduced a scaling algorithm that solves a least- errors by large margins, but it also improves the performance squares problem, which effectively minimizes the sum of the of the dual simplex algorithm. squares of the logarithms of the matrix elements, plus some The learned model has been implemented within the FICO correction terms (Curtis and Reid 1972). Xpress MIP solver and it is used by default since release 8.9, Various different scaling algorithms have been suggested, May 2020, to determine the scaling algorithm Xpress applies each of them beneficial for some classes of instances. How- before solving an LP or a MIP. ever, it is not clear a priori which scaling algorithm is best- suited for a given LP or MIP instance. To this end, we sug- Introduction gest a method to predict which of two of the most common scaling methods will lead to a numerically more robust so- Numerics play an important role in solving linear and mixed lution process. integer programs (LPs and MIPs) (Miltenberger, Ralphs, In this paper, we consider general mixed integer programs and Steffy 2018). All major solvers for LPs and MIPs rely (MIPs) of the form on floating-point arithmetic, hence numerical round-off er- T Z rors and cancellation effects might occur and therefrom, nu- minfc x j Ax ≥ b; ` ≤ x ≤ u; xj 2 8j 2 Ig; (1) merical errors might propagate. This affects the solution with objective coefficient vector c 2 Qn, constraint coeffi- process in various critical ways: first of all, the dual sim- cient matrix A 2 Qm×n, constraint right-hand side b 2 Qm, plex algorithm might be more prone to cycling, leading Qn Q Q to a longer runtime or even an unsuccessful termination. and variable bounds `; u 2 , where := [ {∞}. Furthermore, the set I ⊆ f1; : : : ; ng denotes the indices of The computed optimal solution vectors might have resid- ? ual errors larger than acceptable and consequently, the so- variables that are required to take integer values. If I = , lution might be deemed wrong. In a worst case, instances (1) is called a linear program (LP). By omitting the inte- might be declared infeasible by mistake or seemingly neu- grality requirements for a given MIP, we obtain its LP relax- ation. Copyright © 2021, Association for the Advancement of Artificial We address the solution of LPs and MIPs by a general Intelligence (www.aaai.org). All rights reserved. purpose solver, in our case FICO Xpress (FICO). Recently, 3661 the use of Machine Learning methods to take criticial deci- least squares problem sions within MIP solvers gained a lot of interest. Examples m n X X 2 include learning when to run primal heuristics (Khalil et al. min (log2jAij j − ri − qj) (2) 2017), the addition of new cutting planes (Tang, Agrawal, i=1 j=1 and Faenza 2019) or one of the most challenging tasks bri+0:5c in MIP solving, choosing a variable to branch on (Khalil Then, CR scales the matrix by Rii = 2 and Cjj = bq +0:5c et al. 2016; Balcan et al. 2018). For an overview, see Ben- 2 j . The rationale is that this method takes all ele- gio, Lodi, and Prouvost (2018). However, to the best of our ments into account and not only extreme ones. Generally, knowledge, no publication so far considered learning scaling CR is known to work best on numerically challenging prob- methods or other features addressing the numerical stability lems and is consequently by far the most commonly used of a solve. As an important observation, Tang, Agrawal, and non-default scaling technique within FICO Xpress. How- Faenza (2019) pointed out that learning methods that solely ever, always using CR comes at the price of a slight slow- minimize running time might tend to prefer a less stable al- down of 2–3% on average, according to our computational ternative, given that solvers often terminate faster when they study. Therefore it is not enabled by default. produce a wrong result due to numerical errors. Other approaches have been suggested, with no clear ev- The contribution of this paper is to introduce machine idence that any of them is superior (Larsson 1993; Ploskas learning models to choose between different scalings dur- and Samaras 2013). Up to the experience of the authors, it is ing the runtime of an LP or MIP solve. This is not a proof rare that another method significantly outperforms the better of concept; the technique has been implemented within the of ST and CR. The next common scaling options to make a state-of-the-art MIP solver FICO Xpress and is used by de- difference are to apply scaling before presolving instead of fault in its latest release. To this end, we use the attention after presolving and the question of whether to use dedicated level as a learning label when using ML to take decisions for special rules for so-called big-M constraints. This, however, a mathematical optimization process. The attention level is a is beyond the scope of the present paper. measure between 0 and 1 that aims at estimating how likely Scaling has different goals. Its main purpose is to im- numerical errors are to occur during an LP or MIP solve; for prove the numerical behavior of the solver; a secondary more details see next section. While numerical robustness goal is to improve the runtime of the simplex algorithm. In of an algorithm represents a valuable goal of its own, this fact, the observed runtime improvements mostly are a direct avoids getting the learning process flawed by wrong results. consequence of the improved numerical stability. However, Moreover, we demonstrate that this can still lead to a signif- runtime improvements might be counteracted by the afore- icant speed improvement, at least for LPs, which is mainly mentioned effect that producing wrong results due to a nu- due to the fact that the solver can save on costly recovering merical error might lead to faster termination. Hence, run- procedures. time improvements from scaling might not be as pronounced as improvements in the stability. There are various ways to measure the numerical stability Background: Scaling, Attention Level of an LP or MIP solve. One way is to directly observe the Formally, scaling refers to the multiplication of each row actual number of failures when solving a problem. There are and column in a linear system Ax ≥ b by a non-negative three main types of failures that FICO Xpress tracks for the scalar, hence transforming the system to an equivalent sys- simplex algorithm: dual failures, primal failures and singu- ∗ ∗ −1 Qm×m tem RACx ≥ Rb, x = C x, with R 2 ≥0 ;C 2 lar inverts. Note that during a MIP solve, LPs are typically Qn×n solved via dual simplex, since this allows for warm-starting ≥0 , with C; R being diagonal matrices, i.e., Cij = 0 and after adding cuts or branching restrictions (Tomlin 1971). In- Rij = 0 for i 6= j. In other words, the diagonals of R and C contain the scaling factors for the rows and columns, respec- terior point algorithms, the most common alternative to the tively. Note that for a MIP, integer columns are not scaled, simplex method, are are not considered in the present work as they are invariant to scaling (Andersen et al.

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    8 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us