the gurobi optimizerpython programs are typically stored in text files with .py extension ! most...

Post on 12-Jun-2020

10 Views

Category:

Documents

0 Downloads

Preview:

Click to see full reader

TRANSCRIPT

The Gurobi Optimizer

© 2015 Gurobi Optimization 2

Agenda

}  3:00-3:10 Introduction - Bob Bixby }  3:10-3:25 What's New in Gurobi 6.5 - Bob Bixby

}  3:25-4:00 Modeling with the Gurobi Python Interface - Renan Garcia }  4:00-4:15 Reformulation and Cutting Planes for MIQCP - Chris Maes

}  4:15-4:30 Break

}  4:30-5:00 Gurobi Instant Cloud - Chris Maes }  5:00-5:30 Benchmarks and Roadmap - Bob Bixby

© 2015 Gurobi Optimization 3

}  Gurobi Optimization, founded July 2008 }  Zonghao Gu, Ed Rothberg, Bob Bixby

}  Gurobi Version 1.0 released May 2009

}  History of continuing, significant innovations }  Free academic licenses }  First cloud offering }  Compute server for client-server applications }  Distributed algorithms

}  History of rapid, significant performance improvements }  Close to 2x average speedup year-over-year

Gurobi History

© 2015 Gurobi Optimization 4

Over 1,200 companies have made Gurobi their

solver of choice

© 2015 Gurobi Optimization 5

Why Companies Choose Gurobi

The most experienced development team focused 100% on delivering the best solver and user experience Performance Leader

End-to-End Offering Powerful modeling and development environments, flexible deployment options

Outstanding Support Direct access to PhD-level optimization experts for fast answers to your questions

No surprises Flexible licensing and transparent pricing to meet a full range of business situations

© 2015 Gurobi Optimization 6

}  Gurobi Solvers ◦  Mixed-Integer Programming (MIP, MIQP, MIQCP)

�  Deterministic, parallel

◦  Linear and Quadratic Programming �  Dual and primal simplex; Parallel Barrier

◦  Second-Order Cone Programming �  Parallel Barrier

}  APIs ◦  C, C++, Java, .NET, Python programming interfaces ◦  Simple command-line interface ◦  Python interactive interface ◦  Python modeling interface ◦  Gurobi Compute Server ◦  R and MATLAB matrix interfaces ◦  All standard modeling languages ◦  A variety of free-software projects

}  Commercial and Academic Licenses ◦  Licensing options and pricing available at www.gurobi.com

}  Cloud offering ◦  Amazon EC2 and our own Instant Cloud

}  Distributed Optimization offering

Gurobi Products Overview

© 2015 Gurobi Optimization 7

Very Strong Academic Offering

}  Free Named-user academic licenses ◦  Full-featured university version of Gurobi that can be installed on a single physical

machine.

}  Free multi-user academic site licenses ◦  Full-featured university version that can be installed on a university’s local-area

network.

}  Take Gurobi with You program ◦  First year free, including free support, for qualified recent graduates

© 2015 Gurobi Optimization 8

What's New in Gurobi 6.5

© 2015 Gurobi Optimization 9

Gurobi 6.5 Enhancements

}  Performance improvements }  Gurobi Instant Cloud

}  Variable hints }  API recorder and replay

© 2015 Gurobi Optimization 10

Gurobi 6.5 Enhancements -- Other

}  Python modeling ◦  Significant improvement in performance of expression building ◦  Ability to release Gurobi resources when you are done with a model

}  APIs ◦  IIS support in MATLAB ◦  R interface extensions

}  Licensing ◦  Password protection for token servers ◦  Single-use licenses without token server ◦  New command to provide location of current license file

}  Distributed ◦  Distributed MIP logging

}  Platforms ◦  Support for clang++ on Mac (libc++) ◦  Support for Visual Studio 2015 ◦  Compute Server encryption routines moved to a separate library

}  Other ◦  UpdateMode parameter ◦  BarX attribute to query the best barrier iterate ◦  OPB file format reader

© 2015 Gurobi Optimization 11

Variable Hints

}  Provide hints to the solver about which variable should take which value

}  Guides heuristics and branching }  VarHintVal attribute: ◦  Specifies value for variable

}  VarHintPri attribute: ◦  Specifies level of confidence in this particular variable value

}  Comparison to MIP starts: ◦  MIP start is used to provide an initial feasible solution to the solver

