Providing an initial feasible solution to Gurobi can help reduce the overall solve time (but there is no guarantee). A MIP start can be provided either by using the Start variable attribute or by loading a MIP start (.mst) or a solution (.sol) file.

It is possible to define only values for (a subset of) the binary and integer variables and let Gurobi attempt to compute feasible values for the remaining variables. This can be useful if a full start vector violates constraints by a small amount and is thus not accepted.

A related option is Variable hints. These values guide the solver throughout the solution process. If you know that a variable is likely to have a certain value in the solution, you can set the variable hint to help Gurobi find a solution.

## Using Multiple MIP Starts

It is possible to provide multiple feasible starting solutions to Gurobi. This can be done either through our APIs or from our command-line tool.

From the APIs, you can supply multiple MIP Starts using the NumStart attribute and StartNumber parameter. For example, in our Python API, this could be achieved as follows:

model.NumStart = 2

# iterate over all MIP starts

for s in range(model.NumStart):

# set StartNumber

model.params.StartNumber = s

# now set MIP start values using the Start attribute, e.g.:

for v in model.getVars():

v.Start = <value>

When using our command-line tool, *gurobi_cl*, you can use the *InputFile *argument multiple times, e.g.,

gurobi_cl InputFile=mipstart1.mst InputFile=mipstart2.mst model.mps

With both approaches, Gurobi will investigate all supplied MIP starts and use the best one.

## Completing Partial MIP Starts

The StartNodeLimit parameter can be used to control the number of branch-and-bound nodes explored when trying to complete a partial MIP start. By default, it will use the same number as SubMIPNodes.