from programs to program spaces programming by
play

From Programs to Program Spaces: Programming by Optimisation Holger - PowerPoint PPT Presentation

From Programs to Program Spaces: Programming by Optimisation Holger H. Hoos BETA Lab Department of Computer Science University of British Columbia Canada 45th CREST Open Workshop on Genetic Improvement London, UK, 2016/01/26 The age of


  1. From Programs to Program Spaces: Programming by Optimisation Holger H. Hoos BETA Lab Department of Computer Science University of British Columbia Canada 45th CREST Open Workshop on Genetic Improvement London, UK, 2016/01/26

  2. The age of machines “As soon as an Analytical Engine exists, it will necessarily guide the future course of the science. Whenever any result is sought by its aid, the question will then arise – by what course of calculation can these results be arrived at by the machine in the shortest time?” (Charles Babbage, 1864) Holger Hoos: Programming by Optimisation 1

  3. The age of computation “The maths that computers use to de- cide stu ff [is] infiltrating every aspect of our lives.” I financial markets I social interactions I cultural preferences I artistic production I . . . Holger Hoos: Programming by Optimisation 2

  4. Performance matters ... I computation speed (time is money!) I energy consumption (battery life, ...) I quality of results (cost, profit, weight, ...) ... increasingly: I globalised markets I just-in-time production & services I tighter resource constraints Holger Hoos: Programming by Optimisation 3

  5. solver solver solver application context 1 application context 2 application context 3

  6. solver[ · ] solver[ p1 ] solver[ p2 ] solver solver solver solver solver[ p3 ] application context 1 application context 2 application context 3

  7. 1

  8. Algorithm configuration Observation: Many algorithms have parameters (sometimes hidden / hardwired) whose settings a ff ect performance Challenge: Find parameter settings that achieve good / optimal performance on given type of input data Example: IBM ILOG CPLEX I widely used industrial optimisation software I exact solver, based on sophisticated branch & cut algorithm and numerous heuristics I 135 parameters that directly control search process I find parameter settings that solve MIP-encoded wildlife corridor construction problems as fast as possible Holger Hoos: Programming by Optimisation 5

  9. Lo Hi Holger Hoos: Programming by Optimisation 6

  10. Lo Hi Holger Hoos: Programming by Optimisation 6

  11. CPLEX on Wildlife Corridor Design 10 5 10 4 CPLEX optimised [CPU s] 10 3 10 2 10 1 10 0 10 -1 10 -2 10 -2 10 -1 10 0 10 1 10 2 10 3 10 4 10 5 CPLEX default [CPU s] 52 . 3 × speedup on average! Holger Hoos: Programming by Optimisation 7

  12. The algorithm configuration problem (AC) Given: I parameterised target algorithm A with configuration space C I set of (training) inputs I I performance metric m (w.l.o.g. to be minimised) Want: c ∗ ∈ arg min c ∈ C m ( A [ c ] , I ) Holger Hoos: Programming by Optimisation 8

  13. What if ... we could solve AC e ff ectively? 1. Less fiddling / hand-tuning. 2. Better performing algorithms. 3. More parameters, fewer ad-hoc choices. 4. More expert time spent on ideas, high-level design choices. 5. More broadly applicable software. 6. Automatically customised software. 7. Automatic parallelisation. 8. Partial automation of programming. 9. Fairer evaluation of algorithms and ideas. 10. New insights into e ffi cacy of heuristic mechanisms, empirical complexity of problems. Holger Hoos: Programming by Optimisation 9

  14. Algorithm configuration is challenging: I size of configuration space I parameter interactions I discrete / categorical parameters I conditional parameters I performance varies across inputs (problem instances) I evaluating poor configurations can be very costly I censored algorithm runs standard optimisation methods are insu ffi cient Holger Hoos: Programming by Optimisation 10

  15. Machine Learning Optimisation

  16. Sequential Model-based Optimisation e.g., Jones (1998), Bartz-Beielstein (2006) I Key idea: use predictive performance model (response surface model) to find good configurations I perform runs for selected configurations (initial design) and fit model ( e.g. , noise-free Gaussian process model) I iteratively select promising configuration, perform run and update model Holger Hoos: Programming by Optimisation 11

  17. Sequential Model-based Optimisation parameter response measured (Initialisation) Holger Hoos: Programming by Optimisation 12

  18. Sequential Model-based Optimisation parameter response measured model (Initialisation) Holger Hoos: Programming by Optimisation 12

  19. Sequential Model-based Optimisation parameter response measured model predicted best (Initialisation) Holger Hoos: Programming by Optimisation 12

  20. Sequential Model-based Optimisation parameter response measured model predicted best (Initialisation) Holger Hoos: Programming by Optimisation 12

  21. Sequential Model-based Optimisation parameter response measured model predicted best (Initialisation) Holger Hoos: Programming by Optimisation 12

  22. Sequential Model-based Optimisation parameter response measured model predicted best new incumbent found! (Initialisation) Holger Hoos: Programming by Optimisation 12

  23. Sequential Model-based Algorithm Configuration (SMAC) Hutter, HH, Leyton-Brown (2011) I uses random forest model to predict performance of parameter configurations I predictions based on algorithm parameters and instance features, aggregated across instances I finds promising configurations based on expected improvement criterion , using multi-start local search and random sampling I initialisation with single configuration (algorithm default or randomly chosen) Holger Hoos: Programming by Optimisation 13

  24. 2

  25. Lo Hi Holger Hoos: Programming by Optimisation 14

  26. Lo Hi Holger Hoos: Programming by Optimisation 14

  27. Programming by Optimisation (PbO) HH (2012) Key idea: I program (large) space of programs I encourage software developers to I avoid premature commitment to design choices I seek & maintain design alternatives I automatically find performance-optimising designs for given use context(s) Holger Hoos: Programming by Optimisation 15

  28. Software development in the PbO paradigm design space description parametric instantiated PbO-<L> PbO PbO-<L> <L> <L> design source(s) weaver source(s) source(s) optimiser deployed benchmark executable inputs use context Holger Hoos: Programming by Optimisation 16

  29. Levels of PbO: Level 4: Make no design choice prematurely that cannot be justified compellingly. Level 3: Strive to provide design choices and alternatives. Level 2: Keep and expose design choices considered during software development. Level 1: Expose design choices hardwired into existing code (magic constants, hidden parameters, abandoned design alternatives). Level 0: Optimise settings of parameters exposed by existing software. Holger Hoos: Programming by Optimisation 17

  30. Success in optimising speed: Application, Design choices Speedup PbO level SAT-based software verification ( Spear ), 26 4.5–500 × 2–3 Hutter, Babi´ c, HH, Hu (2007) AI Planning (LPG), 62 3–118 × 1 Vallati, Fawcett, Gerevini, HH, Saetti (2011) Mixed integer programming (CPLEX), 76 2–52 × 0 Hutter, HH, Leyton-Brown (2010) ... and solution quality: University timetabling, 18 design choices, PbO level 2–3 new state of the art; UBC exam scheduling Fawcett, Chiarandini, HH (2009) Machine learning / Classification, 786 design choices, PbO level 0–1 outperforms specialised model selection & hyper-parameter optimisation methods from machine learning Thornton, Hutter, HH, Leyton-Brown (2012) Holger Hoos: Programming by Optimisation 18

  31. Median running time of EAX (state-of-the-art TSP solver) Mu, Hoos, St¨ utzle (under review) √ n EAX (default): 0 . 086 × 1 . 144 EAX (optimised): 1 . 62 × 10 − 8 × n 2 . 836 10 5 10 4 10 3 running time [CPU s] 10 2 10 1 10 0 10 -1 EAX default 10 -2 EAX optimised 10 -3 0 2000 4000 6000 8000 10000 #cities Holger Hoos: Programming by Optimisation 19

  32. Further successful applications: I macro learning in planning (Alhossaini & Beck 2012) I garbage collection in Java (Lengauer & M¨ ossenb¨ ock 2014) I kidney exchange (Dickerson et al. 2012) Holger Hoos: Programming by Optimisation 20

  33. solver design space of solvers Holger Hoos: Programming by Optimisation 21

  34. solver design space of solvers optimised solver application context Holger Hoos: Programming by Optimisation 21

  35. solver parallel planner planner portfolio instance- design space based of solvers selector optimised solver application context Holger Hoos: Programming by Optimisation 21

  36. parallel planner planner portfolio instance- design space based of solvers selector optimised solver application context Holger Hoos: Programming by Optimisation 21

  37. Programming by Optimisation ... I leverages computational power to construct better software I enables creative thinking about design alternatives I produces better performing, more flexible software I facilitates scientific insights into I e ffi cacy of algorithms and their components I empirical complexity of computational problems ... changes how we build and use high-performance software Holger Hoos: Programming by Optimisation 22

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend