Java Developers sometimes face programming challenges, such as creating a school roster or determining a salesperson’s optimal route, that are extremely difficult to crack using conventional approaches. Discover how Evolutionary Algorithms can be applied to solve these complex puzzles. The session starts with a success story from the NASA space archives to explain the concepts. Once the stage is set, it’s puzzle solving time! Learn to code Evolutionary Algorithms using plain Java - although existing Java frameworks such as JGAP are also addressed. The session concludes with a checklist that can be used to determine whether Evolutionary Algorithms are a good fit to the problem. With this checklist, the decision has never been easier!
Evolutionary Algorithms: The Key to Solving Complex Java PuzzlesBas W. Knopper
JavaOne presentation on Evolutionary Algorithms. The abstract of the presentation: Java developers sometimes face programming challenges, such as creating a school roster or determining a salesperson’s optimal route, that are extremely difficult to crack with conventional approaches. Discover how evolutionary algorithms can be applied to solve such complex puzzles. This session starts with a success story from the NASA space archives to explain the concepts. Once the stage is set, it’s puzzle-solving time! Learn how to code evolutionary algorithms by using plain Java—although existing Java frameworks such as JGAP are also addressed. The session concludes with a checklist for determining whether evolutionary algorithms are a good fit for any particular problem. With this checklist, the decision has never been easier!
Distributed Systems Done Right: Why Java Enterprises Are Embracing The Actor ...Lightbend
Most likely, your job is heavily focused on helping your organization modernize for the digital era. As the days of purely Object-Oriented Programming and related frameworks come to a close, enterprises migrating to distributed, cloud infrastructures are embracing a different approach: the Actor Model.
When it comes to distributed computing, the Actor Model is the great-grandparent of it all.
Created by Carl Hewitt in 1973, Forrester Research notes, “the Actor model is seeing renewed interest as cloud concurrency challenges grow.”
Yet even if you understand the Actor Model and used some of the toolkits for it (e.g. Akka and Erlang), how do you easily explain the concept to your team, colleagues and managers? Where do you start?
In this webinar, Hugh McKee, Global Solutions Architect at Lightbend, shows you how Actors behave and interact as humans do when it comes to communicating, and how these similar behavioral patterns provide basic intuition when designing Reactive systems. Actors allow your teams to focus on an application’s business logic rather than on low-level protocols, accelerating time-to-market while keeping your infrastructure costs low.
Our goal is twofold: provide you with a comprehensive review of the Actor Model, and give you the resources you need to help others learn why enterprises like Walmart, Intel, Samsung, IBM, Norwegian Cruise Lines and HSBC are committed production users of Akka, the JVM-based toolkit built on the Actor Model.
In this webinar, you’ll learn:
*Why actor-based systems are one of the foundational technologies for creating microservices architecture (MSA)
*How Actors delegate work by creating other Actors in a supervisor-to-worker relationship
*How Actors manage requests and scale horizontally in large systems
*The difference between traditional systems and actor-based systems
*How an Actor system forms clusters when the flow of work exceeds a system’s capacity to process it
*Why failure detection and failure recovery is an architectural feature of Actor systems
*An example of using Actors to build an Internet of Things (IoT) application
Visit Lightbend.com/blog for more goodness.
Exploring the development and production pipelines for miniatures in the tabletop wargaming industry. Including a look at the career route taken by the speaker, a case study on developing anatomical archetypes for consistent design outcomes, and a brief look at the various production methods available to the industry.
Evolutionary Algorithms: The Key to Solving Complex Java PuzzlesBas W. Knopper
JavaOne presentation on Evolutionary Algorithms. The abstract of the presentation: Java developers sometimes face programming challenges, such as creating a school roster or determining a salesperson’s optimal route, that are extremely difficult to crack with conventional approaches. Discover how evolutionary algorithms can be applied to solve such complex puzzles. This session starts with a success story from the NASA space archives to explain the concepts. Once the stage is set, it’s puzzle-solving time! Learn how to code evolutionary algorithms by using plain Java—although existing Java frameworks such as JGAP are also addressed. The session concludes with a checklist for determining whether evolutionary algorithms are a good fit for any particular problem. With this checklist, the decision has never been easier!
Distributed Systems Done Right: Why Java Enterprises Are Embracing The Actor ...Lightbend
Most likely, your job is heavily focused on helping your organization modernize for the digital era. As the days of purely Object-Oriented Programming and related frameworks come to a close, enterprises migrating to distributed, cloud infrastructures are embracing a different approach: the Actor Model.
When it comes to distributed computing, the Actor Model is the great-grandparent of it all.
Created by Carl Hewitt in 1973, Forrester Research notes, “the Actor model is seeing renewed interest as cloud concurrency challenges grow.”
Yet even if you understand the Actor Model and used some of the toolkits for it (e.g. Akka and Erlang), how do you easily explain the concept to your team, colleagues and managers? Where do you start?
In this webinar, Hugh McKee, Global Solutions Architect at Lightbend, shows you how Actors behave and interact as humans do when it comes to communicating, and how these similar behavioral patterns provide basic intuition when designing Reactive systems. Actors allow your teams to focus on an application’s business logic rather than on low-level protocols, accelerating time-to-market while keeping your infrastructure costs low.
Our goal is twofold: provide you with a comprehensive review of the Actor Model, and give you the resources you need to help others learn why enterprises like Walmart, Intel, Samsung, IBM, Norwegian Cruise Lines and HSBC are committed production users of Akka, the JVM-based toolkit built on the Actor Model.
In this webinar, you’ll learn:
*Why actor-based systems are one of the foundational technologies for creating microservices architecture (MSA)
*How Actors delegate work by creating other Actors in a supervisor-to-worker relationship
*How Actors manage requests and scale horizontally in large systems
*The difference between traditional systems and actor-based systems
*How an Actor system forms clusters when the flow of work exceeds a system’s capacity to process it
*Why failure detection and failure recovery is an architectural feature of Actor systems
*An example of using Actors to build an Internet of Things (IoT) application
Visit Lightbend.com/blog for more goodness.
Exploring the development and production pipelines for miniatures in the tabletop wargaming industry. Including a look at the career route taken by the speaker, a case study on developing anatomical archetypes for consistent design outcomes, and a brief look at the various production methods available to the industry.
Value Objects, Full Throttle (to be updated for spring TC39 meetings)Brendan Eich
Slides I prepared for the 29 January 2014 Ecma TC39 meeting, on Value Objects in JS, an ES7 proposal -- this one shotgunned the roadmap-space of declarative syntax, to find the right amount per TC39 (nearly zero, turns out).
BigInts In JavaScript: A Case Study In TC39 (JSConf EU 2018)Igalia
By Daniel Ehrenberg.
Slides at https://docs.google.com/presentation/d/1apPbAiv_-mJF35P31IjaII8UA6TwSynCA_zhfDEmgOE/edit#slide=id.p
Quick, what do you get when you increment Math.pow(2, 53)? If you said Math.pow(2, 53), you may be a JavaScript programmer.
From the beginning, JavaScript has supported 64-bit binary floats as its sole numeric type. In this talk, I’ll explain how, through TC39, JavaScript developers are working together with JS engine implementers and spec wonks like me to create BigInt: a native, unlimited-size integer type.
Through collaboration, any layer of software can be changed, even the language itself.
(c) JSConf EU 2018
June 2nd & 3rd 2018 — Berlin, Germany
https://2018.jsconf.eu/
It was the talk, titled "Graph-Tool: The Efficient Network Analyzing Tool for Python", at PyCon APAC 2014 [1] and PyCon SG 2014 [2]. It introduces you to Graph-Tool by mass code snippets.
[1] https://tw.pycon.org/2014apac
[2] https://pycon.sg/
Slides about the fat and the gaunt years of C++ and why the language currently experiences its renaissance. They also explain what Modern C++ is. Finally, you'll learn how the language evolved along with its ecosystem and where will it go further.
With more and more digitized companies and software being a crucial asset to gain competitive advantage, some firms choose to beat competition adopting Open Source to boost innovation. However, this journey requires a clear Software Data Strategy to succeed.
This data-driven approach creates new ways to gather and visualize data to better find meaningful insights among software development activity, performance and community, for future reporting and decision making.
GrimoireLab (https://chaoss.github.io/grimoirelab) produces integrated, open source software for analyzing software and visualizing metrics for measuring community, activity, contributions, performance and project health. Is one of the founding software projects of CHAOSS (Community Health Analytics Open Source Software) project, from The Linux Foundation (https://chaoss.community).
DevOps Practice in Nonprofit - Abdurrachman MappujiDevOpsDaysJKT
DevOps practice in nonprofit and how we develop and deploy software to resource-constrained device
Web and commercial space is overrated, there are many other computation that also make a good cause become possible. In this talk I will talk about how we work at nonprofit organization with distributed team consist of developer, volunteer, intern, leaders. This is taken from my background as volunteer in the team. Then we will have a biggest part of the talk discussing about how we employ docker to package our application to resource-constrained and low power device to be deploy in our field (remote area with limited electricity and internet). We create our own linux distro which has some tools embedded for Raspberry Pi. Infrastructure-as-code is somewhat unique in this arena. In this talk we will close our talk with some lesson learned that commercial space can learn from nonprofit like us. How we appreciate contribution accross project. How to attract people to automagically contribute. And many other stuffs. Hope you enjoy.
PGDay.Amsterdam 2018 - Bruce Momjian - Will postgres live foreverPGDay.Amsterdam
Bruce will explain how open source software can live for a very long time, and covers the differences between proprietary and open source software life cycles. He will also cover the increased adoption of open source, and many of the ways that Postgres is innovating to continue to be relevant.
The future of Web-Scale - Johan Tillema, Rene Boere & Chris QuachNLJUG
De afgelopen jaren zijn door grote internetbedrijven en binnen de opensource-community technieken ontwikkeld, die het mogelijk maken om grote hoeveelheden data te verwerken. Dit wordt Web-scale IT genoemd en parallellisatie is hierbij een belangrijke term. In deze sessie bespreken we de technologie die bedrijven als Google, Twitter, Netflix en Facebook toepassen om grote hoeveelheden data te verwerken. We bespreken technieken als Hadoop Storm en HDFS, Akka Reactive Streams, HBase, Redis, Cassandra, Memcached en Apache Thrift. Verder laten we een aantal belangrijke strategieën zien zoals sharding, load balancing, caching, CQRS en NoSQL. Vervolgens bespreken we een aanpak om Web-scale technieken toe te passen binnen een bestaande IT architectuur. Hoe kun jij de Web-scale technieken toepassen binnen je huidige klus?
In many parts of today’s application architectures, a synchronous model is in use for all questions – even those that are really more one way messages than two-way questions, for example HTTP requests from browser to server and JDBC database requests. This approach of ‘hold your breath after asking a question until the response comes in’ is not smart and no longer necessary. This session describes how by leveraging opportunities for asynchronous processing,the perceived responsiveness of our systems is likely to improve. Frequently, the actual scalability is enhanced as well by making much better use of parallel processing power of current CPUs and Virtual Machines and by throttling peak loads by deferring some of the work. This presentation includes the browser (HTML 5, JavaScript, Web Sockets & SSE), middle tier (Java EE, Service Bus) and Database.
More Related Content
Similar to Evolutionary Algorithms: the key to solving complex Java puzzles! - Bas knopper
Value Objects, Full Throttle (to be updated for spring TC39 meetings)Brendan Eich
Slides I prepared for the 29 January 2014 Ecma TC39 meeting, on Value Objects in JS, an ES7 proposal -- this one shotgunned the roadmap-space of declarative syntax, to find the right amount per TC39 (nearly zero, turns out).
BigInts In JavaScript: A Case Study In TC39 (JSConf EU 2018)Igalia
By Daniel Ehrenberg.
Slides at https://docs.google.com/presentation/d/1apPbAiv_-mJF35P31IjaII8UA6TwSynCA_zhfDEmgOE/edit#slide=id.p
Quick, what do you get when you increment Math.pow(2, 53)? If you said Math.pow(2, 53), you may be a JavaScript programmer.
From the beginning, JavaScript has supported 64-bit binary floats as its sole numeric type. In this talk, I’ll explain how, through TC39, JavaScript developers are working together with JS engine implementers and spec wonks like me to create BigInt: a native, unlimited-size integer type.
Through collaboration, any layer of software can be changed, even the language itself.
(c) JSConf EU 2018
June 2nd & 3rd 2018 — Berlin, Germany
https://2018.jsconf.eu/
It was the talk, titled "Graph-Tool: The Efficient Network Analyzing Tool for Python", at PyCon APAC 2014 [1] and PyCon SG 2014 [2]. It introduces you to Graph-Tool by mass code snippets.
[1] https://tw.pycon.org/2014apac
[2] https://pycon.sg/
Slides about the fat and the gaunt years of C++ and why the language currently experiences its renaissance. They also explain what Modern C++ is. Finally, you'll learn how the language evolved along with its ecosystem and where will it go further.
With more and more digitized companies and software being a crucial asset to gain competitive advantage, some firms choose to beat competition adopting Open Source to boost innovation. However, this journey requires a clear Software Data Strategy to succeed.
This data-driven approach creates new ways to gather and visualize data to better find meaningful insights among software development activity, performance and community, for future reporting and decision making.
GrimoireLab (https://chaoss.github.io/grimoirelab) produces integrated, open source software for analyzing software and visualizing metrics for measuring community, activity, contributions, performance and project health. Is one of the founding software projects of CHAOSS (Community Health Analytics Open Source Software) project, from The Linux Foundation (https://chaoss.community).
DevOps Practice in Nonprofit - Abdurrachman MappujiDevOpsDaysJKT
DevOps practice in nonprofit and how we develop and deploy software to resource-constrained device
Web and commercial space is overrated, there are many other computation that also make a good cause become possible. In this talk I will talk about how we work at nonprofit organization with distributed team consist of developer, volunteer, intern, leaders. This is taken from my background as volunteer in the team. Then we will have a biggest part of the talk discussing about how we employ docker to package our application to resource-constrained and low power device to be deploy in our field (remote area with limited electricity and internet). We create our own linux distro which has some tools embedded for Raspberry Pi. Infrastructure-as-code is somewhat unique in this arena. In this talk we will close our talk with some lesson learned that commercial space can learn from nonprofit like us. How we appreciate contribution accross project. How to attract people to automagically contribute. And many other stuffs. Hope you enjoy.
PGDay.Amsterdam 2018 - Bruce Momjian - Will postgres live foreverPGDay.Amsterdam
Bruce will explain how open source software can live for a very long time, and covers the differences between proprietary and open source software life cycles. He will also cover the increased adoption of open source, and many of the ways that Postgres is innovating to continue to be relevant.
Similar to Evolutionary Algorithms: the key to solving complex Java puzzles! - Bas knopper (20)
The future of Web-Scale - Johan Tillema, Rene Boere & Chris QuachNLJUG
De afgelopen jaren zijn door grote internetbedrijven en binnen de opensource-community technieken ontwikkeld, die het mogelijk maken om grote hoeveelheden data te verwerken. Dit wordt Web-scale IT genoemd en parallellisatie is hierbij een belangrijke term. In deze sessie bespreken we de technologie die bedrijven als Google, Twitter, Netflix en Facebook toepassen om grote hoeveelheden data te verwerken. We bespreken technieken als Hadoop Storm en HDFS, Akka Reactive Streams, HBase, Redis, Cassandra, Memcached en Apache Thrift. Verder laten we een aantal belangrijke strategieën zien zoals sharding, load balancing, caching, CQRS en NoSQL. Vervolgens bespreken we een aanpak om Web-scale technieken toe te passen binnen een bestaande IT architectuur. Hoe kun jij de Web-scale technieken toepassen binnen je huidige klus?
In many parts of today’s application architectures, a synchronous model is in use for all questions – even those that are really more one way messages than two-way questions, for example HTTP requests from browser to server and JDBC database requests. This approach of ‘hold your breath after asking a question until the response comes in’ is not smart and no longer necessary. This session describes how by leveraging opportunities for asynchronous processing,the perceived responsiveness of our systems is likely to improve. Frequently, the actual scalability is enhanced as well by making much better use of parallel processing power of current CPUs and Virtual Machines and by throttling peak loads by deferring some of the work. This presentation includes the browser (HTML 5, JavaScript, Web Sockets & SSE), middle tier (Java EE, Service Bus) and Database.
Decoding the airspace above you with Java and $7 hardware - Bert Jan SchrijverNLJUG
Software-defined radio (SDR) is een radio-communicatiesysteem waarbij een deel van de componenten niet als hardware maar als software geïmplementeerd zijn. Goedkope digitale TV-ontvangers werken vaak op die manier. Bepaalde chipsets die veel voor dat soort ontvangers gebruikt worden zijn zelfs dusdanig generiek dat je ze softwarematig op een frequentie naar keuze kunt afstemmen. En dat is waar het leuk begint te worden: met de juiste software kun je niet alleen TV ontvangen maar ook portofoons, scheepvaartverkeer, en.. signalen van ADS-B transponders van commercieel vliegverkeer. In deze sessie laat ik zien hoe je met een USB-stick van 7 dollar ADS-B berichten van vliegtuigen kunt ontvangen. Ik leg uit hoe je die data met een Java-applicatie kunt verwerken en kunt visualiseren via de Google maps API. Het eindresultaat is een webapplicatie die een actuele weergave van het vliegverkeer boven Nederland geeft.
Using Docker to Develop, Test and Run Maven Projects - Wouter DanesNLJUG
Docker recently hit version 1.0 and is being picked up around the world by Ops teams to ease running their applications. Docker can also play a big role in easing the development of applications. In this talk I will address how to use docker to: - create a more scalable build environment using jenkins and docker; - integration test your software using maven and docker; - package your software and run the images in different environments.
Kill the mutants and test your tests - Roy van RijnNLJUG
Quis custodiet ipsos custodes? Better known as: *Who watches the watchmen?* We are all writing tests, doing TDD, BDD. We measure the quality of the tests with line coverage or (even better) branch coverage. This gives you a false sense of security. I've seen projects with tests which have 100% branch coverage but not a single assertion! This is where mutation testing helps out. By creating broken mutated instances of your codebase (mutants) this should result in failing unit tests. This way we can verify that slight code changes (like real life bugs) actually break your tests. In this talk I'll explain what mutation testing is and how it works. We'll also compare some Java frameworks (PIT, Jester, Jumble) that enable automatic mutation testing in your continuous build and how you can start doing mutation testing *right now*.
Real-time user interfaces - sosm gewoon makkelijker - Allard BuijzeNLJUG
Real-time user interfaces zijn niets nieuws. Toch zijn ze vaak beperkt tot chatsites en beursapplicaties, waar de use case vereist dat data continu wordt ververst op het scherm. Dataverversing is echter niet de enige reden om voor een real-time user interface te kiezen. Soms is het simpelweg makkelijker. In deze sessie laat Allard zien hoe een combinatie van eenvoudige standaarden en frameworks kan worden ingezet om de beleving van een gebruiker te verhogen. We houden het niet bij de eenvoudige chat-voorbeelden op basis van WebSockets: we gaan in op de technieken die zijn toegepast in de case management tool van een van Nederland's grootste alarmcentrales.
The end of traditional enterprise IT - ING's journey to the next generation I...NLJUG
Peter will tell about building the engineering culture within ING, how IT within ING has changed, and some examples of the skills we need in our IT organization towards the future. IT from becoming an enabler to a driver for the commercial strategy. About ING’s effort to build an IT engineering culture and to give room for innovation. And some take-away’s towards the future of IT engineering (also within financial institutions).
Performance van Java 8 en verder - Jeroen BorgersNLJUG
We weten allemaal dat de grootste verbetering die Java 8 brengt de ondersteuning voor lambda-expressies is. Dit introduceert functioneel programmeren in Java. Door het toevoegen van de Stream API wordt deze verbetering nog groter: iteratie kan nu intern worden afgehandeld door een bibliotheek, je kunt daarmee nu het beginsel "Tell, don’t ask" toepassen op collecties. Je kunt gewoon vertellen dat er een ??functie uitgevoerd moet worden op je verzameling, of vertellen dat dat parallel, door meerdere cores moet gebeuren. Maar wat betekent dit voor de prestaties van onze Java-toepassingen? Kunnen we nu meteen volledig al onze CPU-cores benutten om betere responstijden te krijgen? Hoe werken filter / map / reduce en parallele streams precies intern? Hoe wordt het Fork-Join framework hierin gebruikt? Zijn lambda's sneller dan inner klassen? - Al deze vragen worden beantwoord in deze sessie. Daarnaast introduceert Java 8 meer performance verbeteringen: tiered compilatie, PermGen verwijdering, java.time, Accumulators, Adders en Map verbeteringen. Ten slotte zullen we ook een kijkje nemen in de keuken van de geplande performance verbeteringen voor Java 9: benutting van GPU's, Value Types en arrays 2.0.
Introduction to Reactive with Play and Akka - Markus JuraNLJUG
Modern web applications that are always connected require a new kind of architecture to handle real-time streaming of data. They require a reactive architecture that is event-driven and resilient to failures. But how hard are these applications to actually build? In this presentation we will learn just how easy it can be to build a reactive application using Play and Akka. The application will use Play to asynchronously read from a web service and stream it to the client using Websockets and JSON. In building this sample you will learn the basics of how a Play application is structured and how it integrates with Akka for building reactive applications.
Web-scale op basis van Hadoop en Akka Reactive Streams - Johan Tillema, Rene ...NLJUG
De ontwikkelingen op het gebied van Big data en Web-scale technieken gaan razendsnel. Hoe ontwerp en realiseer je nu architecturen die steeds grotere datastromen kunnen verwerken? Quintor gaat in deze Keynote in op twee belangrijke producten: Hadoop (Storm, HDFS en Map Reduce) en Akka Reactive Streams.
Cultivating the jenkins job jungle with groovy - Patrick van DisselNLJUG
At bol.com we have 70+ applications that are built and supported by 1000+ Jenkins jobs. And that amount is growing by the week. Each set of Continuous Delivery pipelines consists of around 10 jobs which are mostly the same for each application. Maintaining these jobs in Jenkins by hand via the UI is a hell of a job and error-prone at best. What if there was a better way? A way to describe your Continuous Delivery pipelines in code which can be version-controlled, just like your regular code? There is! By using the Jenkins Job DSL plugin and a bit of Groovy scripting. In this code intensive talk you will learn how to significantly mitigate your risk of RSI by distilling your manual job configurations into automated scripts that are readable, easy to maintain and version controlled. tags: Jenkins, Jenkins JobDSL, Groovy
We hebben SOA nu hebben we µServices (micro). Maar lossen die het architectuur probleem echt op? Of zit er in de basis van onze applicaties al iets mis. Als de basis niet goed is produceren we eigenlijk een distributed big ball of mud. We kijken in deze sessie naar - Architectuur (?) - SOLID principals - Klassieke 3 lagen model - Comonent Based Development - Hexagonal Architecture (ports and adapters) We behandelen hoe deze zaken een (rand) voorwaardelijk zijn voor een goeie architectuur en hoe we dit kunnen toepassen om een monolitische applicatie te verbeteren en daarmee de basis te leggen voor een SOA of µServices architectuur.
Modularity and Domain Driven Design; a killer Combination? - Tom de Wolf & St...NLJUG
Applying domain driven design in a modular fashion has implications on how your data is structured and retrieved. A modular domain consists out of multiple loosely coupled sub-domains, each having their own modular schema in the database. How can we migrate and evolve the database schema's separately with each new sub-domain version? And how do we match this with reporting and cross-domain use cases, where aggregation of data from multiple sub-domains is essential? A case study concerning an OSGi-based business platform for automotive services has driven us to solve these challenges without sacrificing the hard-worked-on modularity and loose coupling. In this presentation you will learn how we used Modular Domain Driven Design with OSGi. 'Liquibase' is elevated to become a first class citizen in OSGi by extending multiple sub-domains with automatic database migration capabilities. On the other hand, 'Elasticsearch' is integrated in OSGi to become a separate search module coordinating cross-domain use cases. This unique combination enabled us to satisfy two important customer requirements. Functionally, the software should not be limited by module boundaries to answer business questions. Non-functionally, a future-proof platform is required in which the impact of change is contained and encapsulated in loosely coupled modules.
Apache Wicket: 10 jaar en verder - Martijn DashorstNLJUG
Wicket is een van de levendigste overlevers van de Grote Web Framework Oorlogen uit het midden van de jaren 2000: dit jaar vieren we het 10 jarige jubileum. Toch komt de vraag "Is er een toekomst voor serverside web frameworks" naar boven. In deze presentatie geeft Martijn Dashorst een kort overzicht van de geschiedenis van Wicket. Met een blik op de huidige stand van zaken, geeft hij een overzicht van de huidige gebruikers van Wicket, de toestand van de community en toekomstige release plannen. Het grootste deel van deze sessie zal worden besteed aan de toekomst van Wicket: heeft een component georienteerd Java web framework een toekomst in het tijdperk van native clients en client side JavaScript frameworks? Martijn zal de plannen presenteren om Wicket productiever te maken voor huidige gebruikers, beter te integreren met JavaEE technologieën en veel meer.
Returning the right results - Jettro CoenradieNLJUG
Every website has one, a search box. Did you ever use it? Did you find the right thing? Some websites do a good job, others do a real bad job. What about yours? Installing an (elastic)search service is easy, configuring your index to find the right thing is a lot harder. There are a lof of things that impact the results of searches. Think about the type of data, analysis of the inserted data, the type of queries. In the end the right data is usually found by looking at the highest score of a matched document. What is a score? How is the score calculated? How can the score be influenced? That is what this talk is about, I’ll show you how to use scoring to find the right thing using elasticsearch. So, do you want to improve your websites search box results? Then join me during my talk and together we make it happen.
Reactive programming met Java 8 en Java EE 7 - Martijn BlankestijnNLJUG
Java SE 8 is een grote stap in de evolutie van het Java Platform. Java 8 introduceerde lambda's, een nieuwe Date-Time API en nog veel meer. Completable Futures is een nieuwe Java 8 feature die vaak over het hoofd wordt gezien. Completable Futures (a.k.a. promises) borduren verder op de bestaande Future API en maakt een asynchroon, non-blocking event-driven programmeermodel mogelijk. Deze sessie geeft een inkijk in de Completable Future API en plaatst deze in de context van het toenemend gebruik en interesse voor asynchroniciteit en 'reactive programming'. De live-demo's demonstreren hoe een traditionele service met 'vanilla' Java EE 7 API's zoals JAX-RS en JSON wordt omgevormd tot een 'pipeline' van (parallel uitgevoerde) operaties.
Event-sourced architectures with Akka - Sander MakNLJUG
Different JVM languages lead to different architectural styles. We all know the typical three-tiered architecture and its limitations. Akka and Scala offer event-sourcing. Event-sourced apps model all state changes explicitly and store them immutably. The actor model makes this horizontally scalable. Even better are the functional benefits: a provably correct auditlog and creating new views on past data. This session introduces the event-sourcing concepts. You’ll see how well they map onto actors. To prove this, we show an event-sourced application using Akka. The new Akka Persistence module provides excellent building blocks. Want to learn about the next generation of scalable architectures on the JVM? Check out event-sourcing with Akka!
Key Trends Shaping the Future of Infrastructure.pdfCheryl Hung
Keynote at DIGIT West Expo, Glasgow on 29 May 2024.
Cheryl Hung, ochery.com
Sr Director, Infrastructure Ecosystem, Arm.
The key trends across hardware, cloud and open-source; exploring how these areas are likely to mature and develop over the short and long-term, and then considering how organisations can position themselves to adapt and thrive.
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...DanBrown980551
Do you want to learn how to model and simulate an electrical network from scratch in under an hour?
Then welcome to this PowSyBl workshop, hosted by Rte, the French Transmission System Operator (TSO)!
During the webinar, you will discover the PowSyBl ecosystem as well as handle and study an electrical network through an interactive Python notebook.
PowSyBl is an open source project hosted by LF Energy, which offers a comprehensive set of features for electrical grid modelling and simulation. Among other advanced features, PowSyBl provides:
- A fully editable and extendable library for grid component modelling;
- Visualization tools to display your network;
- Grid simulation tools, such as power flows, security analyses (with or without remedial actions) and sensitivity analyses;
The framework is mostly written in Java, with a Python binding so that Python developers can access PowSyBl functionalities as well.
What you will learn during the webinar:
- For beginners: discover PowSyBl's functionalities through a quick general presentation and the notebook, without needing any expert coding skills;
- For advanced developers: master the skills to efficiently apply PowSyBl functionalities to your real-world scenarios.
Neuro-symbolic is not enough, we need neuro-*semantic*Frank van Harmelen
Neuro-symbolic (NeSy) AI is on the rise. However, simply machine learning on just any symbolic structure is not sufficient to really harvest the gains of NeSy. These will only be gained when the symbolic structures have an actual semantics. I give an operational definition of semantics as “predictable inference”.
All of this illustrated with link prediction over knowledge graphs, but the argument is general.
Essentials of Automations: Optimizing FME Workflows with ParametersSafe Software
Are you looking to streamline your workflows and boost your projects’ efficiency? Do you find yourself searching for ways to add flexibility and control over your FME workflows? If so, you’re in the right place.
Join us for an insightful dive into the world of FME parameters, a critical element in optimizing workflow efficiency. This webinar marks the beginning of our three-part “Essentials of Automation” series. This first webinar is designed to equip you with the knowledge and skills to utilize parameters effectively: enhancing the flexibility, maintainability, and user control of your FME projects.
Here’s what you’ll gain:
- Essentials of FME Parameters: Understand the pivotal role of parameters, including Reader/Writer, Transformer, User, and FME Flow categories. Discover how they are the key to unlocking automation and optimization within your workflows.
- Practical Applications in FME Form: Delve into key user parameter types including choice, connections, and file URLs. Allow users to control how a workflow runs, making your workflows more reusable. Learn to import values and deliver the best user experience for your workflows while enhancing accuracy.
- Optimization Strategies in FME Flow: Explore the creation and strategic deployment of parameters in FME Flow, including the use of deployment and geometry parameters, to maximize workflow efficiency.
- Pro Tips for Success: Gain insights on parameterizing connections and leveraging new features like Conditional Visibility for clarity and simplicity.
We’ll wrap up with a glimpse into future webinars, followed by a Q&A session to address your specific questions surrounding this topic.
Don’t miss this opportunity to elevate your FME expertise and drive your projects to new heights of efficiency.
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf91mobiles
91mobiles recently conducted a Smart TV Buyer Insights Survey in which we asked over 3,000 respondents about the TV they own, aspects they look at on a new TV, and their TV buying preferences.
Elevating Tactical DDD Patterns Through Object CalisthenicsDorra BARTAGUIZ
After immersing yourself in the blue book and its red counterpart, attending DDD-focused conferences, and applying tactical patterns, you're left with a crucial question: How do I ensure my design is effective? Tactical patterns within Domain-Driven Design (DDD) serve as guiding principles for creating clear and manageable domain models. However, achieving success with these patterns requires additional guidance. Interestingly, we've observed that a set of constraints initially designed for training purposes remarkably aligns with effective pattern implementation, offering a more ‘mechanical’ approach. Let's explore together how Object Calisthenics can elevate the design of your tactical DDD patterns, offering concrete help for those venturing into DDD for the first time!
UiPath Test Automation using UiPath Test Suite series, part 3DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 3. In this session, we will cover desktop automation along with UI automation.
Topics covered:
UI automation Introduction,
UI automation Sample
Desktop automation flow
Pradeep Chinnala, Senior Consultant Automation Developer @WonderBotz and UiPath MVP
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024Tobias Schneck
As AI technology is pushing into IT I was wondering myself, as an “infrastructure container kubernetes guy”, how get this fancy AI technology get managed from an infrastructure operational view? Is it possible to apply our lovely cloud native principals as well? What benefit’s both technologies could bring to each other?
Let me take this questions and provide you a short journey through existing deployment models and use cases for AI software. On practical examples, we discuss what cloud/on-premise strategy we may need for applying it to our own infrastructure to get it to work from an enterprise perspective. I want to give an overview about infrastructure requirements and technologies, what could be beneficial or limiting your AI use cases in an enterprise environment. An interactive Demo will give you some insides, what approaches I got already working for real.
Accelerate your Kubernetes clusters with Varnish CachingThijs Feryn
A presentation about the usage and availability of Varnish on Kubernetes. This talk explores the capabilities of Varnish caching and shows how to use the Varnish Helm chart to deploy it to Kubernetes.
This presentation was delivered at K8SUG Singapore. See https://feryn.eu/presentations/accelerate-your-kubernetes-clusters-with-varnish-caching-k8sug-singapore-28-2024 for more details.
Securing your Kubernetes cluster_ a step-by-step guide to success !KatiaHIMEUR1
Today, after several years of existence, an extremely active community and an ultra-dynamic ecosystem, Kubernetes has established itself as the de facto standard in container orchestration. Thanks to a wide range of managed services, it has never been so easy to set up a ready-to-use Kubernetes cluster.
However, this ease of use means that the subject of security in Kubernetes is often left for later, or even neglected. This exposes companies to significant risks.
In this talk, I'll show you step-by-step how to secure your Kubernetes cluster for greater peace of mind and reliability.
5. Let me introduce myself…
• Bas W. Knopper
• Dutch
• Java Developer
• NCIM (IT Services Company)
• 10 years Java exp
• JavaOne 2013 Speaker
• AI enthousiast
• Soft spot for Evolutionary Algorithms
Slide 5 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
6. Questions
• A lot of ground to cover in 45 mins.
• Ask questions anytime!
• But don’t take it personal if I have to move on…
• We’ll discuss it over a <insert beverage of choice>!
• If time permits it
• Question round at the end as well
Slide 6 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
7. What I would like to accomplish…
• Interest
• Understanding
• How & when
• Add to toolbox
• Attention
#jfall #EvolutionaryAlgorithms @BWKnopper
Slide 7 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
8. NASA
• Space Technology 5 mission
• launched March 22, 2006, and completed June 20, 2006
• Three full service 25-kilogram-class spacecraft
Slide 8 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
9. NASA Continued
• Needs even smaller antenna
• That still functions according to spec
• Need for solution that’s not easy to engineer
• So they used an EA that made these:
Slide 9 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
10. Slide 10 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
11. Recap
• Powerful example
• Evolving object
• First evolved object to travel through space
• How?
Slide 11 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
12. Evolution - “Survival of the fittest”
Finite
Resources
Lifeforms
with a basic
instinct
towards
Reproduction
Natural
Selection
Slide 12 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
15. From evolution to problem solving
Environment Problem
Individual
Slide 15 of 68
Candidate Solution
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
16. Puzzle solving time!
• More down to earth example
• Travelling Salesman Problem
Slide 16 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
17. Travelling Salesman Problem
• Given n cities
• n = number of cities to visit
• Find (optimal) route for visiting all cities
• Visit every city only once
• Return to origin city
• Search space is huge
• For 30 cities there are 30! 10^32 possible routes
That’s 100.000.000.000.000.000.000.000.000.000.000 possible routes!
Brute force might not be the best solution…
Slide 17 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
18. Puzzle solving time!
• More down to earth example
• Travelling Salesman Problem
• Use case to show you
• Evolutionary Algorithm Design
• Plain Java Code
• Demo
Slide 18 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
19. EA Algorithm (Pseudocode)
INITIALISE population with random candidate solutions;
EVALUATE each candidate;
WHILE ( TERMINATION CONDITION is not satisfied ) {
1 SELECT parents;
2 RECOMBINE pairs of parents;
3 MUTATE the resulting offspring;
4 EVALUATE new candidates;
5 SELECT individuals for the next generation;
}
Slide 19 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
20. EA Algorithm (Pseudocode)
INITIALISE population with random candidate solutions;
EVALUATE each candidate;
WHILE ( TERMINATION CONDITION is not satisfied ) {
1 SELECT parents;
2 RECOMBINE pairs of parents;
3 MUTATE the resulting offspring;
4 EVALUATE new candidates;
5 SELECT individuals for the next generation;
}
Slide 20 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
21. Candidate Solution - Representation
• n = 6
• Label cities 1,2,3,4,5,6
• And base city 1
• Candidate Solution
• Signifying the route
• for n = 10
• Enables
1 2 4 3 6 5 1
1 2 8 6 5 3 7 4 9 10 1
• Calculating distance (fitness function)
• Mutation
• Recombination
Slide 21 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
22. EA Algorithm (Pseudocode)
INITIALISE population with random candidate solutions;
EVALUATE each candidate;
WHILE ( TERMINATION CONDITION is not satisfied ) {
1 SELECT parents;
2 RECOMBINE pairs of parents;
3 MUTATE the resulting offspring;
4 EVALUATE new candidates;
5 SELECT individuals for the next generation;
}
Slide 22 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
23. EA Algorithm (Pseudocode)
INITIALISE population with random candidate solutions;
EVALUATE each candidate;
WHILE ( TERMINATION CONDITION is not satisfied ) {
1 SELECT parents;
2 RECOMBINE pairs of parents;
3 MUTATE the resulting offspring;
4 EVALUATE new candidates;
5 SELECT individuals for the next generation;
}
Slide 23 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
25. /**
* Calculates the total distance of the whole route and stores it as this
* candidate solution's fitness
*/
private void calculateFitness() {
/* initialize total distance */
double totalDistance = 0;
/*
* For all Cities in the route (except the last one) get the distance between this
* City and the next and add it to the totalDistance
*/
for (int i = 0; i < route.size() - 1; i++) {
City city = route.get(i);
City nextCity = route.get(i + 1);
totalDistance += city.calculateDistance(nextCity);
}
/* store totalDistance as this candidate solution's fitness */
this.fitness = totalDistance;
}
Slide 25 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
26. /**
* Calculates the total distance of the whole route and stores it as this
* candidate solution's fitness
*/
private void calculateFitness() {
/* initialize total distance */
double totalDistance = 0;
/*
* For all Cities in the route (except the last one) get the distance between this
* City and the next and add it to the totalDistance
*/
for (int i = 0; i < route.size() - 1; i++) {
}
/* store totalDistance as this candidate solution's fitness */
this.fitness = totalDistance;
}
Slide 26 of 68
City city = route.get(i);
City nextCity = route.get(i + 1);
totalDistance += city.calculateDistance(nextCity);
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
27. /**
* Calculates the total distance of the whole route and stores it as this
* candidate solution's fitness
*/
private void calculateFitness() {
/* initialize total distance */
double totalDistance = 0;
/*
* For all Cities in the route (except the last one) get the distance between this
* City and the next and add it to the totalDistance
*/
for (int i = 0; i < route.size() - 1; i++) {
}
/* store totalDistance as this candidate solution's fitness */
this.fitness = totalDistance;
}
Slide 27 of 68
City city = route.get(i);
City nextCity = route.get(i + 1);
totalDistance += city.calculateDistance(nextCity);
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
28. /**
* Calculates the total distance of the whole route and stores it as this
* candidate solution's fitness
*/
private void calculateFitness() {
/* initialize total distance */
double totalDistance = 0;
/*
* For all Cities in the route (except the last one) get the distance between this
* City and the next and add it to the totalDistance
*/
for (int i = 0; i < route.size() - 1; i++) {
}
/* store totalDistance as this candidate solution's fitness */
this.fitness = totalDistance;
}
Slide 28 of 68
City city = route.get(i);
City nextCity = route.get(i + 1);
totalDistance += city.calculateDistance(nextCity);
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
29. /**
* Calculates the total distance of the whole route and stores it as this
* candidate solution's fitness
*/
private void calculateFitness() {
/* initialize total distance */
double totalDistance = 0;
/*
* For all Cities in the route (except the last one) get the distance between this
* City and the next and add it to the totalDistance
*/
for (int i = 0; i < route.size() - 1; i++) {
}
/* store totalDistance as this candidate solution's fitness */
this.fitness = totalDistance;
}
Slide 29 of 68
City city = route.get(i);
City nextCity = route.get(i + 1);
totalDistance += city.calculateDistance(nextCity);
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
30. /**
* Calculates the total distance of the whole route and stores it as this
* candidate solution's fitness
*/
private void calculateFitness() {
/* initialize total distance */
double totalDistance = 0;
/*
* For all Cities in the route (except the last one) get the distance between this
* City and the next and add it to the totalDistance
*/
for (int i = 0; i < route.size() - 1; i++) {
}
/* store totalDistance as this candidate solution's fitness */
this.fitness = totalDistance;
}
Slide 30 of 68
City city = route.get(i);
City nextCity = route.get(i + 1);
totalDistance += city.calculateDistance(nextCity);
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
31. /**
* Calculates the total distance of the whole route and stores it as this
* candidate solution's fitness
*/
private void calculateFitness() {
/* initialize total distance */
double totalDistance = 0;
/*
* For all Cities in the route (except the last one) get the distance between this
* City and the next and add it to the totalDistance
*/
for (int i = 0; i < route.size() - 1; i++) {
}
/* store totalDistance as this candidate solution's fitness */
this.fitness = totalDistance;
}
Slide 31 of 68
City city = route.get(i);
City nextCity = route.get(i + 1);
totalDistance += city.calculateDistance(nextCity);
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
32. EA Algorithm (Pseudocode)
INITIALISE population with random candidate solutions;
EVALUATE each candidate;
WHILE ( TERMINATION CONDITION is not satisfied ) {
1 SELECT parents;
2 RECOMBINE pairs of parents;
3 MUTATE the resulting offspring;
4 EVALUATE new candidates;
5 SELECT individuals for the next generation;
}
Slide 32 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
33. Termination Condition
• EA’s are stochastic
• May never find optimum
• Combination
• Time
• Max number of runs (generations)
• Sure to terminate
• Either:
• Fitness threshold
• Fitness improvement remains under a threshold over runs
Slide 33 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
34. EA Algorithm (Pseudocode)
INITIALISE population with random candidate solutions;
EVALUATE each candidate;
WHILE ( TERMINATION CONDITION is not satisfied ) {
1 SELECT parents;
2 RECOMBINE pairs of parents;
3 MUTATE the resulting offspring;
4 EVALUATE new candidates;
5 SELECT individuals for the next generation;
}
Slide 34 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
35. Parent Selection
• Where x is the number of parents:
• Pick x best
• Random x
• Best x out of random y
• In our example:
• Best x out of random y
Slide 35 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
36. private List<CandidateSolution> parentSelection() {
List<CandidateSolution> tempPopulation = new ArrayList<>(population);
List<CandidateSolution> randomCandidates = new ArrayList<>();
/* create parent pool */
for(int i = 0; i < parentPoolSize; i++)
{
/* select a random candidate solution from the temp population */
int randomlySelectedIndex = random.nextInt(tempPopulation.size());
CandidateSolution randomSelection = tempPopulation.get(randomlySelectedIndex);
randomCandidates.add(randomSelection);
/* delete the candidate from the temp population, so we can't pick it again */
tempPopulation.remove(randomlySelectedIndex);
}
/* Sort the population so that the best candidates are up front */
Collections.sort(randomCandidates);
/* return a list with size parentSelectionSize with the best CandidateSolutions */
return randomCandidates.subList(0, parentSelectionSize);
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
}
Slide 36 of 68
37. private List<CandidateSolution> parentSelection() {
List<CandidateSolution> tempPopulation = new ArrayList<>(population);
List<CandidateSolution> randomCandidates = new ArrayList<>();
/* create parent pool */
for(int i = 0; i < parentPoolSize; i++)
{
/* select a random candidate solution from the temp population */
int randomlySelectedIndex = random.nextInt(tempPopulation.size());
CandidateSolution randomSelection = tempPopulation.get(randomlySelectedIndex);
randomCandidates.add(randomSelection);
/* delete the candidate from the temp population, so we can't pick it again */
tempPopulation.remove(randomlySelectedIndex);
}
/* Sort the population so that the best candidates are up front */
Collections.sort(randomCandidates);
/* return a list with size parentSelectionSize with the best CandidateSolutions */
return randomCandidates.subList(0, parentSelectionSize);
Slide 37 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
}
38. private List<CandidateSolution> parentSelection() {
List<CandidateSolution> tempPopulation = new ArrayList<>(population);
List<CandidateSolution> randomCandidates = new ArrayList<>();
/* create parent pool */
for(int i = 0; i < parentPoolSize; i++)
{
/* select a random candidate solution from the temp population */
int randomlySelectedIndex = random.nextInt(tempPopulation.size());
CandidateSolution randomSelection = tempPopulation.get(randomlySelectedIndex);
randomCandidates.add(randomSelection);
/* delete the candidate from the temp population, so we can't pick it again */
tempPopulation.remove(randomlySelectedIndex);
}
/* Sort the population so that the best candidates are up front */
Collections.sort(randomCandidates);
/* return a list with size parentSelectionSize with the best CandidateSolutions */
return randomCandidates.subList(0, parentSelectionSize);
Slide 38 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
}
39. private List<CandidateSolution> parentSelection() {
List<CandidateSolution> tempPopulation = new ArrayList<>(population);
List<CandidateSolution> randomCandidates = new ArrayList<>();
/* create parent pool */
for(int i = 0; i < parentPoolSize; i++)
{
/* select a random candidate solution from the temp population */
int randomlySelectedIndex = random.nextInt(tempPopulation.size());
CandidateSolution randomSelection = tempPopulation.get(randomlySelectedIndex);
randomCandidates.add(randomSelection);
/* delete the candidate from the temp population, so we can't pick it again */
tempPopulation.remove(randomlySelectedIndex);
}
/* Sort the population so that the best candidates are up front */
Collections.sort(randomCandidates);
/* return a list with size parentSelectionSize with the best CandidateSolutions */
return randomCandidates.subList(0, parentSelectionSize);
Slide 39 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
}
40. private List<CandidateSolution> parentSelection() {
List<CandidateSolution> tempPopulation = new ArrayList<>(population);
List<CandidateSolution> randomCandidates = new ArrayList<>();
/* create parent pool */
for(int i = 0; i < parentPoolSize; i++)
{
/* select a random candidate solution from the temp population */
int randomlySelectedIndex = random.nextInt(tempPopulation.size());
CandidateSolution randomSelection = tempPopulation.get(randomlySelectedIndex);
randomCandidates.add(randomSelection);
/* delete the candidate from the temp population, so we can't pick it again */
tempPopulation.remove(randomlySelectedIndex);
}
/* Sort the population so that the best candidates are up front */
Collections.sort(randomCandidates);
/* return a list with size parentSelectionSize with the best CandidateSolutions */
return randomCandidates.subList(0, parentSelectionSize);
Slide 40 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
}
41. private List<CandidateSolution> parentSelection() {
List<CandidateSolution> tempPopulation = new ArrayList<>(population);
List<CandidateSolution> randomCandidates = new ArrayList<>();
/* create parent pool */
for(int i = 0; i < parentPoolSize; i++)
{
/* select a random candidate solution from the temp population */
int randomlySelectedIndex = random.nextInt(tempPopulation.size());
CandidateSolution randomSelection = tempPopulation.get(randomlySelectedIndex);
randomCandidates.add(randomSelection);
/* delete the candidate from the temp population, so we can't pick it again */
tempPopulation.remove(randomlySelectedIndex);
}
/* Sort the population so that the best candidates are up front */
Collections.sort(randomCandidates);
/* return a list with size parentSelectionSize with the best CandidateSolutions */
return randomCandidates.subList(0, parentSelectionSize);
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
}
Slide 41 of 68
42. private List<CandidateSolution> parentSelection() {
List<CandidateSolution> tempPopulation = new ArrayList<>(population);
List<CandidateSolution> randomCandidates = new ArrayList<>();
/* create parent pool */
for(int i = 0; i < parentPoolSize; i++)
{
/* select a random candidate solution from the temp population */
int randomlySelectedIndex = random.nextInt(tempPopulation.size());
CandidateSolution randomSelection = tempPopulation.get(randomlySelectedIndex);
randomCandidates.add(randomSelection);
/* delete the candidate from the temp population, so we can't pick it again */
tempPopulation.remove(randomlySelectedIndex);
}
/* Sort the population so that the best candidates are up front */
Collections.sort(randomCandidates);
/* return a list with size parentSelectionSize with the best CandidateSolutions */
return randomCandidates.subList(0, parentSelectionSize);
Slide 42 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
}
43. private List<CandidateSolution> parentSelection() {
List<CandidateSolution> tempPopulation = new ArrayList<>(population);
List<CandidateSolution> randomCandidates = new ArrayList<>();
/* create parent pool */
for(int i = 0; i < parentPoolSize; i++)
{
/* select a random candidate solution from the temp population */
int randomlySelectedIndex = random.nextInt(tempPopulation.size());
CandidateSolution randomSelection = tempPopulation.get(randomlySelectedIndex);
randomCandidates.add(randomSelection);
/* delete the candidate from the temp population, so we can't pick it again */
tempPopulation.remove(randomlySelectedIndex);
}
/* Sort the population so that the best candidates are up front */
Collections.sort(randomCandidates);
/* return a list with size parentSelectionSize with the best CandidateSolutions */
return randomCandidates.subList(0, parentSelectionSize);
Slide 43 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
}
44. EA Algorithm (Pseudocode)
INITIALISE population with random candidate solutions;
EVALUATE each candidate;
WHILE ( TERMINATION CONDITION is not satisfied ) {
1 SELECT parents;
2 RECOMBINE pairs of parents;
3 MUTATE the resulting offspring;
4 EVALUATE new candidates;
5 SELECT individuals for the next generation;
}
Slide 44 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
45. Recombination
• In our example:
• half-half does not work
• “Cut-and-crossfill”
1 2 4 3 5 6 1
1 3 6 5 4 2 1
1 2 4 5 3 6 1
1 3 6 5 2 4 1
Slide 45 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
46. public List<CandidateSolution> recombine(CandidateSolution otherParent) {
/* get routes of both parents */
List<City> parentRoute1 = getRoute();
List<City> parentRoute2 = otherParent.getRoute();
/* initialize the routes for the children */
List<City> childRoute1 = new ArrayList<City>();
List<City> childRoute2 = new ArrayList<City>();
/* randomize cutIndex for "cross-and-fill point" */
int cutIndex = new Random().nextInt(parentRoute1.size());
/* copy the first part of the parents cut into the children */
childRoute1.addAll(parentRoute1.subList(0, cutIndex));
childRoute2.addAll(parentRoute2.subList(0, cutIndex));
/* perform crossfill for both children */
crossFill(childRoute1, parentRoute2, cutIndex);
crossFill(childRoute2, parentRoute1, cutIndex);
/* create new children using the new children routes */
CandidateSolution child1 = new CandidateSolution(childRoute1);
CandidateSolution child2 = new CandidateSolution(childRoute2);
/* put the children in a list and return it (omitted for layout reasons) */
}
Slide 46 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
47. public List<CandidateSolution> recombine(CandidateSolution otherParent) {
/* get routes of both parents */
List<City> parentRoute1 = getRoute();
List<City> parentRoute2 = otherParent.getRoute();
/* initialize the routes for the children */
List<City> childRoute1 = new ArrayList<City>();
List<City> childRoute2 = new ArrayList<City>();
/* randomize cutIndex for "cross-and-fill point" */
int cutIndex = new Random().nextInt(parentRoute1.size());
/* copy the first part of the parents cut into the children */
childRoute1.addAll(parentRoute1.subList(0, cutIndex));
childRoute2.addAll(parentRoute2.subList(0, cutIndex));
/* perform crossfill for both children */
crossFill(childRoute1, parentRoute2, cutIndex);
crossFill(childRoute2, parentRoute1, cutIndex);
/* create new children using the new children routes */
CandidateSolution child1 = new CandidateSolution(childRoute1);
CandidateSolution child2 = new CandidateSolution(childRoute2);
/* put the children in a list and return it (omitted for layout reasons) */
}
Slide 47 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
48. public List<CandidateSolution> recombine(CandidateSolution otherParent) {
/* get routes of both parents */
List<City> parentRoute1 = getRoute();
List<City> parentRoute2 = otherParent.getRoute();
/* initialize the routes for the children */
List<City> childRoute1 = new ArrayList<City>();
List<City> childRoute2 = new ArrayList<City>();
/* randomize cutIndex for "cross-and-fill point" */
int cutIndex = new Random().nextInt(parentRoute1.size());
/* copy the first part of the parents cut into the children */
childRoute1.addAll(parentRoute1.subList(0, cutIndex));
childRoute2.addAll(parentRoute2.subList(0, cutIndex));
/* perform crossfill for both children */
crossFill(childRoute1, parentRoute2, cutIndex);
crossFill(childRoute2, parentRoute1, cutIndex);
/* create new children using the new children routes */
CandidateSolution child1 = new CandidateSolution(childRoute1);
CandidateSolution child2 = new CandidateSolution(childRoute2);
/* put the children in a list and return it (omitted for layout reasons) */
}
Slide 48 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
49. public List<CandidateSolution> recombine(CandidateSolution otherParent) {
/* get routes of both parents */
List<City> parentRoute1 = getRoute();
List<City> parentRoute2 = otherParent.getRoute();
/* initialize the routes for the children */
List<City> childRoute1 = new ArrayList<City>();
List<City> childRoute2 = new ArrayList<City>();
/* randomize cutIndex for "cross-and-fill point" */
int cutIndex = new Random().nextInt(parentRoute1.size());
/* copy the first part of the parents cut into the children */
childRoute1.addAll(parentRoute1.subList(0, cutIndex));
childRoute2.addAll(parentRoute2.subList(0, cutIndex));
/* perform crossfill for both children */
crossFill(childRoute1, parentRoute2, cutIndex);
crossFill(childRoute2, parentRoute1, cutIndex);
/* create new children using the new children routes */
CandidateSolution child1 = new CandidateSolution(childRoute1);
CandidateSolution child2 = new CandidateSolution(childRoute2);
/* put the children in a list and return it (omitted for layout reasons) */
}
Slide 49 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
50. public List<CandidateSolution> recombine(CandidateSolution otherParent) {
/* get routes of both parents */
List<City> parentRoute1 = getRoute();
List<City> parentRoute2 = otherParent.getRoute();
/* initialize the routes for the children */
List<City> childRoute1 = new ArrayList<City>();
List<City> childRoute2 = new ArrayList<City>();
/* randomize cutIndex for "cross-and-fill point" */
int cutIndex = new Random().nextInt(parentRoute1.size());
/* copy the first part of the parents cut into the children */
childRoute1.addAll(parentRoute1.subList(0, cutIndex));
childRoute2.addAll(parentRoute2.subList(0, cutIndex));
/* perform crossfill for both children */
crossFill(childRoute1, parentRoute2, cutIndex);
crossFill(childRoute2, parentRoute1, cutIndex);
/* create new children using the new children routes */
CandidateSolution child1 = new CandidateSolution(childRoute1);
CandidateSolution child2 = new CandidateSolution(childRoute2);
/* put the children in a list and return it (omitted for layout reasons) */
}
Slide 50 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
51. public List<CandidateSolution> recombine(CandidateSolution otherParent) {
/* get routes of both parents */
List<City> parentRoute1 = getRoute();
List<City> parentRoute2 = otherParent.getRoute();
/* initialize the routes for the children */
List<City> childRoute1 = new ArrayList<City>();
List<City> childRoute2 = new ArrayList<City>();
/* randomize cutIndex for "cross-and-fill point" */
int cutIndex = new Random().nextInt(parentRoute1.size());
/* copy the first part of the parents cut into the children */
childRoute1.addAll(parentRoute1.subList(0, cutIndex));
childRoute2.addAll(parentRoute2.subList(0, cutIndex));
/* perform crossfill for both children */
crossFill(childRoute1, parentRoute2, cutIndex);
crossFill(childRoute2, parentRoute1, cutIndex);
/* create new children using the new children routes */
CandidateSolution child1 = new CandidateSolution(childRoute1);
CandidateSolution child2 = new CandidateSolution(childRoute2);
/* put the children in a list and return it (omitted for layout reasons) */
}
Slide 51 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
52. /**
* Check the rest of the route in the crossing parent and add the cities
* that are not yet in the child (in the order of the route of the crossing
* parent)
*/
private void crossFill(List<City> childRoute, List<City> parentRoute, int cutIndex) {
/* traverse the parent route from the cut index on and add every city not yet in the child to the child */
for (int i = cutIndex; i < parentRoute.size(); i++) {
City nextCityOnRoute = parentRoute.get(i);
if (!childRoute.contains(nextCityOnRoute)) {
childRoute.add(nextCityOnRoute);
}
}
/* traverse the parent route from the start of the route and add every city not yet in the child to the child */
for (int i = 0; i < cutIndex; i++) {
City nextCityOnRoute = parentRoute.get(i);
if (!childRoute.contains(nextCityOnRoute)) {
}
}
Slide 52 of 68
1 3 6 5 2 4 1
1 3 6 5 2 4 1
childRoute.add(nextCityOnRoute);
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
}
53. EA Algorithm (Pseudocode)
INITIALISE population with random candidate solutions;
EVALUATE each candidate;
WHILE ( TERMINATION CONDITION is not satisfied ) {
1 SELECT parents;
2 RECOMBINE pairs of parents;
3 MUTATE the resulting offspring;
4 EVALUATE new candidates;
5 SELECT individuals for the next generation;
}
Slide 53 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
54. Mutation
• Change of nr won’t work
• Infeasible candidate solution
• Swap to the rescue!
1 26 2 4 3 5 6 26 1
Slide 54 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
55. /**
* Mutates the current individual by swapping two random cities in its
* route.
*/
public void mutate() { 1 2 4 3 5 6 1
Random random = new Random();
/* randomly select two indices in the route */
int indexFirstCity = random.nextInt(route.size());
int indexSecondCity = random.nextInt(route.size());
/* Make sure they are different */
while (indexFirstCity == indexSecondCity) {
}
/* retrieve the Cities on the given indices */
City firstCity = route.get(indexFirstCity);
City secondCity = route.get(indexSecondCity);
/* Changer! */
route.set(indexFirstCity, secondCity);
route.set(indexSecondCity, firstCity);
}
Slide 55 of 68
1 2 4 3 5 6 1
1 6 4 3 5 2 1
indexSecondCity = random.nextInt(route.size());
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
56. EA Algorithm (Pseudocode)
INITIALISE population with random candidate solutions;
EVALUATE each candidate;
WHILE ( TERMINATION CONDITION is not satisfied ) {
1 SELECT parents;
2 RECOMBINE pairs of parents;
3 MUTATE the resulting offspring;
4 EVALUATE new candidates;
5 SELECT individuals for the next generation;
}
Slide 56 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
57. EA Algorithm (Pseudocode)
INITIALISE population with random candidate solutions;
EVALUATE each candidate;
WHILE ( TERMINATION CONDITION is not satisfied ) {
1 SELECT parents;
2 RECOMBINE pairs of parents;
3 MUTATE the resulting offspring;
4 EVALUATE new candidates;
5 SELECT individuals for the next generation;
}
Slide 57 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
58. Survivor Selection
• Replacement Strategy
• ReplaceWorst
Slide 58 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
59. /**
* Selects the survivors by removing the worst candidate
* solutions from the list, so we have the original
* population size again
*/
private void selectSurvivors() {
Collections.sort(population);
population = population.subList(0, populationSize);
}
Slide 59 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
60. Tuning…
• Mutation probability
• Population size
• Nr of offspring
• Termination condition (# runs or fitness)
• Parent selection
• Survival selection
• Initialisation
• Random
Slide 60 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
61. EA Behavior
Figures from “Introduction to Evolutionary Computing” by A.E. Eiben & J.E. Smith (Springer)
Slide 61 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
62. Demo!
• Used NASA World Wind to map route on
• https://github.com/bknopper/TSPEvolutionaryAlgorithmsDemo.git
Slide 62 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
63. Java Frameworks & API’s
http://watchmaker.uncommons.org http://jgap.sourceforge.net/
Slide 63 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
65. With great power comes great responsibility
• Can I find a solution using a brute-force approach?
• (within a reasonable amount of time)
• Am I facing an optimization or search problem?
• Can I encode a candidate solution to the problem?
• Representation possible?
• Can I determine the fitness of a candidate solution?
Slide 65 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
66. “A wise man can learn more from a foolish question
than a fool can learn from a wise answer”
– Bruce Lee
Slide 66 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
67. Additional questions?
• Contact me on @BWKnopper
• Google it!
• There’s lots to find…
• Papers
• Demo’s
• Aforementioned Frameworks/API’s
Slide 67 of 68
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
68. Thank you.
That’s all folks!
Slide 68 of 68
Have a great day at J-Fall!
b.knopper@ncim.nl @BWKnopper github.com/bknopper Passion for Technology
Editor's Notes
Aan het eind: Imagine this going on for a while. There could be individuals that have a great fitness because of traits we didn’t even know could exist. This is impossible to simulate in real life. A computer though… 10000 generations in a few hours is not so hard… Which brings us to Evolutionary Algorithms
Aan het eind: Imagine this going on for a while. There could be individuals that have a great fitness because of traits we didn’t even know could exist. This is impossible to simulate in real life. A computer though… 10000 generations in a few hours is not so hard… Which brings us to Evolutionary Algorithms