�  Is evaluated prior to starting the solution process �  Provides incumbent if feasible �  Does not influence solution process if it is not feasible

◦  Variable Hints guide the search �  High quality hints should lead to a high quality solution quickly

�  Either through heuristics or through branching �  Affects the whole solution process

© 2015 Gurobi Optimization 12

API Recorder

}  Setting Record parameter to 1 will produce recording000.grbr file ◦  Tracks all Gurobi API calls

}  Use gurobi_cl recording000.grbr to replay file ◦  Replay Gurobi execution independently from your own application

}  Use cases: ◦  Debug performance issues

�  Measures time spent in API calls (e.g., model building) and algorithms (solving) ◦  Identify cases where your program leaks Gurobi models or environments

�  Lists number of models and environments that were never freed by your program ◦  Relay exact sequence of commands your program issues to Gurobi

technical support in case you run into a question or issue that is difficult to reproduce �  Just send recording file, instead of having to send the whole application

Modeling with the Python Modeling Interface

© 2015 Gurobi Optimization 14

Goals for this tutorial

}  Understand the basics of modeling with the Gurobi Python Interface

}  Introduce new Python-related features added in version 6.5

}  Review detailed examples that highlight best modeling practices

}  Explore additional Python packages designed to increase productivity

© 2015 Gurobi Optimization 15

Example: LP model

A linear program (LP) is an optimization problem of the form

cj ⋅ x jj∈J∑

aij ⋅ x jj∈J∑ = bi ∀i ∈ I

l j ≤ x j ≤ uj ∀j ∈ J

minimize

subject to

© 2015 Gurobi Optimization 16

cj ⋅ x jj∈J∑

aij ⋅ x jj∈J∑ = bi ∀i ∈ I

l j ≤ x j ≤ uj ∀j ∈ J

minimize

subject to

LP model elements

Decision variables

© 2015 Gurobi Optimization 17

cj ⋅ x jj∈J∑

aij ⋅ x jj∈J∑ = bi ∀i ∈ I

l j ≤ x j ≤ uj ∀j ∈ J

minimize

subject to

LP model elements

Objective function

© 2015 Gurobi Optimization 18

cj ⋅ x jj∈J∑

aij ⋅ x jj∈J∑ = bi ∀i ∈ I

l j ≤ x j ≤ uj ∀j ∈ J

minimize

subject to

LP model elements

Constraints

© 2015 Gurobi Optimization 19

cj ⋅ x jj∈J∑

aij ⋅ x jj∈J∑ = bi ∀i ∈ I

l j ≤ x j ≤ uj ∀j ∈ J

minimize

subject to

LP model elements

Data coefficients

© 2015 Gurobi Optimization 20

cj ⋅ x jj∈J∑

aij ⋅ x jj∈J∑ = bi ∀i ∈ I

l j ≤ x j ≤ uj ∀j ∈ J

minimize

subject to

LP model elements

Index sets

© 2015 Gurobi Optimization 21

cj ⋅ x jj∈J∑

aij ⋅ x jj∈J∑ = bi ∀i ∈ I

l j ≤ x j ≤ uj ∀j ∈ J

minimize

subject to

LP model elements

Subscripts

© 2015 Gurobi Optimization 22

cj ⋅ x jj∈J∑

aij ⋅ x jj∈J∑ = bi ∀i ∈ I

l j ≤ x j ≤ uj ∀j ∈ J

minimize

subject to

LP model elements

Arithmetic operators

© 2015 Gurobi Optimization 23

cj ⋅ x jj∈J∑

aij ⋅ x jj∈J∑ = bi ∀i ∈ I

l j ≤ x j ≤ uj ∀j ∈ J

minimize

subject to

LP model elements

Constraint operators

© 2015 Gurobi Optimization 24

cj ⋅ x jj∈J∑

aij ⋅ x jj∈J∑ = bi ∀i ∈ I

l j ≤ x j ≤ uj ∀j ∈ J

minimize

subject to

LP model elements

For-all operators

© 2015 Gurobi Optimization 25

cj ⋅ x jj∈J∑

aij ⋅ x jj∈J∑ = bi ∀i ∈ I

l j ≤ x j ≤ uj ∀j ∈ J

