Where to start
Learn linear and integer programming with OR-Tools or CVXPY first, so you can compute strong baselines and optimality gaps. Then train a learned heuristic and test it on larger or differently distributed instances.
How deep learning is used for optimisation
Learned heuristics for routing
A neural network trained on many random instances learns to build routes city by city, giving good solutions quickly. Results are compared with classical solvers on the same instances.
Real example: Attention model for routing. Kool, van Hoof and Welling trained an attention-based model with reinforcement learning to construct solutions to the travelling salesman and vehicle routing problems.
Guiding exact solvers
Inside branch-and-bound, a network learns which variable to branch on by imitating an expensive expert rule. The solver stays exact while the learned choices speed up its search.
Real example: GCNN branching. Gasse and colleagues trained a graph convolutional network by imitation learning to choose branching variables for mixed-integer linear programs.
Neural components for mixed-integer programs
Learned models propose partial assignments and branching decisions, so a solver finds good feasible solutions sooner on a family of similar problems.
Real example: Neural Diving and Neural Branching (DeepMind). DeepMind and Google researchers built neural network components called Neural Diving and Neural Branching to use inside a MIP solver.
Fast surrogates for simulations
A network trained on simulator output predicts the next state much faster than the original simulation. Optimisation can then search over many designs using the surrogate.
Real example: Learning to Simulate (DeepMind). DeepMind's graph network simulator learned to simulate fluids, rigid solids and deformable materials from data.
Optimising control of real systems
Models trained on sensor history predict how settings affect performance, and the system chooses settings that improve it within safety limits.
Real example: Google data centre cooling. DeepMind reported that applying its machine learning to Google data centres reduced the energy used for cooling by up to 40 per cent.
Can you learn deep learning for optimisation?
Yes, but it combines two fields, so expect to learn classical optimisation as well as deep learning. Learn Python and linear algebra, then linear and integer programming with a solver, then neural networks and reinforcement learning.
- Python and linear algebra. Write NumPy code and understand vectors, matrices and gradients. Taught in the Maths track of Foundations of AI
- Classical optimisation. Model problems as linear and integer programs and solve them with OR-Tools or CVXPY, which are the baselines you must compare against.
- Neural networks. Train networks with PyTorch, including attention and graph models, which suit routing and solver data. Covered by the Deep Learning course (coming next)
- Learning to optimise. Reproduce a learned routing model with RL4CO, check every solution for feasibility, and report the gap to the best known solution.
Moving into learning-based optimisation
If you already work in the field
If you work in operations research, logistics or planning, you already know the problems, constraints and solvers. Add PyTorch and reinforcement learning, then try learning a heuristic for a family of instances you solve repeatedly.
If you come from data science or ML
If you come from machine learning, learn linear and integer programming, duality and how solvers work. Always compare against a classical solver and check feasibility, because a fast infeasible answer is worthless.
Roles that do this work: Operations research scientistMachine learning engineer, optimisationApplied scientist, supply chainResearch scientist
Tools you will use
| Tool | What you use it for |
|---|---|
| OR-Tools | Solve routing, scheduling and integer programs to produce baselines and reference solutions. |
| CVXPY | Model convex optimisation problems in Python with a readable syntax. |
| cvxpylayers | Put a convex optimisation problem inside a PyTorch network and differentiate through its solution. |
| RL4CO | Train neural solvers for routing and scheduling problems with reinforcement learning in PyTorch. |
| PyTorch | Build surrogate models and custom training loops for learned optimisation components. |
Public data to practise on
- TSPLIB: Classic travelling-salesman instances with known optimal tour lengths, for measuring a learned solver's gap.
- CVRPLIB: Vehicle-routing benchmark instances with best known solutions, for testing routing heuristics.
- MIPLIB 2017: Mixed-integer programming benchmark instances, for learning branching rules or solver settings.
Your first project
Download TSPLIB instances of up to about 100 cities, solve them with an RL4CO attention model trained on random instances, and compare with OR-Tools routing using the gap to the published optimal tour lengths.
Keep the result, your code and a short note on what didn't work. That record is worth more than the score.