Try our new documentation site (beta).


SoftMemLimit

Soft memory limit
 Type: double
 Default value: Infinity
 Minimum value: 0
 Maximum value: Infinity

Limits the total amount of memory (in GB, i.e., <span>$</span>10^9<span>$</span> bytes) available to Gurobi. If more is needed, Gurobi will terminate with a MEM_LIMIT status code (see the Status Code section for further details).

In contrast to the MemLimit parameter, the SoftMemLimit parameter leads to a graceful exit of the optimization, such that it is possible to retrieve solution information afterwards or (in the case of a MIP solve) resume the optimization.

A disadvantage compared to MemLimit is that the SoftMemLimit is only checked at places where optimization can be terminated gracefully, so memory use may exceed the limit between these checks.

Note that allocated memory is tracked across all models within a Gurobi environment. If you create multiple models in one environment, these additional models will count towards overall memory consumption.

Memory usage is also tracked across all threads. One consequence of this is that termination may be non-deterministic for multi-threaded runs.

For examples of how to query or modify parameter values from our different APIs, refer to our Parameter Examples.

Try Gurobi for Free

Choose the evaluation license that fits you best, and start working with our Expert Team for technical guidance and support.

Evaluation License
Get a free, full-featured license of the Gurobi Optimizer to experience the performance, support, benchmarking and tuning services we provide as part of our product offering.
Academic License
Gurobi supports the teaching and use of optimization within academic institutions. We offer free, full-featured copies of Gurobi for use in class, and for research.
Cloud Trial

Request free trial hours, so you can see how quickly and easily a model can be solved on the cloud.

Search

Gurobi Optimization