minimize

subject to

LP model elements

Aggregate sum operators

© 2015 Gurobi Optimization 26

General optimization modeling constructs

}  Decision variables }  Objective function }  Constraints

}  Built with: ◦  Coefficients ◦  Indices and subscripts ◦  Operators

�  Basic arithmetic (+, -, ×, ÷) �  Constraint (≤, =, ≥) �  For-all �  Aggregate sum

© 2015 Gurobi Optimization 27

Building optimization models with Gurobi

}  Option 1 – use a modeling language ◦  Very easy to build models

�  Optimization modeling constructs built into language ◦  Attractive choice for non-programmers ◦  Alternatives: AMPL, GAMS, Pyomo, …

}  Option 2 – use a full programming language ◦  Much more powerful and flexible development environment

�  Complete access to solver functionality �  Richer set of language features

◦  Natural choice when deploying models and/or integrating them into applications for others to use

◦  Alternatives: C, C++, C#, Java, MATLAB, Python, R, VB

}  But what if users didn't have to choose between easy and powerful?

© 2015 Gurobi Optimization 28

Gurobi Python Environment

}  High-level optimization modeling constructs embedded in Python programming language ◦  Combines expressiveness of a modeling language with the power and

flexibility of a programming language

}  Design goals: ◦  Require minimal programming skills to get started ◦  Bring "feel" of a modeling language to the Python interface ◦  Allow for code that is easy to write and maintain ◦  Maintain unified design across all of our interfaces ◦  Remain lightweight and efficient (memory & CPU) when compared with

solver alone ◦  Support all solver and programming needs

}  Consistently earns high praise from our users

© 2015 Gurobi Optimization 29

Why Python?

}  Fast, powerful and easy-to-use

}  Extendible with vast library of prewritten modules (over 50,000) ◦  Statistical analysis, visualization, GUIs, web development, web services,

data connections, file compression, data encryption, …

}  One of top-10 most popular programming languages, according to TIOBE Programming Community Index ◦  http://www.tiobe.com/index.php/content/paperinfo/tpci/index.html ◦  Large and rapidly growing Python community with great training resources

}  Interactive shell is useful for prototyping

}  Can be deployed to create full-featured optimization applications ◦  GUI, server, web, …

}  Free and open source with license that's business-friendly

© 2015 Gurobi Optimization 30

Getting started with Python

}  Don't need to be an expert to start modeling in Python

}  Nothing extra to buy or install ◦  Gurobi distribution includes Python interpreter and basic modules

}  Gurobi Interactive Shell is Python shell with Gurobi extensions ◦  Powerful environment for interacting with existing models

}  To launch the shell: ◦  Windows

�  Double-click the Gurobi icon on the desktop �  Or run gurobi from a Command Prompt window

◦  Linux �  Run the gurobi.sh command from a terminal

◦  Mac �  Click on the Gurobi icon in the Launchpad �  Or run the gurobi.sh command from a terminal

© 2015 Gurobi Optimization 31

Programming in Python

}  Python is a cross-platform, high-level programming language ◦  Object-oriented ◦  Interpreted ◦  Dynamically typed ◦  Automatic memory management ◦  Includes a large standard library ◦  Documentation tightly integrated with the code

}  Python programs are typically stored in text files with .py extension

}  Most functionality in Python is provided by modules ◦  To use a module in Python programs, include an import statement

}  To use the Gurobi interface, import the gurobipy module: from gurobipy import *

© 2015 Gurobi Optimization 32

Editing and running Python programs

}  Any text editor can be used to work with .py files ◦  Most programming editors have Python mode with syntax highlighting,

etc.

}  To run a program: ◦  Windows

�  At a Command Prompt window, enter gurobi [program_name]

◦  Linux/Mac �  At a terminal, enter

gurobi.sh [program_name]

}  Many IDEs available ◦  https://wiki.python.org/moin/IntegratedDevelopmentEnvironments ◦  Easy to install Gurobi in other Python distributions

© 2015 Gurobi Optimization 33

Essential Gurobi modeling constructs

}  Model a model }  Var a decision variable }  Constr a constraint

}  Overloaded operators ◦  Basic arithmetic (+, -, ×, ÷) ◦  Constraint (≤, =, ≥)

}  Aggregate sum operator (quicksum)

}  Python provides the rest!

