Open BEAGLE: A New Versatile C++ Framework for Evolutionary Computation

Christian Gagné, Marc Parizeau

Abstract

Open BEAGLE is a high-performance, open-source C++ framework designed to provide a generic and extensible environment for Evolutionary Computation (EC). By leveraging advanced object-oriented design patterns, it allows researchers to easily implement and switch between different EC flavors, such as Genetic Algorithms (GA) and Genetic Programming (GP), within a unified architecture. This paper details the framework's hierarchical design, its core components, and its utility in solving standard EC benchmarks.

Introduction

In the early 2000s, researchers in Evolutionary Computation (EC) faced a fragmented software landscape. Existing tools were often specialized for a single algorithm type, required complex compile-time configurations, or suffered from the performance overhead of high-level languages like Java. Open BEAGLE was introduced to bridge these gaps, offering a versatile framework that is efficient (C++), user-friendly (automated memory management), and highly generic.

Architectural Overview

Open BEAGLE is built on a three-level hierarchical architecture that ensures both portability and extensibility. This structure allows the core engine to remain agnostic of the specific evolutionary paradigm being used.

The hierarchical architecture of Open BEAGLE, illustrating the progression from the C++ Standard Template Library to specialized EC frameworks.
  1. Object-Oriented Foundations: This base layer extends C++ with features like a custom smart pointer system (Handle) for automatic garbage collection and generic containers called "Bags." It also integrates XML I/O for flexible configuration and state-saving.
  2. Generic EC Framework: The "engine room" of the system, defining the structure of evolving populations and the logic for the evolution process.
  3. Specialized Frameworks: Top-level modules that implement specific paradigms, such as GA and GP, by providing specialized operators and data structures.

Core Components and Logic

The framework maintains a strict separation between data structures and algorithmic logic. This separation is key to its flexibility, allowing users to modify the evolutionary process without altering the underlying population data.

The relationship between data structures (Vivarium, Deme, Individual) and the algorithmic Evolver in the Open BEAGLE framework.

Data Structures

The population is organized into a hierarchy: a Vivarium contains multiple Demes (sub-populations), which consist of Individuals, which in turn contain one or more Genotypes. This recursive structure supports complex multi-genotype evolution.

The Evolver and Operators

The evolution logic is encapsulated in an "Evolver" using the Strategy design pattern. The Evolver executes a sequence of "Operators" (e.g., selection, crossover, mutation). By separating these into "bootstrap" (initialization) and "main-loop" sets, the framework allows users to change the entire behavior of the algorithm—such as switching from a generational to a steady-state GA—simply by modifying a configuration file.

Key Design Principles

  • Dynamic Polymorphism: Unlike frameworks that rely heavily on C++ templates (static polymorphism), Open BEAGLE favors inheritance. This choice improves code readability and ease of modification while maintaining the high performance required for EC.
  • Robustness through "Milestones": Built-in mechanisms periodically save the state of evolution to XML files. These "milestones" allow for automatic restarts if a long-running process is interrupted.
  • Standards Compliance: The software is fully compliant with ANSI/ISO C++ standards and the Standard Template Library (STL), ensuring high portability across different operating systems.

Evaluation and Results

The framework's utility was evaluated using a standard benchmark: Classic Symbolic Regression. The goal was to evolve a mathematical expression for the polynomial $p(x) = x^4 + x^3 + x^2 + x$ based on 20 sampled points.

Results demonstrated high code efficiency; a complete GP application for this problem could be implemented in fewer than 100 lines of code. By abstracting memory management and population tracking, Open BEAGLE allows researchers to focus solely on defining problem-specific primitives and fitness functions.

Future Work

While version 1.0 established a strong foundation, the authors identified several areas for expansion, including the implementation of Evolutionary Strategies (ES), the development of "Distributed BEAGLE" for cluster computing, and a web-based visualization tool to monitor evolution statistics in real-time.

Summary updated

BibTeX
@inproceedings{gagne2002open,
  author = {Christian Gagné and Marc Parizeau},
  title = {{Open BEAGLE: A New Versatile C++ Framework for Evolutionary Computation}},
  booktitle = {GECCO Late Breaking Papers},
  year = {2002},
}
Figure