Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Web-ML-Berlin

JBClion
November 03, 2017

 Web-ML-Berlin

Bridge JS development and Genetic Algorithm.
+ Evoria https://evoria-1984.firebaseapp.com
+ Evoria - GitLab https://gitlab.com/JBClion/Evoria
+ Example - GitLab https://gitlab.com/JBClion/GA-SIMPLE
+ Speakerdeck https://speakerdeck.com/jbclion/web-ml-berlin
+ Twitter @JBaptisteClion

JBClion

November 03, 2017
Tweet

More Decks by JBClion

Other Decks in Programming

Transcript

  1. UP

  2. 16 possible configurations 0000 0001 0010 0011 0100 0101 0110

    0111 1000 1001 1010 1011 1100 1101 1110 1111
  3. One movement per configuration 10 01 11 00 01 10

    00 01 11 10 00 01 11 10 00 00 0001 0010 0011 0100 0101 0110 0111 1000 1001 1010 1011 1100 1101 1110 1111 0000
  4. 10 01 11 00 01 10 00 01 11 10

    00 01 11 10 00 00 0001 0010 0011 0100 0101 0110 0111 1000 1001 1010 1011 1100 1101 1110 1111 0000 Never change
  5. 10 01 11 00 01 10 00 01 11 10

    00 01 11 10 00 00 0001 0010 0011 0100 0101 0110 0111 1000 1001 1010 1011 1100 1101 1110 1111 0000 Never change Change
  6. 10 01 11 00 01 10 00 01 11 10

    00 01 11 10 00 00 Change
  7. 10 01 11 00 01 10 00 01 11 10

    00 01 11 10 00 00
  8. 01100011001001000100110100010101 32 bits = 232 = 4,294,967,296 possibilities four billion,

    two hundred and ninety-four million, nine hundred and sixty-seven thousand, two hundred and ninety-six
  9. Search space The set of all possible solutions able to

    satisfy a given problem’s constraints.
  10. Scale 1/256 VALID SOLUTIONS Where Do I Start? How Do

    I Navigate? Memorize progresses Intelligence
  11. Scale 1/256 VALID SOLUTIONS Where Do I Start? How Do

    I Navigate? Memorize progresses Learning Intelligence
  12. Intelligence Capacity to search the most adapted solution to a

    given problem in the most efficient way and within the shortest possible time.
  13. 101010 0.5 000000 0.2 111011 111111 0.7 G 0 6.

    Crossover best solution with other solutions
  14. 101010 0.5 000000 0.2 111011 110011 111111 0.7 G 0

    6. Crossover best solution with other solutions
  15. 101010 0.5 000000 0.2 011010 111011 111111 0.7 8. Add

    best to avoid regression 111111 0.7 G 0
  16. 100001 1.0 010001 0.6 101000 0.3 G N VALID SOLUTION!

    5. Is best a valid solution? Yes => STOP
  17. 1. Select N random possible solutions in space 2. Appy

    Fitness function on selected solutions 3. Sort selected solution by Fitness 4. Extract best solution 5. Is best a valid solution? Yes => STOP 6. Crossover best solution with other solutions 7. Mutate new solutions 8. Add best to avoid regression SUMMARY
  18. Scale 1/256 VALID SOLUTIONS 0.40 0.60 0.51 0.79 G #2

    0.32 0.64 0.24 0.44 0.48 DRIVE THE CONVERGENCE
  19. Scale 1/256 VALID SOLUTIONS 0.40 0.60 0.51 0.79 G #2

    0.32 0.64 0.24 0.44 0.48 AVOID REGRESSIONS DRIVE THE CONVERGENCE
  20. Scale 1/256 VALID SOLUTIONS 0.35 0.29 0.34 0.37 0.21 G

    #4 SIMILAR GENOTYPES = SIMILAR GENERATIONS
  21. Scale 1/256 VALID SOLUTIONS 0.35 0.29 0.34 0.37 0.21 G

    #4 SIMILAR GENOTYPES = SIMILAR GENERATIONS = LOCAL MAXIMA
  22. Scale 1/256 VALID SOLUTIONS 0.35 0.29 0.34 0.37 0.21 G

    #4 SIMILAR GENOTYPES = SIMILAR GENERATIONS = LOCAL MAXIMA = NO CONVERGENCE
  23. Scale 1/256 VALID SOLUTIONS 0.35 0.34 0.34 0.37 0.64 G

    #5 MUTATION ENABLE JUMP ACROSS THE SPACE
  24. Scale 1/256 VALID SOLUTIONS 0.35 0.34 0.34 0.37 0.64 G

    #5 MUTATION ENABLE JUMP ACROSS THE SPACE !! HIGH MUTATION RATIO !! CREATE A RANDOM SEARCH
  25. Scale 1/256 VALID SOLUTIONS 0.35 0.34 0.34 0.37 0.64 G

    #5 MUTATION ENABLE JUMP ACROSS THE SPACE !! HIGH MUTATION RATIO !! CREATE A RANDOM SEARCH
  26. Thank you! Jean-Baptiste Clion Google Developer Expert Twitter @JBaptisteClion GitHub

    https://gitlab.com/JBClion/Evoria Speakerdeck https://speakerdeck.com/jbclion/web-ml-berlin Evoria https://evoria-1984.firebaseapp.com