© 2015 Gurobi Optimization 34

Typical steps for building a model

}  Create empty Model object with Model() constructor

}  Add variables with Model.addVar()

}  Call Model.update() once to process pending model updates ◦  Gurobi provides efficient "lazy updates" ◦  Only call Model.update() when necessary to reference new elements

}  Call Model.setObjective() to set objective function

}  Add constraints with Model.addConstr()

}  Solve the model with Model.optimize()◦  Will process any pending model updates

© 2015 Gurobi Optimization 35

Example: simple model

# Create empty Model

m = Model()

# Add variables

x = m.addVar(vtype=GRB.BINARY)

y = m.addVar(vtype=GRB.BINARY)

z = m.addVar(vtype=GRB.BINARY)

# Process pending updates

m.update()

© 2015 Gurobi Optimization 36

Example: simple model

# Set objective function

m.setObjective(x + y + 2*z, GRB.MAXIMIZE)

# Add constraints

m.addConstr(x + 2*y + 3*z <= 4)

m.addConstr(x + y >= 1)

# Solve model

m.optimize()

© 2015 Gurobi Optimization 37

Indices and subscripts in Python

}  List is a mutable sequence of elements ◦  Useful when representing index sets ◦  Elements of any type (integers, strings, …) indexed by integers (0 to n-1) ◦  Ex: cities=['CHI', 'NYC', 'ATL']; cities.append('MIA'); cities[2]='BOS'; cities.remove('NYC'); cities.sort()

}  Tuple is an immutable, compound grouping of elements ◦  Ideal for representing multidimensional subscripts ◦  Ex: arc=('CHI','NYC'); j=arc[1]

}  Dictionary is a mutable mapping from keys to values ◦  Useful when representing coefficients or variables indexed by subscripts ◦  Keys must be immutable (integers, strings, tuples, …) ◦  Ex: cost={('CHI','NYC'):100, ('ATL','MIA'):150}; cost[('NYC','MIA')]=200; c=cost['ATL','MIA']

© 2015 Gurobi Optimization 38

Iterating in Python and aggregate sums }  Loops iterate over collections of elements (list, dictionary, …) ◦  Useful when representing the for-all modeling construct ◦  Ex: for c in cities:

print c # must indent all statements in loop

}  List comprehension efficiently builds lists via set notation ◦  Ex: penaltyarcs=[a for a in arcs if cost[a]>1000]

}  quicksum() is direct replacement for Python's sum() function ◦  Gurobi feature that is more efficient when working with Var objects ◦  Ex: obj=quicksum(cost[a]*x[a] for a in arcs)

}  Combining loops with sums is ideal when building constraints Ex: can be built with for i in I: m.addConstr(quicksum(x[i,j] for j in J) <= 5)

xijj∈J∑ ≤ 5,∀i ∈ I

© 2015 Gurobi Optimization 39

Interactive Examples

© 2015 Gurobi Optimization 40

Latest Python-related enhancements in v6.5

}  Interactive examples for commonly faced business problems ◦  http://www.gurobi.com/resources/examples/example-models-overview

}  Expression building is more than 4X faster

}  Lazy update mode ◦  Set new UpdateMode parameter to 1 ◦  Refer to new variables and constraints without calling Model.update()

}  More control over when Gurobi environments are created/released ◦  Default environment not created until first used ◦  Released with new disposeDefaultEnv() method

}  New Conda package simplifies installation for the Anaconda Python distribution $ conda config --add channels http://conda.anaconda.org/gurobi$ conda install gurobi

© 2015 Gurobi Optimization 41

Jupyter Demo

© 2015 Gurobi Optimization 42

References

}  Visit http://www.gurobi.com/documentation/ for more information on the Gurobi Python Interface ◦  Quick Start Guide ◦  Reference Manual

}  Explore our functional code examples to learn more about advanced features ◦  Working with sparse models: netflow, workforce ◦  Accessing data sources (databases, spreadsheets, …): diet

}  Visit https://docs.python.org/ learn more about Python ◦  Official Python website ◦  Tutorials, documentation, examples, …

}  Visit https://www.continuum.io to get started with the Anaconda Python distribution, which includes iPython and Jupyter

Reformulation and Cutting Planes for MIQCP

© 2015 Gurobi Optimization 44

MIQCP/MISOCP Improvements

}  6.5 has many performance improvements in MIQCP/MISOCP }  We will cover some of the ideas behind these improvements ◦  Stay tuned for performance benchmarks

}  Reformulation ◦  Cone disaggregation ◦  Cone strengthening ◦  Other presolve improvements

}  Cutting planes ◦  Use of integer variables information to strengthen cone cuts ◦  Better control of cone cuts

}  General MIP improvements ◦  Changing tie-breaking threshold in branching

© 2015 Gurobi Optimization 45

Cone Disaggregation

}  Reformulation ◦  Replace the large cone x1

2 + x22 + … + xn

2 ≤ y2 (1) y ≥ 0 with xi

2 ≤ ziy, i = 1, 2, …, n (2) n rotated cones z1 + z2 + … + zn ≤ y (3) 1 linear constraint y ≥ 0, z1, z2, …, zn ≥ 0 n new variables

}  Proof of valid reformulation ◦  Constraints (2) + (3) => (1) ◦  Solution to (1) => solution to (2) and (3) by setting

zi = xi2 / y , if y > 0

= 0, if y = 0

}  See Vielma, Dunning, Huchette, Lubin (2015) on Extended Formulations

© 2015 Gurobi Optimization 46

Cone Disaggregation

}  Objective gap between LP with cone cuts and SOCP ◦  Disaggregation speeds up gap closing on our internal MISOCP set ◦  Disaggregation should see same improvement on continuous

SOCP models �  But slower gap closing on our internal SOCP set

}  Cone constraint violations ◦  All solvers must have tolerances for constraint violations ◦  Gurobi’s default feasibility tolerance is 10-6

}  Suppose we have small violations on the disagg. cones ◦  xi

2 = y zi + e, i=1, …, n with z1 + z2 + … + zn = y ◦  Then x1

2 + x22 + … + xn

2 ≤ y2 + ne ◦  Violation on original cone is n times the violation of disagg. cones ◦  Using appropriate scaling is important

© 2015 Gurobi Optimization 47

Cone Strengthening

}  Consider the following x2 ≤ y (1) y ≤ u*z (2) x, y ≥ 0 and continuous z binary variable

}  Strengthening x2 ≤ y*z (3)

}  Proof of valid reformulation ◦  If z = 1, y*z = y ◦  If z = 0, (2) => y = 0, so y*z = 0 = y

}  Observe in a fractional solution: y*z ≤ y, since z ≤ 1 }  Cuts off fractional solution (x, y, z) = (1, 1, 0.5) with u = 2

}  See Günlük and Linderoth (2011) on Perspective Reformulations

© 2015 Gurobi Optimization 48

Cone Cut Strengthening }  Consider the following

x2 ≤ y y is a general integer LP relaxation solution (x, y) = (0.5, 0)

}  Cone cut ◦  Increase y to satisfy x2 = y, we get (x’, y’) = (0.5, 0.25) ◦  Cone cut: 2 x’ (x – x’) ≤ y – y’, x – y ≤ 0.25 (1)

}  Strengthened cone cut ◦  Let y = floor(0.25) = 0 and y = ceil(0.25) = 1 ◦  Using x2 = y, we get two points: (0, 0) and (1, 1) ◦  The line passing the two points defines the strengthened cut x – y ≤ 0 (2) ◦  (2) is clearly stronger than (1)

© 2015 Gurobi Optimization 49

Other Improvements

}  Extended more presolve reductions to MISOCP ◦  Now perform more aggregations on quadratic variables

}  Better control of cone cuts ◦  When many conic constraints are violated, which cone cuts should

be added?

}  General MIP improvements ◦  Changing tie-breaking threshold in branching

© 2015 Gurobi Optimization 50

Computation

}  Internal MISOCP sets ◦  323 models, time limit 10000s, Xeon E3-1240 ◦  >1s, 190 models, 2.78X vs 6.0 ◦  >100s, 86 models, 6.49X

}  Where does the performance come from (internal set) ◦  Cone disaggregation ◦  Cone strengthening and other presolve reductions ◦  Cone cuts ◦  MIP improvements, e.g. changing branching threshold

}  Mittelmann MISOCP (45 models) ◦  CPLEX: 1.9X ◦  XPRESS: 5.28X ◦  MOSEK: 19.7X

Gurobi Instant Cloud

© 2015 Gurobi Optimization 52

Gurobi: Leader in Optimization on the Cloud

}  First with enterprise-grade optimization on the cloud ◦  Over 5 years of experience with optimization on the cloud

}  Moving to the cloud requires no changes in your code ◦  Full Gurobi API, with all Gurobi supported languages & platforms

}  Introducing the next step in the Gurobi Cloud ◦  Gurobi Instant Cloud ◦  More flexible pricing

}  Gurobi Cloud for AWS is still available for experienced Amazon EC2 users

© 2015 Gurobi Optimization 53

The Cloud isn’t for Everyone

}  Before you get started it’s important to understand if the Cloud is right for you

}  In some cases, data transmission may be a bottleneck

}  You may not be ready to trust others to manage your computers

}  It may be cheaper to own than to rent ◦  Long-term applications that run (nearly) 24/7

}  Most customers continue to use traditional licenses

© 2015 Gurobi Optimization 54

Why use the Cloud for Optimization?

}  Pay just for what you use ◦  Short-term projects ◦  Occasional use ◦  Meet a peak in demand

}  No software or hardware to purchase or configure

}  Get many fast computers quickly ◦  Especially valuable for distributed optimization

}  Increased robustness ◦  Get computers in multiple locations ◦  World-class management of computer center

© 2015 Gurobi Optimization 55

Gurobi Instant Cloud

}  Gurobi Instant Cloud makes it fast and easy to use the cloud for optimization.

}  No need to be an expert in cloud computing! }  Simply install Gurobi Optimizer on your client computers

}  Visit the Instant Cloud website: https://cloud.gurobi.com ◦  Or access directly via REST API

}  Launch a fast cloud machine to quickly solve your model }  Run from Windows, Mac, or Linux clients

}  Communication between your client and your cloud server encrypted with 256-bit AES

}  Gurobi does not have the ability to access your models or your data

© 2015 Gurobi Optimization 56

Distributed Optimization on the Instant Cloud

}  Distributed Optimization is a great fit for the Instant Cloud }  Quickly get access to a cluster of machines in the Cloud

☁ + = 😀

© 2015 Gurobi Optimization 57

Demonstration: Gurobi Instant Cloud

© 2015 Gurobi Optimization 58

Gurobi Instant Cloud API

}  Simple HTTPS API ◦  List your licenses ◦  List your running machines ◦  Launch a set of machines ◦  Kill a set of machine

}  API calls authenticated by signing with secret key

}  Embed access id and secret key in your client programs ◦  Revoke secret key if necessary

© 2015 Gurobi Optimization 59

Gurobi Instant Cloud API

}  Open source API clients available on GitHub: ◦  Python - https://github.com/Gurobi/instantcloud-python ◦  C - https://github.com/Gurobi/instantcloud-c ◦  C# - https://github.com/Gurobi/instantcloud-dotnet ◦  Java - https://github.com/Gurobi/instantcloud-python

}  Use them to start and stop cloud machines from the command-line

}  Or as a library for controlling cloud machines from your own programs

© 2015 Gurobi Optimization 60

Instant Cloud Pricing

}  Cloud pricing has two components: ◦  Machine Price: what you pay for the machine ◦  License Price: what you pay for Gurobi software

}  Allows you to choose the best machine for your needs

}  Different licenses for light and heavy/advanced users ◦  You only pay for the features you use

}  Frequent cloud users automatically receive savings

© 2015 Gurobi Optimization 61

Gurobi Instant Cloud Licenses

Light License Full License Multiple Jobs ✖ ✔

Job Queuing ✖ ✔

Load Balancing ✖ ✔

Distributed Optimization ✖ ✔

}  Light License ◦  Equivalent to Single-Use license ◦  Perfect if you are solving a single model at a time

}  Full License ◦  Equivalent to Compute Server license with Distributed Optimization add on ◦  Perfect for solving multiple models from multiple users ◦  Perfect for Distributed Optimization

© 2015 Gurobi Optimization 62

Automatic License Savings

Light License Full License Hourly Price $10/hr $20/hr

Monthly Price Cap $1500 $3000

}  Price cap lets you run a machine 24 hrs/day for ~750hrs in a month

© 2015 Gurobi Optimization 63

Distributed Workers

}  When you perform distributed optimization you need: ◦  A manager machine with a Full license ◦  A cluster of distributed workers

}  No license charge for distributed workers

}  Add as many as you need to your cluster

}  Pay only the cost of running the worker machines

© 2015 Gurobi Optimization 64

Gurobi Instant Cloud Machines

Machine vCPU RAM (GB) Price East-1 ($/hr)

c4.large 2 3.75 0.11 c4.2xlarge 8 15 0.46 c4.4xlarge 16 30 0.88 c4.8xlarge 36 60 1.86 r3.8xlarge 32 244 2.80

}  Includes Amazon’s latest compute optimized c4 machines }  Includes a machine with 244 GB of RAM for your largest models

}  Machine prices vary by region (prices shown are for US-East-1)

© 2015 Gurobi Optimization 65

References

}  Visit www.gurobi.com for more details on the Instant Cloud

}  Commercial clients, ask your account representative for a free trial

}  Get started using the Instant Cloud today

Performance Benchmarks

© 2015 Gurobi Optimization 67

Two Kinds of Benchmarks

}  Internal benchmarks ◦  Most important: compare Gurobi version-over-version ◦  Use internal Library of some 10,000 models

}  External, competitive benchmarks ◦  Conducted by Hans Mittelmann, Arizona State University

�  http://plato.asu.edu/bench.html

◦  For MIP, largely based upon MIPLIB 2010

© 2015 Gurobi Optimization 68

Internal Benchmarks

Gurobi MIP Library (3842 models)

1

10

100

1000

10000

100000

1000000

10000000

100000000

1E+09

1 10 100 1000 10000 100000 1000000 10000000 100000000

Colu

mns

Rows

100,000

1,000,000

© 2015 Gurobi Optimization 70

Performance Improvements in Gurobi 6.5

}  Gurobi 6.0 vs. 6.5: > 1.00x means that Gurobi 6.5 is faster }  MIQP: big speedup from 5 models of a single source }  QP not included: only 16 models > 1s

ProblemClass

>1s >100s

# Wins Losses Speedup # Wins Losses Speedup

LP 409 122 50 1.16x 148 55 30 1.32x

primal 390 111 66 1.03x 169 61 34 1.02x

dual 362 103 57 1.11x 131 47 27 1.24x

barrier 408 120 41 1.12x 133 61 23 1.25x

QCP/SOCP 78 15 11 1.16x 20 6 2 1.97x

MILP 1851 982 407 1.37x 832 514 215 1.72x

MIQP 95 57 22 1.99x 36 24 9 4.98x MIQCP 190 130 44 2.78x 86 67 17 6.49x

© 2015 Gurobi Optimization 71

-

5.0

10.0

15.0

20.0

25.0

30.0

35.0

40.0

45.0

50.0

0.00

0.50

1.00

1.50

2.00

2.50

3.00

1.0 -> 2.0 2.0 -> 3.0 3.0 -> 4.0 4.0 -> 5.0 5.0 -> 6.0 6.0 -> 6.5

Cum

ulat

ive

Spee

dup

Vers

ion-

to-V

ersi

on S

peed

up

Version to Version Speedup Cumulative Speedup

Gurobi Keeps Getting Better

71

48.7x improvement

(six years)

Gurobi Version-to-Version Pairs

© 2015 Gurobi Optimization 72

Where does the MIP Performance come from?

}  Cuts 24.1% ◦  …

}  Presolve 15.6% ◦  …

}  Branching 7.7% ◦  …

© 2015 Gurobi Optimization 73

Where does the MIP Performance come from?

}  MIP/LP integration 7.5% ◦  …

}  Heuristics 3.5% ◦  …

}  Node presolve 3.9% ◦  …

}  Compiler 2.0% ◦  …

© 2015 Gurobi Optimization 74

Where does the LP Performance come from?

}  LP default, concurrent ◦  Speedup of barrier and dual simplex

}  Barrier (mainly in crossover) ◦  More aggressive reduction of superbasic variables in crossover ◦  Detecting numerically challenging models and adjusting numeric settings

}  Dual simplex ◦  Better and faster handling of degenerate pivots ◦  More aggressive on starting basis crash

}  Presolve ◦  Improve implied bound handling and reduce extra iterations after uncrush ◦  More aggressive on dependent row reduction

}  Compiler ◦  Switched to Intel 2016 compiler

© 2015 Gurobi Optimization 75

External Benchmarks(Hans Mittelmann, http://plato.asu.edu/bench.html)

© 2015 Gurobi Optimization 76

LP

Benchmarks

© 2015 Gurobi Optimization 77

}  Complete test data available here: http://plato.asu.edu/ftp/lpcom.html }  40 models, time limit 25000 sec., 8 threads

2.04 1.97

2.48

0.97 1.09

1.28

2.48

2.01 1.92

0.00

0.50

1.00

1.50

2.00

2.50

3.00

Dual Barrier Concurrent

Gurobi 6.5 CPLEX 12.6.2 XPress 7.9 Mosek 7.1

Low

er is

bet

ter

LP Solve Times

© 2015 Gurobi Optimization 78

MILP Benchmarks

© 2015 Gurobi Optimization 79

§  Gurobi 6.5 vs. Competition: Solve times (> 1.0 means Gurobi faster)

Benchmark CPLEX XPRESS

P=1 P=4 P=12 P=1 P=4 P=12 Optimality 1.16X 1.26X 1.21X 1.07X 0.96X 1.36X

Optimality, 5 permuted 1.09X - - 1.36X - -

Feasibility - 1.10X - - 4.62X -

Infeasibility - 1.05X - - 1.67X -

“Easy” Optimality - - 1.16X - - 1.96X

Mittelmann (MIPLIB 2010): MIP Solve Times

© 2015 Gurobi Optimization 80

§  Gurobi 6.5 vs. Competition: Solve times (> 1.0 means Gurobi faster)

Benchmark CPLEX XPRESS

P=1 P=4 P=12 P=1 P=4 P=12 Optimality 1.21X 1.12X

Optimality, 5 permuted 1.09X - - 1.36X - -

Feasibility - 1.10X - - 4.62X -

Infeasibility - 1.05X - - 1.67X -

Mittelmann (MIPLIB 2010): MIP Solve Times

“Easy” Optimality - - 1.16X - - 1.96X “Easy” Optimality (-87) - - 1.13X - - 2.55X

© 2015 Gurobi Optimization 81

Gurobi 6.5 vs. Competition: Hit time limit

Benchmark Gurobi CPLEX XPRESS Optimality 2 4 2 Feasibility 0 0 3 Infeasibility 0 0 0 “Easy” -- Optimality 11 12 38

Mittelmann: MILP Solvability

© 2015 Gurobi Optimization 82

Benchmarks – Open Source MIP

}  Mittelmann MIPLIB2010 tests, P=1 (>1X means Gurobi wins):

January 2012

January 2013

January 2015

October 2015 % Solved

CBC 10X 13X 17X 21.2X 55%

SCIP 6X 7X 7X 7.1X 80%

GLPK 22X 27X - - 1%

LPSOLVE 19X 24X - - 6%

}  Open source MIP solvers continue falling further behind

© 2015 Gurobi Optimization 83

QP

Benchmarks

© 2015 Gurobi Optimization 84

§  Gurobi 6.5 vs. Competition: Solve times (> 1.0 means Gurobi is faster)

Benchmark CPLEX XPRESS

MIQP 1.29X 1.36X - MIQCP 1.45X 1.61X - MISOCP 1.91X 5.28X 19.7X SOCP 2.52X 1.22X 0.97X

Mittelmann: QP Solve Times

Projected Roadmap

© 2015 Gurobi Optimization 86

Projected Roadmap

}  Performance }  Parallelism ◦  Improve performance on 12+ core systems ◦  Improve distributed MIP performance and scalability

}  Enhanced Gurobi Cloud offering

}  Piecewise-linear extensions ◦  PWL objective in MIP ◦  PWL constraint coefficients in MIP

}  Automatic linearization of common logical constraints

© 2015 Gurobi Optimization 87

Thank You

}  New academic users should visit our Academic Licensing page to get free academic versions of Gurobi ◦  http://www.gurobi.com/products/licensing-and-pricing/academic-

licensing

}  New commercial users should request a free evaluation version of Gurobi by emailing sales@gurobi.com.

}  For any general questions email info@gurobi.com.

top related