Compare commits
No commits in common. "master" and "fix/HVrange" have entirely different histories.
master
...
fix/HVrang
47
.github/workflows/build_ubuntu_debug.yml
vendored
|
|
@ -1,47 +0,0 @@
|
||||||
name: Build Debug (Ubuntu)
|
|
||||||
on: [push, pull_request]
|
|
||||||
|
|
||||||
env:
|
|
||||||
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
|
|
||||||
BUILD_TYPE: Debug
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
build:
|
|
||||||
# The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac.
|
|
||||||
# You can convert this to a matrix build if you need cross-platform coverage.
|
|
||||||
# See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
strategy:
|
|
||||||
matrix:
|
|
||||||
compiler: [g++-10, g++-9, g++-8, g++-7, clang-6, clang-7, clang-8, clang-9, clang-10, clang-11, clang-12]
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: Caching objects
|
|
||||||
id: cache-objects
|
|
||||||
uses: actions/cache@v4
|
|
||||||
with:
|
|
||||||
path: ~/.cache/ccache
|
|
||||||
key: ${{ runner.os }}-${{env.BUILD_TYPE}}-${{ matrix.compiler }}-objects
|
|
||||||
|
|
||||||
- name: Install Dependencies
|
|
||||||
shell: bash
|
|
||||||
run: |
|
|
||||||
sudo apt-get install libeigen3-dev libboost-dev
|
|
||||||
|
|
||||||
- name: Configure
|
|
||||||
# Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make.
|
|
||||||
# See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type
|
|
||||||
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DEDO=ON -DEDO_USE_LIB=Eigen3 -DENABLE_CMAKE_EXAMPLE=ON -DENABLE_CMAKE_TESTING=ON
|
|
||||||
|
|
||||||
- name: Build
|
|
||||||
# Build your program with the given configuration
|
|
||||||
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}
|
|
||||||
|
|
||||||
- name: Test
|
|
||||||
working-directory: ${{github.workspace}}/build
|
|
||||||
# Execute tests defined by the CMake configuration.
|
|
||||||
# See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail
|
|
||||||
run: ctest -C ${{env.BUILD_TYPE}}
|
|
||||||
|
|
||||||
15
.gitignore
vendored
|
|
@ -1,21 +1,11 @@
|
||||||
# ignore generated files
|
# ignore html files
|
||||||
*.html
|
*.html
|
||||||
*.pdf
|
|
||||||
|
|
||||||
# ignore all textual files
|
# ignore all textual files
|
||||||
*.txt
|
*.txt
|
||||||
*.swp
|
|
||||||
*.swo
|
|
||||||
.kak_history
|
|
||||||
*.log
|
|
||||||
*.csv
|
|
||||||
*.ods
|
|
||||||
|
|
||||||
# ignore object and archive files
|
# ignore object and archive files
|
||||||
*.[oa]
|
*.[oa]
|
||||||
*.bak
|
|
||||||
*.tar*
|
|
||||||
tags
|
|
||||||
|
|
||||||
# ignore auto-saved files
|
# ignore auto-saved files
|
||||||
*~
|
*~
|
||||||
|
|
@ -38,7 +28,4 @@ debug/*
|
||||||
build/*
|
build/*
|
||||||
website/EO_star.png
|
website/EO_star.png
|
||||||
website/paradiseo_logo.png
|
website/paradiseo_logo.png
|
||||||
Release/*
|
|
||||||
Debug/*
|
|
||||||
Build/*
|
|
||||||
|
|
||||||
|
|
|
||||||
33
AUTHORS
|
|
@ -1,52 +1,41 @@
|
||||||
Current maintainers
|
Current maintainers
|
||||||
===================
|
===================
|
||||||
|
Arnaud Liefooghe <arnaud.liefooghe@univ-lille1.fr>
|
||||||
|
Clive Canape <clive.canape@inria.fr>
|
||||||
Johann Dreo <johann@dreo.fr>
|
Johann Dreo <johann@dreo.fr>
|
||||||
|
Sébastien Verel <sebastien.verel@inria.fr>
|
||||||
|
|
||||||
|
Active developpers
|
||||||
|
==================
|
||||||
|
Alexandre Quemy <alexandre.quemy@inria.fr>
|
||||||
|
Benjamin Bouvier <bnjbouv@gmail.com>
|
||||||
|
Caner Candan <caner@candan.fr>
|
||||||
|
Pierre Savéant <pierre.saveant@thalesgroup.com>
|
||||||
|
|
||||||
Past contributors
|
Past contributors
|
||||||
=================
|
=================
|
||||||
|
|
||||||
atantar
|
atantar
|
||||||
Alesandro Sidero
|
|
||||||
Alexandre Quemy
|
|
||||||
Alix Zheng
|
|
||||||
Amine Aziz-Alaoui
|
|
||||||
Arnaud Liefooghe
|
|
||||||
Benjamin Bouvier
|
|
||||||
Bahri
|
|
||||||
Caner Candan
|
|
||||||
Clive Canape
|
|
||||||
fatene
|
fatene
|
||||||
Gustavo Romero Lopez
|
Gustavo Romero Lopez
|
||||||
jboisson
|
jboisson
|
||||||
Jeroen Eggermont
|
Jeroen Eggermont
|
||||||
Jochen Küpper
|
Jochen Küpper
|
||||||
Joost
|
Joost <joost@dsj.nl>
|
||||||
Juan Julian Merelo Guervos
|
Juan Julian Merelo Guervos
|
||||||
Jérémie Humeau
|
Jérémie Humeau
|
||||||
Jxtopher
|
|
||||||
Karima Boufaras
|
Karima Boufaras
|
||||||
legillono
|
legillon
|
||||||
Leo Bertheas
|
|
||||||
Louis Da Costa
|
Louis Da Costa
|
||||||
Loïc Jean David Arjanen
|
Loïc Jean David Arjanen
|
||||||
Maarten Keijzer
|
Maarten Keijzer
|
||||||
Mammar Amara
|
|
||||||
Manu
|
|
||||||
Marc Schoenauer
|
Marc Schoenauer
|
||||||
Marie-Éleonore
|
Marie-Éleonore
|
||||||
Mostepha Khouadjia
|
Mostepha Khouadjia
|
||||||
Olivier König
|
Olivier König
|
||||||
Pierre Savéant
|
|
||||||
Pedro Angel Castillo Valdivieso
|
Pedro Angel Castillo Valdivieso
|
||||||
Potalas
|
|
||||||
Ronald Pinho
|
|
||||||
Steve Madere
|
Steve Madere
|
||||||
Sébastien Cahon
|
Sébastien Cahon
|
||||||
Sébastien Verel
|
|
||||||
Thomas Legrand
|
Thomas Legrand
|
||||||
Thibault Lasnier
|
|
||||||
Victor Manuel Rivas Santos
|
Victor Manuel Rivas Santos
|
||||||
wcancino
|
wcancino
|
||||||
xohm
|
xohm
|
||||||
|
|
|
||||||
|
|
@ -1,36 +1,34 @@
|
||||||
# ParadiseO
|
# ParadiseO
|
||||||
|
|
||||||
|
|
||||||
######################################################################################
|
######################################################################################
|
||||||
### 0) Check the CMake version
|
### 0) Check the CMake version
|
||||||
######################################################################################
|
######################################################################################
|
||||||
|
|
||||||
cmake_minimum_required(VERSION 3.10 FATAL_ERROR)
|
cmake_minimum_required(VERSION 2.8 FATAL_ERROR)
|
||||||
|
|
||||||
######################################################################################
|
######################################################################################
|
||||||
### 1) Define the project
|
### 1) Define the project
|
||||||
######################################################################################
|
######################################################################################
|
||||||
|
|
||||||
## Name
|
## Name
|
||||||
project("ParadisEO"
|
project("ParadisEO")
|
||||||
VERSION 3.1.3
|
|
||||||
DESCRIPTION "Evolutionary optimization framework"
|
|
||||||
LANGUAGES C CXX)
|
|
||||||
|
|
||||||
## Language
|
## Language
|
||||||
set(CMAKE_CXX_STANDARD 17)
|
enable_language(CXX)
|
||||||
|
|
||||||
## ccache
|
## Test the presence of a compiler
|
||||||
find_program(CCACHE_PROGRAM ccache)
|
if("${CMAKE_CXX_COMPILER}" STREQUAL "" OR "${CMAKE_C_COMPILER}" STREQUAL "")
|
||||||
|
message(FATAL_ERROR "No compiler found!")
|
||||||
|
endif()
|
||||||
|
|
||||||
if (CCACHE_PROGRAM)
|
## Versioning
|
||||||
message(NOTICE "-- ccache is enabled (found here: ${CCACHE_PROGRAM})")
|
set(VERSION_MAJOR 2 CACHE STRING "Major version number" )
|
||||||
set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE "\"${CCACHE_PROGRAM}\"")
|
set(VERSION_MINOR 1 CACHE STRING "Minor version number" )
|
||||||
set_property(GLOBAL PROPERTY RULE_LAUNCH_LINK "\"${CCACHE_PROGRAM}\"")
|
set(VERSION_PATCH 0 CACHE STRING "Patch version number" )
|
||||||
else ()
|
|
||||||
message(NOTICE "-- ccache has not been found")
|
|
||||||
endif ()
|
|
||||||
|
|
||||||
|
SET(PROJECT_VERSION "${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}.${PROJECT_VERSION_PATCH}" CACHE INTERNAL "Package version" FORCE)
|
||||||
|
SET(VERSION "${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}${PROJECT_VERSION_MISC}" CACHE INTERNAL "Global version" FORCE)
|
||||||
|
SET(GLOBAL_VERSION "${VERSION}")
|
||||||
|
|
||||||
######################################################################################
|
######################################################################################
|
||||||
### 2) Check dependencies
|
### 2) Check dependencies
|
||||||
|
|
@ -39,11 +37,6 @@ endif ()
|
||||||
## Optional
|
## Optional
|
||||||
set(CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/module" CACHE INTERNAL "Cmake module" FORCE)
|
set(CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/module" CACHE INTERNAL "Cmake module" FORCE)
|
||||||
include(FindDoxygen OPTIONAL)
|
include(FindDoxygen OPTIONAL)
|
||||||
if(NOT DOXYGEN_FOUND)
|
|
||||||
message(WARNING "Doxygen was not found, install it if you want to generate the documentation.")
|
|
||||||
else()
|
|
||||||
message(STATUS "Doxygen found, use the target `doc` to generate the documentation.")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
######################################################################################
|
######################################################################################
|
||||||
### 3) Include CMake files
|
### 3) Include CMake files
|
||||||
|
|
@ -63,16 +56,16 @@ include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/Target.cmake)
|
||||||
######################################################################################
|
######################################################################################
|
||||||
|
|
||||||
## Paths to sources of modules
|
## Paths to sources of modules
|
||||||
set( EO_SRC_DIR "${PROJECT_SOURCE_DIR}/eo" CACHE INTERNAL "ParadisEO-EO source directory" FORCE)
|
set( EO_SRC_DIR "${CMAKE_SOURCE_DIR}/eo" CACHE INTERNAL "ParadisEO-EO source directory" FORCE)
|
||||||
set( EDO_SRC_DIR "${PROJECT_SOURCE_DIR}/edo" CACHE INTERNAL "ParadisEO-EDO source directory" FORCE)
|
set( EDO_SRC_DIR "${CMAKE_SOURCE_DIR}/edo" CACHE INTERNAL "ParadisEO-EDO source directory" FORCE)
|
||||||
set( MO_SRC_DIR "${PROJECT_SOURCE_DIR}/mo" CACHE INTERNAL "ParadisEO-MO source directory" FORCE)
|
set( MO_SRC_DIR "${CMAKE_SOURCE_DIR}/mo" CACHE INTERNAL "ParadisEO-MO source directory" FORCE)
|
||||||
set(MOEO_SRC_DIR "${PROJECT_SOURCE_DIR}/moeo" CACHE INTERNAL "ParadisEO-MOEO source directory" FORCE)
|
set(MOEO_SRC_DIR "${CMAKE_SOURCE_DIR}/moeo" CACHE INTERNAL "ParadisEO-MOEO source directory" FORCE)
|
||||||
set( SMP_SRC_DIR "${PROJECT_SOURCE_DIR}/smp" CACHE INTERNAL "ParadisEO-SMP source directory" FORCE)
|
set( SMP_SRC_DIR "${CMAKE_SOURCE_DIR}/smp" CACHE INTERNAL "ParadisEO-SMP source directory" FORCE)
|
||||||
set( MPI_SRC_DIR "${PROJECT_SOURCE_DIR}/eo/src/mpi" CACHE INTERNAL "ParadisEO-MPI source directory" FORCE)
|
set( MPI_SRC_DIR "${CMAKE_SOURCE_DIR}/eo/src/mpi" CACHE INTERNAL "ParadisEO-MPI source directory" FORCE)
|
||||||
|
|
||||||
set(PROBLEMS_SRC_DIR "${PROJECT_SOURCE_DIR}/problems" CACHE INTERNAL "Problems dependant source directory" FORCE)
|
set(PROBLEMS_SRC_DIR "${CMAKE_SOURCE_DIR}/problems" CACHE INTERNAL "Problems dependant source directory" FORCE)
|
||||||
|
|
||||||
set(CMAKE_BASE_SOURCE_DIR ${PROJECT_SOURCE_DIR})
|
set(CMAKE_BASE_SOURCE_DIR ${CMAKE_SOURCE_DIR})
|
||||||
|
|
||||||
# All libraries are built in <build_dir>/lib/
|
# All libraries are built in <build_dir>/lib/
|
||||||
set( EO_BIN_DIR "${CMAKE_BINARY_DIR}" CACHE INTERNAL "ParadisEO-EO binary directory" FORCE)
|
set( EO_BIN_DIR "${CMAKE_BINARY_DIR}" CACHE INTERNAL "ParadisEO-EO binary directory" FORCE)
|
||||||
|
|
@ -92,34 +85,31 @@ set(SMP "false" CACHE BOOL "Build the SMP module")
|
||||||
set(MPI "false" CACHE BOOL "Build the MPI module")
|
set(MPI "false" CACHE BOOL "Build the MPI module")
|
||||||
|
|
||||||
## EO Module
|
## EO Module
|
||||||
set(MODULE_NAME "Paradiseo")
|
set(EO_MODULE_NAME "Evolving Object")
|
||||||
set(DOXYGEN_CONFIG_DIR ${CMAKE_CURRENT_SOURCE_DIR}/doxygen)
|
|
||||||
# set(EO_MODULE_NAME "Evolving Objects")
|
|
||||||
set(CMAKE_SOURCE_DIR ${EO_SRC_DIR})
|
set(CMAKE_SOURCE_DIR ${EO_SRC_DIR})
|
||||||
add_subdirectory(${EO_SRC_DIR})
|
add_subdirectory(${EO_SRC_DIR})
|
||||||
|
|
||||||
if(NOT EO_ONLY)
|
if(NOT EO_ONLY)
|
||||||
## MO Module
|
## MO Module
|
||||||
# set(MO_MODULE_NAME "Moving Objects")
|
set(MO_MODULE_NAME "Moving objects")
|
||||||
# set(MODULE_NAME "Moving Objects")
|
|
||||||
set(CMAKE_SOURCE_DIR ${MO_SRC_DIR})
|
set(CMAKE_SOURCE_DIR ${MO_SRC_DIR})
|
||||||
add_subdirectory(${MO_SRC_DIR})
|
add_subdirectory(${MO_SRC_DIR})
|
||||||
|
|
||||||
## EDO Module
|
## EDO Module
|
||||||
if(EDO)
|
if(EDO)
|
||||||
# set(EDO_MODULE_NAME "Evolving Distribution Objects")
|
set(EDO_MODULE_NAME "Evolving Distribution Objects")
|
||||||
set(CMAKE_SOURCE_DIR ${EDO_SRC_DIR})
|
set(CMAKE_SOURCE_DIR ${EDO_SRC_DIR})
|
||||||
add_subdirectory(${EDO_SRC_DIR})
|
add_subdirectory(${EDO_SRC_DIR})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
## MOEO Module
|
## MOEO Module
|
||||||
# set(MOEO_MODULE_NAME "Multi-Objectives EO")
|
set(MOEO_MODULE_NAME "Multi-Objectives EO")
|
||||||
set(CMAKE_SOURCE_DIR ${MOEO_SRC_DIR})
|
set(CMAKE_SOURCE_DIR ${MOEO_SRC_DIR})
|
||||||
add_subdirectory(${MOEO_SRC_DIR})
|
add_subdirectory(${MOEO_SRC_DIR})
|
||||||
|
|
||||||
## SMP Module
|
## SMP Module
|
||||||
if(SMP)
|
if(SMP)
|
||||||
# set(SMP_MODULE_NAME "Symmetric Multi-Processing")
|
set(SMP_MODULE_NAME "Symmetric Multi-Processing")
|
||||||
set(CMAKE_SOURCE_DIR ${SMP_SRC_DIR})
|
set(CMAKE_SOURCE_DIR ${SMP_SRC_DIR})
|
||||||
add_subdirectory(${SMP_SRC_DIR})
|
add_subdirectory(${SMP_SRC_DIR})
|
||||||
endif()
|
endif()
|
||||||
|
|
@ -142,12 +132,3 @@ endif()
|
||||||
if("${CMAKE_BUILD_TYPE}" STREQUAL "Release")
|
if("${CMAKE_BUILD_TYPE}" STREQUAL "Release")
|
||||||
include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/Package.cmake)
|
include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/Package.cmake)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
|
||||||
# Add all targets to the build-tree export set
|
|
||||||
export(TARGETS eo FILE "${PROJECT_BINARY_DIR}/paradiseo-config.cmake")
|
|
||||||
|
|
||||||
# Export the package for use from the build-tree
|
|
||||||
# (this registers the build-tree with a global CMake-registry)
|
|
||||||
export(PACKAGE paradiseo)
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,84 +0,0 @@
|
||||||
|
|
||||||
Licenses
|
|
||||||
========
|
|
||||||
|
|
||||||
ParadisEO modules are using free software licenses,
|
|
||||||
any contribution should be licensed under the same license.
|
|
||||||
|
|
||||||
| Module | License | Version | Copyleft | Patent-left |
|
|
||||||
|--------|---------|---------|----------|-------------|
|
|
||||||
| EO | LGPL | 2 | Lib only | No |
|
|
||||||
| EDO | LGPL | 2 | Lib only | No |
|
|
||||||
| MO | CeCILL | 2.1 | Yes | No |
|
|
||||||
| MOEO | CeCILL | 2.1 | Yes | No |
|
|
||||||
| SMP | CeCILL | 2.1 | Yes | No |
|
|
||||||
|
|
||||||
|
|
||||||
Contribution Workflow
|
|
||||||
=====================
|
|
||||||
|
|
||||||
The maintainer(s) will try to answer under a couple of weeks, if not, do not hesitate to send an e-mail.
|
|
||||||
|
|
||||||
If you're not familiar with Git and merge requests, start by cloning one of the main repository:
|
|
||||||
- `git clone https://github.com/nojhan/paradiseo.git`
|
|
||||||
- `git clone https://scm.gforge.inria.fr/anonscm/git/paradiseo/paradiseo.git`
|
|
||||||
|
|
||||||
|
|
||||||
Git workflow
|
|
||||||
------------
|
|
||||||
|
|
||||||
ParadisEO follows a classical Git workflow using merge requests.
|
|
||||||
In order to fix a bug or add a feature yourself, you would follow this process.
|
|
||||||
|
|
||||||
```bash
|
|
||||||
cd paradiseo
|
|
||||||
git pull origin master # Always start with an up-to-date version.
|
|
||||||
git checkout -b <my_feature> # Always work on a dedicated branch.
|
|
||||||
# [ make some modifications… ]
|
|
||||||
git commit <whatever>
|
|
||||||
mkdir build
|
|
||||||
cd build
|
|
||||||
cmake -DCMAKE_BUILD_TYPE=Debug -BUILD_TESTING=ON -DENABLE_CMAKE_TESTING=ON .. && make && ctest # Always test.
|
|
||||||
cd ..
|
|
||||||
git pull origin master # Always check that your modification still merges.
|
|
||||||
```
|
|
||||||
|
|
||||||
If everything went without error, you can either send the patch or submit a merge request.
|
|
||||||
To do so, you can either:
|
|
||||||
- submit a "pull request" on Github: [nojhan/paradiseo](https://github.com/nojhan/paradiseo),
|
|
||||||
- or send a patch on the [ParadisEO mailing list](https://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/paradiseo-users).
|
|
||||||
|
|
||||||
See below for the details.
|
|
||||||
|
|
||||||
|
|
||||||
Github pull request
|
|
||||||
-------------------
|
|
||||||
|
|
||||||
Once logged in Github, go to the [maintainer repository](https://github.com/nojhan/paradiseo) and click the "fork" button.
|
|
||||||
You should have your own copy of the ParadisEO project under your own name.
|
|
||||||
Then add it as an additional "remote" to your ParadisEO Git tree: `git remote add me <your own URL>`.
|
|
||||||
Then, checkout the branch holding the modifications you want to propose, check that it merges with the main repository
|
|
||||||
and push it on your own repository:
|
|
||||||
```bash
|
|
||||||
git checkout <my_feature>
|
|
||||||
git pull origin master
|
|
||||||
git push me <my_feature>
|
|
||||||
```
|
|
||||||
|
|
||||||
Then go to the maintainer's repository page, click on the "Pull request" tab, and on the "New pull request" button.
|
|
||||||
You should then select the maintainer's master branch on the left dropdown list, and your own `my_feature` on the right one.
|
|
||||||
Explain why the maintainer should merge your modifications and click the "Submit" button.
|
|
||||||
|
|
||||||
|
|
||||||
E-mail your patch
|
|
||||||
-----------------
|
|
||||||
|
|
||||||
Generate a patch file from the difference between your branch and a fresh master:
|
|
||||||
```bash
|
|
||||||
git pull origin master
|
|
||||||
git diff master <my_feature> > my_feature.patch
|
|
||||||
```
|
|
||||||
|
|
||||||
Then send the `my_feature.patch` (along with your explanations about why the maintainer should merge your modifications)
|
|
||||||
to the [mailing list](https://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/paradiseo-users).
|
|
||||||
|
|
||||||
200
INSTALL
Normal file
|
|
@ -0,0 +1,200 @@
|
||||||
|
|
||||||
|
==========================================================================================
|
||||||
|
INSTALLING PARADISEO
|
||||||
|
==========================================================================================
|
||||||
|
|
||||||
|
There is several ways to install ParadisEO, according to your needs.
|
||||||
|
|
||||||
|
==========================================================================================
|
||||||
|
WINDOWS
|
||||||
|
==========================================================================================
|
||||||
|
|
||||||
|
On Windows, and for compatibility reason, ParadisEO supply support only for MinGW.
|
||||||
|
Feel free to test with another compiler and to send us you report.
|
||||||
|
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
1) WITH EXE
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
The simpliest way ton install ParadisEO on Windows is to use the NSIS installer.
|
||||||
|
We would like to draw your attention on the fact that the PATH variable will not
|
||||||
|
be affected by the installation in order to allow anybody to install ParadisEO
|
||||||
|
without administration right. To have further information about how to use ParadisEO
|
||||||
|
in your project, see the tutorial on ParadisEO website (http://paradiseo.gforge.inria.fr/).
|
||||||
|
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
2) WITH CMAKE
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
You can also install ParadisEO using CMake. For that you must have a compiler installed,
|
||||||
|
and obviously cmake.
|
||||||
|
Then, follow UNIX instructions.
|
||||||
|
|
||||||
|
==========================================================================================
|
||||||
|
UNIX
|
||||||
|
==========================================================================================
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
1. WITH CMAKE
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
1.0 DEPENDENCIES
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
Optionnal
|
||||||
|
- Doxygen for documentation
|
||||||
|
- lcov for coverage
|
||||||
|
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
1.1 FAST INSTALLATION
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
After getting ParadisEO sources from repository, you have to create a build directory in order to keep your file tree clean.
|
||||||
|
|
||||||
|
> mkdir build
|
||||||
|
> cd build
|
||||||
|
|
||||||
|
To make the installation easier, ParadisEO propose you two installation types which are "Full" and "Min".
|
||||||
|
Full corresponds examples / lessons, tests and obviously libraries.
|
||||||
|
Min corresponds to libraries and headers and it is the standard behavior.
|
||||||
|
|
||||||
|
You can specified an installation type by adding the following declaration to cmake :
|
||||||
|
|
||||||
|
> cmake .. -DINSTALL_TYPE=full
|
||||||
|
> cmake .. -DINSTALL_TYPE=min
|
||||||
|
which is equivalent to
|
||||||
|
> cmake ..
|
||||||
|
|
||||||
|
Actually, by default the generator will be "Unix Makefiles" and cmake will try to look for a C++ compiler.
|
||||||
|
Be sure you have make installed, or choose an alternative according to your configuration.
|
||||||
|
To know available generators on your computer, type cmake -help. If you are on Windows and you use MinGW, you have to specify it explicitly by adding -G "MinGW Makefiles".
|
||||||
|
|
||||||
|
To compile ParadisEO simply compile sources using your generator. For instance, if you are using Unix Makefiles, type make.
|
||||||
|
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
1.2 BUILD TYPE
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
There are 2 types of build : Release or Debug.
|
||||||
|
To explicitly change the type, add -DDEBUG=true, otherwise, it will be the Release type.
|
||||||
|
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
1.3 COMPILERS
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
You can change the compiler used by CMake with the following options :
|
||||||
|
|
||||||
|
>-DCMAKE_C_COMPILER=/path/to/your/c/compiler
|
||||||
|
|
||||||
|
>-DCMAKE_CXX_COMPILER=/path/to/your/c++/compiler
|
||||||
|
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
1.4 INSTALLATION
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
WARNING : This require administration rights.
|
||||||
|
|
||||||
|
To install ParadisEO in standard paths (such as /usr/lib for lib and /usr/include for headers on UNIX-like) :
|
||||||
|
|
||||||
|
> make install
|
||||||
|
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
2. SPECIFIC MODULE
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
2.1 EO MODULE ONLY
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
If you want to compile and install only the Evolving Objects module, you can add to CMake the following option :
|
||||||
|
|
||||||
|
> cmake .. -DEO_ONLY
|
||||||
|
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
2.1 SMP MODULE
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
WARNING : The SMP module requires gcc 4.7 or higher. This is due to the fact that it uses the new C++ standard.
|
||||||
|
|
||||||
|
WARNING : At the moment, the SMP module does not work on Windows or Mac OS X since MinGW does not provide support for std::thread
|
||||||
|
and Apple does not supply a recent version of gcc (but you can try to compile gcc 4.7 by yourself).
|
||||||
|
|
||||||
|
To enable the compilation of the SMP module, just add -DSMP=true to CMake :
|
||||||
|
|
||||||
|
> cmake .. -DSMP=true
|
||||||
|
|
||||||
|
Depending on your distribution, you might have to give to CMake the path of gcc and g++ 4.7.
|
||||||
|
This is the case for Ubuntu 12.04 LTS for instance. Please, check installation guide on ParadisEO website for more details.
|
||||||
|
|
||||||
|
If you are in that case and assuming you have a standard path for gcc et g++ 4.7 :
|
||||||
|
|
||||||
|
> cmake .. -DSMP=true -DCMAKE_C_COMPILER=/usr/bin/gcc-4.7 -DCMAKE_CXX_COMPILER=/usr/bin/g++-4.7
|
||||||
|
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
2.2 PEO MODULE
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
WARNING : The PEO module requires libXML 2 and a MPI implementation such as MPICH2.
|
||||||
|
|
||||||
|
To enable the compilation of the PEO module, just add -DPEO=true to CMake :
|
||||||
|
|
||||||
|
> cmake .. -DPEO=true
|
||||||
|
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
2.3 EDO MODULE
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
WARNING : The EDO module requires either the Boost::ublas or the Eigen3 library.
|
||||||
|
|
||||||
|
To enable the compilation of the EDO module, just add -DEDO=true to CMake :
|
||||||
|
|
||||||
|
> cmake .. -DEDO=true
|
||||||
|
|
||||||
|
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
3. DOCUMENTATION
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
There is 2 ways to build ParadisEO documentation : module by module, or all the documentation.
|
||||||
|
|
||||||
|
Targets are :
|
||||||
|
doc for all documentations
|
||||||
|
doc-eo for building EO documentation
|
||||||
|
doc-mo for MO
|
||||||
|
doc-edo for MO
|
||||||
|
doc-moeo for MOEO
|
||||||
|
doc-smp for SMP
|
||||||
|
|
||||||
|
Each documentation are generated separatly in the module build folder.
|
||||||
|
For instance, after the generation of the MO documentation, you will find it in build/paradise-mo/doc.
|
||||||
|
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
4. LESSONS / EXAMPLES
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
Examples and lessons are generated by default.
|
||||||
|
If you want to disable lessons manually, you have to specify -DENABLE_CMAKE_TESTING=false to CMake.
|
||||||
|
If you want to build a specific lesson or example, you can check the list of available targets with make help.
|
||||||
|
|
||||||
|
All lessons are build on the same pattern : <module>Lesson<number>.
|
||||||
|
For instance, make moLesson4 will build the Lesson 4 from the MO module.
|
||||||
|
Easy, isn't it ?
|
||||||
|
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
5. TESTS
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
5.1 CTESTS
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
By performing tests, you can check your installation.
|
||||||
|
Testing is disable by default, except if you build with the full install type.
|
||||||
|
To enable testing, define -DENABLE_TESTING when you launch cmake.
|
||||||
|
|
||||||
|
To perform tests simply type ctest ou make test.
|
||||||
|
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
5.2 REPORTING
|
||||||
|
------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
Feel free to send us reports about building, installation, tests and profiling in order to help us to improve compatibilty and installation process. Sending reports is very simple :
|
||||||
|
|
||||||
|
> ctest -D Experimental
|
||||||
|
|
||||||
|
WARNING : Reports are anonymous. CTest will also send informations about your configuration such as OS, CPU frequency, etc.
|
||||||
|
|
||||||
|
|
||||||
217
INSTALL.md
|
|
@ -1,217 +0,0 @@
|
||||||
|
|
||||||
Summary
|
|
||||||
=======
|
|
||||||
|
|
||||||
As Paradiseo is a development framework, you do not really need to install it on all your systems.
|
|
||||||
Just put it somewhere on your development computer, compile it from here and indicate where to find it to your favorite build system.
|
|
||||||
|
|
||||||
|
|
||||||
Build
|
|
||||||
-----
|
|
||||||
|
|
||||||
Paradiseo is mainly developed for Linux, on which it is straightforward to install a C++ build chain. For example, on Ubuntu 18.04:
|
|
||||||
```bash
|
|
||||||
sudo apt install g++-8 cmake make libeigen3-dev libopenmpi-dev doxygen graphviz libgnuplot-iostream-dev
|
|
||||||
```
|
|
||||||
|
|
||||||
Paradiseo use the CMake build system, so building it should be as simple as:
|
|
||||||
```bash
|
|
||||||
mkdir build ; cd build ; cmake -DEDO=ON .. && make -j
|
|
||||||
```
|
|
||||||
|
|
||||||
The file `howto_build_paradiseo.apptainer.def` shows you how to install and build from scratch.
|
|
||||||
It is a definition file for the [Apptainer](https://apptainer.org/) container system,
|
|
||||||
which is often used on HPC clusters.
|
|
||||||
|
|
||||||
|
|
||||||
Develop
|
|
||||||
-------
|
|
||||||
|
|
||||||
Download the quick start project template, edit the `CMakeLists.txt` file to indicate where to find Paradiseo and start developing your own solver.
|
|
||||||
|
|
||||||
If you don't know CMake or a modern build system, you should still be able to build a stand-alone code from a `paradiseo/build` directory with something like:
|
|
||||||
```bash
|
|
||||||
c++ ../solver.cpp -I../eo/src -I../edo/src -DWITH_EIGEN=1 -I/usr/include/eigen3 -std=c++17 -L./lib/ -leo -leoutils -les -lga -o solver
|
|
||||||
```
|
|
||||||
|
|
||||||
|
|
||||||
Install
|
|
||||||
-------
|
|
||||||
|
|
||||||
If you want to install ParadisEO system-wide anyway:
|
|
||||||
```bash
|
|
||||||
cmake -D CMAKE_BUILD_TYPE=Release .. && sudo make install
|
|
||||||
```
|
|
||||||
|
|
||||||
|
|
||||||
More details
|
|
||||||
============
|
|
||||||
|
|
||||||
As a templated framework, most of the ParadisEO code rely within headers and is thus compiled
|
|
||||||
by you when you build your own solver.
|
|
||||||
|
|
||||||
However, in order to save some compilation time,
|
|
||||||
the EO and EDO modules are compiled within static libraries by the default build system.
|
|
||||||
|
|
||||||
If you believe you have a working build chain and want to test if it works with ParadisEO,
|
|
||||||
you can try to build the tests and the examples.
|
|
||||||
Note that if some of them failed (but not all), you may still be able to build your own solver,
|
|
||||||
as you will most probably not use all ParadisEO features anyway.
|
|
||||||
|
|
||||||
|
|
||||||
Windows
|
|
||||||
-------
|
|
||||||
|
|
||||||
Last time we checked, ParadisEO could only be built with MinGW.
|
|
||||||
Feel free to test with another compiler and to send us your report.
|
|
||||||
|
|
||||||
As of today, we cannot guarantee that it will be easy to
|
|
||||||
install ParadisEO under Windows if you're a beginner.
|
|
||||||
There is still some (possibly outdated) help about oldest version on the [Website](http://paradiseo.gforge.inria.fr/).
|
|
||||||
|
|
||||||
If you know how to install a working compiler and the dependencies,
|
|
||||||
you may follow the same steps than the Linux process below.
|
|
||||||
|
|
||||||
If you are a beginner, we strongly suggest you install a Linux distribution
|
|
||||||
(either as an OS, as a virtual machine or using the Windows 10 compatibility layer).
|
|
||||||
|
|
||||||
|
|
||||||
Linux
|
|
||||||
-----
|
|
||||||
|
|
||||||
### Dependencies
|
|
||||||
|
|
||||||
In order to build the latest version of Paradiseo, you will need a C++ compiler supporting C++17.
|
|
||||||
So far, GCC and CLANG gave good results under Linux. You will also need the CMake and make build tools.
|
|
||||||
|
|
||||||
Some features are only available if some dependencies are installed:
|
|
||||||
- Most of the EDO module depends on either uBlas or Eigen3. The recommended package is Eigen3, which enables the adaptive algorithms.
|
|
||||||
- Doxygen is needed to build the API documentation, and you should also install graphviz if you want the class relationship diagrams.
|
|
||||||
- GNUplot is needed to have the… GNUplot graphs at checkpoints.
|
|
||||||
|
|
||||||
To install all those dependencies at once under Ubuntu (18.04), just type:
|
|
||||||
```bash
|
|
||||||
sudo apt install g++-8 cmake make libeigen3-dev libopenmpi-dev doxygen graphviz libgnuplot-iostream-dev.
|
|
||||||
```
|
|
||||||
|
|
||||||
|
|
||||||
### Build
|
|
||||||
|
|
||||||
The build chain uses the classical workflow of CMake.
|
|
||||||
The recommended method is to build in a specific, separated directory and call `cmake ..` from here.
|
|
||||||
CMake will prepare the compilation script for your system of choice which you can change with the `-G <generator-name>` option (see your CMake doc for the list of available generators).
|
|
||||||
|
|
||||||
Under Linux, the default is `make`, and a build command is straitghtforward:
|
|
||||||
```bash
|
|
||||||
mkdir build ; cd build ; cmake .. && make -j
|
|
||||||
```
|
|
||||||
|
|
||||||
There is, however, several build options which you may want to switch.
|
|
||||||
To see them, we recommend the use of a CMake gui, like ccmake or cmake-gui.
|
|
||||||
On the command line, you can see the available options with: `cmake -LH ..`.
|
|
||||||
Those options can be set with the `-D<option>=<value>` argument to cmake.
|
|
||||||
|
|
||||||
The first option to consider is `CMAKE_BUILD_TYPE`,
|
|
||||||
which you most probably want to set to "Debug" (during development/tests)
|
|
||||||
or "Release" (for production/validation).
|
|
||||||
|
|
||||||
|
|
||||||
### More compilation options
|
|
||||||
|
|
||||||
Other important options are: `EDO` (which is false by default)
|
|
||||||
and parallelization options: `ENABLE_OPENMP`, `MPI`, `SMP`.
|
|
||||||
|
|
||||||
By default, the build script will build the Paradiseo libraries only.
|
|
||||||
|
|
||||||
If you `ENABLE_CMAKE_TESTING` and `BUILD_TESTING`, it will build the tests,
|
|
||||||
which you can run with the `ctest` command.
|
|
||||||
|
|
||||||
If you `ENABLE_CMAKE_EXAMPLE`, it will also build the examples.
|
|
||||||
|
|
||||||
You can change the compiler used by CMake with the following options:
|
|
||||||
`CMAKE_CXX_COMPILER=/path/to/your/c++/compiler`.
|
|
||||||
|
|
||||||
|
|
||||||
Even more details
|
|
||||||
=================
|
|
||||||
|
|
||||||
Evolving Objects (EO) module
|
|
||||||
----------------------------
|
|
||||||
|
|
||||||
If you want to compile and install only the core EO module, set `EO_ONLY`,
|
|
||||||
this can be helpful if you don't need other modules with more complex dependencies.
|
|
||||||
|
|
||||||
Shared Memory Processing (SMP) module
|
|
||||||
-------------------------------------
|
|
||||||
|
|
||||||
The SMP module requires gcc 4.7 or higher. This is due to the fact that it uses the new C++ standard.
|
|
||||||
|
|
||||||
At the moment, the SMP module does not work on Windows or Mac OS X since MinGW does not provide support for std::thread and Apple does not supply a recent version of gcc (but you can try to compile gcc 4.7 by yourself).
|
|
||||||
|
|
||||||
To enable the compilation of the SMP module, just set the `SMP` option.
|
|
||||||
|
|
||||||
Depending on your distribution, you might have to give to CMake the path of gcc and g++ 4.7.
|
|
||||||
This is the case for Ubuntu 12.04 LTS for instance.
|
|
||||||
|
|
||||||
If you are in that case and assuming you have a standard path for gcc et g++ 4.7:
|
|
||||||
```bash
|
|
||||||
cmake .. -DSMP=true -DCMAKE_C_COMPILER=/usr/bin/gcc-4.7 -DCMAKE_CXX_COMPILER=/usr/bin/g++-4.7
|
|
||||||
```
|
|
||||||
|
|
||||||
Estimating Distribution Objects (EDO) module
|
|
||||||
--------------------------------------------
|
|
||||||
|
|
||||||
To enable the compilation of the EDO module, just set the `EDO` option.
|
|
||||||
|
|
||||||
The EDO module requires a linear algebra library.
|
|
||||||
So far the core features are implemented in either [Boost::ublas](https://www.boost.org/doc/libs/release/libs/numeric/ublas) or the [Eigen3 library](https://eigen.tuxfamily.org).
|
|
||||||
|
|
||||||
The adaptive algorithms are only implemented with Eigen3, which is thus the recommended package.
|
|
||||||
|
|
||||||
|
|
||||||
Documentation
|
|
||||||
-------------
|
|
||||||
|
|
||||||
There is 2 ways to build ParadisEO documentation: module by module, or all the documentation.
|
|
||||||
|
|
||||||
Targets for the build system (usually `make`) are:
|
|
||||||
- `doc` for all documentations,
|
|
||||||
- `doc-eo` for building EO documentation,
|
|
||||||
- `doc-mo` for MO,
|
|
||||||
- `doc-edo` for MO,
|
|
||||||
- `doc-moeo` for MOEO,
|
|
||||||
- `doc-smp` for SMP.
|
|
||||||
|
|
||||||
Each documentation are generated separatly in the module build folder.
|
|
||||||
For instance, after the generation of the MO documentation, you will find it in `build/paradise-mo/doc`.
|
|
||||||
|
|
||||||
Examples
|
|
||||||
--------
|
|
||||||
|
|
||||||
Examples and lessons are generated when `ENABLE_CMAKE_EXAMPLE` is set.
|
|
||||||
|
|
||||||
If you want to build a specific lesson or example, you can check the list of available targets with `make help`.
|
|
||||||
|
|
||||||
All lessons are build on the same pattern: `<module>Lesson<number>`.
|
|
||||||
For instance, make `moLesson4` will build the Lesson 4 from the MO module.
|
|
||||||
Easy, isn't it ?
|
|
||||||
|
|
||||||
Tests
|
|
||||||
-----
|
|
||||||
|
|
||||||
By performing tests, you can check your installation.
|
|
||||||
Testing is disable by default, except if you build with the full install type.
|
|
||||||
To enable testing, define `ENABLE_CMAKE_TESTING` when you run cmake.
|
|
||||||
|
|
||||||
To perform tests simply type `ctest` or `make test`.
|
|
||||||
|
|
||||||
Reporting
|
|
||||||
---------
|
|
||||||
|
|
||||||
Feel free to send us reports about building, installation, tests and profiling in order to help us to improve compatibilty and installation process. Generate reports is very simple:
|
|
||||||
```bash
|
|
||||||
ctest -D Experimental
|
|
||||||
```
|
|
||||||
|
|
||||||
NOTE: Reports are anonymous, but CTest will also send informations about your configuration such as OS, CPU frequency, etc.
|
|
||||||
|
|
||||||
83
README
Normal file
|
|
@ -0,0 +1,83 @@
|
||||||
|
|
||||||
|
==========================================================================================
|
||||||
|
RELEASE
|
||||||
|
==========================================================================================
|
||||||
|
|
||||||
|
The current release is paradisEO-2.0
|
||||||
|
|
||||||
|
==========================================================================================
|
||||||
|
INSTALLATION
|
||||||
|
==========================================================================================
|
||||||
|
The basic installation procedure must be done in a separatly folder in order to keep
|
||||||
|
your file tree clean.
|
||||||
|
|
||||||
|
1) mkdir build
|
||||||
|
2) cd build
|
||||||
|
3) cmake ..
|
||||||
|
4) make
|
||||||
|
5) Take a cofee.
|
||||||
|
6) Congratulation, ParadiseEO is installed !
|
||||||
|
|
||||||
|
Please refer to paradisEO website or INSTALL file for further information about
|
||||||
|
installation types and options.
|
||||||
|
|
||||||
|
==========================================================================================
|
||||||
|
DIRECTORY STRUCTURE
|
||||||
|
==========================================================================================
|
||||||
|
After unpacking the archive file, you should end up with the following
|
||||||
|
structure:
|
||||||
|
|
||||||
|
.../
|
||||||
|
|
|
||||||
|
|
|
||||||
|
+-- AUTHORS Author list
|
||||||
|
|
|
||||||
|
|
|
||||||
|
+-- cmake/ CMake dir
|
||||||
|
|
|
||||||
|
|
|
||||||
|
+-- CMakeLists.txt For building process
|
||||||
|
|
|
||||||
|
|
|
||||||
|
+-- CTestConfig.cmake For testing process
|
||||||
|
|
|
||||||
|
|
|
||||||
|
+-- INSTALL INSTALL file
|
||||||
|
|
|
||||||
|
|
|
||||||
|
+-- LICENCE Licence contents
|
||||||
|
|
|
||||||
|
|
|
||||||
|
+-- paradiseo-eo paradiseo-eo dir
|
||||||
|
|
|
||||||
|
|
|
||||||
|
+-- paradiseo-mo paradiseo-mo dir
|
||||||
|
|
|
||||||
|
|
|
||||||
|
+-- paradiseo-moeo paradiseo-moeo dir
|
||||||
|
|
|
||||||
|
|
|
||||||
|
+-- problems classical problems evaluation functions
|
||||||
|
|
|
||||||
|
|
|
||||||
|
+-- README README file
|
||||||
|
|
||||||
|
==========================================================================================
|
||||||
|
NOTES
|
||||||
|
==========================================================================================
|
||||||
|
|
||||||
|
ParadisEO uses EO, a templates-based, ANSI-C++ compliant evolutionary computation library.
|
||||||
|
It contains classes for almost any kind of evolutionary computation you might come up to - at
|
||||||
|
least for the ones we could think of.
|
||||||
|
EO Website: http://eodev.sourceforge.net/.
|
||||||
|
EO is distributed under the GNU Lesser General Public License: http://www.gnu.org/copyleft/lesser.html
|
||||||
|
|
||||||
|
Please read README file of each extracted directory if you have
|
||||||
|
problems for the installation.
|
||||||
|
|
||||||
|
==========================================================================================
|
||||||
|
CONTACT
|
||||||
|
==========================================================================================
|
||||||
|
For further information about ParadisEO, help or to report any
|
||||||
|
problem : paradiseo-help@lists.gforge.inria.fr
|
||||||
|
|
||||||
273
README.md
|
|
@ -1,273 +0,0 @@
|
||||||
# Paradiseo: a Heuristic Optimization Framework
|
|
||||||
|
|
||||||
Paradiseo is an open-source ***full-featured evolutionary computation framework*** which main purpose is to help you write ***your own stochastic optimization algorithms***, insanely fast.
|
|
||||||
|
|
||||||
It focus on the efficiency of the implementation of solvers, by providing:
|
|
||||||
- a ***modular design*** for several types of paradigms,
|
|
||||||
- the ***largest codebase*** of existing components,
|
|
||||||
- tools for ***automated design and selection*** of algorithms,
|
|
||||||
- a focus on ***speed*** and several ***parallelization*** options.
|
|
||||||
|
|
||||||
<div align="center">
|
|
||||||
<img width="640" alt="Paradiseo logo" src="https://raw.githubusercontent.com/nojhan/paradiseo/master/docs/img/paradiseo_logo_dark.svg"/>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
# Quick Start
|
|
||||||
|
|
||||||
# Very Quick Start
|
|
||||||
|
|
||||||
1. Use a recent Linux, like an Ubuntu.
|
|
||||||
2. `sudo apt install g++-8 cmake make libeigen3-dev libopenmpi-dev doxygen graphviz libgnuplot-iostream-dev`
|
|
||||||
3. From the Paradiseo directory: `mkdir build ; cd build ; cmake -D CMAKE_BUILD_TYPE=Release -DEDO=ON .. && make -j`
|
|
||||||
4. Copy-paste this CMA-ES code in `cmaes.cpp`:
|
|
||||||
```cpp
|
|
||||||
#include <eo>
|
|
||||||
#include <edo>
|
|
||||||
#include <es.h>
|
|
||||||
#include <do/make_pop.h>
|
|
||||||
#include <do/make_run.h>
|
|
||||||
#include <do/make_continue.h>
|
|
||||||
#include <do/make_checkpoint.h>
|
|
||||||
|
|
||||||
using R = eoReal<eoMinimizingFitness>;
|
|
||||||
using CMA = edoNormalAdaptive<R>;
|
|
||||||
|
|
||||||
R::FitnessType sphere(const R& sol) {
|
|
||||||
double sum = 0;
|
|
||||||
for(auto x : sol) { sum += x * x; }
|
|
||||||
return sum;
|
|
||||||
}
|
|
||||||
|
|
||||||
int main(int argc, char** argv) {
|
|
||||||
eoParser parser(argc, argv);
|
|
||||||
eoState state;
|
|
||||||
|
|
||||||
size_t dim = parser.createParam<size_t>(10,
|
|
||||||
"dimension", "Dimension", 'd',
|
|
||||||
"Problem").value();
|
|
||||||
|
|
||||||
size_t max_eval = parser.getORcreateParam<size_t>(100 * dim,
|
|
||||||
"maxEval", "Maximum number of evaluations", 'E',
|
|
||||||
"Stopping criterion").value();
|
|
||||||
|
|
||||||
edoNormalAdaptive<R> gaussian(dim);
|
|
||||||
|
|
||||||
auto& obj_func = state.pack< eoEvalFuncPtr<R> >(sphere);
|
|
||||||
auto& eval = state.pack< eoEvalCounterThrowException<R> >(obj_func, max_eval);
|
|
||||||
auto& pop_eval = state.pack< eoPopLoopEval<R> >(eval);
|
|
||||||
|
|
||||||
auto& gen = state.pack< eoUniformGenerator<R::AtomType> >(-5, 5);
|
|
||||||
auto& init = state.pack< eoInitFixedLength<R> >(dim, gen);
|
|
||||||
auto& pop = do_make_pop(parser, state, init);
|
|
||||||
pop_eval(pop,pop);
|
|
||||||
|
|
||||||
auto& eo_continue = do_make_continue( parser, state, eval);
|
|
||||||
auto& pop_continue = do_make_checkpoint(parser, state, eval, eo_continue);
|
|
||||||
auto& best = state.pack< eoBestIndividualStat<R> >();
|
|
||||||
pop_continue.add( best );
|
|
||||||
auto& distrib_continue = state.pack< edoContAdaptiveFinite<CMA> >();
|
|
||||||
|
|
||||||
auto& selector = state.pack< eoRankMuSelect<R> >(dim/2);
|
|
||||||
auto& estimator = state.pack< edoEstimatorNormalAdaptive<R> >(gaussian);
|
|
||||||
auto& bounder = state.pack< edoBounderRng<R> >(R(dim, -5), R(dim, 5), gen);
|
|
||||||
auto& sampler = state.pack< edoSamplerNormalAdaptive<R> >(bounder);
|
|
||||||
auto& replacor = state.pack< eoCommaReplacement<R> >();
|
|
||||||
|
|
||||||
make_verbose(parser);
|
|
||||||
make_help(parser);
|
|
||||||
|
|
||||||
auto& algo = state.pack< edoAlgoAdaptive<CMA> >(
|
|
||||||
gaussian , pop_eval, selector,
|
|
||||||
estimator, sampler , replacor,
|
|
||||||
pop_continue, distrib_continue);
|
|
||||||
|
|
||||||
try {
|
|
||||||
algo(pop);
|
|
||||||
} catch (eoMaxEvalException& e) {
|
|
||||||
eo::log << eo::progress << "STOP" << std::endl;
|
|
||||||
}
|
|
||||||
|
|
||||||
std::cout << best.value() << std::endl;
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
```
|
|
||||||
|
|
||||||
5. Compile it with: `c++ cmaes.cpp -I../eo/src -I../edo/src -DWITH_EIGEN=1 -I/usr/include/eigen3 -std=c++17 -L./lib/ -leo -leoutils -les -o cmaes`
|
|
||||||
6. `./cmaes -h`
|
|
||||||
|
|
||||||
|
|
||||||
## Not-so-quick Start
|
|
||||||
|
|
||||||
1. Use your system of choice, as soon as you know how to operate a C++ buildchain on it.
|
|
||||||
2. Dependencies are: `libeigen3-dev libopenmpi-dev doxygen graphviz libgnuplot-iostream-dev` (or similar packagesnames, depending on your system)
|
|
||||||
3. From the Paradiseo directory, within a `build` directory, call the equivalent of `cmake -D CMAKE_BUILD_TYPE=Release -DEDO=ON ..`, then call your system's favorite generator (see cmake's documentation for the `-G` option).
|
|
||||||
4. Code your own algorithm, starting from one of the numerous examples (or tests) available around ParadisEO
|
|
||||||
(see the source code in `<module>/test/` or `<module>/tutorial/`, or see the website).
|
|
||||||
5. Build it, indicating where to include the needed ParadisEO `<module>/src/` directories, and the `build/lib` directory for the library linker.
|
|
||||||
|
|
||||||
|
|
||||||
# Rationale
|
|
||||||
|
|
||||||
## Black-box and Gray-box Optimization Problems
|
|
||||||
|
|
||||||
Paradiseo targets the development of solvers for mathematical optimization
|
|
||||||
problems for which you cannot compute gradients.
|
|
||||||
The classical use case is the automated design or configuration of
|
|
||||||
some system which is simulated.
|
|
||||||
|
|
||||||
## Metaheuristics / Evolutionary Algorithms
|
|
||||||
|
|
||||||
Paradiseo targets the design of metaheuristics solvers using
|
|
||||||
computational intelligence methods, a subdomain of artificial intelligence.
|
|
||||||
|
|
||||||
## Why choosing Paradiseo?
|
|
||||||
|
|
||||||
Learning a full-featured framework like Paradiseo very often seems overkill.
|
|
||||||
However, we would like to stress out that you may forget some points
|
|
||||||
while jumping to this conclusion.
|
|
||||||
|
|
||||||
**Paradiseo provides the *largest mature codebase* of state-of-the-art algorithms, and is focused on (automatically) find the *most efficient solvers*.**
|
|
||||||
|
|
||||||
The most classical impediment to the use of Paradiseo is that you just want to check if your problem can actually be solved with heuristics. You feel that it would be a loss of time to learn complex stuff if it ends being useless.
|
|
||||||
|
|
||||||
However, you should keep in mind that:
|
|
||||||
|
|
||||||
- Metaheuristics do seem very easy to implement in textbooks, but the state-of-the art versions of efficient algorithms can be a lot more complex.
|
|
||||||
- It is usually easy to get something to actually run, but it is far more difficult to get an efficient solver.
|
|
||||||
- Metaheuristics performances on a given problem are very sensitive to small variations in the parameter setting or the choice of some operators. Which render large experimental plans and algorithm selection compulsory to attain peak efficiency.
|
|
||||||
|
|
||||||
**Fortunately, Paradiseo have the *largest codebase* of the market, hardened along 20 years of development of tens of solvers. Additionally, it provides the tools to rapidly search for the best combination of algorithms to solve your problem, even searching for this combination *automatically*.**
|
|
||||||
|
|
||||||
Paradiseo is the fastest framework on the market, which is a crucial feature for modern and robust approach to solver design and validation.
|
|
||||||
|
|
||||||
Another classical criticism against Paradiseo is that C++ is hard and that a fast language is useless because speed is not a concern when your objective function is dominating all the runtime.
|
|
||||||
|
|
||||||
However, we argue that:
|
|
||||||
|
|
||||||
- During the design phase of your solver, you will need to estimate its performance against synthetic benchmarks that are fast to compute. In that case, fast computation means fast design iterations. And it's even more true if you plan to use automated design to find the best solver for your problem.
|
|
||||||
- Modern C++ makes use of the very same high-level abstractions you would find in more accepted languages like Python. Sure, the syntax is cumbersome, but you will not see it after a while, given that you will work at the algorithm level.
|
|
||||||
- C++ provides full type checking and the largest set of tooling for any modern language, which are your first line of defense against long-term bugs. Sure, it sometimes gives you the impression that you fight against the compiler, but chasing subtle interface bugs across a complex Python code is even harder.
|
|
||||||
|
|
||||||
# Features
|
|
||||||
|
|
||||||
## Component-based Design
|
|
||||||
|
|
||||||
Designing an algorithm with Paradiseo consists in choosing what components (called operators) you want to use for your specific needs, just as building a structure with Lego blocks.
|
|
||||||
|
|
||||||
If you have a classical problem for which available code exists (for example if you have a black-box problem with real-valued variables), you will just choose operators to form an algorithm and connect it to your evaluation function (which computes the quality of a given solution).
|
|
||||||
|
|
||||||
If your problem is a bit more exotic, you will have to code a class that encodes how solutions to your problem are represented, and perhaps a few more. For instance, you may want ad-hoc variations operators, but most of the other operators (selection, replacement, stopping criteria, command-line interface, etc.) are already available in Paradiseo.
|
|
||||||
|
|
||||||
## Large Choice of Components
|
|
||||||
|
|
||||||
Paradiseo is organized in several modules, either providing different "grammars" for different algorithms, either providing high-level features. All modules follows the same architecture design and are interoperable with the others, so that you can easily choose the subset of features you need.
|
|
||||||
|
|
||||||
It is, for instance, easy to start with a simple local search, then add multi-objective capabilities, then shared-memory parallelization, then hybridization with an evolutionary algorithm and finally plug everything in an objective function so as to optimize the parameters with a particle swarm optimizer.
|
|
||||||
|
|
||||||
## Portability
|
|
||||||
|
|
||||||
Paradiseo is mainly developed under Linux operating systems, where its dependencies and the C++ toolchain are easy to install. Recent versions have been tested with gcc and clang compilers.
|
|
||||||
|
|
||||||
Stable versions should however work on Windows and any Unix-like operating system with a standard-conforming C++ development system.
|
|
||||||
|
|
||||||
|
|
||||||
# Code
|
|
||||||
|
|
||||||
The latest stable version is on the official Git repository of INRIA: `git clone git://scm.gforge.inria.fr/paradiseo/paradiseo.git`
|
|
||||||
|
|
||||||
## Dependencies
|
|
||||||
|
|
||||||
In order to build the latest version of Paradiseo, you will need a C++ compiler supporting C++17. So far, GCC and CLANG gave good results under Linux. You will also need the CMake and make build tools.
|
|
||||||
|
|
||||||
A free working build chain under Windows seems always difficult to find. Paradiseo 2.0.1 was successfully tested with MinGW (minus the PEO module), but it's unsure if it still work for recent versions. If you managed to build under Windows, your feedback would be appreciated.
|
|
||||||
|
|
||||||
Some features are only available if some dependencies are installed:
|
|
||||||
|
|
||||||
- Most of the EDO module depends on either uBlas or Eigen3. The recommended package is Eigen3, which enables the adaptive algorithms.
|
|
||||||
- Doxygen is needed to build the API documentation, and you should also install graphviz if you want the class relationship diagrams.
|
|
||||||
- GNUplot is needed to have the… GNUplot graphs at checkpoints.
|
|
||||||
|
|
||||||
To install all those dependencies at once under Ubuntu (18.04), just type: `sudo apt install g++-8 cmake make libeigen3-dev libopenmpi-dev doxygen graphviz libgnuplot-iostream-dev`.
|
|
||||||
|
|
||||||
## Compilation
|
|
||||||
|
|
||||||
The build chain uses the classical workflow of CMake. The recommended method is to build in a specific, separated directory and call `cmake ..` from here. CMake will prepare the compilation script for your system of choice which you can change with the `-G <generator-name>` option (see the CMake doc for the list of available generators).
|
|
||||||
|
|
||||||
Under Linux, the default is make, and a build command is straitghtforward: `mkdir build ; cd build ; cmake .. && make -j`.
|
|
||||||
|
|
||||||
There is, however, several build options which you may want to switch. To see them, we recommend the use of a CMake gui, like ccmake or cmake-gui. On the command line, you can see the available options with: `cmake -LH ..` . Those options can be set with the `-D<option>=<value>` argument to cmake.
|
|
||||||
|
|
||||||
**The first option to consider is `CMAKE_BUILD_TYPE`, which you most probably want to set to `Debug` (during development/tests) or `Release` (for production/validation).**
|
|
||||||
|
|
||||||
|
|
||||||
Other important options are: `EDO` (which is false by default) and parallelization options: `ENABLE_OPENMP`, `MPI`, `SMP`.
|
|
||||||
|
|
||||||
By default, the build script will build the Paradiseo libraries only.
|
|
||||||
|
|
||||||
If you `ENABLE_CMAKE_TESTING` and `BUILD_TESTING`, it will be the tests, which you can run with the `ctest` command.
|
|
||||||
|
|
||||||
If you `ENABLE_CMAKE_EXAMPLE`, it will also build the examples.
|
|
||||||
|
|
||||||
If may want to make build scripts more verbose (especially when building the
|
|
||||||
doc) by enabling `CMAKE_VERBOSE_MAKEFILE`.
|
|
||||||
|
|
||||||
If `ccache` installed in your environment, it will try its best to re-use other compilations,
|
|
||||||
which may speed-up your builds if you manage several compatible builds at the same time.
|
|
||||||
To clear all cached objects, execute `ccache -C`.
|
|
||||||
|
|
||||||
## Licenses
|
|
||||||
|
|
||||||
Paradiseo is distributed under the GNU Lesser General Public License and the CeCILL license (depending on the modules).
|
|
||||||
|
|
||||||
Note that those licenses places copyleft restrictions on a program created with Paradiseo, but does not apply these restrictions to other software that would links with the program.
|
|
||||||
|
|
||||||
|
|
||||||
# Documentation
|
|
||||||
|
|
||||||
Paradiseo has a lot of documentation! You will find in the source repository
|
|
||||||
a lot of examples, the tutorials and you can generate the API documentation
|
|
||||||
(`make doc`, then open
|
|
||||||
`paradiseo/<build>/<module>/doc/html/index.html`).
|
|
||||||
|
|
||||||
Tutorials are located in each module's directory. For example for the EO module:
|
|
||||||
`paradiseo/eo/tutorial`.
|
|
||||||
A lot of examples for (almost) each class are available in the test directories
|
|
||||||
(e.g. `paradiseo/eo/test`). Example problems and bindings to external
|
|
||||||
benchmark libraries are in `paradiseo/problems`.
|
|
||||||
|
|
||||||
For academic articles, books, more tutorials, presentations slides,
|
|
||||||
real life example of solvers and contact information,
|
|
||||||
please see the web site (available in `paradiseo/website/index.html`).
|
|
||||||
|
|
||||||
|
|
||||||
# Citing Paradiseo
|
|
||||||
|
|
||||||
If you use Paradiseo, please cite the following publication:
|
|
||||||
|
|
||||||
Johann Dreo, Arnaud Liefooghe, Sébastien Verel, Marc Schoenauer, Juan J. Merelo, Alexandre Quemy, Benjamin Bouvier, and Jan Gmys, [Paradiseo: from a modular framework for evolutionary computation to the automated design of metaheuristics —22 years of Paradiseo—](https://doi.org/10.1145/3449726.3463276), GECCO'21: Proceedings of the Genetic and Evolutionary Computation Conference Companion, 1522–1530 (2021).
|
|
||||||
|
|
||||||
BiBTeX entry:
|
|
||||||
|
|
||||||
```
|
|
||||||
@inproceedings{Dreo-al_2021_Paradiseo,
|
|
||||||
author = {Dreo, Johann and Liefooghe, Arnaud and Verel, S\'{e}bastien and Schoenauer, Marc and Merelo, Juan J. and Quemy, Alexandre and Bouvier, Benjamin and Gmys, Jan},
|
|
||||||
title = {Paradiseo: From a Modular Framework for Evolutionary Computation to the Automated Design of Metaheuristics: 22 Years of Paradiseo},
|
|
||||||
year = {2021},
|
|
||||||
isbn = {9781450383516},
|
|
||||||
publisher = {Association for Computing Machinery},
|
|
||||||
address = {Online conference},
|
|
||||||
url = {https://doi.org/10.1145/3449726.3463276},
|
|
||||||
booktitle = {Proceedings of the Genetic and Evolutionary Computation Conference Companion},
|
|
||||||
pages = {1522–1530},
|
|
||||||
numpages = {9}
|
|
||||||
}
|
|
||||||
```
|
|
||||||
|
|
||||||
# Contact
|
|
||||||
|
|
||||||
For further information about ParadisEO, help or to report any
|
|
||||||
problem, you can either:
|
|
||||||
|
|
||||||
- Chat with us on our Matrix chatroom: https://app.element.io/#/room/#paradiseo:matrix.org
|
|
||||||
- Post an issue: https://github.com/nojhan/paradiseo/issues
|
|
||||||
|
|
||||||
|
|
@ -31,12 +31,17 @@ endif()
|
||||||
### 0) Define general CXX flags for DEBUG and RELEASE
|
### 0) Define general CXX flags for DEBUG and RELEASE
|
||||||
######################################################################################
|
######################################################################################
|
||||||
|
|
||||||
|
#if(DEBUG)
|
||||||
|
# set(CMAKE_BUILD_TYPE "Debug" CACHE STRING "" FORCE)
|
||||||
|
#else(DEBUG)
|
||||||
|
# set(CMAKE_BUILD_TYPE "Release" CACHE STRING "" FORCE)
|
||||||
|
#endif(DEBUG)
|
||||||
|
|
||||||
add_definitions(-DDEPRECATED_MESSAGES)
|
add_definitions(-DDEPRECATED_MESSAGES)
|
||||||
set(CMAKE_CXX_FLAGS_DEBUG "-Wunknown-pragmas -O0 -g -Wall -Wextra -ansi -pedantic" CACHE STRING "" FORCE)
|
set(CMAKE_CXX_FLAGS_DEBUG "-Wunknown-pragmas -O0 -g -Wall -Wextra -ansi -pedantic" CACHE STRING "" FORCE)
|
||||||
set(CMAKE_CXX_FLAGS_RELEASE "-Wunknown-pragmas -O2" CACHE STRING "" FORCE)
|
set(CMAKE_CXX_FLAGS_RELEASE "-Wunknown-pragmas -O2" CACHE STRING "" FORCE)
|
||||||
|
|
||||||
if(SMP)
|
if(SMP)
|
||||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS_DEBUG} -std=c++11 -pthread" CACHE STRING "" FORCE)
|
|
||||||
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -std=c++11 -pthread" CACHE STRING "" FORCE)
|
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -std=c++11 -pthread" CACHE STRING "" FORCE)
|
||||||
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -std=c++11 -pthread" CACHE STRING "" FORCE)
|
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -std=c++11 -pthread" CACHE STRING "" FORCE)
|
||||||
add_definitions(-D_GLIBCXX_USE_NANOSLEEP)
|
add_definitions(-D_GLIBCXX_USE_NANOSLEEP)
|
||||||
|
|
|
||||||
|
|
@ -47,8 +47,8 @@ set(CPACK_COMPONENT_DOC_INSTALL_TYPES Full)
|
||||||
# For more details: http://www.cmake.org/Wiki/CMake:Component_Install_With_CPack
|
# For more details: http://www.cmake.org/Wiki/CMake:Component_Install_With_CPack
|
||||||
|
|
||||||
#cpack package information
|
#cpack package information
|
||||||
set(CPACK_PACKAGE_DESCRIPTION_FILE "${CMAKE_CURRENT_SOURCE_DIR}/README.md")
|
set(CPACK_PACKAGE_DESCRIPTION_FILE "${CMAKE_CURRENT_SOURCE_DIR}/README")
|
||||||
set(CPACK_RESOURCE_FILE_README "${CMAKE_CURRENT_SOURCE_DIR}/README.md")
|
set(CPACK_RESOURCE_FILE_README "${CMAKE_CURRENT_SOURCE_DIR}/README")
|
||||||
set(CPACK_PACKAGE_DESCRIPTION "ParadisEO is a white-box object-oriented framework dedicated to the flexible design of metaheuristics. This template-based, ANSI-C++ compliant computation library is portable across both Windows system and sequential platforms (Unix, Linux, Mac OS X, etc.). ParadisEO is distributed under the CeCill license and can be used under several environments.")
|
set(CPACK_PACKAGE_DESCRIPTION "ParadisEO is a white-box object-oriented framework dedicated to the flexible design of metaheuristics. This template-based, ANSI-C++ compliant computation library is portable across both Windows system and sequential platforms (Unix, Linux, Mac OS X, etc.). ParadisEO is distributed under the CeCill license and can be used under several environments.")
|
||||||
set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/LICENSE")
|
set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/LICENSE")
|
||||||
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "A Software Framework for Metaheuristics")
|
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "A Software Framework for Metaheuristics")
|
||||||
|
|
|
||||||
|
|
@ -11,119 +11,22 @@ endif(UNIX)
|
||||||
######################################################################################
|
######################################################################################
|
||||||
|
|
||||||
if(DOXYGEN_FOUND AND DOXYGEN_EXECUTABLE)
|
if(DOXYGEN_FOUND AND DOXYGEN_EXECUTABLE)
|
||||||
# FIXME this would work in cmake 3.13
|
if(SMP)
|
||||||
# set(DOC_EO "make doc-eo")
|
|
||||||
# if(NOT EO_ONLY)
|
|
||||||
# set(DOC_MO "make doc-mo")
|
|
||||||
# set(DOC_MOEO "make doc-moeo")
|
|
||||||
# if(EDO)
|
|
||||||
# set(DOC_EDO "make doc-edo")
|
|
||||||
# else()
|
|
||||||
# set(DOC_EDO "")
|
|
||||||
# endif()
|
|
||||||
# if(SMP)
|
|
||||||
# set(DOC_SMP "make doc-smp")
|
|
||||||
# else()
|
|
||||||
# set(DOC_SMP "")
|
|
||||||
# endif()
|
|
||||||
# if(MPI)
|
|
||||||
# set(DOC_MPI "make doc-mpi")
|
|
||||||
# else()
|
|
||||||
# set(DOC_MPI "")
|
|
||||||
# endif()
|
|
||||||
# endif()
|
|
||||||
#
|
|
||||||
# add_custom_target(doc
|
|
||||||
# COMMAND ${DOC_EO}
|
|
||||||
# COMMAND ${DOC_MO}
|
|
||||||
# COMMAND ${DOC_MOEO}
|
|
||||||
# COMMAND ${DOC_EDO}
|
|
||||||
# COMMAND ${DOC_SMP}
|
|
||||||
# COMMAND ${DOC_MPI}
|
|
||||||
# )
|
|
||||||
# FIXME in the meantime, we must enumerate...
|
|
||||||
if(EO_ONLY)
|
|
||||||
add_custom_target(doc
|
add_custom_target(doc
|
||||||
COMMAND make doc-eo
|
COMMAND make doc-eo
|
||||||
|
COMMAND make doc-edo
|
||||||
|
COMMAND make doc-mo
|
||||||
|
COMMAND make doc-moeo
|
||||||
|
COMMAND make doc-smp
|
||||||
)
|
)
|
||||||
else()
|
else()
|
||||||
# No optional module.
|
add_custom_target(doc
|
||||||
if(NOT EDO AND NOT SMP AND NOT MPI)
|
COMMAND make doc-eo
|
||||||
add_custom_target(doc
|
COMMAND make doc-edo
|
||||||
COMMAND make doc-eo
|
COMMAND make doc-mo
|
||||||
COMMAND make doc-mo
|
COMMAND make doc-moeo
|
||||||
COMMAND make doc-moeo
|
)
|
||||||
)
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
# One optional module.
|
|
||||||
if(EDO AND NOT SMP AND NOT MPI)
|
|
||||||
add_custom_target(doc
|
|
||||||
COMMAND make doc-eo
|
|
||||||
COMMAND make doc-mo
|
|
||||||
COMMAND make doc-moeo
|
|
||||||
COMMAND make doc-edo
|
|
||||||
)
|
|
||||||
endif()
|
|
||||||
if(NOT EDO AND SMP AND NOT MPI)
|
|
||||||
add_custom_target(doc
|
|
||||||
COMMAND make doc-eo
|
|
||||||
COMMAND make doc-mo
|
|
||||||
COMMAND make doc-moeo
|
|
||||||
COMMAND make doc-smp
|
|
||||||
)
|
|
||||||
endif()
|
|
||||||
if(NOT EDO AND NOT SMP AND MPI)
|
|
||||||
add_custom_target(doc
|
|
||||||
COMMAND make doc-eo
|
|
||||||
COMMAND make doc-mo
|
|
||||||
COMMAND make doc-moeo
|
|
||||||
# COMMAND make doc-mpi
|
|
||||||
)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# Two optional modules.
|
|
||||||
if(NOT EDO AND SMP AND MPI)
|
|
||||||
add_custom_target(doc
|
|
||||||
COMMAND make doc-eo
|
|
||||||
COMMAND make doc-mo
|
|
||||||
COMMAND make doc-moeo
|
|
||||||
COMMAND make doc-smp
|
|
||||||
# COMMAND make doc-mpi
|
|
||||||
)
|
|
||||||
endif()
|
|
||||||
if(EDO AND NOT SMP AND MPI)
|
|
||||||
add_custom_target(doc
|
|
||||||
COMMAND make doc-eo
|
|
||||||
COMMAND make doc-mo
|
|
||||||
COMMAND make doc-moeo
|
|
||||||
COMMAND make doc-edo
|
|
||||||
# COMMAND make doc-mpi
|
|
||||||
)
|
|
||||||
endif()
|
|
||||||
if(EDO AND SMP AND NOT MPI)
|
|
||||||
add_custom_target(doc
|
|
||||||
COMMAND make doc-eo
|
|
||||||
COMMAND make doc-mo
|
|
||||||
COMMAND make doc-moeo
|
|
||||||
COMMAND make doc-edo
|
|
||||||
COMMAND make doc-smp
|
|
||||||
)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# Three optional modules
|
|
||||||
if(EDO AND SMP AND MPI)
|
|
||||||
add_custom_target(doc
|
|
||||||
COMMAND make doc-eo
|
|
||||||
COMMAND make doc-mo
|
|
||||||
COMMAND make doc-moeo
|
|
||||||
COMMAND make doc-edo
|
|
||||||
COMMAND make doc-smp
|
|
||||||
# COMMAND make doc-mpi
|
|
||||||
)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
endif(EO_ONLY)
|
|
||||||
endif(DOXYGEN_FOUND AND DOXYGEN_EXECUTABLE)
|
endif(DOXYGEN_FOUND AND DOXYGEN_EXECUTABLE)
|
||||||
|
|
||||||
######################################################################################
|
######################################################################################
|
||||||
|
|
@ -131,7 +34,7 @@ endif(DOXYGEN_FOUND AND DOXYGEN_EXECUTABLE)
|
||||||
######################################################################################
|
######################################################################################
|
||||||
|
|
||||||
if(PROFILING)
|
if(PROFILING)
|
||||||
find_program(LCOV
|
find_program(LCOV
|
||||||
NAMES lcov
|
NAMES lcov
|
||||||
PATHS
|
PATHS
|
||||||
"/usr/local/bin /usr/bin [HKEY_LOCAL_MACHINE\\SOFTWARE\\Rational Software\\Purify\\Setup;InstallFolder] [HKEY_CURRENT_USER\\Software]"
|
"/usr/local/bin /usr/bin [HKEY_LOCAL_MACHINE\\SOFTWARE\\Rational Software\\Purify\\Setup;InstallFolder] [HKEY_CURRENT_USER\\Software]"
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,3 @@
|
||||||
# The script use the following variables as search paths, if they are defined:
|
|
||||||
# - PARADISEO_ROOT : the project root
|
|
||||||
# - PARADISEO_DIR : the build/install directory with libraries binaries
|
|
||||||
#
|
#
|
||||||
# The following variables are filled out:
|
# The following variables are filled out:
|
||||||
# - PARADISEO_INCLUDE_DIR : EO, MO and MOEO source dir
|
# - PARADISEO_INCLUDE_DIR : EO, MO and MOEO source dir
|
||||||
|
|
@ -39,21 +36,15 @@ if(UNIX)
|
||||||
set(INSTALL_SUB_DIR /paradiseo)
|
set(INSTALL_SUB_DIR /paradiseo)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(PARADISEO_DIR)
|
|
||||||
# CMake config module is case sensitive
|
|
||||||
set(Paradiseo_DIR ${PARADISEO_DIR})
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# enabled components
|
# enabled components
|
||||||
if (Paradiseo_FIND_COMPONENTS STREQUAL "")
|
if ("${Paradiseo_FIND_COMPONENTS}" STREQUAL "")
|
||||||
set(PARADISEO_LIBRARIES_TO_FIND eo eoutils cma es flowshop ga moeo)
|
set(PARADISEO_LIBRARIES_TO_FIND eo eoutils cma es flowshop ga moeo)
|
||||||
else()
|
else()
|
||||||
set(PARADISEO_LIBRARIES_TO_FIND ${Paradiseo_FIND_COMPONENTS})
|
set(PARADISEO_LIBRARIES_TO_FIND ${Paradiseo_FIND_COMPONENTS})
|
||||||
endif()
|
endif()
|
||||||
message(STATUS "${PARADISEO_LIBRARIES_TO_FIND}")
|
|
||||||
|
|
||||||
#set the build directory
|
#set the build directory
|
||||||
#set(BUILD_DIR build)
|
set(BUILD_DIR build)
|
||||||
|
|
||||||
# Path
|
# Path
|
||||||
set(PARADISEO_SRC_PATHS
|
set(PARADISEO_SRC_PATHS
|
||||||
|
|
@ -81,36 +72,32 @@ find_path(MOEO_INCLUDE_DIR moeo
|
||||||
PATH_SUFFIXES include${INSTALL_SUB_DIR}/moeo moeo/src
|
PATH_SUFFIXES include${INSTALL_SUB_DIR}/moeo moeo/src
|
||||||
PATHS ${PARADISEO_SRC_PATHS})
|
PATHS ${PARADISEO_SRC_PATHS})
|
||||||
|
|
||||||
set(PARADISEO_INCLUDE_DIR ${EO_INCLUDE_DIR} ${MO_INCLUDE_DIR} ${MOEO_INCLUDE_DIR})
|
# Specific for SMP and PEO
|
||||||
|
|
||||||
# Specific for SMP, EDO and PEO
|
|
||||||
foreach(COMP ${PARADISEO_LIBRARIES_TO_FIND})
|
foreach(COMP ${PARADISEO_LIBRARIES_TO_FIND})
|
||||||
if(${COMP} STREQUAL "smp")
|
if(${COMP} STREQUAL "smp")
|
||||||
set(SMP_FOUND true)
|
set(SMP_FOUND true)
|
||||||
find_path(SMP_INCLUDE_DIR smp
|
find_path(SMP_INCLUDE_DIR smp
|
||||||
PATH_SUFFIXES include${INSTALL_SUB_DIR}/smp smp/src
|
PATH_SUFFIXES include${INSTALL_SUB_DIR}/smp smp/src
|
||||||
PATHS ${PARADISEO_SRC_PATHS})
|
PATHS ${PARADISEO_SRC_PATHS})
|
||||||
elseif(${COMP} STREQUAL "edo")
|
elseif(${COMP} STREQUAL "peo")
|
||||||
set(EDO_FOUND true)
|
set(PEO_FOUND true)
|
||||||
find_path(EDO_INCLUDE_DIR edo
|
find_path(EDO_INCLUDE_DIR edo
|
||||||
PATH_SUFFIXES include${INSTALL_SUB_DIR}/edo edo/src
|
PATH_SUFFIXES include${INSTALL_SUB_DIR}/edo edo/src
|
||||||
PATHS ${PARADISEO_SRC_PATHS})
|
PATHS ${PARADISEO_SRC_PATHS})
|
||||||
elseif(${COMP} STREQUAL "peo")
|
elseif(${COMP} STREQUAL "edo")
|
||||||
set(PEO_FOUND true)
|
set(EDO_FOUND true)
|
||||||
find_path(PEO_INCLUDE_DIR peo
|
find_path(EDO_INCLUDE_DIR peo
|
||||||
PATH_SUFFIXES include${INSTALL_SUB_DIR}/peo peo/src
|
PATH_SUFFIXES include${INSTALL_SUB_DIR}/peo peo/src
|
||||||
PATHS ${PARADISEO_SRC_PATHS})
|
PATHS ${PARADISEO_SRC_PATHS})
|
||||||
endif()
|
endif()
|
||||||
endforeach()
|
endforeach()
|
||||||
|
|
||||||
|
set(PARADISEO_INCLUDE_DIR ${EO_INCLUDE_DIR} ${EDO_INCLUDE_DIR} ${MO_INCLUDE_DIR} ${MOEO_INCLUDE_DIR})
|
||||||
|
|
||||||
if(SMP_FOUND)
|
if(SMP_FOUND)
|
||||||
set(PARADISEO_INCLUDE_DIR ${PARADISEO_INCLUDE_DIR} ${SMP_INCLUDE_DIR})
|
set(PARADISEO_INCLUDE_DIR ${PARADISEO_INCLUDE_DIR} ${SMP_INCLUDE_DIR})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(EDO_FOUND)
|
|
||||||
set(PARADISEO_INCLUDE_DIR ${PARADISEO_INCLUDE_DIR} ${EDO_INCLUDE_DIR})
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if(PEO_FOUND)
|
if(PEO_FOUND)
|
||||||
set(PARADISEO_INCLUDE_DIR ${PARADISEO_INCLUDE_DIR} ${PEO_INCLUDE_DIR})
|
set(PARADISEO_INCLUDE_DIR ${PARADISEO_INCLUDE_DIR} ${PEO_INCLUDE_DIR})
|
||||||
endif()
|
endif()
|
||||||
|
|
@ -119,14 +106,8 @@ endif()
|
||||||
set(PARADISEO_FOUND true) # will be set to false if one of the required modules is not found
|
set(PARADISEO_FOUND true) # will be set to false if one of the required modules is not found
|
||||||
|
|
||||||
set(FIND_PARADISEO_LIB_PATHS
|
set(FIND_PARADISEO_LIB_PATHS
|
||||||
# ${PARADISEO_ROOT}/${BUILD_DIR}
|
${PARADISEO_ROOT}/${BUILD_DIR}
|
||||||
${Paradiseo_DIR}
|
$ENV{PARADISEO_ROOT}
|
||||||
$ENV{PARADISEO_ROOT}/build
|
|
||||||
$ENV{PARADISEO_ROOT}/release
|
|
||||||
$ENV{PARADISEO_ROOT}/debug
|
|
||||||
${PARADISEO_ROOT}/build
|
|
||||||
${PARADISEO_ROOT}/release
|
|
||||||
${PARADISEO_ROOT}/debug
|
|
||||||
/usr/local/
|
/usr/local/
|
||||||
/usr/
|
/usr/
|
||||||
/sw # Fink
|
/sw # Fink
|
||||||
|
|
@ -172,20 +153,18 @@ endforeach()
|
||||||
|
|
||||||
# handle result
|
# handle result
|
||||||
if(PARADISEO_FOUND)
|
if(PARADISEO_FOUND)
|
||||||
message(STATUS "Found the following ParadisEO include directories:")
|
message(STATUS "Found ParadisEO includes :")
|
||||||
message(STATUS "\tEO\t: " ${EO_INCLUDE_DIR})
|
message(${EO_INCLUDE_DIR})
|
||||||
message(STATUS "\tMO\t: " ${MO_INCLUDE_DIR})
|
message(${EDO_INCLUDE_DIR})
|
||||||
message(STATUS "\tMOEO\t: " ${MOEO_INCLUDE_DIR})
|
message(${MO_INCLUDE_DIR})
|
||||||
|
message(${MOEO_INCLUDE_DIR})
|
||||||
if(SMP_FOUND)
|
if(SMP_FOUND)
|
||||||
message(STATUS "\tSMP\t: " ${SMP_INCLUDE_DIR})
|
message(${SMP_INCLUDE_DIR})
|
||||||
endif()
|
|
||||||
if(EDO_FOUND)
|
|
||||||
message(STATUS "\tEDO\t: " ${EDO_INCLUDE_DIR})
|
|
||||||
endif()
|
endif()
|
||||||
if(PEO_FOUND)
|
if(PEO_FOUND)
|
||||||
message(STATUS "\tPEO\t: " ${PEO_INCLUDE_DIR})
|
message(${PEO_INCLUDE_DIR})
|
||||||
endif()
|
endif()
|
||||||
else()
|
else()
|
||||||
# include directory or library not found
|
# include directory or library not found
|
||||||
message(FATAL_ERROR "Could NOT find ParadisEO (missing \t: ${FIND_PARADISEO_MISSING})")
|
message(FATAL_ERROR "Could NOT find ParadisEO (missing : ${FIND_PARADISEO_MISSING})")
|
||||||
endif()
|
endif()
|
||||||
|
|
|
||||||
|
Before Width: | Height: | Size: 94 KiB |
|
Before Width: | Height: | Size: 296 KiB |
|
Before Width: | Height: | Size: 229 KiB |
|
Before Width: | Height: | Size: 10 KiB |
|
Before Width: | Height: | Size: 12 KiB |
|
Before Width: | Height: | Size: 2.7 MiB |
|
Before Width: | Height: | Size: 33 KiB |
|
Before Width: | Height: | Size: 134 KiB |
1393
docs/index.html
|
|
@ -1,868 +0,0 @@
|
||||||
* {
|
|
||||||
padding:0px;
|
|
||||||
margin:0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
html {
|
|
||||||
}
|
|
||||||
|
|
||||||
body {
|
|
||||||
font-size:1em;
|
|
||||||
color: #333333;
|
|
||||||
font-family:Arial, sans-serif;
|
|
||||||
|
|
||||||
background-image:url("img/eo_logo_fronde.svg");
|
|
||||||
background-repeat:no-repeat;
|
|
||||||
background-position:bottom right;
|
|
||||||
}
|
|
||||||
|
|
||||||
.logo {
|
|
||||||
font-family: 'Comfortaa', monospace;
|
|
||||||
font-style:normal;
|
|
||||||
font-weight:400;
|
|
||||||
}
|
|
||||||
|
|
||||||
.logo_eo {
|
|
||||||
font-family: 'Comfortaa', monospace;
|
|
||||||
font-style:normal;
|
|
||||||
font-weight:700;
|
|
||||||
}
|
|
||||||
|
|
||||||
pre {
|
|
||||||
display:inline;
|
|
||||||
/* overflow-wrap:break-word; */
|
|
||||||
white-space: pre-wrap;
|
|
||||||
}
|
|
||||||
|
|
||||||
.command {
|
|
||||||
background-color:#333;
|
|
||||||
color:lightgrey;
|
|
||||||
padding:2px;
|
|
||||||
margin:0.2em;
|
|
||||||
border:thin solid white;
|
|
||||||
}
|
|
||||||
|
|
||||||
#alt {
|
|
||||||
font-size:0.75em;
|
|
||||||
float:left;
|
|
||||||
width:20%;
|
|
||||||
max-width:40ch;
|
|
||||||
height:100%;
|
|
||||||
text-align:center;
|
|
||||||
margin-right:5%;
|
|
||||||
background-color:#3771c8;
|
|
||||||
color:#aef;
|
|
||||||
position:fixed;
|
|
||||||
top:0;
|
|
||||||
left:0;
|
|
||||||
overflow-y:auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
#toc {
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
#main {
|
|
||||||
float:right;
|
|
||||||
width:78%;
|
|
||||||
padding-right:1em;
|
|
||||||
padding-bottom:1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
#header_logo {
|
|
||||||
background-image:url("img/paradiseo_logo.svg");
|
|
||||||
height:30ch;
|
|
||||||
background-size: contain;
|
|
||||||
background-repeat: no-repeat;
|
|
||||||
background-position: center center;
|
|
||||||
text-align:center;
|
|
||||||
vertical-align:text-bottom;
|
|
||||||
}
|
|
||||||
|
|
||||||
#header_logo em.logo {
|
|
||||||
display:none;
|
|
||||||
}
|
|
||||||
|
|
||||||
#slogan {
|
|
||||||
text-align:center;
|
|
||||||
font-weight:normal;
|
|
||||||
font-style:italic;
|
|
||||||
padding:1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
nav {
|
|
||||||
text-align:left;
|
|
||||||
clear:both;
|
|
||||||
}
|
|
||||||
|
|
||||||
nav p {
|
|
||||||
margin-top:2em;
|
|
||||||
margin-bottom:0em;
|
|
||||||
}
|
|
||||||
|
|
||||||
nav ul {
|
|
||||||
margin-top:0em;
|
|
||||||
}
|
|
||||||
|
|
||||||
nav#menu {
|
|
||||||
padding:0.5em;
|
|
||||||
/* height:100%; */
|
|
||||||
}
|
|
||||||
|
|
||||||
nav a {
|
|
||||||
color: white;
|
|
||||||
font-weight: normal;
|
|
||||||
text-decoration: none;
|
|
||||||
outline:none;
|
|
||||||
}
|
|
||||||
|
|
||||||
nav a:hover {
|
|
||||||
color: white;
|
|
||||||
font-weight: normal;
|
|
||||||
text-decoration: underline;
|
|
||||||
}
|
|
||||||
|
|
||||||
blockquote {
|
|
||||||
padding-left:1em;
|
|
||||||
border-left: 2px solid blue;
|
|
||||||
color:gray;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.examples {
|
|
||||||
margin-right:0.5em;
|
|
||||||
}
|
|
||||||
|
|
||||||
ul.publications em {
|
|
||||||
font-weight:bold;
|
|
||||||
color:#f0f;
|
|
||||||
}
|
|
||||||
|
|
||||||
h1, h2, h3, h4, h5, h6, p, pre, blockquote, label, ul, ol, dl,
|
|
||||||
fieldset, address { margin:0.75em 0;}
|
|
||||||
|
|
||||||
h1 {
|
|
||||||
font-size:2em;
|
|
||||||
border-bottom:3px solid #3771c8;
|
|
||||||
margin-top:2em;
|
|
||||||
}
|
|
||||||
|
|
||||||
h2 {
|
|
||||||
font-size:1.39em;
|
|
||||||
border-bottom:thin solid #eee;
|
|
||||||
}
|
|
||||||
|
|
||||||
h3 {font-size:1.1em;}
|
|
||||||
|
|
||||||
h4 {font-size:1em;}
|
|
||||||
|
|
||||||
li, dd {
|
|
||||||
margin-left:2em;
|
|
||||||
}
|
|
||||||
|
|
||||||
table > caption {
|
|
||||||
font-weight:bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
table {
|
|
||||||
padding:0.5em;
|
|
||||||
border:thin solid lightgray;
|
|
||||||
border-left:0.2em solid #3366CC;
|
|
||||||
}
|
|
||||||
|
|
||||||
a {
|
|
||||||
color: #3366CC;
|
|
||||||
/*background-color: #FFFFFF;*/
|
|
||||||
font-weight: normal;
|
|
||||||
text-decoration: none;
|
|
||||||
outline:none;
|
|
||||||
}
|
|
||||||
|
|
||||||
a:hover {
|
|
||||||
color: #0033CC;
|
|
||||||
/*background-color: #FFFFFF;*/
|
|
||||||
font-weight: normal;
|
|
||||||
text-decoration: underline;
|
|
||||||
}
|
|
||||||
|
|
||||||
.excerpt {
|
|
||||||
font-size: 1.3em;
|
|
||||||
background-color:#3771c8;
|
|
||||||
color:white;
|
|
||||||
padding:1em;
|
|
||||||
border: thin solid black;
|
|
||||||
display:block;
|
|
||||||
margin:1em;
|
|
||||||
box-shadow: 10px 10px 15px #074198;
|
|
||||||
}
|
|
||||||
|
|
||||||
.excerpt em {
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
.excerpt a {
|
|
||||||
color:white;
|
|
||||||
text-decoration:underline;
|
|
||||||
}
|
|
||||||
|
|
||||||
ul#menu {
|
|
||||||
clear:both;
|
|
||||||
margin: 0;
|
|
||||||
padding: 0;
|
|
||||||
list-style: none;
|
|
||||||
/*width:650px;*/
|
|
||||||
}
|
|
||||||
|
|
||||||
ul#menu li {
|
|
||||||
margin: 0;
|
|
||||||
padding:0;
|
|
||||||
float: left;
|
|
||||||
width:16.5%;
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
ul#menu li a {
|
|
||||||
display: block;
|
|
||||||
font-size: 0.75em;
|
|
||||||
color: #FFFFFF;
|
|
||||||
font-weight: bold;
|
|
||||||
text-decoration: none;
|
|
||||||
background: #5588CC;
|
|
||||||
padding: 2px 0px 2px 0px;
|
|
||||||
padding: 0em 1em 0em 1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
ul#menu li a:hover { background: #3366CC; color: #FFFFFF; }
|
|
||||||
ul#menu a.selected:link { background: #3366CC; color: #FFFFFF; }
|
|
||||||
ul#menu a.selected:visited { background: #3366CC; color: #FFFFFF; }
|
|
||||||
|
|
||||||
.collapsible {
|
|
||||||
background-color: #eee;
|
|
||||||
color:#36C;
|
|
||||||
cursor: pointer;
|
|
||||||
padding: 0.2em;
|
|
||||||
border: thin solid #ccc;
|
|
||||||
text-align: left;
|
|
||||||
outline: none;
|
|
||||||
font-size: 0.75em;
|
|
||||||
margin-left:2em;
|
|
||||||
max-width:50%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.active, .collapsible:hover {
|
|
||||||
background-color: #ddd;
|
|
||||||
color:#03C;
|
|
||||||
/* text-decoration: underline; */
|
|
||||||
}
|
|
||||||
|
|
||||||
.collapsible:after {
|
|
||||||
content: "\002B ";
|
|
||||||
font-weight: bold;
|
|
||||||
float: left;
|
|
||||||
margin-left: 5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.active:after {
|
|
||||||
content: "\2212 ";
|
|
||||||
}
|
|
||||||
|
|
||||||
.details {
|
|
||||||
padding: 0 18px;
|
|
||||||
max-height: 0;
|
|
||||||
overflow: hidden;
|
|
||||||
transition: max-height 0.2s ease-out;
|
|
||||||
background-color: #fbfbfb;
|
|
||||||
border: thin solid #ccc;
|
|
||||||
margin-left:2em;
|
|
||||||
}
|
|
||||||
|
|
||||||
figure {
|
|
||||||
text-align:center;
|
|
||||||
padding:1em;
|
|
||||||
border:thin solid lightgray;
|
|
||||||
box-shadow: 5px 10px 18px #ddd;
|
|
||||||
/* min-width:400px; */
|
|
||||||
max-width: 60%;
|
|
||||||
margin:1em;
|
|
||||||
margin-left:20%
|
|
||||||
}
|
|
||||||
|
|
||||||
figcaption {
|
|
||||||
font-size: 0.75em;
|
|
||||||
max-width: 90%;
|
|
||||||
margin-left:5%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.code {
|
|
||||||
width:95%;
|
|
||||||
height:70ch;
|
|
||||||
resize:vertical;
|
|
||||||
overflow-y:scroll;
|
|
||||||
box-shadow: 10px 10px 10px #888;
|
|
||||||
background-color:#2b2b2b;
|
|
||||||
color: #d4cfc9;
|
|
||||||
border:thin solid black;
|
|
||||||
white-space: pre;
|
|
||||||
}
|
|
||||||
|
|
||||||
.vimCodeElement { /* white-space: pre-wrap; */ font-family: monospace; color: #d4cfc9; background-color: #2b2b2b; }
|
|
||||||
.String { color: #cc7844; background-color: #272935; padding-bottom: 1px; }
|
|
||||||
.Character { color: #da4939; }
|
|
||||||
.Number { color: #519f50; }
|
|
||||||
.LineNr { color: #6b758f; background-color: #272935; padding-bottom: 1px; }
|
|
||||||
.Statement { color: #da4939; font-weight: bold; }
|
|
||||||
.Type { color: #6d9cbe; }
|
|
||||||
.Repeat { color: #da4939; }
|
|
||||||
.Include { color: #6d9cbe; }
|
|
||||||
.Exception { color: #da4939; }
|
|
||||||
.StorageClass { color: #ffc66d; }
|
|
||||||
.cppOperator { color: #b6b3eb; }
|
|
||||||
.cppSTL { color: #f4f1ed; }
|
|
||||||
.cppBraces { color: #ffc66d; }
|
|
||||||
.cppStatement { color: #ffc66d; }
|
|
||||||
.cppEndline { color: #6b758f; }
|
|
||||||
|
|
||||||
.table {
|
|
||||||
padding:1em;
|
|
||||||
border:thin solid lightgray;
|
|
||||||
box-shadow: 5px 10px 18px #ddd;
|
|
||||||
width:60%;
|
|
||||||
max-width: 40em;
|
|
||||||
margin-left:20%
|
|
||||||
}
|
|
||||||
|
|
||||||
figure.table table {
|
|
||||||
width:100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
a.comment-indicator:hover + comment { background:#ffd; position:absolute; display:block; border:1px solid black; padding:0.5em; }
|
|
||||||
a.comment-indicator { background:red; display:inline-block; border:1px solid black; width:0.5em; height:0.5em; }
|
|
||||||
comment { display:none; }
|
|
||||||
|
|
||||||
@media (min-resolution: 192dpi) {
|
|
||||||
body {
|
|
||||||
font-size:1.5em;
|
|
||||||
}
|
|
||||||
#alt {
|
|
||||||
font-size:1em;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@media only screen and (max-width: 50em), screen and (min-resolution: 192dpi) and (max-width: 75em) {
|
|
||||||
#alt {
|
|
||||||
clear:left;
|
|
||||||
width:100%;
|
|
||||||
max-width:100%;
|
|
||||||
height:auto;
|
|
||||||
text-align:left;
|
|
||||||
position:relative;
|
|
||||||
}
|
|
||||||
|
|
||||||
#shortcuts {
|
|
||||||
margin-left:30%;
|
|
||||||
}
|
|
||||||
|
|
||||||
#toc_header {
|
|
||||||
width:100%;
|
|
||||||
display:block;
|
|
||||||
}
|
|
||||||
|
|
||||||
#toc ol {
|
|
||||||
counter-reset: LIST-ITEMS 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.toc_section:before
|
|
||||||
{
|
|
||||||
float:left;
|
|
||||||
content: counter( LIST-ITEMS ) ".";
|
|
||||||
counter-increment: LIST-ITEMS;
|
|
||||||
}
|
|
||||||
.toc_section {
|
|
||||||
display:inline-block;
|
|
||||||
vertical-align:top;
|
|
||||||
*display:list-item;
|
|
||||||
}
|
|
||||||
|
|
||||||
#main {
|
|
||||||
clear:left;
|
|
||||||
width:95%;
|
|
||||||
padding-left:1em;
|
|
||||||
padding-right:1em;
|
|
||||||
text-align:justify;
|
|
||||||
}
|
|
||||||
|
|
||||||
pre {
|
|
||||||
text-align:left;
|
|
||||||
}
|
|
||||||
|
|
||||||
figure {
|
|
||||||
max-width:90%;
|
|
||||||
margin-left:5%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.table {
|
|
||||||
padding:1em;
|
|
||||||
border:thin solid lightgray;
|
|
||||||
box-shadow: 5px 10px 18px #ddd;
|
|
||||||
width:80%;
|
|
||||||
max-width: 30em;
|
|
||||||
margin-left:5%
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@media only screen and (min-width: 90em) {
|
|
||||||
#main {
|
|
||||||
}
|
|
||||||
|
|
||||||
.details {
|
|
||||||
font-size:0.80em;
|
|
||||||
color:gray;
|
|
||||||
box-shadow: inset 5px 5px 5px #ddd;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Plan .excerpt {
|
|
||||||
width:80%;
|
|
||||||
margin-left:5%;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* QUICKSTART */
|
|
||||||
|
|
||||||
#Quickstart {
|
|
||||||
text-align:justify;
|
|
||||||
display:grid;
|
|
||||||
grid-template-columns:1fr 1fr;
|
|
||||||
grid-gap:2em;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Quickstart h1 {
|
|
||||||
grid-row:1;
|
|
||||||
grid-column-start:1;
|
|
||||||
grid-column-end:3;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Quickstart #Download {
|
|
||||||
grid-row:2;
|
|
||||||
grid-column:1;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Quickstart #Build {
|
|
||||||
grid-row:3;
|
|
||||||
grid-column:1;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Quickstart #Develop {
|
|
||||||
grid-row:4;
|
|
||||||
grid-column:1;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Quickstart #Gethelp {
|
|
||||||
grid-row:5;
|
|
||||||
grid-column:1;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Quickstart .code {
|
|
||||||
grid-row-start:2;
|
|
||||||
grid-row-end:6;
|
|
||||||
grid-column:2;
|
|
||||||
height:110ch;
|
|
||||||
max-height:95vh;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* RATIONALE */
|
|
||||||
|
|
||||||
#Rationale {
|
|
||||||
display:grid;
|
|
||||||
grid-template-columns:1fr 1fr;
|
|
||||||
grid-gap:2em;
|
|
||||||
text-align:justify;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Rationale .collapsible {
|
|
||||||
display:none;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Rationale .details {
|
|
||||||
max-height:100%;
|
|
||||||
width:80%;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Rationale h1 {
|
|
||||||
grid-row:1;
|
|
||||||
grid-column-start:1;
|
|
||||||
grid-column-end:3;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Rationale #Optimization {
|
|
||||||
grid-row:2;
|
|
||||||
grid-column:1;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Rationale #Optimization_details {
|
|
||||||
grid-row:2;
|
|
||||||
grid-column:2;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Rationale #Metaheuristics {
|
|
||||||
grid-row:3;
|
|
||||||
grid-column:1;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Rationale #Metaheuristics_details {
|
|
||||||
grid-row:3;
|
|
||||||
grid-column:2;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Rationale #Why {
|
|
||||||
grid-row:4;
|
|
||||||
grid-column-start:1;
|
|
||||||
grid-column-end:3;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Rationale #Why_fullfeatured {
|
|
||||||
grid-row:5;
|
|
||||||
grid-column:1;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Rationale #Why_fullfeatured_details {
|
|
||||||
grid-row:5;
|
|
||||||
grid-column:2;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Rationale #Why_efficiency {
|
|
||||||
grid-row:6;
|
|
||||||
grid-column:1;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Rationale #Why_efficiency_details {
|
|
||||||
grid-row:6;
|
|
||||||
grid-column:2;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Rationale #Fast {
|
|
||||||
grid-row:7;
|
|
||||||
grid-column:1;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Rationale #Fast_details {
|
|
||||||
grid-row:7;
|
|
||||||
grid-column:2;
|
|
||||||
margin-top:15ch;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* FEATURES */
|
|
||||||
|
|
||||||
#Features {
|
|
||||||
display:grid;
|
|
||||||
grid-template-columns:1fr 1fr;
|
|
||||||
grid-gap:2em;
|
|
||||||
text-align:justify;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Features .collapsible {
|
|
||||||
display:none;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Features .details {
|
|
||||||
max-height:100%;
|
|
||||||
width:80%;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Features figure {
|
|
||||||
max-width:100%;
|
|
||||||
margin-left:1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Features h1 {
|
|
||||||
grid-row:1;
|
|
||||||
grid-column-start:1;
|
|
||||||
grid-column-end:3;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Features #ComponentBased {
|
|
||||||
grid-row:2;
|
|
||||||
grid-column:1;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Features #ComponentBased_details {
|
|
||||||
grid-row:2;
|
|
||||||
grid-column:2;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Features #LargeChoice {
|
|
||||||
grid-row:3;
|
|
||||||
grid-column:1;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Features #LargeChoice_details {
|
|
||||||
grid-row:3;
|
|
||||||
grid-column:2;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Features #Portability {
|
|
||||||
grid-row:4;
|
|
||||||
grid-column:1;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Features #Portability_details {
|
|
||||||
grid-row:4;
|
|
||||||
grid-column:2;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Features #VS {
|
|
||||||
grid-row:5;
|
|
||||||
grid-column-start:1;
|
|
||||||
grid-column-end:3;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Features #VS figure {
|
|
||||||
margin-left:15%;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* DOCUMENTATION */
|
|
||||||
|
|
||||||
#Documentation {
|
|
||||||
display:flex;
|
|
||||||
flex-wrap: wrap;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Documentation div {
|
|
||||||
margin:1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Documentation #Articles {
|
|
||||||
flex: 1 1 25em;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Documentation #Presentations {
|
|
||||||
flex: 1 1 25em;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Documentation #Tutorials {
|
|
||||||
flex: 1 1 30em;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Documentation #API {
|
|
||||||
flex: 1 1 25em;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Documentation #Examples {
|
|
||||||
flex: 1 1 25em;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* DOCUMENTATION */
|
|
||||||
|
|
||||||
#Code {
|
|
||||||
display:flex;
|
|
||||||
flex-wrap: wrap;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Code div {
|
|
||||||
margin:1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Code #Downloads {
|
|
||||||
flex: 1 1 20em;
|
|
||||||
text-align:justify;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Code #Dependencies {
|
|
||||||
flex: 1 1 40em;
|
|
||||||
text-align:justify;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Code #Compilation {
|
|
||||||
flex: 1 1 40em;
|
|
||||||
text-align:justify;
|
|
||||||
}
|
|
||||||
|
|
||||||
#Code #Licenses_Contribute {
|
|
||||||
flex: 1 1 20em;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* HISTORY */
|
|
||||||
|
|
||||||
#History {
|
|
||||||
display:grid;
|
|
||||||
grid-template-columns:1fr 2fr;
|
|
||||||
grid-gap:2em;
|
|
||||||
}
|
|
||||||
|
|
||||||
#History h1 {
|
|
||||||
grid-row:1;
|
|
||||||
grid-column-start:1;
|
|
||||||
grid-column-end:3;
|
|
||||||
}
|
|
||||||
|
|
||||||
#History #Institution {
|
|
||||||
grid-row:2;
|
|
||||||
grid-column:1;
|
|
||||||
}
|
|
||||||
|
|
||||||
#History #Authors {
|
|
||||||
grid-row:2;
|
|
||||||
grid-column:2;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
@media only print {
|
|
||||||
|
|
||||||
#header_logo {
|
|
||||||
background-image:none;
|
|
||||||
height:100%;
|
|
||||||
}
|
|
||||||
#header_logo em.logo {
|
|
||||||
display:block;
|
|
||||||
font-size:5em;
|
|
||||||
}
|
|
||||||
|
|
||||||
body {
|
|
||||||
background:none;
|
|
||||||
font-size:11pt;
|
|
||||||
}
|
|
||||||
|
|
||||||
a {
|
|
||||||
color:black;
|
|
||||||
font-style:italic;
|
|
||||||
}
|
|
||||||
|
|
||||||
#main a::after{
|
|
||||||
content: " [" attr(href) "] ";
|
|
||||||
color:#888;
|
|
||||||
}
|
|
||||||
|
|
||||||
h1 a {
|
|
||||||
display:none;
|
|
||||||
}
|
|
||||||
|
|
||||||
h2 a {
|
|
||||||
display:none;
|
|
||||||
}
|
|
||||||
|
|
||||||
h2 {
|
|
||||||
border-bottom:thin solid black;
|
|
||||||
margin-top:2ch;
|
|
||||||
}
|
|
||||||
|
|
||||||
h3 {
|
|
||||||
margin:2ch 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
#alt {
|
|
||||||
clear:left;
|
|
||||||
width:100%;
|
|
||||||
max-width:100%;
|
|
||||||
height:auto;
|
|
||||||
text-align:left;
|
|
||||||
position:relative;
|
|
||||||
background-color:transparent;
|
|
||||||
color:black;
|
|
||||||
}
|
|
||||||
|
|
||||||
#alt * {
|
|
||||||
color:black;
|
|
||||||
}
|
|
||||||
|
|
||||||
#shortcuts {
|
|
||||||
display:none;
|
|
||||||
}
|
|
||||||
|
|
||||||
#toc_header {
|
|
||||||
display:none;
|
|
||||||
}
|
|
||||||
|
|
||||||
#main {
|
|
||||||
counter-reset: heading;
|
|
||||||
clear:left;
|
|
||||||
width:95%;
|
|
||||||
padding-left:1em;
|
|
||||||
padding-right:1em;
|
|
||||||
text-align:justify;
|
|
||||||
}
|
|
||||||
|
|
||||||
h1:before {
|
|
||||||
content: counter(heading)". ";
|
|
||||||
counter-increment: heading;
|
|
||||||
}
|
|
||||||
h1 {
|
|
||||||
counter-reset: subheading;
|
|
||||||
}
|
|
||||||
h2:before {
|
|
||||||
content: counter(heading)"." counter(subheading)". ";
|
|
||||||
counter-increment: subheading;
|
|
||||||
}
|
|
||||||
|
|
||||||
.excerpt {
|
|
||||||
box-shadow:none;
|
|
||||||
border:2pt solid #3771c8;
|
|
||||||
background-color:white;
|
|
||||||
color: #3771c8;
|
|
||||||
page-break-inside:avoid;
|
|
||||||
}
|
|
||||||
|
|
||||||
.command {
|
|
||||||
background-color:white;
|
|
||||||
color:black;
|
|
||||||
border:none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.collapsible {
|
|
||||||
color:gray;
|
|
||||||
}
|
|
||||||
|
|
||||||
.details {
|
|
||||||
background-color:white;
|
|
||||||
color:gray;
|
|
||||||
font-size:0.8em;
|
|
||||||
max-height:100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
figure {
|
|
||||||
max-width:90%;
|
|
||||||
margin-left:5%;
|
|
||||||
box-shadow:none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.table {
|
|
||||||
padding:1em;
|
|
||||||
border:thin solid lightgray;
|
|
||||||
box-shadow: 5px 10px 18px #ddd;
|
|
||||||
width:80%;
|
|
||||||
max-width: 30em;
|
|
||||||
margin-left:5%
|
|
||||||
}
|
|
||||||
|
|
||||||
#cmaes * {
|
|
||||||
background-color:white;
|
|
||||||
}
|
|
||||||
|
|
||||||
.vimCodeElement {
|
|
||||||
background-color:white;
|
|
||||||
color:#444;
|
|
||||||
}
|
|
||||||
|
|
||||||
.code {
|
|
||||||
background-color:white;
|
|
||||||
color:black;
|
|
||||||
height:100%;
|
|
||||||
overflow-y:auto;
|
|
||||||
white-space: pre-wrap;
|
|
||||||
box-shadow:none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.cppSTL {color:black;}
|
|
||||||
.cppStatement {color:#dfa64d;}
|
|
||||||
.StorageClass {color:#dfa64d;}
|
|
||||||
|
|
||||||
.table {
|
|
||||||
margin-left:20%;
|
|
||||||
box-shadow:none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.comment-indicator {
|
|
||||||
display:none;
|
|
||||||
}
|
|
||||||
|
|
||||||
comment {
|
|
||||||
display:none;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,226 +0,0 @@
|
||||||
<doxygenlayout version="1.0">
|
|
||||||
<!-- Generated by doxygen 1.8.17 -->
|
|
||||||
<!-- Navigation index tabs for HTML output -->
|
|
||||||
<navindex>
|
|
||||||
<tab type="mainpage" visible="yes" title=""/>
|
|
||||||
<tab type="pages" visible="yes" title="" intro=""/>
|
|
||||||
<tab type="modules" visible="yes" title="" intro=""/>
|
|
||||||
<tab type="namespaces" visible="yes" title="">
|
|
||||||
<tab type="namespacelist" visible="yes" title="" intro=""/>
|
|
||||||
<tab type="namespacemembers" visible="yes" title="" intro=""/>
|
|
||||||
</tab>
|
|
||||||
<tab type="interfaces" visible="yes" title="">
|
|
||||||
<tab type="interfacelist" visible="yes" title="" intro=""/>
|
|
||||||
<tab type="interfaceindex" visible="$ALPHABETICAL_INDEX" title=""/>
|
|
||||||
<tab type="interfacehierarchy" visible="yes" title="" intro=""/>
|
|
||||||
</tab>
|
|
||||||
<tab type="classes" visible="yes" title="">
|
|
||||||
<tab type="classlist" visible="yes" title="" intro=""/>
|
|
||||||
<tab type="classindex" visible="$ALPHABETICAL_INDEX" title=""/>
|
|
||||||
<tab type="hierarchy" visible="yes" title="" intro=""/>
|
|
||||||
<tab type="classmembers" visible="yes" title="" intro=""/>
|
|
||||||
</tab>
|
|
||||||
<tab type="structs" visible="yes" title="">
|
|
||||||
<tab type="structlist" visible="yes" title="" intro=""/>
|
|
||||||
<tab type="structindex" visible="$ALPHABETICAL_INDEX" title=""/>
|
|
||||||
</tab>
|
|
||||||
<tab type="exceptions" visible="yes" title="">
|
|
||||||
<tab type="exceptionlist" visible="yes" title="" intro=""/>
|
|
||||||
<tab type="exceptionindex" visible="$ALPHABETICAL_INDEX" title=""/>
|
|
||||||
<tab type="exceptionhierarchy" visible="yes" title="" intro=""/>
|
|
||||||
</tab>
|
|
||||||
<tab type="files" visible="yes" title="">
|
|
||||||
<tab type="filelist" visible="yes" title="" intro=""/>
|
|
||||||
<tab type="globals" visible="yes" title="" intro=""/>
|
|
||||||
</tab>
|
|
||||||
<tab type="examples" visible="yes" title="" intro=""/>
|
|
||||||
</navindex>
|
|
||||||
|
|
||||||
<!-- Layout definition for a class page -->
|
|
||||||
<class>
|
|
||||||
<briefdescription visible="yes"/>
|
|
||||||
<includes visible="$SHOW_INCLUDE_FILES"/>
|
|
||||||
<inheritancegraph visible="$CLASS_GRAPH"/>
|
|
||||||
<collaborationgraph visible="$COLLABORATION_GRAPH"/>
|
|
||||||
<detaileddescription title=""/>
|
|
||||||
<memberdecl>
|
|
||||||
<publicmethods title=""/>
|
|
||||||
<publicstaticmethods title=""/>
|
|
||||||
<publicattributes title=""/>
|
|
||||||
<publicstaticattributes title=""/>
|
|
||||||
<protectedtypes title=""/>
|
|
||||||
<protectedslots title=""/>
|
|
||||||
<protectedmethods title=""/>
|
|
||||||
<protectedstaticmethods title=""/>
|
|
||||||
<protectedattributes title=""/>
|
|
||||||
<protectedstaticattributes title=""/>
|
|
||||||
<nestedclasses visible="yes" title=""/>
|
|
||||||
<publictypes title=""/>
|
|
||||||
<services title=""/>
|
|
||||||
<interfaces title=""/>
|
|
||||||
<publicslots title=""/>
|
|
||||||
<signals title=""/>
|
|
||||||
<packagetypes title=""/>
|
|
||||||
<packagemethods title=""/>
|
|
||||||
<packagestaticmethods title=""/>
|
|
||||||
<packageattributes title=""/>
|
|
||||||
<packagestaticattributes title=""/>
|
|
||||||
<properties title=""/>
|
|
||||||
<events title=""/>
|
|
||||||
<privatetypes title=""/>
|
|
||||||
<privateslots title=""/>
|
|
||||||
<privatemethods title=""/>
|
|
||||||
<privatestaticmethods title=""/>
|
|
||||||
<privateattributes title=""/>
|
|
||||||
<privatestaticattributes title=""/>
|
|
||||||
<friends title=""/>
|
|
||||||
<related title="" subtitle=""/>
|
|
||||||
<membergroups visible="yes"/>
|
|
||||||
</memberdecl>
|
|
||||||
<memberdef>
|
|
||||||
<constructors title=""/>
|
|
||||||
<functions title=""/>
|
|
||||||
<related title=""/>
|
|
||||||
<variables title=""/>
|
|
||||||
<properties title=""/>
|
|
||||||
<inlineclasses title=""/>
|
|
||||||
<typedefs title=""/>
|
|
||||||
<enums title=""/>
|
|
||||||
<services title=""/>
|
|
||||||
<interfaces title=""/>
|
|
||||||
<events title=""/>
|
|
||||||
</memberdef>
|
|
||||||
<allmemberslink visible="yes"/>
|
|
||||||
<usedfiles visible="$SHOW_USED_FILES"/>
|
|
||||||
<authorsection visible="yes"/>
|
|
||||||
</class>
|
|
||||||
|
|
||||||
<!-- Layout definition for a namespace page -->
|
|
||||||
<namespace>
|
|
||||||
<briefdescription visible="yes"/>
|
|
||||||
<detaileddescription title=""/>
|
|
||||||
<memberdecl>
|
|
||||||
<nestednamespaces visible="yes" title=""/>
|
|
||||||
<constantgroups visible="yes" title=""/>
|
|
||||||
<interfaces visible="yes" title=""/>
|
|
||||||
<classes visible="yes" title=""/>
|
|
||||||
<structs visible="yes" title=""/>
|
|
||||||
<exceptions visible="yes" title=""/>
|
|
||||||
<typedefs title=""/>
|
|
||||||
<sequences title=""/>
|
|
||||||
<dictionaries title=""/>
|
|
||||||
<enums title=""/>
|
|
||||||
<functions title=""/>
|
|
||||||
<variables title=""/>
|
|
||||||
<membergroups visible="yes"/>
|
|
||||||
</memberdecl>
|
|
||||||
<memberdef>
|
|
||||||
<inlineclasses title=""/>
|
|
||||||
<typedefs title=""/>
|
|
||||||
<sequences title=""/>
|
|
||||||
<dictionaries title=""/>
|
|
||||||
<enums title=""/>
|
|
||||||
<functions title=""/>
|
|
||||||
<variables title=""/>
|
|
||||||
</memberdef>
|
|
||||||
<authorsection visible="yes"/>
|
|
||||||
</namespace>
|
|
||||||
|
|
||||||
<!-- Layout definition for a file page -->
|
|
||||||
<file>
|
|
||||||
<briefdescription visible="yes"/>
|
|
||||||
<includes visible="$SHOW_INCLUDE_FILES"/>
|
|
||||||
<includegraph visible="$INCLUDE_GRAPH"/>
|
|
||||||
<includedbygraph visible="$INCLUDED_BY_GRAPH"/>
|
|
||||||
<sourcelink visible="yes"/>
|
|
||||||
<detaileddescription title=""/>
|
|
||||||
<memberdecl>
|
|
||||||
<interfaces visible="yes" title=""/>
|
|
||||||
<classes visible="yes" title=""/>
|
|
||||||
<structs visible="yes" title=""/>
|
|
||||||
<exceptions visible="yes" title=""/>
|
|
||||||
<namespaces visible="yes" title=""/>
|
|
||||||
<constantgroups visible="yes" title=""/>
|
|
||||||
<defines title=""/>
|
|
||||||
<typedefs title=""/>
|
|
||||||
<sequences title=""/>
|
|
||||||
<dictionaries title=""/>
|
|
||||||
<enums title=""/>
|
|
||||||
<functions title=""/>
|
|
||||||
<variables title=""/>
|
|
||||||
<membergroups visible="yes"/>
|
|
||||||
</memberdecl>
|
|
||||||
<memberdef>
|
|
||||||
<inlineclasses title=""/>
|
|
||||||
<defines title=""/>
|
|
||||||
<typedefs title=""/>
|
|
||||||
<sequences title=""/>
|
|
||||||
<dictionaries title=""/>
|
|
||||||
<enums title=""/>
|
|
||||||
<functions title=""/>
|
|
||||||
<variables title=""/>
|
|
||||||
</memberdef>
|
|
||||||
<authorsection/>
|
|
||||||
</file>
|
|
||||||
|
|
||||||
<!-- Layout definition for a group page -->
|
|
||||||
<group>
|
|
||||||
<briefdescription visible="yes"/>
|
|
||||||
<groupgraph visible="$GROUP_GRAPHS"/>
|
|
||||||
<detaileddescription title=""/>
|
|
||||||
<memberdecl>
|
|
||||||
<nestedgroups visible="yes" title=""/>
|
|
||||||
<namespaces visible="yes" title=""/>
|
|
||||||
<functions title=""/>
|
|
||||||
<classes visible="yes" title=""/>
|
|
||||||
<defines title=""/>
|
|
||||||
<typedefs title=""/>
|
|
||||||
<dirs visible="yes" title=""/>
|
|
||||||
<files visible="yes" title=""/>
|
|
||||||
<sequences title=""/>
|
|
||||||
<dictionaries title=""/>
|
|
||||||
<enums title=""/>
|
|
||||||
<enumvalues title=""/>
|
|
||||||
<variables title=""/>
|
|
||||||
<signals title=""/>
|
|
||||||
<publicslots title=""/>
|
|
||||||
<protectedslots title=""/>
|
|
||||||
<privateslots title=""/>
|
|
||||||
<events title=""/>
|
|
||||||
<properties title=""/>
|
|
||||||
<friends title=""/>
|
|
||||||
<membergroups visible="yes"/>
|
|
||||||
</memberdecl>
|
|
||||||
<memberdef>
|
|
||||||
<pagedocs/>
|
|
||||||
<inlineclasses title=""/>
|
|
||||||
<defines title=""/>
|
|
||||||
<typedefs title=""/>
|
|
||||||
<sequences title=""/>
|
|
||||||
<dictionaries title=""/>
|
|
||||||
<enums title=""/>
|
|
||||||
<enumvalues title=""/>
|
|
||||||
<functions title=""/>
|
|
||||||
<variables title=""/>
|
|
||||||
<signals title=""/>
|
|
||||||
<publicslots title=""/>
|
|
||||||
<protectedslots title=""/>
|
|
||||||
<privateslots title=""/>
|
|
||||||
<events title=""/>
|
|
||||||
<properties title=""/>
|
|
||||||
<friends title=""/>
|
|
||||||
</memberdef>
|
|
||||||
<authorsection visible="yes"/>
|
|
||||||
</group>
|
|
||||||
|
|
||||||
<!-- Layout definition for a directory page -->
|
|
||||||
<directory>
|
|
||||||
<briefdescription visible="yes"/>
|
|
||||||
<directorygraph visible="yes"/>
|
|
||||||
<detaileddescription title=""/>
|
|
||||||
<memberdecl>
|
|
||||||
<dirs visible="yes"/>
|
|
||||||
<files visible="yes"/>
|
|
||||||
</memberdecl>
|
|
||||||
</directory>
|
|
||||||
</doxygenlayout>
|
|
||||||
|
|
@ -1,791 +0,0 @@
|
||||||
/* This doxygen theme is free to use. If you like this, please Star https://github.com/kcwongjoe/doxygen_theme_flat_design */
|
|
||||||
|
|
||||||
/* Color Pattern. You can change this pattern to design your theme. */
|
|
||||||
|
|
||||||
:root {
|
|
||||||
/* Content */
|
|
||||||
--bgcolor: #ffffff;
|
|
||||||
--bgfont: #303030;
|
|
||||||
--bgfont2: #3771c8;
|
|
||||||
--bgfont-hover: #3771c8;
|
|
||||||
--bgfont-hover-text-decoration: underline solid #3771c8;
|
|
||||||
--bgborder: #7d7d7d;
|
|
||||||
--bgborder2: #f6f6f6;
|
|
||||||
--bgfont-link:#1751a8;
|
|
||||||
/* Main Header */
|
|
||||||
--bg1color: #303030;
|
|
||||||
--bg1font: #ffffff;
|
|
||||||
--bg1font2: #3771c8;
|
|
||||||
/* Second header */
|
|
||||||
--bg2color: #E2E2E2;
|
|
||||||
--bg2font: #7D7D7D;
|
|
||||||
--bg2-hover-bg: #ffffff;
|
|
||||||
--bg2-hover-font: #303030;
|
|
||||||
--bg2-hover-topborder: #3771c8;
|
|
||||||
/* Third header */
|
|
||||||
--bg3color: #f6f6f6;
|
|
||||||
--bg3font: #303030;
|
|
||||||
--bg3font2: #7D7D7D;
|
|
||||||
/* Code */
|
|
||||||
--code-bg: #232323;
|
|
||||||
--code-comment: #a5c261;
|
|
||||||
--code-keyword: #db4939;
|
|
||||||
--code-preprocessor: #efcd45;
|
|
||||||
--code-keywordtype: #87bbff;
|
|
||||||
--code-text: #b1cfb1;
|
|
||||||
--code-code: #d3d0cc;
|
|
||||||
--code-line: #73707c;
|
|
||||||
--code-line-bg: #232323;
|
|
||||||
--code-link: #b7dbff;
|
|
||||||
/* Namespace List, Class List icon */
|
|
||||||
--icon-bg: #303030
|
|
||||||
--icon-font: #3771c8;
|
|
||||||
/* Class Index */
|
|
||||||
--qindex-menu-bg: #303030;
|
|
||||||
--qindex-menu-font: #ffffff;
|
|
||||||
--qindex-menu-font-hover: #3771c8;
|
|
||||||
--qindex-icon-bg: #3771c8;
|
|
||||||
--qindex-icon-font: #303030;
|
|
||||||
/* Member table */
|
|
||||||
--mem-title-bg: #3771c8;
|
|
||||||
--mem-title-font: #ffffff;
|
|
||||||
--mem-subtitle-bg: #77b1f8;
|
|
||||||
--mem-subtitle-font: #303030;
|
|
||||||
--mem-subtitle-font-hover: #303030;
|
|
||||||
--mem-content-bg: #ffffff;
|
|
||||||
--mem-content-font: #303030;
|
|
||||||
--mem-content-border: grey;
|
|
||||||
--mem-content-highlighted:#3771c8;
|
|
||||||
/* Nav Tree */
|
|
||||||
--nav-tree-bg: #E2E2E2;
|
|
||||||
--nav-tree-bg-hover: #ffffff;
|
|
||||||
--nav-tree-font: #7D7D7D;
|
|
||||||
--nav-tree-font-hover: #303030;
|
|
||||||
--nav-tree-bg-selected: #3771c8;
|
|
||||||
--nav-tree-font-selected: white;
|
|
||||||
}
|
|
||||||
|
|
||||||
body, table, div, p, dl {
|
|
||||||
color: var(--bgfont);
|
|
||||||
background-color: var(--bgcolor);
|
|
||||||
line-height: 150%;
|
|
||||||
font: 14px/22px, Roboto, Arial;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.contents {
|
|
||||||
margin: 20px 40px;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.contents ul {
|
|
||||||
line-height: 200%;
|
|
||||||
}
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
/********** Project header *********/
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
#titlearea {
|
|
||||||
border-bottom: none;
|
|
||||||
padding-bottom: 20px;
|
|
||||||
padding-top: 20px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#titlearea, #titlearea * {
|
|
||||||
color: var(--bg1font);
|
|
||||||
background-color: var(--bg1color);
|
|
||||||
}
|
|
||||||
|
|
||||||
#projectname {
|
|
||||||
padding: 0px 40px !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
#projectbrief {
|
|
||||||
padding: 0px 40px !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
#projectalign {
|
|
||||||
padding: 0px !important;
|
|
||||||
vertical-align: bottom;
|
|
||||||
}
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
/************ Main Menu ************/
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
/* Margin */
|
|
||||||
|
|
||||||
#main-menu {
|
|
||||||
padding: 0px 30px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#main-menu a, #main-menu a:hover {
|
|
||||||
padding-top: 10px;
|
|
||||||
padding-bottom: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Menu button */
|
|
||||||
|
|
||||||
#main-menu li a {
|
|
||||||
background-image: none;
|
|
||||||
font-family: Arial;
|
|
||||||
text-shadow: none;
|
|
||||||
font-size: 14px;
|
|
||||||
font-weight: 700;
|
|
||||||
}
|
|
||||||
|
|
||||||
#main-menu, #main-menu>li>a {
|
|
||||||
background-image: none;
|
|
||||||
background-color: var(--bg2color);
|
|
||||||
color: var(--bg2font);
|
|
||||||
transition: 0.2s;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* hover Effect */
|
|
||||||
|
|
||||||
#main-menu>li {
|
|
||||||
border-top: 5px solid var(--bg2color);
|
|
||||||
}
|
|
||||||
|
|
||||||
#main-menu>li:hover {
|
|
||||||
color: var(--bg2-hover-font);
|
|
||||||
background-color: var(--bg2-hover-bg);
|
|
||||||
border-top: 5px solid var(--bg2-hover-topborder);
|
|
||||||
font-width: bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
#main-menu>li:hover, #main-menu>li>a:hover, #main-menu>li>a.highlighted {
|
|
||||||
color: var(--bg2-hover-font);
|
|
||||||
background-color: var(--bg2-hover-bg);
|
|
||||||
font-width: bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Search Bar */
|
|
||||||
|
|
||||||
#MSearchBox {
|
|
||||||
border-radius: 0;
|
|
||||||
box-shadow: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
#MSearchBox>span {
|
|
||||||
margin: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#main-menu>li:last-child {
|
|
||||||
padding: 25px 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Reset search hover color*/
|
|
||||||
|
|
||||||
#main-menu>li:last-child:hover {
|
|
||||||
color: var(--bg2font);
|
|
||||||
background-color: var(--bg2color);
|
|
||||||
border-top: 5px solid var(--bg2color);
|
|
||||||
}
|
|
||||||
|
|
||||||
#MSearchResultsWindow {
|
|
||||||
border: 1px solid var(--bg3font2);
|
|
||||||
background-color: var(--bg3color);
|
|
||||||
padding: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
body.SRPage, body.SRPage * {
|
|
||||||
font-family: Arial;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Sub Menu */
|
|
||||||
|
|
||||||
#main-menu>li ul {
|
|
||||||
transition: max-height 0.2s ease-in-out;
|
|
||||||
padding: 0px;
|
|
||||||
border-radius: 0px !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
#main-menu>li ul:before, #main-menu>li ul:after {
|
|
||||||
border-width: 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#main-menu>li>ul li a, #main-menu>li>ul li {
|
|
||||||
background-color: var(--bgcolor);
|
|
||||||
color: var(--bgfont);
|
|
||||||
background-image: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
#main-menu>li>ul li a:hover, #main-menu>li>ul li:hover {
|
|
||||||
background-color: var(--bgfont2);
|
|
||||||
/*color: var(--bgfont);*/
|
|
||||||
color: white;
|
|
||||||
font-width: bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
/************** Header *************/
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
div.headertitle {
|
|
||||||
padding: 5px 40px;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.header, div.header * {
|
|
||||||
color: var(--bg3font);
|
|
||||||
background-color: var(--bg3color);
|
|
||||||
border-bottom: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.summary {
|
|
||||||
padding-right: 40px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
/************** Link *************/
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
a, a:visited, a:active, .contents a:visited, body.SRPage a, body.SRPage a:visited, body.SRPage a:active {
|
|
||||||
color: var(--bgfont-link);
|
|
||||||
text-decoration: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
a:hover, .contents a:hover, body.SRPage a:hover {
|
|
||||||
color: var(--bgfont-hover);
|
|
||||||
text-decoration: var(--bgfont-hover-text-decoration);
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
.dynheader {
|
|
||||||
color: var(--bgfont-link);
|
|
||||||
text-decoration: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.dynheader:hover {
|
|
||||||
color: var(--bgfont-hover);
|
|
||||||
text-decoration: var(--bgfont-hover-text-decoration);
|
|
||||||
}
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
/************ Nav-path ************/
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
#nav-path, #nav-path ul {
|
|
||||||
background-image: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
#nav-path ul {
|
|
||||||
padding: 5px 30px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#nav-path, #nav-path * {
|
|
||||||
color: var(--bg3font2);
|
|
||||||
background-color: var(--bg3color);
|
|
||||||
border: none;
|
|
||||||
font-family: Arial;
|
|
||||||
}
|
|
||||||
|
|
||||||
li.navelem {
|
|
||||||
background-image: url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZlcnNpb249IjEuMSIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHhtbG5zOnN2Z2pzPSJodHRwOi8vc3ZnanMuY29tL3N2Z2pzIiB3aWR0aD0iNTEyIiBoZWlnaHQ9IjUxMiIgeD0iMCIgeT0iMCIgdmlld0JveD0iMCAwIDI5Mi4zNTkgMjkyLjM1OSIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAgNTEyIDUxMiIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgY2xhc3M9IiI+PGc+CjxnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+Cgk8cGF0aCBkPSJNMjIyLjk3OSwxMzMuMzMxTDk1LjA3Myw1LjQyNEM5MS40NTYsMS44MDcsODcuMTc4LDAsODIuMjI2LDBjLTQuOTUyLDAtOS4yMzMsMS44MDctMTIuODUsNS40MjQgICBjLTMuNjE3LDMuNjE3LTUuNDI0LDcuODk4LTUuNDI0LDEyLjg0N3YyNTUuODEzYzAsNC45NDgsMS44MDcsOS4yMzIsNS40MjQsMTIuODQ3YzMuNjIxLDMuNjE3LDcuOTAyLDUuNDI4LDEyLjg1LDUuNDI4ICAgYzQuOTQ5LDAsOS4yMy0xLjgxMSwxMi44NDctNS40MjhsMTI3LjkwNi0xMjcuOTA3YzMuNjE0LTMuNjEzLDUuNDI4LTcuODk3LDUuNDI4LTEyLjg0NyAgIEMyMjguNDA3LDE0MS4yMjksMjI2LjU5NCwxMzYuOTQ4LDIyMi45NzksMTMzLjMzMXoiIGZpbGw9IiM3ZDdkN2QiIGRhdGEtb3JpZ2luYWw9IiMwMDAwMDAiIHN0eWxlPSIiIGNsYXNzPSIiPjwvcGF0aD4KPC9nPgo8ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPgo8L2c+CjxnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjwvZz4KPGcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPC9nPgo8ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPgo8L2c+CjxnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjwvZz4KPGcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPC9nPgo8ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPgo8L2c+CjxnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjwvZz4KPGcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPC9nPgo8ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPgo8L2c+CjxnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjwvZz4KPGcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPC9nPgo8ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPgo8L2c+CjxnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjwvZz4KPGcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPC9nPgo8L2c+PC9zdmc+);
|
|
||||||
background-size: 9px;
|
|
||||||
}
|
|
||||||
|
|
||||||
li.navelem a {
|
|
||||||
margin-right: 20px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
/*************** mem ***************/
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
.memtitle {
|
|
||||||
padding: 15px;
|
|
||||||
margin-top: 30px;
|
|
||||||
border-top-left-radius: 0px;
|
|
||||||
border-top-right-radius: 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.memtitle, .memtitle *, .memtitle a:visited {
|
|
||||||
border: none;
|
|
||||||
background-image: none;
|
|
||||||
color: var(--mem-title-font);
|
|
||||||
background-color: var(--mem-title-bg);
|
|
||||||
}
|
|
||||||
|
|
||||||
.memproto {
|
|
||||||
padding: 2em;
|
|
||||||
text-shadow: none;
|
|
||||||
border-top-right-radius: 0px;
|
|
||||||
-moz-border-radius-topright: 0px;
|
|
||||||
-webkit-border-top-right-radius: 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.memproto, .memproto *, .memproto a:visited {
|
|
||||||
border: none;
|
|
||||||
background-image: none;
|
|
||||||
background-color: var(--mem-subtitle-bg);
|
|
||||||
color: var(--mem-subtitle-font);
|
|
||||||
font-size: inherit;
|
|
||||||
line-height: 100%
|
|
||||||
}
|
|
||||||
|
|
||||||
.memproto a:hover {
|
|
||||||
color: var(--mem-subtitle-font-hover);
|
|
||||||
}
|
|
||||||
|
|
||||||
.memdoc {
|
|
||||||
border-bottom: 1px solid var(--mem-content-border);
|
|
||||||
border-left: 1px solid var(--mem-content-border);
|
|
||||||
border-right: 1px solid var(--mem-content-border);
|
|
||||||
background-color: var(--mem-content-bg);
|
|
||||||
color: var(--mem-content-font);
|
|
||||||
border-bottom-left-radius: 0px;
|
|
||||||
border-bottom-right-radius: 0px;
|
|
||||||
-moz-border-radius-bottomleft: 0px;
|
|
||||||
-moz-border-radius-bottomright: 0px;
|
|
||||||
-webkit-border-bottom-left-radius: 0px;
|
|
||||||
-webkit-border-bottom-right-radius: 0px;
|
|
||||||
padding:1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
.memdoc p, .memdoc dt {
|
|
||||||
/*padding: 0px 20px;*/
|
|
||||||
}
|
|
||||||
|
|
||||||
.memdoc > p {
|
|
||||||
font-size:1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
.paramname {
|
|
||||||
color:black;
|
|
||||||
}
|
|
||||||
|
|
||||||
td.memItemRight > a:first-of-type {
|
|
||||||
font-size:1.3em;
|
|
||||||
}
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
/************* Contents ************/
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
a.anchor {
|
|
||||||
padding-top: 20px;
|
|
||||||
}
|
|
||||||
|
|
||||||
dl {
|
|
||||||
border-left: 5px solid;
|
|
||||||
padding:1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
dt {
|
|
||||||
font-variant-caps: small-caps;
|
|
||||||
}
|
|
||||||
|
|
||||||
dl.warning {
|
|
||||||
border-top: thin solid red;
|
|
||||||
border-right: thin solid red;
|
|
||||||
border-bottom: thin solid red;
|
|
||||||
border-left-color: red;
|
|
||||||
background-color: #fee;
|
|
||||||
}
|
|
||||||
|
|
||||||
dl.warning > dt {
|
|
||||||
color: #500;
|
|
||||||
}
|
|
||||||
|
|
||||||
dl.note {
|
|
||||||
border-top:thin solid green;
|
|
||||||
border-right:thin solid green;
|
|
||||||
border-bottom:thin solid green;
|
|
||||||
border-left-color:green;
|
|
||||||
background-color: #efe;
|
|
||||||
}
|
|
||||||
|
|
||||||
dl.note > dt {
|
|
||||||
color: #050;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.textblock {
|
|
||||||
padding:2em;
|
|
||||||
border: 2px solid var(--bgfont2);
|
|
||||||
box-shadow:0.5em 0.5em 0.5em var(--bgfont);
|
|
||||||
background-color: #fafaff;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.textblock > p {
|
|
||||||
font-size:1.2em;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.textblock > p.definition {
|
|
||||||
font-size:0.8em;
|
|
||||||
}
|
|
||||||
|
|
||||||
p.definition {
|
|
||||||
font-size: 0.8em;
|
|
||||||
}
|
|
||||||
|
|
||||||
p.reference {
|
|
||||||
font-size: 0.8em;
|
|
||||||
}
|
|
||||||
|
|
||||||
p {
|
|
||||||
background-color: transparent;
|
|
||||||
}
|
|
||||||
|
|
||||||
table {
|
|
||||||
margin-top:4em;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.memname {
|
|
||||||
margin-top:0.1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.mlabels {
|
|
||||||
margin-top:0.1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
/************* fragment ************/
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
h2.groupheader {
|
|
||||||
color: #303030;
|
|
||||||
font-size: 200%;
|
|
||||||
font-weight: bold;
|
|
||||||
border-bottom: thin solid var(--bgfont2);
|
|
||||||
padding-bottom:1px;
|
|
||||||
margin-top:3em;
|
|
||||||
}
|
|
||||||
|
|
||||||
h3 {
|
|
||||||
background-color:var(--bgfont2);
|
|
||||||
color: var(--bgcolor);
|
|
||||||
font-size: 1.5em;
|
|
||||||
margin:0px;
|
|
||||||
padding:1em;
|
|
||||||
margin-bottom:2em;
|
|
||||||
border: 2px solid var(--bgfont2);
|
|
||||||
box-shadow:0.5em 0.5em 0.5em var(--bgfont);
|
|
||||||
font-family:monospace;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.fragment, pre.fragment {
|
|
||||||
border: none;
|
|
||||||
padding: 1em;
|
|
||||||
margin-left: 1em;
|
|
||||||
margin-right: 1em;
|
|
||||||
background-color: var(--code-bg);
|
|
||||||
border-left: 2px solid black;
|
|
||||||
border-top: 2px solid black;
|
|
||||||
border-right: 2px solid grey;
|
|
||||||
border-bottom: 2px solid grey;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.fragment > div.line {
|
|
||||||
font-size:1em;
|
|
||||||
line-height:150%;
|
|
||||||
color: var(--code-code);
|
|
||||||
}
|
|
||||||
|
|
||||||
.textblock > div.fragment {
|
|
||||||
font-size: 1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
.textblock > dl.section {
|
|
||||||
font-size: 1.2em;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.line {
|
|
||||||
background-color: var(--code-bg);
|
|
||||||
}
|
|
||||||
|
|
||||||
span.comment {
|
|
||||||
color: var(--code-comment);
|
|
||||||
}
|
|
||||||
|
|
||||||
span.keyword {
|
|
||||||
color: var(--code-keyword);
|
|
||||||
}
|
|
||||||
|
|
||||||
span.preprocessor {
|
|
||||||
color: var(--code-preprocessor);
|
|
||||||
}
|
|
||||||
|
|
||||||
span.keywordtype {
|
|
||||||
color: var(--code-keywordtype);
|
|
||||||
}
|
|
||||||
|
|
||||||
span.stringliteral {
|
|
||||||
color: var(--code-text);
|
|
||||||
}
|
|
||||||
|
|
||||||
span.mlabel {
|
|
||||||
background-color: var(--code-text);
|
|
||||||
color: var(--code-bg);
|
|
||||||
border-top: none;
|
|
||||||
border-left: none;
|
|
||||||
border-right: none;
|
|
||||||
border-bottom: none;
|
|
||||||
padding: 10px;
|
|
||||||
border-radius: 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.fragment > div.line > a.code {
|
|
||||||
color: var(--code-link);
|
|
||||||
}
|
|
||||||
|
|
||||||
span.lineno, span.lineno>* {
|
|
||||||
color: var(--code-line);
|
|
||||||
border-right: none;
|
|
||||||
background-color: var(--code-bg);
|
|
||||||
}
|
|
||||||
|
|
||||||
span.lineno a {
|
|
||||||
background-color: var(--code-line-bg);
|
|
||||||
}
|
|
||||||
|
|
||||||
span.lineno a:hover {
|
|
||||||
color: var(--bg3font);
|
|
||||||
background-color: var(--code-line-bg);
|
|
||||||
}
|
|
||||||
|
|
||||||
code {
|
|
||||||
color:black;
|
|
||||||
}
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
/************* directory ***********/
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
.directory tr.even {
|
|
||||||
background-color: inherit;
|
|
||||||
}
|
|
||||||
|
|
||||||
.iconfclosed {
|
|
||||||
background-image: url(closed-folder.png);
|
|
||||||
margin-right: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.iconfopen {
|
|
||||||
background-image: url(opened-folder.png);
|
|
||||||
margin-right: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.icondoc {
|
|
||||||
background-image: url(document.png);
|
|
||||||
margin-right: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.arrow {
|
|
||||||
color: #7d7d7d;
|
|
||||||
}
|
|
||||||
|
|
||||||
.icona {
|
|
||||||
vertical-align: middle;
|
|
||||||
margin-right: 5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.icon {
|
|
||||||
background-color: var(--icon-bg);
|
|
||||||
color: var(--icon-font);
|
|
||||||
display: table-cell;
|
|
||||||
vertical-align: middle;
|
|
||||||
height: 20px;
|
|
||||||
width: 20px;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.ah {
|
|
||||||
background-color: var(--qindex-icon-bg);
|
|
||||||
color: var(--qindex-icon-font);
|
|
||||||
text-align: center;
|
|
||||||
background-image: none;
|
|
||||||
-webkit-box-shadow: none;
|
|
||||||
box-shadow: none;
|
|
||||||
-webkit-border-radius: 0px;
|
|
||||||
border-radius: 0px;
|
|
||||||
border: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.qindex {
|
|
||||||
background-color: var(--qindex-menu-bg);
|
|
||||||
border: none;
|
|
||||||
padding: 20px;
|
|
||||||
}
|
|
||||||
|
|
||||||
a.qindex {
|
|
||||||
color: var(--qindex-menu-font);
|
|
||||||
font-weight: normal;
|
|
||||||
font-size: 20px;
|
|
||||||
}
|
|
||||||
|
|
||||||
a:hover.qindex {
|
|
||||||
color: var(--qindex-menu-font-hover);
|
|
||||||
}
|
|
||||||
|
|
||||||
a:visited.qindex {
|
|
||||||
color: var(--qindex-menu-font);
|
|
||||||
}
|
|
||||||
|
|
||||||
table.classindex {
|
|
||||||
margin-top: 30px;
|
|
||||||
margin-bottom: 30px;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.classindex a.el {
|
|
||||||
font-weight: normal;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.params {
|
|
||||||
margin-top:1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
#titlearea > table {
|
|
||||||
margin-top:0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.directory > tbody > tr {
|
|
||||||
border-top: thin solid var(--nav-tree-bg);
|
|
||||||
border-bottom: thin solid var(--nav-tree-bg);
|
|
||||||
}
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
/************** footer *************/
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
div.directory {
|
|
||||||
border-top: 1px solid var(--bgborder);
|
|
||||||
border-bottom: none;
|
|
||||||
margin: 20px 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.directory a.el {
|
|
||||||
font-weight: normal;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.directory>table {
|
|
||||||
margin: 20px 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
hr.footer {
|
|
||||||
border: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.contents>hr {
|
|
||||||
border-top: 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
/*********** memberdecls ***********/
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
.memItemLeft, .memItemRight {
|
|
||||||
padding: 15px 30px;
|
|
||||||
background-color: inherit;
|
|
||||||
}
|
|
||||||
|
|
||||||
.mdescRight {
|
|
||||||
padding: 0px 30px 10px 30px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.memberdecls * {
|
|
||||||
background-color: inherit;
|
|
||||||
}
|
|
||||||
|
|
||||||
.memSeparator {
|
|
||||||
border-bottom: 1px solid var(--bgborder2);
|
|
||||||
}
|
|
||||||
|
|
||||||
.memTemplParams {
|
|
||||||
color: var(--bgfont);
|
|
||||||
}
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
/*********** nav-tree ***********/
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
#nav-tree-contents {
|
|
||||||
background-color: var(--nav-tree-bg);
|
|
||||||
margin: 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#side-nav, #nav-tree {
|
|
||||||
background-image: none;
|
|
||||||
background-color: var(--nav-tree-bg);
|
|
||||||
}
|
|
||||||
|
|
||||||
#nav-tree .item {
|
|
||||||
background-color: var(--nav-tree-bg);
|
|
||||||
font-family: Arial;
|
|
||||||
text-shadow: none;
|
|
||||||
font-size: 14px;
|
|
||||||
font-weight: 700;
|
|
||||||
padding: 10px;
|
|
||||||
color: var(--nav-tree-font);
|
|
||||||
}
|
|
||||||
|
|
||||||
#nav-tree .arrow {
|
|
||||||
color: var(--nav-tree-font);
|
|
||||||
}
|
|
||||||
|
|
||||||
#nav-tree .selected {
|
|
||||||
background-image: none;
|
|
||||||
background-color: var(--nav-tree-bg-selected);
|
|
||||||
}
|
|
||||||
|
|
||||||
#nav-tree .selected a {
|
|
||||||
color: var(--nav-tree-font-selected);
|
|
||||||
}
|
|
||||||
|
|
||||||
#nav-tree .item:hover {
|
|
||||||
background-color: var(--nav-tree-bg-hover);
|
|
||||||
color: var(--nav-tree-font-hover);
|
|
||||||
}
|
|
||||||
|
|
||||||
#nav-tree .item a:hover {
|
|
||||||
color: var(--nav-tree-font-hover);
|
|
||||||
}
|
|
||||||
|
|
||||||
#side-nav .ui-resizable-e {
|
|
||||||
background-image: none;
|
|
||||||
background-color: var(--nav-tree-bg);
|
|
||||||
}
|
|
||||||
|
|
||||||
#nav-sync {
|
|
||||||
background-color: transparent;
|
|
||||||
}
|
|
||||||
|
|
||||||
#nav-sync>img {
|
|
||||||
content: url(off_sync.png);
|
|
||||||
}
|
|
||||||
|
|
||||||
#nav-sync.sync>img {
|
|
||||||
content: url(on_sync.png);
|
|
||||||
}
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
/*********** Plant UML ***********/
|
|
||||||
|
|
||||||
/***********************************/
|
|
||||||
|
|
||||||
.plantumlgraph > img {
|
|
||||||
width: 80%;
|
|
||||||
}
|
|
||||||
|
|
@ -26,8 +26,8 @@ endif()
|
||||||
### Include subdirectories
|
### Include subdirectories
|
||||||
######################################################################################
|
######################################################################################
|
||||||
|
|
||||||
add_subdirectory(src)
|
|
||||||
add_subdirectory(doc)
|
add_subdirectory(doc)
|
||||||
|
add_subdirectory(src)
|
||||||
|
|
||||||
if(ENABLE_CMAKE_TESTING AND EIGEN3_FOUND) # see edoNormalAdaptive
|
if(ENABLE_CMAKE_TESTING AND EIGEN3_FOUND) # see edoNormalAdaptive
|
||||||
add_subdirectory(test)
|
add_subdirectory(test)
|
||||||
|
|
|
||||||
502
edo/LICENSE
|
|
@ -1,502 +0,0 @@
|
||||||
GNU LESSER GENERAL PUBLIC LICENSE
|
|
||||||
Version 2.1, February 1999
|
|
||||||
|
|
||||||
Copyright (C) 1991, 1999 Free Software Foundation, Inc.
|
|
||||||
59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
Everyone is permitted to copy and distribute verbatim copies
|
|
||||||
of this license document, but changing it is not allowed.
|
|
||||||
|
|
||||||
[This is the first released version of the Lesser GPL. It also counts
|
|
||||||
as the successor of the GNU Library Public License, version 2, hence
|
|
||||||
the version number 2.1.]
|
|
||||||
|
|
||||||
Preamble
|
|
||||||
|
|
||||||
The licenses for most software are designed to take away your
|
|
||||||
freedom to share and change it. By contrast, the GNU General Public
|
|
||||||
Licenses are intended to guarantee your freedom to share and change
|
|
||||||
free software--to make sure the software is free for all its users.
|
|
||||||
|
|
||||||
This license, the Lesser General Public License, applies to some
|
|
||||||
specially designated software packages--typically libraries--of the
|
|
||||||
Free Software Foundation and other authors who decide to use it. You
|
|
||||||
can use it too, but we suggest you first think carefully about whether
|
|
||||||
this license or the ordinary General Public License is the better
|
|
||||||
strategy to use in any particular case, based on the explanations below.
|
|
||||||
|
|
||||||
When we speak of free software, we are referring to freedom of use,
|
|
||||||
not price. Our General Public Licenses are designed to make sure that
|
|
||||||
you have the freedom to distribute copies of free software (and charge
|
|
||||||
for this service if you wish); that you receive source code or can get
|
|
||||||
it if you want it; that you can change the software and use pieces of
|
|
||||||
it in new free programs; and that you are informed that you can do
|
|
||||||
these things.
|
|
||||||
|
|
||||||
To protect your rights, we need to make restrictions that forbid
|
|
||||||
distributors to deny you these rights or to ask you to surrender these
|
|
||||||
rights. These restrictions translate to certain responsibilities for
|
|
||||||
you if you distribute copies of the library or if you modify it.
|
|
||||||
|
|
||||||
For example, if you distribute copies of the library, whether gratis
|
|
||||||
or for a fee, you must give the recipients all the rights that we gave
|
|
||||||
you. You must make sure that they, too, receive or can get the source
|
|
||||||
code. If you link other code with the library, you must provide
|
|
||||||
complete object files to the recipients, so that they can relink them
|
|
||||||
with the library after making changes to the library and recompiling
|
|
||||||
it. And you must show them these terms so they know their rights.
|
|
||||||
|
|
||||||
We protect your rights with a two-step method: (1) we copyright the
|
|
||||||
library, and (2) we offer you this license, which gives you legal
|
|
||||||
permission to copy, distribute and/or modify the library.
|
|
||||||
|
|
||||||
To protect each distributor, we want to make it very clear that
|
|
||||||
there is no warranty for the free library. Also, if the library is
|
|
||||||
modified by someone else and passed on, the recipients should know
|
|
||||||
that what they have is not the original version, so that the original
|
|
||||||
author's reputation will not be affected by problems that might be
|
|
||||||
introduced by others.
|
|
||||||
|
|
||||||
Finally, software patents pose a constant threat to the existence of
|
|
||||||
any free program. We wish to make sure that a company cannot
|
|
||||||
effectively restrict the users of a free program by obtaining a
|
|
||||||
restrictive license from a patent holder. Therefore, we insist that
|
|
||||||
any patent license obtained for a version of the library must be
|
|
||||||
consistent with the full freedom of use specified in this license.
|
|
||||||
|
|
||||||
Most GNU software, including some libraries, is covered by the
|
|
||||||
ordinary GNU General Public License. This license, the GNU Lesser
|
|
||||||
General Public License, applies to certain designated libraries, and
|
|
||||||
is quite different from the ordinary General Public License. We use
|
|
||||||
this license for certain libraries in order to permit linking those
|
|
||||||
libraries into non-free programs.
|
|
||||||
|
|
||||||
When a program is linked with a library, whether statically or using
|
|
||||||
a shared library, the combination of the two is legally speaking a
|
|
||||||
combined work, a derivative of the original library. The ordinary
|
|
||||||
General Public License therefore permits such linking only if the
|
|
||||||
entire combination fits its criteria of freedom. The Lesser General
|
|
||||||
Public License permits more lax criteria for linking other code with
|
|
||||||
the library.
|
|
||||||
|
|
||||||
We call this license the "Lesser" General Public License because it
|
|
||||||
does Less to protect the user's freedom than the ordinary General
|
|
||||||
Public License. It also provides other free software developers Less
|
|
||||||
of an advantage over competing non-free programs. These disadvantages
|
|
||||||
are the reason we use the ordinary General Public License for many
|
|
||||||
libraries. However, the Lesser license provides advantages in certain
|
|
||||||
special circumstances.
|
|
||||||
|
|
||||||
For example, on rare occasions, there may be a special need to
|
|
||||||
encourage the widest possible use of a certain library, so that it becomes
|
|
||||||
a de-facto standard. To achieve this, non-free programs must be
|
|
||||||
allowed to use the library. A more frequent case is that a free
|
|
||||||
library does the same job as widely used non-free libraries. In this
|
|
||||||
case, there is little to gain by limiting the free library to free
|
|
||||||
software only, so we use the Lesser General Public License.
|
|
||||||
|
|
||||||
In other cases, permission to use a particular library in non-free
|
|
||||||
programs enables a greater number of people to use a large body of
|
|
||||||
free software. For example, permission to use the GNU C Library in
|
|
||||||
non-free programs enables many more people to use the whole GNU
|
|
||||||
operating system, as well as its variant, the GNU/Linux operating
|
|
||||||
system.
|
|
||||||
|
|
||||||
Although the Lesser General Public License is Less protective of the
|
|
||||||
users' freedom, it does ensure that the user of a program that is
|
|
||||||
linked with the Library has the freedom and the wherewithal to run
|
|
||||||
that program using a modified version of the Library.
|
|
||||||
|
|
||||||
The precise terms and conditions for copying, distribution and
|
|
||||||
modification follow. Pay close attention to the difference between a
|
|
||||||
"work based on the library" and a "work that uses the library". The
|
|
||||||
former contains code derived from the library, whereas the latter must
|
|
||||||
be combined with the library in order to run.
|
|
||||||
|
|
||||||
GNU LESSER GENERAL PUBLIC LICENSE
|
|
||||||
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
|
||||||
|
|
||||||
0. This License Agreement applies to any software library or other
|
|
||||||
program which contains a notice placed by the copyright holder or
|
|
||||||
other authorized party saying it may be distributed under the terms of
|
|
||||||
this Lesser General Public License (also called "this License").
|
|
||||||
Each licensee is addressed as "you".
|
|
||||||
|
|
||||||
A "library" means a collection of software functions and/or data
|
|
||||||
prepared so as to be conveniently linked with application programs
|
|
||||||
(which use some of those functions and data) to form executables.
|
|
||||||
|
|
||||||
The "Library", below, refers to any such software library or work
|
|
||||||
which has been distributed under these terms. A "work based on the
|
|
||||||
Library" means either the Library or any derivative work under
|
|
||||||
copyright law: that is to say, a work containing the Library or a
|
|
||||||
portion of it, either verbatim or with modifications and/or translated
|
|
||||||
straightforwardly into another language. (Hereinafter, translation is
|
|
||||||
included without limitation in the term "modification".)
|
|
||||||
|
|
||||||
"Source code" for a work means the preferred form of the work for
|
|
||||||
making modifications to it. For a library, complete source code means
|
|
||||||
all the source code for all modules it contains, plus any associated
|
|
||||||
interface definition files, plus the scripts used to control compilation
|
|
||||||
and installation of the library.
|
|
||||||
|
|
||||||
Activities other than copying, distribution and modification are not
|
|
||||||
covered by this License; they are outside its scope. The act of
|
|
||||||
running a program using the Library is not restricted, and output from
|
|
||||||
such a program is covered only if its contents constitute a work based
|
|
||||||
on the Library (independent of the use of the Library in a tool for
|
|
||||||
writing it). Whether that is true depends on what the Library does
|
|
||||||
and what the program that uses the Library does.
|
|
||||||
|
|
||||||
1. You may copy and distribute verbatim copies of the Library's
|
|
||||||
complete source code as you receive it, in any medium, provided that
|
|
||||||
you conspicuously and appropriately publish on each copy an
|
|
||||||
appropriate copyright notice and disclaimer of warranty; keep intact
|
|
||||||
all the notices that refer to this License and to the absence of any
|
|
||||||
warranty; and distribute a copy of this License along with the
|
|
||||||
Library.
|
|
||||||
|
|
||||||
You may charge a fee for the physical act of transferring a copy,
|
|
||||||
and you may at your option offer warranty protection in exchange for a
|
|
||||||
fee.
|
|
||||||
|
|
||||||
2. You may modify your copy or copies of the Library or any portion
|
|
||||||
of it, thus forming a work based on the Library, and copy and
|
|
||||||
distribute such modifications or work under the terms of Section 1
|
|
||||||
above, provided that you also meet all of these conditions:
|
|
||||||
|
|
||||||
a) The modified work must itself be a software library.
|
|
||||||
|
|
||||||
b) You must cause the files modified to carry prominent notices
|
|
||||||
stating that you changed the files and the date of any change.
|
|
||||||
|
|
||||||
c) You must cause the whole of the work to be licensed at no
|
|
||||||
charge to all third parties under the terms of this License.
|
|
||||||
|
|
||||||
d) If a facility in the modified Library refers to a function or a
|
|
||||||
table of data to be supplied by an application program that uses
|
|
||||||
the facility, other than as an argument passed when the facility
|
|
||||||
is invoked, then you must make a good faith effort to ensure that,
|
|
||||||
in the event an application does not supply such function or
|
|
||||||
table, the facility still operates, and performs whatever part of
|
|
||||||
its purpose remains meaningful.
|
|
||||||
|
|
||||||
(For example, a function in a library to compute square roots has
|
|
||||||
a purpose that is entirely well-defined independent of the
|
|
||||||
application. Therefore, Subsection 2d requires that any
|
|
||||||
application-supplied function or table used by this function must
|
|
||||||
be optional: if the application does not supply it, the square
|
|
||||||
root function must still compute square roots.)
|
|
||||||
|
|
||||||
These requirements apply to the modified work as a whole. If
|
|
||||||
identifiable sections of that work are not derived from the Library,
|
|
||||||
and can be reasonably considered independent and separate works in
|
|
||||||
themselves, then this License, and its terms, do not apply to those
|
|
||||||
sections when you distribute them as separate works. But when you
|
|
||||||
distribute the same sections as part of a whole which is a work based
|
|
||||||
on the Library, the distribution of the whole must be on the terms of
|
|
||||||
this License, whose permissions for other licensees extend to the
|
|
||||||
entire whole, and thus to each and every part regardless of who wrote
|
|
||||||
it.
|
|
||||||
|
|
||||||
Thus, it is not the intent of this section to claim rights or contest
|
|
||||||
your rights to work written entirely by you; rather, the intent is to
|
|
||||||
exercise the right to control the distribution of derivative or
|
|
||||||
collective works based on the Library.
|
|
||||||
|
|
||||||
In addition, mere aggregation of another work not based on the Library
|
|
||||||
with the Library (or with a work based on the Library) on a volume of
|
|
||||||
a storage or distribution medium does not bring the other work under
|
|
||||||
the scope of this License.
|
|
||||||
|
|
||||||
3. You may opt to apply the terms of the ordinary GNU General Public
|
|
||||||
License instead of this License to a given copy of the Library. To do
|
|
||||||
this, you must alter all the notices that refer to this License, so
|
|
||||||
that they refer to the ordinary GNU General Public License, version 2,
|
|
||||||
instead of to this License. (If a newer version than version 2 of the
|
|
||||||
ordinary GNU General Public License has appeared, then you can specify
|
|
||||||
that version instead if you wish.) Do not make any other change in
|
|
||||||
these notices.
|
|
||||||
|
|
||||||
Once this change is made in a given copy, it is irreversible for
|
|
||||||
that copy, so the ordinary GNU General Public License applies to all
|
|
||||||
subsequent copies and derivative works made from that copy.
|
|
||||||
|
|
||||||
This option is useful when you wish to copy part of the code of
|
|
||||||
the Library into a program that is not a library.
|
|
||||||
|
|
||||||
4. You may copy and distribute the Library (or a portion or
|
|
||||||
derivative of it, under Section 2) in object code or executable form
|
|
||||||
under the terms of Sections 1 and 2 above provided that you accompany
|
|
||||||
it with the complete corresponding machine-readable source code, which
|
|
||||||
must be distributed under the terms of Sections 1 and 2 above on a
|
|
||||||
medium customarily used for software interchange.
|
|
||||||
|
|
||||||
If distribution of object code is made by offering access to copy
|
|
||||||
from a designated place, then offering equivalent access to copy the
|
|
||||||
source code from the same place satisfies the requirement to
|
|
||||||
distribute the source code, even though third parties are not
|
|
||||||
compelled to copy the source along with the object code.
|
|
||||||
|
|
||||||
5. A program that contains no derivative of any portion of the
|
|
||||||
Library, but is designed to work with the Library by being compiled or
|
|
||||||
linked with it, is called a "work that uses the Library". Such a
|
|
||||||
work, in isolation, is not a derivative work of the Library, and
|
|
||||||
therefore falls outside the scope of this License.
|
|
||||||
|
|
||||||
However, linking a "work that uses the Library" with the Library
|
|
||||||
creates an executable that is a derivative of the Library (because it
|
|
||||||
contains portions of the Library), rather than a "work that uses the
|
|
||||||
library". The executable is therefore covered by this License.
|
|
||||||
Section 6 states terms for distribution of such executables.
|
|
||||||
|
|
||||||
When a "work that uses the Library" uses material from a header file
|
|
||||||
that is part of the Library, the object code for the work may be a
|
|
||||||
derivative work of the Library even though the source code is not.
|
|
||||||
Whether this is true is especially significant if the work can be
|
|
||||||
linked without the Library, or if the work is itself a library. The
|
|
||||||
threshold for this to be true is not precisely defined by law.
|
|
||||||
|
|
||||||
If such an object file uses only numerical parameters, data
|
|
||||||
structure layouts and accessors, and small macros and small inline
|
|
||||||
functions (ten lines or less in length), then the use of the object
|
|
||||||
file is unrestricted, regardless of whether it is legally a derivative
|
|
||||||
work. (Executables containing this object code plus portions of the
|
|
||||||
Library will still fall under Section 6.)
|
|
||||||
|
|
||||||
Otherwise, if the work is a derivative of the Library, you may
|
|
||||||
distribute the object code for the work under the terms of Section 6.
|
|
||||||
Any executables containing that work also fall under Section 6,
|
|
||||||
whether or not they are linked directly with the Library itself.
|
|
||||||
|
|
||||||
6. As an exception to the Sections above, you may also combine or
|
|
||||||
link a "work that uses the Library" with the Library to produce a
|
|
||||||
work containing portions of the Library, and distribute that work
|
|
||||||
under terms of your choice, provided that the terms permit
|
|
||||||
modification of the work for the customer's own use and reverse
|
|
||||||
engineering for debugging such modifications.
|
|
||||||
|
|
||||||
You must give prominent notice with each copy of the work that the
|
|
||||||
Library is used in it and that the Library and its use are covered by
|
|
||||||
this License. You must supply a copy of this License. If the work
|
|
||||||
during execution displays copyright notices, you must include the
|
|
||||||
copyright notice for the Library among them, as well as a reference
|
|
||||||
directing the user to the copy of this License. Also, you must do one
|
|
||||||
of these things:
|
|
||||||
|
|
||||||
a) Accompany the work with the complete corresponding
|
|
||||||
machine-readable source code for the Library including whatever
|
|
||||||
changes were used in the work (which must be distributed under
|
|
||||||
Sections 1 and 2 above); and, if the work is an executable linked
|
|
||||||
with the Library, with the complete machine-readable "work that
|
|
||||||
uses the Library", as object code and/or source code, so that the
|
|
||||||
user can modify the Library and then relink to produce a modified
|
|
||||||
executable containing the modified Library. (It is understood
|
|
||||||
that the user who changes the contents of definitions files in the
|
|
||||||
Library will not necessarily be able to recompile the application
|
|
||||||
to use the modified definitions.)
|
|
||||||
|
|
||||||
b) Use a suitable shared library mechanism for linking with the
|
|
||||||
Library. A suitable mechanism is one that (1) uses at run time a
|
|
||||||
copy of the library already present on the user's computer system,
|
|
||||||
rather than copying library functions into the executable, and (2)
|
|
||||||
will operate properly with a modified version of the library, if
|
|
||||||
the user installs one, as long as the modified version is
|
|
||||||
interface-compatible with the version that the work was made with.
|
|
||||||
|
|
||||||
c) Accompany the work with a written offer, valid for at
|
|
||||||
least three years, to give the same user the materials
|
|
||||||
specified in Subsection 6a, above, for a charge no more
|
|
||||||
than the cost of performing this distribution.
|
|
||||||
|
|
||||||
d) If distribution of the work is made by offering access to copy
|
|
||||||
from a designated place, offer equivalent access to copy the above
|
|
||||||
specified materials from the same place.
|
|
||||||
|
|
||||||
e) Verify that the user has already received a copy of these
|
|
||||||
materials or that you have already sent this user a copy.
|
|
||||||
|
|
||||||
For an executable, the required form of the "work that uses the
|
|
||||||
Library" must include any data and utility programs needed for
|
|
||||||
reproducing the executable from it. However, as a special exception,
|
|
||||||
the materials to be distributed need not include anything that is
|
|
||||||
normally distributed (in either source or binary form) with the major
|
|
||||||
components (compiler, kernel, and so on) of the operating system on
|
|
||||||
which the executable runs, unless that component itself accompanies
|
|
||||||
the executable.
|
|
||||||
|
|
||||||
It may happen that this requirement contradicts the license
|
|
||||||
restrictions of other proprietary libraries that do not normally
|
|
||||||
accompany the operating system. Such a contradiction means you cannot
|
|
||||||
use both them and the Library together in an executable that you
|
|
||||||
distribute.
|
|
||||||
|
|
||||||
7. You may place library facilities that are a work based on the
|
|
||||||
Library side-by-side in a single library together with other library
|
|
||||||
facilities not covered by this License, and distribute such a combined
|
|
||||||
library, provided that the separate distribution of the work based on
|
|
||||||
the Library and of the other library facilities is otherwise
|
|
||||||
permitted, and provided that you do these two things:
|
|
||||||
|
|
||||||
a) Accompany the combined library with a copy of the same work
|
|
||||||
based on the Library, uncombined with any other library
|
|
||||||
facilities. This must be distributed under the terms of the
|
|
||||||
Sections above.
|
|
||||||
|
|
||||||
b) Give prominent notice with the combined library of the fact
|
|
||||||
that part of it is a work based on the Library, and explaining
|
|
||||||
where to find the accompanying uncombined form of the same work.
|
|
||||||
|
|
||||||
8. You may not copy, modify, sublicense, link with, or distribute
|
|
||||||
the Library except as expressly provided under this License. Any
|
|
||||||
attempt otherwise to copy, modify, sublicense, link with, or
|
|
||||||
distribute the Library is void, and will automatically terminate your
|
|
||||||
rights under this License. However, parties who have received copies,
|
|
||||||
or rights, from you under this License will not have their licenses
|
|
||||||
terminated so long as such parties remain in full compliance.
|
|
||||||
|
|
||||||
9. You are not required to accept this License, since you have not
|
|
||||||
signed it. However, nothing else grants you permission to modify or
|
|
||||||
distribute the Library or its derivative works. These actions are
|
|
||||||
prohibited by law if you do not accept this License. Therefore, by
|
|
||||||
modifying or distributing the Library (or any work based on the
|
|
||||||
Library), you indicate your acceptance of this License to do so, and
|
|
||||||
all its terms and conditions for copying, distributing or modifying
|
|
||||||
the Library or works based on it.
|
|
||||||
|
|
||||||
10. Each time you redistribute the Library (or any work based on the
|
|
||||||
Library), the recipient automatically receives a license from the
|
|
||||||
original licensor to copy, distribute, link with or modify the Library
|
|
||||||
subject to these terms and conditions. You may not impose any further
|
|
||||||
restrictions on the recipients' exercise of the rights granted herein.
|
|
||||||
You are not responsible for enforcing compliance by third parties with
|
|
||||||
this License.
|
|
||||||
|
|
||||||
11. If, as a consequence of a court judgment or allegation of patent
|
|
||||||
infringement or for any other reason (not limited to patent issues),
|
|
||||||
conditions are imposed on you (whether by court order, agreement or
|
|
||||||
otherwise) that contradict the conditions of this License, they do not
|
|
||||||
excuse you from the conditions of this License. If you cannot
|
|
||||||
distribute so as to satisfy simultaneously your obligations under this
|
|
||||||
License and any other pertinent obligations, then as a consequence you
|
|
||||||
may not distribute the Library at all. For example, if a patent
|
|
||||||
license would not permit royalty-free redistribution of the Library by
|
|
||||||
all those who receive copies directly or indirectly through you, then
|
|
||||||
the only way you could satisfy both it and this License would be to
|
|
||||||
refrain entirely from distribution of the Library.
|
|
||||||
|
|
||||||
If any portion of this section is held invalid or unenforceable under any
|
|
||||||
particular circumstance, the balance of the section is intended to apply,
|
|
||||||
and the section as a whole is intended to apply in other circumstances.
|
|
||||||
|
|
||||||
It is not the purpose of this section to induce you to infringe any
|
|
||||||
patents or other property right claims or to contest validity of any
|
|
||||||
such claims; this section has the sole purpose of protecting the
|
|
||||||
integrity of the free software distribution system which is
|
|
||||||
implemented by public license practices. Many people have made
|
|
||||||
generous contributions to the wide range of software distributed
|
|
||||||
through that system in reliance on consistent application of that
|
|
||||||
system; it is up to the author/donor to decide if he or she is willing
|
|
||||||
to distribute software through any other system and a licensee cannot
|
|
||||||
impose that choice.
|
|
||||||
|
|
||||||
This section is intended to make thoroughly clear what is believed to
|
|
||||||
be a consequence of the rest of this License.
|
|
||||||
|
|
||||||
12. If the distribution and/or use of the Library is restricted in
|
|
||||||
certain countries either by patents or by copyrighted interfaces, the
|
|
||||||
original copyright holder who places the Library under this License may add
|
|
||||||
an explicit geographical distribution limitation excluding those countries,
|
|
||||||
so that distribution is permitted only in or among countries not thus
|
|
||||||
excluded. In such case, this License incorporates the limitation as if
|
|
||||||
written in the body of this License.
|
|
||||||
|
|
||||||
13. The Free Software Foundation may publish revised and/or new
|
|
||||||
versions of the Lesser General Public License from time to time.
|
|
||||||
Such new versions will be similar in spirit to the present version,
|
|
||||||
but may differ in detail to address new problems or concerns.
|
|
||||||
|
|
||||||
Each version is given a distinguishing version number. If the Library
|
|
||||||
specifies a version number of this License which applies to it and
|
|
||||||
"any later version", you have the option of following the terms and
|
|
||||||
conditions either of that version or of any later version published by
|
|
||||||
the Free Software Foundation. If the Library does not specify a
|
|
||||||
license version number, you may choose any version ever published by
|
|
||||||
the Free Software Foundation.
|
|
||||||
|
|
||||||
14. If you wish to incorporate parts of the Library into other free
|
|
||||||
programs whose distribution conditions are incompatible with these,
|
|
||||||
write to the author to ask for permission. For software which is
|
|
||||||
copyrighted by the Free Software Foundation, write to the Free
|
|
||||||
Software Foundation; we sometimes make exceptions for this. Our
|
|
||||||
decision will be guided by the two goals of preserving the free status
|
|
||||||
of all derivatives of our free software and of promoting the sharing
|
|
||||||
and reuse of software generally.
|
|
||||||
|
|
||||||
NO WARRANTY
|
|
||||||
|
|
||||||
15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
|
|
||||||
WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
|
|
||||||
EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR
|
|
||||||
OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY
|
|
||||||
KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
|
|
||||||
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
|
||||||
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
|
|
||||||
LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME
|
|
||||||
THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
|
||||||
|
|
||||||
16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
|
|
||||||
WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY
|
|
||||||
AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU
|
|
||||||
FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR
|
|
||||||
CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE
|
|
||||||
LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
|
|
||||||
RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
|
|
||||||
FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
|
|
||||||
SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
|
|
||||||
DAMAGES.
|
|
||||||
|
|
||||||
END OF TERMS AND CONDITIONS
|
|
||||||
|
|
||||||
How to Apply These Terms to Your New Libraries
|
|
||||||
|
|
||||||
If you develop a new library, and you want it to be of the greatest
|
|
||||||
possible use to the public, we recommend making it free software that
|
|
||||||
everyone can redistribute and change. You can do so by permitting
|
|
||||||
redistribution under these terms (or, alternatively, under the terms of the
|
|
||||||
ordinary General Public License).
|
|
||||||
|
|
||||||
To apply these terms, attach the following notices to the library. It is
|
|
||||||
safest to attach them to the start of each source file to most effectively
|
|
||||||
convey the exclusion of warranty; and each file should have at least the
|
|
||||||
"copyright" line and a pointer to where the full notice is found.
|
|
||||||
|
|
||||||
<one line to give the library's name and a brief idea of what it does.>
|
|
||||||
Copyright (C) <year> <name of author>
|
|
||||||
|
|
||||||
This library is free software; you can redistribute it and/or
|
|
||||||
modify it under the terms of the GNU Lesser General Public
|
|
||||||
License as published by the Free Software Foundation; either
|
|
||||||
version 2 of the License, or (at your option) any later version.
|
|
||||||
|
|
||||||
This library is distributed in the hope that it will be useful,
|
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
||||||
Lesser General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU Lesser General Public
|
|
||||||
License along with this library; if not, write to the Free Software
|
|
||||||
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
|
|
||||||
Also add information on how to contact you by electronic and paper mail.
|
|
||||||
|
|
||||||
You should also get your employer (if you work as a programmer) or your
|
|
||||||
school, if any, to sign a "copyright disclaimer" for the library, if
|
|
||||||
necessary. Here is a sample; alter the names:
|
|
||||||
|
|
||||||
Yoyodyne, Inc., hereby disclaims all copyright interest in the
|
|
||||||
library `Frob' (a library for tweaking knobs) written by James Random Hacker.
|
|
||||||
|
|
||||||
<signature of Ty Coon>, 1 April 1990
|
|
||||||
Ty Coon, President of Vice
|
|
||||||
|
|
||||||
That's all there is to it!
|
|
||||||
|
|
@ -28,7 +28,7 @@ Authors:
|
||||||
#include <eo>
|
#include <eo>
|
||||||
//#include <mo>
|
//#include <mo>
|
||||||
|
|
||||||
#include <eoEvalCounterThrowException.h>
|
#include <eoEvalFuncCounterBounder.h>
|
||||||
|
|
||||||
#include <do/make_pop.h>
|
#include <do/make_pop.h>
|
||||||
#include <do/make_run.h>
|
#include <do/make_run.h>
|
||||||
|
|
@ -67,7 +67,7 @@ int main(int ac, char** av)
|
||||||
eoEvalFunc< RealVec >* plainEval = new Rosenbrock< RealVec >();
|
eoEvalFunc< RealVec >* plainEval = new Rosenbrock< RealVec >();
|
||||||
state.storeFunctor(plainEval);
|
state.storeFunctor(plainEval);
|
||||||
|
|
||||||
eoEvalCounterThrowException< RealVec > eval(*plainEval, max_eval);
|
eoEvalFuncCounterBounder< RealVec > eval(*plainEval, max_eval);
|
||||||
|
|
||||||
eoRndGenerator< double >* gen = new eoUniformGenerator< double >(-5, 5);
|
eoRndGenerator< double >* gen = new eoUniformGenerator< double >(-5, 5);
|
||||||
state.storeFunctor(gen);
|
state.storeFunctor(gen);
|
||||||
|
|
@ -84,7 +84,7 @@ int main(int ac, char** av)
|
||||||
eoPop< RealVec >& pop = do_make_pop(parser, state, *init);
|
eoPop< RealVec >& pop = do_make_pop(parser, state, *init);
|
||||||
|
|
||||||
// (2) First evaluation before starting the research algorithm
|
// (2) First evaluation before starting the research algorithm
|
||||||
::apply(eval, pop);
|
apply(eval, pop);
|
||||||
|
|
||||||
// Prepare bounder class to set bounds of sampling.
|
// Prepare bounder class to set bounds of sampling.
|
||||||
// This is used by edoSampler.
|
// This is used by edoSampler.
|
||||||
|
|
@ -145,7 +145,7 @@ int main(int ac, char** av)
|
||||||
eo::log << eo::progress << "Best solution after random init: " << pop.best_element().fitness() << std::endl;
|
eo::log << eo::progress << "Best solution after random init: " << pop.best_element().fitness() << std::endl;
|
||||||
do_run(*algo, pop);
|
do_run(*algo, pop);
|
||||||
|
|
||||||
} catch (eoMaxEvalException& e) {
|
} catch (eoEvalFuncCounterBounderException& e) {
|
||||||
eo::log << eo::warnings << "warning: " << e.what() << std::endl;
|
eo::log << eo::warnings << "warning: " << e.what() << std::endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -28,7 +28,7 @@ Authors:
|
||||||
#include <eo>
|
#include <eo>
|
||||||
// #include <mo>
|
// #include <mo>
|
||||||
|
|
||||||
#include <eoEvalCounterThrowException.h>
|
#include <eoEvalFuncCounterBounder.h>
|
||||||
|
|
||||||
#include <do/make_pop.h>
|
#include <do/make_pop.h>
|
||||||
#include <do/make_run.h>
|
#include <do/make_run.h>
|
||||||
|
|
@ -69,7 +69,7 @@ int main(int ac, char** av)
|
||||||
state.storeFunctor(plainEval);
|
state.storeFunctor(plainEval);
|
||||||
|
|
||||||
unsigned long max_eval = parser.getORcreateParam((unsigned long)0, "maxEval", "Maximum number of evaluations (0 = none)", 'E', "Stopping criterion").value(); // E
|
unsigned long max_eval = parser.getORcreateParam((unsigned long)0, "maxEval", "Maximum number of evaluations (0 = none)", 'E', "Stopping criterion").value(); // E
|
||||||
eoEvalCounterThrowException< EOT > eval(*plainEval, max_eval);
|
eoEvalFuncCounterBounder< EOT > eval(*plainEval, max_eval);
|
||||||
|
|
||||||
eoRndGenerator< double >* gen = new eoUniformGenerator< double >(-5, 5);
|
eoRndGenerator< double >* gen = new eoUniformGenerator< double >(-5, 5);
|
||||||
state.storeFunctor(gen);
|
state.storeFunctor(gen);
|
||||||
|
|
@ -87,7 +87,7 @@ int main(int ac, char** av)
|
||||||
eoPop< EOT >& pop = do_make_pop(parser, state, *init);
|
eoPop< EOT >& pop = do_make_pop(parser, state, *init);
|
||||||
|
|
||||||
// (2) First evaluation before starting the research algorithm
|
// (2) First evaluation before starting the research algorithm
|
||||||
::apply(eval, pop);
|
apply(eval, pop);
|
||||||
|
|
||||||
// Prepare bounder class to set bounds of sampling.
|
// Prepare bounder class to set bounds of sampling.
|
||||||
// This is used by edoSampler.
|
// This is used by edoSampler.
|
||||||
|
|
@ -169,7 +169,7 @@ int main(int ac, char** av)
|
||||||
try {
|
try {
|
||||||
do_run(*algo, pop);
|
do_run(*algo, pop);
|
||||||
|
|
||||||
} catch (eoMaxEvalException& e) {
|
} catch (eoEvalFuncCounterBounderException& e) {
|
||||||
eo::log << eo::warnings << "warning: " << e.what() << std::endl;
|
eo::log << eo::warnings << "warning: " << e.what() << std::endl;
|
||||||
|
|
||||||
} catch (std::exception& e) {
|
} catch (std::exception& e) {
|
||||||
|
|
|
||||||
|
|
@ -22,8 +22,7 @@ if(DOXYGEN_FOUND)
|
||||||
)
|
)
|
||||||
endif(UNIX AND NOT ${CMAKE_VERBOSE_MAKEFILE})
|
endif(UNIX AND NOT ${CMAKE_VERBOSE_MAKEFILE})
|
||||||
endif(DOXYGEN_EXECUTABLE)
|
endif(DOXYGEN_EXECUTABLE)
|
||||||
# configure_file("${CMAKE_CURRENT_SOURCE_DIR}/${EDO_DOC_CONFIG_FILE}.cmake"
|
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/${EDO_DOC_CONFIG_FILE}.cmake"
|
||||||
configure_file("${DOXYGEN_CONFIG_DIR}/doxyfile.cmake"
|
|
||||||
"${EDO_DOC_DIR}/${EDO_DOC_CONFIG_FILE}")
|
"${EDO_DOC_DIR}/${EDO_DOC_CONFIG_FILE}")
|
||||||
install(
|
install(
|
||||||
DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
|
DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
|
||||||
|
|
|
||||||
|
|
@ -25,13 +25,13 @@ DOXYFILE_ENCODING = UTF-8
|
||||||
# The PROJECT_NAME tag is a single word (or a sequence of words surrounded
|
# The PROJECT_NAME tag is a single word (or a sequence of words surrounded
|
||||||
# by quotes) that should identify the project.
|
# by quotes) that should identify the project.
|
||||||
|
|
||||||
PROJECT_NAME = @EDO_MODULE_NAME@
|
PROJECT_NAME = @PACKAGE_NAME@
|
||||||
|
|
||||||
# The PROJECT_NUMBER tag can be used to enter a project or revision number.
|
# The PROJECT_NUMBER tag can be used to enter a project or revision number.
|
||||||
# This could be handy for archiving the generated documentation or
|
# This could be handy for archiving the generated documentation or
|
||||||
# if some version control system is used.
|
# if some version control system is used.
|
||||||
|
|
||||||
PROJECT_NUMBER = @PROJECT_VERSION@
|
PROJECT_NUMBER = @PACKAGE_VERSION@
|
||||||
|
|
||||||
# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute)
|
# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute)
|
||||||
# base path where the generated documentation will be put.
|
# base path where the generated documentation will be put.
|
||||||
|
|
@ -1030,7 +1030,7 @@ SERVER_BASED_SEARCH = NO
|
||||||
# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will
|
# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will
|
||||||
# generate Latex output.
|
# generate Latex output.
|
||||||
|
|
||||||
GENERATE_LATEX = NO
|
GENERATE_LATEX = YES
|
||||||
|
|
||||||
# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put.
|
# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put.
|
||||||
# If a relative path is entered the value of OUTPUT_DIRECTORY will be
|
# If a relative path is entered the value of OUTPUT_DIRECTORY will be
|
||||||
|
|
|
||||||
|
|
@ -46,12 +46,9 @@ Authors:
|
||||||
#include "edoEstimatorNormalMono.h"
|
#include "edoEstimatorNormalMono.h"
|
||||||
#include "edoEstimatorNormalMulti.h"
|
#include "edoEstimatorNormalMulti.h"
|
||||||
#include "edoEstimatorAdaptive.h"
|
#include "edoEstimatorAdaptive.h"
|
||||||
#include "edoEstimatorAdaptiveReset.h"
|
|
||||||
#include "edoEstimatorAdaptiveEdit.h"
|
|
||||||
#include "edoEstimatorNormalAdaptive.h"
|
#include "edoEstimatorNormalAdaptive.h"
|
||||||
#include "edoEstimatorBinomial.h"
|
#include "edoEstimatorBinomial.h"
|
||||||
#include "edoEstimatorBinomialMulti.h"
|
#include "edoEstimatorBinomialMulti.h"
|
||||||
#include "edoEstimatorCombined.h"
|
|
||||||
|
|
||||||
#include "edoModifier.h"
|
#include "edoModifier.h"
|
||||||
#include "edoModifierDispersion.h"
|
#include "edoModifierDispersion.h"
|
||||||
|
|
@ -81,9 +78,6 @@ Authors:
|
||||||
#include "edoBounderUniform.h"
|
#include "edoBounderUniform.h"
|
||||||
|
|
||||||
#include "edoContinue.h"
|
#include "edoContinue.h"
|
||||||
#include "edoCombinedContinue.h"
|
|
||||||
#include "edoContAdaptiveIllCovar.h"
|
|
||||||
#include "edoContAdaptiveFinite.h"
|
|
||||||
#include "utils/edoCheckPoint.h"
|
#include "utils/edoCheckPoint.h"
|
||||||
|
|
||||||
#include "utils/edoStat.h"
|
#include "utils/edoStat.h"
|
||||||
|
|
@ -96,8 +90,6 @@ Authors:
|
||||||
|
|
||||||
#include "edoTransform.h"
|
#include "edoTransform.h"
|
||||||
|
|
||||||
#include "edoDistribReset.h"
|
|
||||||
|
|
||||||
#endif // !_edo_
|
#endif // !_edo_
|
||||||
|
|
||||||
// Local Variables:
|
// Local Variables:
|
||||||
|
|
|
||||||
|
|
@ -34,7 +34,7 @@ Authors:
|
||||||
|
|
||||||
#include "edoAlgo.h"
|
#include "edoAlgo.h"
|
||||||
#include "edoEstimator.h"
|
#include "edoEstimator.h"
|
||||||
// #include "edoModifierMass.h"
|
#include "edoModifierMass.h"
|
||||||
#include "edoSampler.h"
|
#include "edoSampler.h"
|
||||||
#include "edoContinue.h"
|
#include "edoContinue.h"
|
||||||
|
|
||||||
|
|
@ -67,44 +67,7 @@ public:
|
||||||
public:
|
public:
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
Takes all operators.
|
Takes algo operators, all are mandatory
|
||||||
|
|
||||||
\param distrib A distribution to use, if you want to update this parameter (e.g. CMA-ES) instead of replacing it (e.g. an EDA)
|
|
||||||
\param evaluator Evaluate a population
|
|
||||||
\param selector Selection of the best candidate solutions in the population
|
|
||||||
\param estimator Estimation of the distribution parameters
|
|
||||||
\param estimator_init Estimation of the distribution parameters, called before the main loop.
|
|
||||||
\param sampler Generate feasible solutions using the distribution
|
|
||||||
\param replacor Replace old solutions by new ones
|
|
||||||
\param pop_continuator Stopping criterion based on the population features
|
|
||||||
\param distribution_continuator Stopping criterion based on the distribution features
|
|
||||||
*/
|
|
||||||
edoAlgoAdaptive(
|
|
||||||
D & distrib,
|
|
||||||
eoPopEvalFunc < EOType > & evaluator,
|
|
||||||
eoSelect< EOType > & selector,
|
|
||||||
edoEstimator< D > & estimator,
|
|
||||||
edoEstimator< D > & estimator_init,
|
|
||||||
edoSampler< D > & sampler,
|
|
||||||
eoReplacement< EOType > & replacor,
|
|
||||||
eoContinue< EOType > & pop_continuator,
|
|
||||||
edoContinue< D > & distribution_continuator
|
|
||||||
) :
|
|
||||||
_distrib(distrib),
|
|
||||||
_evaluator(evaluator),
|
|
||||||
_selector(selector),
|
|
||||||
_estimator(estimator),
|
|
||||||
_estimator_init(estimator_init),
|
|
||||||
_sampler(sampler),
|
|
||||||
_replacor(replacor),
|
|
||||||
_pop_continuator(pop_continuator),
|
|
||||||
_dummy_continue(),
|
|
||||||
_distribution_continuator(distribution_continuator)
|
|
||||||
{}
|
|
||||||
|
|
||||||
|
|
||||||
/*!
|
|
||||||
Without the initialization estimator (set the same estimator everywhere).
|
|
||||||
|
|
||||||
\param distrib A distribution to use, if you want to update this parameter (e.gMA-ES) instead of replacing it (e.g. an EDA)
|
\param distrib A distribution to use, if you want to update this parameter (e.gMA-ES) instead of replacing it (e.g. an EDA)
|
||||||
\param evaluator Evaluate a population
|
\param evaluator Evaluate a population
|
||||||
|
|
@ -129,7 +92,6 @@ public:
|
||||||
_evaluator(evaluator),
|
_evaluator(evaluator),
|
||||||
_selector(selector),
|
_selector(selector),
|
||||||
_estimator(estimator),
|
_estimator(estimator),
|
||||||
_estimator_init(estimator),
|
|
||||||
_sampler(sampler),
|
_sampler(sampler),
|
||||||
_replacor(replacor),
|
_replacor(replacor),
|
||||||
_pop_continuator(pop_continuator),
|
_pop_continuator(pop_continuator),
|
||||||
|
|
@ -163,7 +125,6 @@ public:
|
||||||
_evaluator(evaluator),
|
_evaluator(evaluator),
|
||||||
_selector(selector),
|
_selector(selector),
|
||||||
_estimator(estimator),
|
_estimator(estimator),
|
||||||
_estimator_init(estimator),
|
|
||||||
_sampler(sampler),
|
_sampler(sampler),
|
||||||
_replacor(replacor),
|
_replacor(replacor),
|
||||||
_pop_continuator(pop_continuator),
|
_pop_continuator(pop_continuator),
|
||||||
|
|
@ -180,18 +141,18 @@ public:
|
||||||
{
|
{
|
||||||
assert(pop.size() > 0);
|
assert(pop.size() > 0);
|
||||||
|
|
||||||
|
eoPop< EOType > current_pop;
|
||||||
|
eoPop< EOType > selected_pop;
|
||||||
|
|
||||||
// update the extern distribution passed to the estimator (cf. CMA-ES)
|
// update the extern distribution passed to the estimator (cf. CMA-ES)
|
||||||
// OR replace the dummy distribution for estimators that do not need extern distributions (cf. EDA)
|
// OR replace the dummy distribution for estimators that do not need extern distributions (cf. EDA)
|
||||||
_distrib = _estimator_init(pop);
|
_distrib = _estimator(pop);
|
||||||
|
|
||||||
// Evaluating a first time the candidate solutions
|
// Evaluating a first time the candidate solutions
|
||||||
// The first pop is not supposed to be evaluated (@see eoPopLoopEval).
|
// The first pop is not supposed to be evaluated (@see eoPopLoopEval).
|
||||||
// _evaluator( current_pop, pop );
|
// _evaluator( current_pop, pop );
|
||||||
|
|
||||||
do {
|
do {
|
||||||
eoPop< EOType > current_pop;
|
|
||||||
eoPop< EOType > selected_pop;
|
|
||||||
|
|
||||||
// (1) Selection of the best points in the population
|
// (1) Selection of the best points in the population
|
||||||
_selector(pop, selected_pop);
|
_selector(pop, selected_pop);
|
||||||
assert( selected_pop.size() > 0 );
|
assert( selected_pop.size() > 0 );
|
||||||
|
|
@ -199,26 +160,13 @@ public:
|
||||||
// (2) Estimation of the distribution parameters
|
// (2) Estimation of the distribution parameters
|
||||||
_distrib = _estimator(selected_pop);
|
_distrib = _estimator(selected_pop);
|
||||||
|
|
||||||
// TODO modularization: the estimator and the continuator perform
|
|
||||||
// the same decomposition twice, see how to decompose those operators
|
|
||||||
|
|
||||||
// Call the continuator right after the distribution update,
|
|
||||||
// because we may have generated an ill-conditioned distribution,
|
|
||||||
// which would lead to bad solution sampling.
|
|
||||||
if(not _distribution_continuator(_distrib)) {
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
// (3) sampling
|
// (3) sampling
|
||||||
// The sampler produces feasible solutions (@see edoSampler that
|
// The sampler produces feasible solutions (@see edoSampler that
|
||||||
// encapsulate an edoBounder)
|
// encapsulate an edoBounder)
|
||||||
current_pop.clear(); current_pop.reserve(pop.size());
|
current_pop.clear();
|
||||||
for( unsigned int i = 0; i < pop.size(); ++i ) {
|
for( unsigned int i = 0; i < pop.size(); ++i ) {
|
||||||
current_pop.push_back( _sampler(_distrib) );
|
current_pop.push_back( _sampler(_distrib) );
|
||||||
}
|
}
|
||||||
// TODO modluraziation: the sampler may generate solution that are
|
|
||||||
// not finite. See how to stop right from there instead of
|
|
||||||
// performing useless evaluations.
|
|
||||||
|
|
||||||
// (4) Evaluate new solutions
|
// (4) Evaluate new solutions
|
||||||
_evaluator( pop, current_pop );
|
_evaluator( pop, current_pop );
|
||||||
|
|
@ -226,7 +174,7 @@ public:
|
||||||
// (5) Replace old solutions by new ones
|
// (5) Replace old solutions by new ones
|
||||||
_replacor(pop, current_pop); // e.g. copy current_pop in pop
|
_replacor(pop, current_pop); // e.g. copy current_pop in pop
|
||||||
|
|
||||||
} while( _pop_continuator( pop ) );
|
} while( _distribution_continuator( _distrib ) && _pop_continuator( pop ) );
|
||||||
} // operator()
|
} // operator()
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -244,9 +192,6 @@ protected:
|
||||||
//! A EOType estimator. It is going to estimate distribution parameters.
|
//! A EOType estimator. It is going to estimate distribution parameters.
|
||||||
edoEstimator<D> & _estimator;
|
edoEstimator<D> & _estimator;
|
||||||
|
|
||||||
//! A EOType estimator. Called before the main loop.
|
|
||||||
edoEstimator<D> & _estimator_init;
|
|
||||||
|
|
||||||
//! A D sampler
|
//! A D sampler
|
||||||
edoSampler<D> & _sampler;
|
edoSampler<D> & _sampler;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,74 +0,0 @@
|
||||||
/*
|
|
||||||
The Evolving Distribution Objects framework (EDO) is a template-based,
|
|
||||||
ANSI-C++ evolutionary computation library which helps you to write your
|
|
||||||
own estimation of distribution algorithms.
|
|
||||||
|
|
||||||
This library is free software; you can redistribute it and/or
|
|
||||||
modify it under the terms of the GNU Lesser General Public
|
|
||||||
License as published by the Free Software Foundation; either
|
|
||||||
version 2.1 of the License, or (at your option) any later version.
|
|
||||||
|
|
||||||
This library is distributed in the hope that it will be useful,
|
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
||||||
Lesser General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU Lesser General Public
|
|
||||||
License along with this library; if not, write to the Free Software
|
|
||||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|
||||||
|
|
||||||
Copyright (C) 2020 Thales group
|
|
||||||
*/
|
|
||||||
/*
|
|
||||||
Authors:
|
|
||||||
Johann Dréo <johann.dreo@thalesgroup.com>
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef _edoCombinedContinue_h
|
|
||||||
#define _edoCombinedContinue_h
|
|
||||||
|
|
||||||
#include <eoFunctor.h>
|
|
||||||
#include <eoPersistent.h>
|
|
||||||
|
|
||||||
/** Combine several EDO continuators in a single one.
|
|
||||||
*
|
|
||||||
* Return true if any of the managed continuator ask for a stop.
|
|
||||||
*
|
|
||||||
* @see edoContinue
|
|
||||||
*
|
|
||||||
* @ingroup Continuators
|
|
||||||
* @ingroup Core
|
|
||||||
*/
|
|
||||||
template<class D>
|
|
||||||
class edoCombinedContinue : public edoContinue<D>, public std::vector<edoContinue<D>*>
|
|
||||||
{
|
|
||||||
public:
|
|
||||||
edoCombinedContinue( edoContinue<D>& cont ) :
|
|
||||||
edoContinue<D>(),
|
|
||||||
std::vector<edoContinue<D>*>(1,&cont)
|
|
||||||
{ }
|
|
||||||
|
|
||||||
edoCombinedContinue( std::vector<edoContinue<D>*> conts ) :
|
|
||||||
edoContinue<D>(),
|
|
||||||
std::vector<edoContinue<D>*>(conts)
|
|
||||||
{ }
|
|
||||||
|
|
||||||
void add( edoContinue<D>& cont)
|
|
||||||
{
|
|
||||||
this->push_back(&cont);
|
|
||||||
}
|
|
||||||
|
|
||||||
bool operator()(const D& distrib)
|
|
||||||
{
|
|
||||||
for(const auto cont : *this) {
|
|
||||||
if( not (*cont)(distrib)) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
virtual std::string className() const { return "edoCombinedContinue"; }
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif // !_edoCombinedContinue_h
|
|
||||||
|
|
@ -1,114 +0,0 @@
|
||||||
/*
|
|
||||||
The Evolving Distribution Objects framework (EDO) is a template-based,
|
|
||||||
ANSI-C++ evolutionary computation library which helps you to write your
|
|
||||||
own estimation of distribution algorithms.
|
|
||||||
|
|
||||||
This library is free software; you can redistribute it and/or
|
|
||||||
modify it under the terms of the GNU Lesser General Public
|
|
||||||
License as published by the Free Software Foundation; either
|
|
||||||
version 2.1 of the License, or (at your option) any later version.
|
|
||||||
|
|
||||||
This library is distributed in the hope that it will be useful,
|
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
||||||
Lesser General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU Lesser General Public
|
|
||||||
License along with this library; if not, write to the Free Software
|
|
||||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|
||||||
|
|
||||||
Copyright (C) 2020 Thales group
|
|
||||||
*/
|
|
||||||
/*
|
|
||||||
Authors:
|
|
||||||
Johann Dréo <johann.dreo@thalesgroup.com>
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef _edoContAdaptiveFinite_h
|
|
||||||
#define _edoContAdaptiveFinite_h
|
|
||||||
|
|
||||||
#include "edoContinue.h"
|
|
||||||
|
|
||||||
/** A continuator that check if any element in the parameters
|
|
||||||
* of an edoNormalAdaptive distribution are finite
|
|
||||||
*
|
|
||||||
* If any element of any parameter is infinity or NaN (Not A Number),
|
|
||||||
* it will ask for a stop.
|
|
||||||
*
|
|
||||||
* @ingroup Continuators
|
|
||||||
*/
|
|
||||||
template<class D>
|
|
||||||
class edoContAdaptiveFinite : public edoContinue<D>
|
|
||||||
{
|
|
||||||
public:
|
|
||||||
using EOType = typename D::EOType;
|
|
||||||
using Matrix = typename D::Matrix;
|
|
||||||
using Vector = typename D::Vector;
|
|
||||||
|
|
||||||
bool operator()(const D& d)
|
|
||||||
{
|
|
||||||
bool fin_sigma = is_finite(d.sigma() );
|
|
||||||
bool fin_path_sigma = is_finite(d.path_sigma());
|
|
||||||
bool fin_scaling = is_finite(d.scaling() );
|
|
||||||
bool fin_coord_sys = is_finite(d.coord_sys() );
|
|
||||||
bool fin_path_covar = is_finite(d.path_covar());
|
|
||||||
bool fin_covar = is_finite(d.covar() );
|
|
||||||
|
|
||||||
bool all_finite = fin_covar
|
|
||||||
and fin_path_covar
|
|
||||||
and fin_coord_sys
|
|
||||||
and fin_scaling
|
|
||||||
and fin_path_sigma
|
|
||||||
and fin_sigma;
|
|
||||||
|
|
||||||
if( not all_finite ) {
|
|
||||||
eo::log << eo::progress << "STOP because parameters are not finite: ";
|
|
||||||
if( not fin_covar ) { eo::log << eo::errors << "covar, "; }
|
|
||||||
if( not fin_path_covar ) { eo::log << eo::errors << "path_covar, "; }
|
|
||||||
if( not fin_coord_sys ) { eo::log << eo::errors << "coord_sys, "; }
|
|
||||||
if( not fin_scaling ) { eo::log << eo::errors << "scaling, "; }
|
|
||||||
if( not fin_path_sigma ) { eo::log << eo::errors << "path_sigma, "; }
|
|
||||||
if( not fin_sigma ) { eo::log << eo::errors << "sigma"; }
|
|
||||||
eo::log << eo::errors << std::endl;
|
|
||||||
}
|
|
||||||
return all_finite;
|
|
||||||
}
|
|
||||||
|
|
||||||
virtual std::string className() const { return "edoContAdaptiveFinite"; }
|
|
||||||
|
|
||||||
protected:
|
|
||||||
bool is_finite(const Matrix& mat) const
|
|
||||||
{
|
|
||||||
for(long i=0; i<mat.rows(); ++i) {
|
|
||||||
for(long j=0; j<mat.cols(); ++j) {
|
|
||||||
// Double negation because one want to escape
|
|
||||||
// as soon as one element is not finite.
|
|
||||||
if(not is_finite(mat(i,j))) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
bool is_finite(const Vector& vec) const
|
|
||||||
{
|
|
||||||
for(long i=0; i<vec.size(); ++i) {
|
|
||||||
if(not is_finite(vec[i])) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
bool is_finite(const typename EOType::AtomType& x) const
|
|
||||||
{
|
|
||||||
if(std::isfinite(x)) {
|
|
||||||
return true;
|
|
||||||
} else {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
@ -1,112 +0,0 @@
|
||||||
/*
|
|
||||||
The Evolving Distribution Objects framework (EDO) is a template-based,
|
|
||||||
ANSI-C++ evolutionary computation library which helps you to write your
|
|
||||||
own estimation of distribution algorithms.
|
|
||||||
|
|
||||||
This library is free software; you can redistribute it and/or
|
|
||||||
modify it under the terms of the GNU Lesser General Public
|
|
||||||
License as published by the Free Software Foundation; either
|
|
||||||
version 2.1 of the License, or (at your option) any later version.
|
|
||||||
|
|
||||||
This library is distributed in the hope that it will be useful,
|
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
||||||
Lesser General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU Lesser General Public
|
|
||||||
License along with this library; if not, write to the Free Software
|
|
||||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|
||||||
|
|
||||||
Copyright (C) 2020 Thales group
|
|
||||||
*/
|
|
||||||
/*
|
|
||||||
Authors:
|
|
||||||
Johann Dréo <johann.dreo@thalesgroup.com>
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef _edoContAdaptiveIllCovar_h
|
|
||||||
#define _edoContAdaptiveIllCovar_h
|
|
||||||
|
|
||||||
#ifdef WITH_EIGEN
|
|
||||||
|
|
||||||
#include<Eigen/Dense>
|
|
||||||
|
|
||||||
#include "edoContinue.h"
|
|
||||||
|
|
||||||
/** A continuator that check if the covariance matrix
|
|
||||||
* of an edoNormalAdaptive distribution is ill-conditioned.
|
|
||||||
*
|
|
||||||
* If the condition number of the covariance matrix
|
|
||||||
* is strictly greater than the threshold given at construction,
|
|
||||||
* it will ask for a stop.
|
|
||||||
*
|
|
||||||
* @ingroup Continuators
|
|
||||||
*/
|
|
||||||
template<class D>
|
|
||||||
class edoContAdaptiveIllCovar : public edoContinue<D>
|
|
||||||
{
|
|
||||||
public:
|
|
||||||
using EOType = typename D::EOType;
|
|
||||||
using Matrix = typename D::Matrix;
|
|
||||||
using Vector = typename D::Vector;
|
|
||||||
|
|
||||||
edoContAdaptiveIllCovar( double threshold = 1e6) :
|
|
||||||
_threshold(threshold)
|
|
||||||
{ }
|
|
||||||
|
|
||||||
bool operator()(const D& d)
|
|
||||||
{
|
|
||||||
Eigen::SelfAdjointEigenSolver<Matrix> eigensolver( d.covar() );
|
|
||||||
|
|
||||||
auto info = eigensolver.info();
|
|
||||||
if(info == Eigen::ComputationInfo::NumericalIssue) {
|
|
||||||
eo::log << eo::warnings << "WARNING: the eigen decomposition of the covariance matrix"
|
|
||||||
<< " did not satisfy the prerequisites." << std::endl;
|
|
||||||
} else if(info == Eigen::ComputationInfo::NoConvergence) {
|
|
||||||
eo::log << eo::warnings << "WARNING: the eigen decomposition of the covariance matrix"
|
|
||||||
<< " did not converged." << std::endl;
|
|
||||||
} else if(info == Eigen::ComputationInfo::InvalidInput) {
|
|
||||||
eo::log << eo::warnings << "WARNING: the eigen decomposition of the covariance matrix"
|
|
||||||
<< " had invalid inputs." << std::endl;
|
|
||||||
}
|
|
||||||
if(info != Eigen::ComputationInfo::Success) {
|
|
||||||
eo::log << eo::progress << "STOP because the covariance matrix"
|
|
||||||
<< " cannot be decomposed" << std::endl;
|
|
||||||
#ifndef NDEBUG
|
|
||||||
eo::log << eo::xdebug
|
|
||||||
<< "mean:\n" << d.mean() << std::endl
|
|
||||||
<< "sigma:" << d.sigma() << std::endl
|
|
||||||
<< "coord_sys:\n" << d.coord_sys() << std::endl
|
|
||||||
<< "scaling:\n" << d.scaling() << std::endl;
|
|
||||||
#endif
|
|
||||||
return false;
|
|
||||||
|
|
||||||
}else {
|
|
||||||
Matrix EV = eigensolver.eigenvalues();
|
|
||||||
double condition = EV.maxCoeff() / EV.minCoeff();
|
|
||||||
|
|
||||||
if( not std::isfinite(condition) ) {
|
|
||||||
eo::log << eo::progress << "STOP because the covariance matrix"
|
|
||||||
<< " condition is not finite." << std::endl;
|
|
||||||
return false;
|
|
||||||
|
|
||||||
} else if( condition >= _threshold ) {
|
|
||||||
eo::log << eo::progress << "STOP because the covariance matrix"
|
|
||||||
<< " is ill-conditionned (condition number: " << condition << ")" << std::endl;
|
|
||||||
return false;
|
|
||||||
|
|
||||||
} else {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
virtual std::string className() const { return "edoContAdaptiveIllCovar"; }
|
|
||||||
|
|
||||||
protected:
|
|
||||||
const double _threshold;
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif // WITH_EIGEN
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
@ -25,8 +25,8 @@ Authors:
|
||||||
Caner Candan <caner.candan@thalesgroup.com>
|
Caner Candan <caner.candan@thalesgroup.com>
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef _edoContinue_h
|
#ifndef _doContinue_h
|
||||||
#define _edoContinue_h
|
#define _doContinue_h
|
||||||
|
|
||||||
#include <eoFunctor.h>
|
#include <eoFunctor.h>
|
||||||
#include <eoPersistent.h>
|
#include <eoPersistent.h>
|
||||||
|
|
@ -44,18 +44,20 @@ class edoContinue : public eoUF< const D&, bool >, public eoPersistent
|
||||||
public:
|
public:
|
||||||
virtual std::string className(void) const { return "edoContinue"; }
|
virtual std::string className(void) const { return "edoContinue"; }
|
||||||
|
|
||||||
// May be implemented by subclasses if persistent interface needed
|
void readFrom(std::istream&)
|
||||||
virtual void readFrom(std::istream&)
|
{
|
||||||
{ }
|
/* It should be implemented by subclasses ! */
|
||||||
|
}
|
||||||
|
|
||||||
virtual void printOn(std::ostream&) const
|
void printOn(std::ostream&) const
|
||||||
{ }
|
{
|
||||||
|
/* It should be implemented by subclasses ! */
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
template < typename D >
|
template < typename D >
|
||||||
class edoDummyContinue : public edoContinue< D >
|
class edoDummyContinue : public edoContinue< D >
|
||||||
{
|
{
|
||||||
public:
|
|
||||||
bool operator()(const D&){ return true; }
|
bool operator()(const D&){ return true; }
|
||||||
|
|
||||||
virtual std::string className() const { return "edoDummyContinue"; }
|
virtual std::string className() const { return "edoDummyContinue"; }
|
||||||
|
|
|
||||||
|
|
@ -1,70 +0,0 @@
|
||||||
|
|
||||||
/*
|
|
||||||
The Evolving Objects framework is a template-based,
|
|
||||||
ANSI-C++ evolutionary computation library which helps you to write your
|
|
||||||
own evolutionary algorithms.
|
|
||||||
|
|
||||||
This library is free software; you can redistribute it and/or
|
|
||||||
modify it under the terms of the GNU Lesser General Public
|
|
||||||
License as published by the Free Software Foundation;
|
|
||||||
version 2.1 of the License.
|
|
||||||
|
|
||||||
This library is distributed in the hope that it will be useful,
|
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
||||||
Lesser General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU Lesser General Public
|
|
||||||
License along with this library; if not, write to the Free Software
|
|
||||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|
||||||
|
|
||||||
Copyright (C) 2020 Thales group
|
|
||||||
*/
|
|
||||||
/*
|
|
||||||
Authors:
|
|
||||||
Johann Dréo <johann.dreo@thalesgroup.com>
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef _EDODISTRIBRESET_H_
|
|
||||||
#define _EDODISTRIBRESET_H_
|
|
||||||
|
|
||||||
#include <eoAlgoReset.h>
|
|
||||||
|
|
||||||
/** Reset a distrib when called (as an algorithm).
|
|
||||||
*
|
|
||||||
* @ingroup Reset
|
|
||||||
*/
|
|
||||||
template<class D>
|
|
||||||
class edoDistribReset : public eoAlgoReset<typename D::EOType>
|
|
||||||
{
|
|
||||||
public:
|
|
||||||
using EOType = typename D::EOType;
|
|
||||||
|
|
||||||
edoDistribReset( D& distrib ) :
|
|
||||||
_has_dim(false),
|
|
||||||
_dim(0),
|
|
||||||
_distrib(distrib)
|
|
||||||
{ }
|
|
||||||
|
|
||||||
edoDistribReset( D& distrib, size_t dim ) :
|
|
||||||
_has_dim(true),
|
|
||||||
_dim(dim),
|
|
||||||
_distrib(distrib)
|
|
||||||
{ }
|
|
||||||
|
|
||||||
virtual void operator()( eoPop<EOType>& /*pop*/ )
|
|
||||||
{
|
|
||||||
if(_has_dim) {
|
|
||||||
_distrib.reset(_dim);
|
|
||||||
} else {
|
|
||||||
_distrib.reset();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
protected:
|
|
||||||
bool _has_dim;
|
|
||||||
size_t _dim;
|
|
||||||
D& _distrib;
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif // _EDODISTRIBRESET_H_
|
|
||||||
|
|
@ -45,14 +45,14 @@ class edoEstimatorAdaptive : public edoEstimator<D>
|
||||||
public:
|
public:
|
||||||
typedef typename D::EOType EOType;
|
typedef typename D::EOType EOType;
|
||||||
|
|
||||||
edoEstimatorAdaptive( D& distrib ) : _distrib(distrib) {}
|
edoEstimatorAdaptive<D>( D& distrib ) : _distrib(distrib) {}
|
||||||
|
|
||||||
// virtual D operator() ( eoPop< EOT >& )=0 (provided by eoUF< A1, R >)
|
// virtual D operator() ( eoPop< EOT >& )=0 (provided by eoUF< A1, R >)
|
||||||
|
|
||||||
D& distribution() { return _distrib; }
|
D & distribution() const { return _distrib; }
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
D& _distrib;
|
D & _distrib;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // !_edoEstimatorAdaptive_h
|
#endif // !_edoEstimatorAdaptive_h
|
||||||
|
|
|
||||||
|
|
@ -1,79 +0,0 @@
|
||||||
/*
|
|
||||||
The Evolving Distribution Objects framework (EDO) is a template-based,
|
|
||||||
ANSI-C++ evolutionary computation library which helps you to write your
|
|
||||||
own estimation of distribution algorithms.
|
|
||||||
|
|
||||||
This library is free software; you can redistribute it and/or
|
|
||||||
modify it under the terms of the GNU Lesser General Public
|
|
||||||
License as published by the Free Software Foundation; either
|
|
||||||
version 2.1 of the License, or (at your option) any later version.
|
|
||||||
|
|
||||||
This library is distributed in the hope that it will be useful,
|
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
||||||
Lesser General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU Lesser General Public
|
|
||||||
License along with this library; if not, write to the Free Software
|
|
||||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|
||||||
|
|
||||||
Copyright (C) 2020 Thales group
|
|
||||||
*/
|
|
||||||
/*
|
|
||||||
Authors:
|
|
||||||
Johann Dréo <johann.dreo@thalesgroup.com>
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef _edoEstimatorAdaptiveEdit_h
|
|
||||||
#define _edoEstimatorAdaptiveEdit_h
|
|
||||||
|
|
||||||
#include <eoPop.h>
|
|
||||||
|
|
||||||
#include "edoEstimatorAdaptive.h"
|
|
||||||
|
|
||||||
/** An estimator that change the parameters on the managed distribution.
|
|
||||||
*
|
|
||||||
* @ingroup Estimators
|
|
||||||
*/
|
|
||||||
template<class D, class P = typename D::EOType>
|
|
||||||
class edoEstimatorAdaptiveEdit : public edoEstimatorAdaptive<D>
|
|
||||||
{
|
|
||||||
public:
|
|
||||||
typedef typename D::EOType EOType;
|
|
||||||
|
|
||||||
/** Edit the given distribution's members with the given accessors.
|
|
||||||
*
|
|
||||||
* For example, to shift the distribution's mean toward pop's best element
|
|
||||||
* (note the lack of parenthesis):
|
|
||||||
* @code
|
|
||||||
* edoEstimatorAdaptiveEdit<D> e(distrib,
|
|
||||||
* std::bind(&eoPop<S>::best_element, &pop),
|
|
||||||
* // std::bind(&D::mean, &distrib, std::placeholders::_1) // Fail to deduce templates
|
|
||||||
* // but you can use lambdas (even more readable):
|
|
||||||
* [&distrib](S center){distrib.mean(center);}
|
|
||||||
* distrib.mean, pop.best_element);
|
|
||||||
* @endcode
|
|
||||||
*/
|
|
||||||
edoEstimatorAdaptiveEdit(
|
|
||||||
D& distrib,
|
|
||||||
std::function<P()> getter,
|
|
||||||
std::function<void(P)> setter
|
|
||||||
) :
|
|
||||||
edoEstimatorAdaptive<D>(distrib),
|
|
||||||
_getter(getter),
|
|
||||||
_setter(setter)
|
|
||||||
{}
|
|
||||||
|
|
||||||
virtual D operator()( eoPop<EOType>& )
|
|
||||||
{
|
|
||||||
_setter( _getter() );
|
|
||||||
return this->_distrib;
|
|
||||||
}
|
|
||||||
|
|
||||||
protected:
|
|
||||||
std::function< P ( )> _getter;
|
|
||||||
std::function<void(P)> _setter;
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif // !_edoEstimatorAdaptiveEdit_h
|
|
||||||
|
|
@ -1,64 +0,0 @@
|
||||||
/*
|
|
||||||
The Evolving Distribution Objects framework (EDO) is a template-based,
|
|
||||||
ANSI-C++ evolutionary computation library which helps you to write your
|
|
||||||
own estimation of distribution algorithms.
|
|
||||||
|
|
||||||
This library is free software; you can redistribute it and/or
|
|
||||||
modify it under the terms of the GNU Lesser General Public
|
|
||||||
License as published by the Free Software Foundation; either
|
|
||||||
version 2.1 of the License, or (at your option) any later version.
|
|
||||||
|
|
||||||
This library is distributed in the hope that it will be useful,
|
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
||||||
Lesser General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU Lesser General Public
|
|
||||||
License along with this library; if not, write to the Free Software
|
|
||||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|
||||||
|
|
||||||
Copyright (C) 2020 Thales group
|
|
||||||
*/
|
|
||||||
/*
|
|
||||||
Authors:
|
|
||||||
Johann Dréo <johann.dreo@thalesgroup.com>
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef _edoEstimatorAdaptiveReset_h
|
|
||||||
#define _edoEstimatorAdaptiveReset_h
|
|
||||||
|
|
||||||
#include <eoPop.h>
|
|
||||||
|
|
||||||
#include "edoEstimatorAdaptive.h"
|
|
||||||
|
|
||||||
/** An estimator that calls `reset` on the managed distribution.
|
|
||||||
*
|
|
||||||
* @ingroup Estimators
|
|
||||||
*/
|
|
||||||
template<class D>
|
|
||||||
class edoEstimatorAdaptiveReset : public edoEstimatorAdaptive<D>
|
|
||||||
{
|
|
||||||
public:
|
|
||||||
typedef typename D::EOType EOType;
|
|
||||||
|
|
||||||
edoEstimatorAdaptiveReset( D& distrib ) :
|
|
||||||
edoEstimatorAdaptive<D>(distrib),
|
|
||||||
_dim(0)
|
|
||||||
{ }
|
|
||||||
|
|
||||||
edoEstimatorAdaptiveReset( D& distrib, size_t dim ) :
|
|
||||||
edoEstimatorAdaptive<D>(distrib),
|
|
||||||
_dim(dim)
|
|
||||||
{ }
|
|
||||||
|
|
||||||
virtual D operator()( eoPop<EOType>& )
|
|
||||||
{
|
|
||||||
this->_distrib.reset(_dim);
|
|
||||||
return this->_distrib;
|
|
||||||
}
|
|
||||||
|
|
||||||
protected:
|
|
||||||
size_t _dim;
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif // !_edoEstimatorAdaptiveReset_h
|
|
||||||
|
|
@ -1,103 +0,0 @@
|
||||||
/*
|
|
||||||
The Evolving Distribution Objects framework (EDO) is a template-based,
|
|
||||||
ANSI-C++ evolutionary computation library which helps you to write your
|
|
||||||
own estimation of distribution algorithms.
|
|
||||||
|
|
||||||
This library is free software; you can redistribute it and/or
|
|
||||||
modify it under the terms of the GNU Lesser General Public
|
|
||||||
License as published by the Free Software Foundation; either
|
|
||||||
version 2.1 of the License, or (at your option) any later version.
|
|
||||||
|
|
||||||
This library is distributed in the hope that it will be useful,
|
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
||||||
Lesser General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU Lesser General Public
|
|
||||||
License along with this library; if not, write to the Free Software
|
|
||||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|
||||||
|
|
||||||
Copyright (C) 2020 Thales group
|
|
||||||
*/
|
|
||||||
/*
|
|
||||||
Authors:
|
|
||||||
Johann Dréo <johann.dreo@thalesgroup.com>
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef _edoEstimatorAdaptiveCombined_h
|
|
||||||
#define _edoEstimatorAdaptiveCombined_h
|
|
||||||
|
|
||||||
#include <vector>
|
|
||||||
|
|
||||||
#include <eoPop.h>
|
|
||||||
|
|
||||||
#include "edoEstimatorAdaptive.h"
|
|
||||||
|
|
||||||
/** An estimator that calls several ordered estimators, stateful version.
|
|
||||||
*
|
|
||||||
* @ingroup Estimators
|
|
||||||
*/
|
|
||||||
template<class D>
|
|
||||||
class edoEstimatorCombinedAdaptive : public edoEstimatorAdaptive<D>, public std::vector<edoEstimator<D>*>
|
|
||||||
{
|
|
||||||
public:
|
|
||||||
typedef typename D::EOType EOType;
|
|
||||||
|
|
||||||
edoEstimatorCombinedAdaptive( D& distrib, edoEstimator<D>& estim) :
|
|
||||||
edoEstimatorAdaptive<D>(distrib),
|
|
||||||
std::vector<edoEstimator<D>*>(1,&estim)
|
|
||||||
{}
|
|
||||||
|
|
||||||
edoEstimatorCombinedAdaptive( D& distrib, std::vector<edoEstimator<D>*> estims) :
|
|
||||||
edoEstimatorAdaptive<D>(distrib),
|
|
||||||
std::vector<edoEstimator<D>*>(estims)
|
|
||||||
{}
|
|
||||||
|
|
||||||
void add( edoEstimator<D>& estim )
|
|
||||||
{
|
|
||||||
this->push_back(&estim);
|
|
||||||
}
|
|
||||||
|
|
||||||
virtual D operator()( eoPop<EOType>& pop )
|
|
||||||
{
|
|
||||||
for(edoEstimator<D>* pestim : *this) {
|
|
||||||
this->_distrib = (*pestim)( pop );
|
|
||||||
}
|
|
||||||
return this->_distrib;
|
|
||||||
}
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
/** An estimator that calls several ordered estimators, stateless version.
|
|
||||||
*
|
|
||||||
* @ingroup Estimators
|
|
||||||
*/
|
|
||||||
template<class D>
|
|
||||||
class edoEstimatorCombinedStateless : public edoEstimatorCombinedAdaptive<D>
|
|
||||||
{
|
|
||||||
public:
|
|
||||||
typedef typename D::EOType EOType;
|
|
||||||
|
|
||||||
edoEstimatorCombinedStateless( edoEstimator<D>& estim ) :
|
|
||||||
edoEstimatorCombinedAdaptive<D>(*(new D), estim)
|
|
||||||
{}
|
|
||||||
|
|
||||||
edoEstimatorCombinedStateless( std::vector<edoEstimator<D>*> estims) :
|
|
||||||
edoEstimatorCombinedAdaptive<D>(*(new D), estims)
|
|
||||||
{}
|
|
||||||
|
|
||||||
virtual D operator()( eoPop<EOType>& pop )
|
|
||||||
{
|
|
||||||
delete &(this->_distrib);
|
|
||||||
this->_distrib = *(new D);
|
|
||||||
return edoEstimatorCombinedAdaptive<D>::operator()(pop);
|
|
||||||
}
|
|
||||||
|
|
||||||
~edoEstimatorCombinedStateless()
|
|
||||||
{
|
|
||||||
delete &(this->_distrib);
|
|
||||||
}
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif // !_edoEstimatorAdaptiveCombined_h
|
|
||||||
|
|
@ -90,8 +90,7 @@ public:
|
||||||
* INITIALIZATION
|
* INITIALIZATION
|
||||||
*********************************************************************/
|
*********************************************************************/
|
||||||
|
|
||||||
unsigned int N = this->distribution().size();
|
unsigned int N = pop[0].size(); // FIXME expliciter la dimension du pb ?
|
||||||
assert(this->distribution().size() == pop[0].size());
|
|
||||||
unsigned int lambda = pop.size();
|
unsigned int lambda = pop.size();
|
||||||
|
|
||||||
// number of calls to the operator == number of generations
|
// number of calls to the operator == number of generations
|
||||||
|
|
@ -228,15 +227,14 @@ public:
|
||||||
// Matrix CS = C.triangularView<Eigen::Upper>() + C.triangularView<Eigen::StrictlyUpper>().transpose();
|
// Matrix CS = C.triangularView<Eigen::Upper>() + C.triangularView<Eigen::StrictlyUpper>().transpose();
|
||||||
d.covar( C );
|
d.covar( C );
|
||||||
|
|
||||||
Eigen::SelfAdjointEigenSolver<Matrix> eigensolver( d.covar() );
|
Eigen::SelfAdjointEigenSolver<Matrix> eigensolver( d.covar() ); // FIXME use JacobiSVD?
|
||||||
|
d.coord_sys( eigensolver.eigenvectors() );
|
||||||
Matrix mD = eigensolver.eigenvalues().asDiagonal();
|
Matrix mD = eigensolver.eigenvalues().asDiagonal();
|
||||||
|
assert( mD.innerSize() == N && mD.outerSize() == N );
|
||||||
|
|
||||||
// from variance to standard deviations
|
// from variance to standard deviations
|
||||||
mD=mD.cwiseSqrt();
|
mD.cwiseSqrt();
|
||||||
d.scaling( mD.diagonal() );
|
d.scaling( mD.diagonal() );
|
||||||
|
|
||||||
d.coord_sys( eigensolver.eigenvectors() );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return d;
|
return d;
|
||||||
|
|
|
||||||
|
|
@ -119,13 +119,7 @@ public:
|
||||||
|
|
||||||
unsigned int size()
|
unsigned int size()
|
||||||
{
|
{
|
||||||
assert( _mean.innerSize() == _dim );
|
return _mean.innerSize();
|
||||||
assert( _C.innerSize() == _dim && _C.outerSize() == _dim );
|
|
||||||
assert( _B.innerSize() == _dim && _B.outerSize() == _dim );
|
|
||||||
assert( _D.innerSize() == _dim );
|
|
||||||
assert( _p_c.innerSize() == _dim );
|
|
||||||
assert( _p_s.innerSize() == _dim );
|
|
||||||
return _dim;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Vector mean() const {return _mean;}
|
Vector mean() const {return _mean;}
|
||||||
|
|
@ -145,7 +139,6 @@ public:
|
||||||
*/
|
*/
|
||||||
void mean( EOT m )
|
void mean( EOT m )
|
||||||
{
|
{
|
||||||
assert(m.size() == _dim);
|
|
||||||
Vector center( m.size() );
|
Vector center( m.size() );
|
||||||
for( unsigned int i=0, end=m.size(); i<end; ++i) {
|
for( unsigned int i=0, end=m.size(); i<end; ++i) {
|
||||||
center[i] = m[i];
|
center[i] = m[i];
|
||||||
|
|
@ -160,26 +153,6 @@ public:
|
||||||
void path_covar( Vector p ) { _p_c = p; assert( p.size() == _dim ); }
|
void path_covar( Vector p ) { _p_c = p; assert( p.size() == _dim ); }
|
||||||
void path_sigma( Vector p ) { _p_s = p; assert( p.size() == _dim ); }
|
void path_sigma( Vector p ) { _p_s = p; assert( p.size() == _dim ); }
|
||||||
|
|
||||||
/** Reset the distribution, like it was just instanciated.
|
|
||||||
*
|
|
||||||
* @param dim Dimension of the space, if set to 0 (the default), use the dimension that was lastly set.
|
|
||||||
*/
|
|
||||||
void reset(size_t dim = 0)
|
|
||||||
{
|
|
||||||
if(dim == 0) {
|
|
||||||
dim = _dim;
|
|
||||||
}
|
|
||||||
_dim = dim;
|
|
||||||
|
|
||||||
_mean = Vector::Zero(_dim);
|
|
||||||
_C = Matrix::Identity(_dim,_dim);
|
|
||||||
_B = Matrix::Identity(_dim,_dim);
|
|
||||||
_D = Vector::Constant( _dim, 1);
|
|
||||||
_sigma = 1.0;
|
|
||||||
_p_c = Vector::Zero(_dim);
|
|
||||||
_p_s = Vector::Zero(_dim);
|
|
||||||
}
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
unsigned int _dim;
|
unsigned int _dim;
|
||||||
Vector _mean; // mean vector
|
Vector _mean; // mean vector
|
||||||
|
|
|
||||||
|
|
@ -39,7 +39,7 @@ template < typename EOT >
|
||||||
class edoRepairerModulo: public edoRepairerApplyBinary<EOT>
|
class edoRepairerModulo: public edoRepairerApplyBinary<EOT>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
edoRepairerModulo( double denominator ) : edoRepairerApplyBinary<EOT>( std::fmod, denominator ) {}
|
edoRepairerModulo<EOT>( double denominator ) : edoRepairerApplyBinary<EOT>( std::fmod, denominator ) {}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -51,13 +51,13 @@ public:
|
||||||
* The default implementation is to push back a true boolean.
|
* The default implementation is to push back a true boolean.
|
||||||
* If you have a more complex data structure, you can just overload this.
|
* If you have a more complex data structure, you can just overload this.
|
||||||
*/
|
*/
|
||||||
virtual void make_true( AtomType & atom, unsigned int, unsigned int )
|
virtual void make_true( AtomType & atom, unsigned int i, unsigned int j )
|
||||||
{
|
{
|
||||||
atom.push_back( 1 );
|
atom.push_back( 1 );
|
||||||
}
|
}
|
||||||
|
|
||||||
/** @see make_true */
|
/** @see make_true */
|
||||||
virtual void make_false( AtomType & atom, unsigned int, unsigned int )
|
virtual void make_false( AtomType & atom, unsigned int i, unsigned int j )
|
||||||
{
|
{
|
||||||
atom.push_back( 0 );
|
atom.push_back( 0 );
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -72,32 +72,11 @@ public:
|
||||||
// mean(N,1) + sigma * B(N,N) * ( D(N,1) .* T(N,1) )
|
// mean(N,1) + sigma * B(N,N) * ( D(N,1) .* T(N,1) )
|
||||||
Vector sol = distrib.mean()
|
Vector sol = distrib.mean()
|
||||||
+ distrib.sigma()
|
+ distrib.sigma()
|
||||||
* distrib.coord_sys()
|
* distrib.coord_sys() * (distrib.scaling().cwiseProduct(T) ); // C * T = B * (D .* T)
|
||||||
* (distrib.scaling().cwiseProduct(T) ); // C * T = B * (D .* T)
|
|
||||||
assert( sol.size() == N );
|
assert( sol.size() == N );
|
||||||
/*Vector sol = distrib.mean() + distrib.sigma()
|
/*Vector sol = distrib.mean() + distrib.sigma()
|
||||||
* distrib.coord_sys().dot( distrib.scaling().dot( T ) );*/
|
* distrib.coord_sys().dot( distrib.scaling().dot( T ) );*/
|
||||||
|
|
||||||
#ifndef NDEBUG
|
|
||||||
bool is_finite = true;
|
|
||||||
for(long i=0; i<sol.size(); ++i) {
|
|
||||||
if(not std::isfinite(sol(i))) {
|
|
||||||
is_finite = false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if(not is_finite) {
|
|
||||||
eo::log << eo::warnings << "WARNING: sampled solution is not finite"
|
|
||||||
<< " (the search should stop after this warning)" << std::endl;
|
|
||||||
eo::log << eo::debug << sol << std::endl;
|
|
||||||
eo::log << eo::xdebug
|
|
||||||
<< "mean:\n" << distrib.mean() << std::endl
|
|
||||||
<< "sigma:" << distrib.sigma() << std::endl
|
|
||||||
<< "coord_sys:\n" << distrib.coord_sys() << std::endl
|
|
||||||
<< "scaling:\n" << distrib.scaling() << std::endl;
|
|
||||||
}
|
|
||||||
// assert(is_finite);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// copy in the EOT structure (more probably a vector)
|
// copy in the EOT structure (more probably a vector)
|
||||||
EOT solution( N );
|
EOT solution( N );
|
||||||
for( unsigned int i = 0; i < N; i++ ) {
|
for( unsigned int i = 0; i < N; i++ ) {
|
||||||
|
|
|
||||||
|
|
@ -1,111 +0,0 @@
|
||||||
/*
|
|
||||||
The Evolving Distribution Objects framework (EDO) is a template-based,
|
|
||||||
ANSI-C++ evolutionary computation library which helps you to write your
|
|
||||||
own estimation of distribution algorithms.
|
|
||||||
|
|
||||||
This library is free software; you can redistribute it and/or
|
|
||||||
modify it under the terms of the GNU Lesser General Public
|
|
||||||
License as published by the Free Software Foundation; either
|
|
||||||
version 2.1 of the License, or (at your option) any later version.
|
|
||||||
|
|
||||||
This library is distributed in the hope that it will be useful,
|
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
||||||
Lesser General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU Lesser General Public
|
|
||||||
License along with this library; if not, write to the Free Software
|
|
||||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|
||||||
|
|
||||||
Copyright (C) 2013 Thales group
|
|
||||||
*/
|
|
||||||
/*
|
|
||||||
Authors:
|
|
||||||
Johann Dréo <johann.dreo@thalesgroup.com>
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef _edoTransform_h
|
|
||||||
#define _edoTransform_h
|
|
||||||
|
|
||||||
#include <eo> // eoTransform
|
|
||||||
|
|
||||||
/** @defgroup Wrappers
|
|
||||||
*
|
|
||||||
* Wrappers to interact with other parts of the framework
|
|
||||||
*/
|
|
||||||
|
|
||||||
/** Abstract base class for wrapping an estimator and a sampler as an eoTransform
|
|
||||||
*
|
|
||||||
* @ingroup Wrappers
|
|
||||||
*/
|
|
||||||
template<class D>
|
|
||||||
class edoTransform : public eoTransform< eoPop<typename D::EOType>& >
|
|
||||||
{
|
|
||||||
public:
|
|
||||||
typedef typename D::EOType EOType;
|
|
||||||
|
|
||||||
edoTransform( edoEstimator<D> & estimator, edoSampler<D> & sampler ) :
|
|
||||||
_estimator(estimator), _sampler(sampler)
|
|
||||||
{}
|
|
||||||
|
|
||||||
virtual void operator()( eoPop<EOType> & pop ) = 0;
|
|
||||||
|
|
||||||
protected:
|
|
||||||
edoEstimator<D> & _estimator;
|
|
||||||
edoSampler<D> & _sampler;
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
/** Wrapping an estimator and a sampler as an eoTransform.
|
|
||||||
*
|
|
||||||
* @ingroup Wrappers
|
|
||||||
*/
|
|
||||||
template<typename D>
|
|
||||||
class edoTransformAdaptive : public edoTransform<D>
|
|
||||||
{
|
|
||||||
public:
|
|
||||||
typedef typename D::EOType EOType;
|
|
||||||
|
|
||||||
edoTransformAdaptive( D & distrib, edoEstimator<D> & estimator, edoSampler<D> & sampler )
|
|
||||||
: _distrib(distrib), _estimator(estimator), _sampler(sampler)
|
|
||||||
{}
|
|
||||||
|
|
||||||
virtual void operator()( eoPop<EOType> & pop )
|
|
||||||
{
|
|
||||||
_distrib = _estimator( pop );
|
|
||||||
pop.clear();
|
|
||||||
for( unsigned int i = 0; i < pop.size(); ++i ) {
|
|
||||||
pop.push_back( _sampler(_distrib) );
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
protected:
|
|
||||||
D & _distrib;
|
|
||||||
edoEstimator<D> & _estimator;
|
|
||||||
edoSampler<D> & _sampler;
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
/** Wrapping an estimator and a sampler as an eoTransform,
|
|
||||||
* the distribution is created at instanciation and replaced at each call.
|
|
||||||
*
|
|
||||||
* @ingroup Wrappers
|
|
||||||
*/
|
|
||||||
template<typename D>
|
|
||||||
class edoTransformStateless : public edoTransformAdaptive<D>
|
|
||||||
{
|
|
||||||
public:
|
|
||||||
typedef typename D::EOType EOType;
|
|
||||||
|
|
||||||
edoTransformStateless( edoEstimator<D> & estimator, edoSampler<D> & sampler )
|
|
||||||
: edoTransformAdaptive<D>( *(new D), estimator, sampler )
|
|
||||||
{}
|
|
||||||
|
|
||||||
~edoTransformStateless()
|
|
||||||
{
|
|
||||||
// delete the temporary distrib allocated in constructor
|
|
||||||
delete &(this->_distrib);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif // !_edoTransform_h
|
|
||||||
|
|
@ -14,7 +14,7 @@ set(LIBRARY_OUTPUT_PATH ${EDOUTILS_LIB_OUTPUT_PATH})
|
||||||
|
|
||||||
file(GLOB SOURCES *.cpp)
|
file(GLOB SOURCES *.cpp)
|
||||||
add_library(edoutils ${SOURCES})
|
add_library(edoutils ${SOURCES})
|
||||||
install(TARGETS edoutils EXPORT paradiseo-targets ARCHIVE DESTINATION ${LIB} COMPONENT libraries)
|
install(TARGETS edoutils ARCHIVE DESTINATION ${LIB} COMPONENT libraries)
|
||||||
|
|
||||||
set(EDOUTILS_VERSION ${GLOBAL_VERSION})
|
set(EDOUTILS_VERSION ${GLOBAL_VERSION})
|
||||||
set_target_properties(edoutils PROPERTIES VERSION "${EDOUTILS_VERSION}")
|
set_target_properties(edoutils PROPERTIES VERSION "${EDOUTILS_VERSION}")
|
||||||
|
|
|
||||||
|
|
@ -59,7 +59,7 @@ edoFileSnapshot::edoFileSnapshot(std::string dirname,
|
||||||
|
|
||||||
if ( (res == -1) || (res == 127) )
|
if ( (res == -1) || (res == 127) )
|
||||||
{
|
{
|
||||||
throw eoSystemError(s, res);
|
throw std::runtime_error("Problem executing test of dir in eoFileSnapshot");
|
||||||
}
|
}
|
||||||
|
|
||||||
// now make sure there is a dir without any genXXX file in it
|
// now make sure there is a dir without any genXXX file in it
|
||||||
|
|
@ -76,7 +76,8 @@ edoFileSnapshot::edoFileSnapshot(std::string dirname,
|
||||||
s = " ";
|
s = " ";
|
||||||
}
|
}
|
||||||
|
|
||||||
(void)/*ignore returned*/ system(s.c_str());
|
int dummy;
|
||||||
|
dummy = system(s.c_str());
|
||||||
// all done
|
// all done
|
||||||
|
|
||||||
_descOfFiles = new std::ofstream( std::string(dirname + "/list_of_files.txt").c_str() );
|
_descOfFiles = new std::ofstream( std::string(dirname + "/list_of_files.txt").c_str() );
|
||||||
|
|
@ -111,8 +112,8 @@ eoMonitor& edoFileSnapshot::operator()(void)
|
||||||
|
|
||||||
if (!os)
|
if (!os)
|
||||||
{
|
{
|
||||||
// std::string str = "edoFileSnapshot: Could not open " + _currentFileName;
|
std::string str = "edoFileSnapshot: Could not open " + _currentFileName;
|
||||||
throw eoFileError(_currentFileName);
|
throw std::runtime_error(str);
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( _saveFilenames )
|
if ( _saveFilenames )
|
||||||
|
|
|
||||||
|
|
@ -42,7 +42,6 @@ set(SOURCES
|
||||||
t-repairer-modulo
|
t-repairer-modulo
|
||||||
t-binomial
|
t-binomial
|
||||||
t-binomialmulti
|
t-binomialmulti
|
||||||
t-minimal-cmaes
|
|
||||||
)
|
)
|
||||||
|
|
||||||
foreach(current ${SOURCES})
|
foreach(current ${SOURCES})
|
||||||
|
|
|
||||||
|
|
@ -28,7 +28,7 @@ Authors:
|
||||||
#include <eo>
|
#include <eo>
|
||||||
#include <edo>
|
#include <edo>
|
||||||
|
|
||||||
#include "../application/common/Rosenbrock.h"
|
#include "Rosenbrock.h"
|
||||||
|
|
||||||
typedef eoReal< eoMinimizingFitness > EOT;
|
typedef eoReal< eoMinimizingFitness > EOT;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -28,7 +28,7 @@ Authors:
|
||||||
#include <eo>
|
#include <eo>
|
||||||
#include <edo>
|
#include <edo>
|
||||||
|
|
||||||
#include "../application/common/Rosenbrock.h"
|
#include "Rosenbrock.h"
|
||||||
|
|
||||||
typedef eoReal< eoMinimizingFitness > EOT;
|
typedef eoReal< eoMinimizingFitness > EOT;
|
||||||
typedef edoUniform< EOT > Distrib;
|
typedef edoUniform< EOT > Distrib;
|
||||||
|
|
|
||||||
|
|
@ -33,8 +33,8 @@ Authors:
|
||||||
|
|
||||||
#include <edo>
|
#include <edo>
|
||||||
|
|
||||||
#include "../application/common/Rosenbrock.h"
|
#include "Rosenbrock.h"
|
||||||
#include "../application/common/Sphere.h"
|
#include "Sphere.h"
|
||||||
|
|
||||||
typedef eoReal< eoMinimizingFitness > EOT;
|
typedef eoReal< eoMinimizingFitness > EOT;
|
||||||
typedef edoNormalMulti< EOT > Distrib;
|
typedef edoNormalMulti< EOT > Distrib;
|
||||||
|
|
|
||||||
|
|
@ -38,8 +38,8 @@ Authors:
|
||||||
#include <edo>
|
#include <edo>
|
||||||
|
|
||||||
|
|
||||||
#include "../application/common/Rosenbrock.h"
|
#include "Rosenbrock.h"
|
||||||
#include "../application/common/Sphere.h"
|
#include "Sphere.h"
|
||||||
|
|
||||||
typedef eoReal< eoMinimizingFitness > EOT;
|
typedef eoReal< eoMinimizingFitness > EOT;
|
||||||
typedef edoNormalMulti< EOT > Distrib;
|
typedef edoNormalMulti< EOT > Distrib;
|
||||||
|
|
@ -65,9 +65,9 @@ int main(int ac, char** av)
|
||||||
|
|
||||||
std::string section("Algorithm parameters");
|
std::string section("Algorithm parameters");
|
||||||
|
|
||||||
unsigned int r_max = parser.createParam((unsigned int)10, "run-number", "Number of run", 'r', section).value(); // r
|
unsigned int r_max = parser.createParam((unsigned int)100, "run-number", "Number of run", 'r', section).value(); // r
|
||||||
unsigned int p_min = parser.createParam((unsigned int)10, "population-min", "Population min", 'p', section).value(); // p
|
unsigned int p_min = parser.createParam((unsigned int)10, "population-min", "Population min", 'p', section).value(); // p
|
||||||
unsigned int p_max = parser.createParam((unsigned int)100, "population-max", "Population max", 'P', section).value(); // P
|
unsigned int p_max = parser.createParam((unsigned int)1000, "population-max", "Population max", 'P', section).value(); // P
|
||||||
unsigned int p_step = parser.createParam((unsigned int)50, "population-step", "Population step", 't', section).value(); // t
|
unsigned int p_step = parser.createParam((unsigned int)50, "population-step", "Population step", 't', section).value(); // t
|
||||||
unsigned int s_size = parser.createParam((unsigned int)2, "dimension-size", "Dimension size", 'd', section).value(); // d
|
unsigned int s_size = parser.createParam((unsigned int)2, "dimension-size", "Dimension size", 'd', section).value(); // d
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,69 +0,0 @@
|
||||||
#include <eo>
|
|
||||||
#include <edo>
|
|
||||||
#include <es.h>
|
|
||||||
#include <do/make_pop.h>
|
|
||||||
#include <do/make_run.h>
|
|
||||||
#include <do/make_continue.h>
|
|
||||||
#include <do/make_checkpoint.h>
|
|
||||||
|
|
||||||
using R = eoReal<eoMinimizingFitness>;
|
|
||||||
using CMA = edoNormalAdaptive<R>;
|
|
||||||
|
|
||||||
R::FitnessType sphere(const R& sol) {
|
|
||||||
double sum = 0;
|
|
||||||
for(auto x : sol) { sum += x * x; }
|
|
||||||
return sum;
|
|
||||||
}
|
|
||||||
|
|
||||||
int main(int argc, char** argv) {
|
|
||||||
eoParser parser(argc, argv);
|
|
||||||
eoState state;
|
|
||||||
|
|
||||||
size_t dim = parser.createParam<size_t>(10,
|
|
||||||
"dimension", "Dimension", 'd',
|
|
||||||
"Problem").value();
|
|
||||||
|
|
||||||
size_t max_eval = parser.getORcreateParam<size_t>(100 * dim,
|
|
||||||
"maxEval", "Maximum number of evaluations", 'E',
|
|
||||||
"Stopping criterion").value();
|
|
||||||
|
|
||||||
edoNormalAdaptive<R> gaussian(dim);
|
|
||||||
|
|
||||||
auto& obj_func = state.pack< eoEvalFuncPtr<R> >(sphere);
|
|
||||||
auto& eval = state.pack< eoEvalCounterThrowException<R> >(obj_func, max_eval);
|
|
||||||
auto& pop_eval = state.pack< eoPopLoopEval<R> >(eval);
|
|
||||||
|
|
||||||
auto& gen = state.pack< eoUniformGenerator<R::AtomType> >(-5, 5);
|
|
||||||
auto& init = state.pack< eoInitFixedLength<R> >(dim, gen);
|
|
||||||
auto& pop = do_make_pop(parser, state, init);
|
|
||||||
pop_eval(pop,pop);
|
|
||||||
|
|
||||||
auto& eo_continue = do_make_continue( parser, state, eval);
|
|
||||||
auto& pop_continue = do_make_checkpoint(parser, state, eval, eo_continue);
|
|
||||||
auto& best = state.pack< eoBestIndividualStat<R> >();
|
|
||||||
pop_continue.add( best );
|
|
||||||
auto& distrib_continue = state.pack< edoContAdaptiveFinite<CMA> >();
|
|
||||||
|
|
||||||
auto& selector = state.pack< eoRankMuSelect<R> >(dim/2);
|
|
||||||
auto& estimator = state.pack< edoEstimatorNormalAdaptive<R> >(gaussian);
|
|
||||||
auto& bounder = state.pack< edoBounderRng<R> >(R(dim, -5), R(dim, 5), gen);
|
|
||||||
auto& sampler = state.pack< edoSamplerNormalAdaptive<R> >(bounder);
|
|
||||||
auto& replacor = state.pack< eoCommaReplacement<R> >();
|
|
||||||
|
|
||||||
make_verbose(parser);
|
|
||||||
make_help(parser);
|
|
||||||
|
|
||||||
auto& algo = state.pack< edoAlgoAdaptive<CMA> >(
|
|
||||||
gaussian , pop_eval, selector,
|
|
||||||
estimator, sampler , replacor,
|
|
||||||
pop_continue, distrib_continue);
|
|
||||||
|
|
||||||
try {
|
|
||||||
algo(pop);
|
|
||||||
} catch (eoMaxEvalException& e) {
|
|
||||||
eo::log << eo::progress << "STOP" << std::endl;
|
|
||||||
}
|
|
||||||
|
|
||||||
std::cout << best.value() << std::endl;
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
@ -28,7 +28,7 @@ Authors:
|
||||||
#include <eo>
|
#include <eo>
|
||||||
#include <edo>
|
#include <edo>
|
||||||
|
|
||||||
#include "../application/common/Rosenbrock.h"
|
#include "Rosenbrock.h"
|
||||||
|
|
||||||
typedef eoReal< eoMinimizingFitness > EOT;
|
typedef eoReal< eoMinimizingFitness > EOT;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -108,12 +108,7 @@ public:
|
||||||
if (is) {
|
if (is) {
|
||||||
virus.resize(bits.size());
|
virus.resize(bits.size());
|
||||||
std::transform(bits.begin(), bits.end(), virus.begin(),
|
std::transform(bits.begin(), bits.end(), virus.begin(),
|
||||||
#if __cplusplus >= 201103L
|
|
||||||
std::bind(std::equal_to<char>(), std::placeholders::_1, '1'));
|
|
||||||
#else
|
|
||||||
// Deprecated since C++11.
|
|
||||||
std::bind2nd(std::equal_to<char>(), '1'));
|
std::bind2nd(std::equal_to<char>(), '1'));
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,78 +0,0 @@
|
||||||
|
|
||||||
######################################################################################
|
|
||||||
# Project settings
|
|
||||||
######################################################################################
|
|
||||||
|
|
||||||
cmake_minimum_required(VERSION 3.10 FATAL_ERROR)
|
|
||||||
|
|
||||||
project("paradiseo-irace")
|
|
||||||
|
|
||||||
enable_language(CXX) # C++
|
|
||||||
set(CMAKE_CXX_STANDARD 17)
|
|
||||||
|
|
||||||
## Current version
|
|
||||||
set(VERSION_MAJOR 0 CACHE STRING "Major version number" )
|
|
||||||
set(VERSION_MINOR 1 CACHE STRING "Minor version number" )
|
|
||||||
set(VERSION_PATCH 0 CACHE STRING "Patch version number" )
|
|
||||||
mark_as_advanced(VERSION_MAJOR VERSION_MINOR VERSION_PATCH)
|
|
||||||
|
|
||||||
|
|
||||||
######################################################################################
|
|
||||||
# Configurable user settings
|
|
||||||
######################################################################################
|
|
||||||
|
|
||||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Wpedantic")
|
|
||||||
|
|
||||||
# put binaries in the build directory
|
|
||||||
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR})
|
|
||||||
|
|
||||||
# Dump used compiler flags.
|
|
||||||
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
|
|
||||||
|
|
||||||
|
|
||||||
######################################################################################
|
|
||||||
# Dependencies
|
|
||||||
######################################################################################
|
|
||||||
|
|
||||||
# ParadisEO
|
|
||||||
set(PARADISEO_ROOT "../../../../paradiseo" CACHE PATH "Where to find ParadisEO")
|
|
||||||
set(PARADISEO_BUILD "${PARADISEO_ROOT}/build" CACHE PATH "Build dir of ParadisEO")
|
|
||||||
|
|
||||||
include_directories(${PARADISEO_ROOT})
|
|
||||||
include_directories(${PARADISEO_ROOT}/eo/src)
|
|
||||||
link_directories(${PARADISEO_BUILD}/lib)
|
|
||||||
set(PARADISEO_LIBRARIES ga eoutils eo)
|
|
||||||
|
|
||||||
# IOH
|
|
||||||
set(IOH_ROOT "~/code/IOHexperimenter/" CACHE PATH "Where to find IOHexperimenter")
|
|
||||||
find_path(IOH_HPP "ioh.hpp" PATHS ${IOH_ROOT}/include/)
|
|
||||||
# find_library(IOH_LIBRARY "IOH" PATHS ${IOH_ROOT} PATH_SUFFIXES release Release debug Debug build Build)
|
|
||||||
|
|
||||||
if(EXISTS ${IOH_HPP}) # AND EXISTS ${IOH_LIBRARY})
|
|
||||||
message(STATUS "Found IOH in ${IOH_ROOT}")
|
|
||||||
include_directories(${IOH_ROOT}/include/)
|
|
||||||
include_directories(${IOH_ROOT}/external/fmt/include/)
|
|
||||||
include_directories(${IOH_ROOT}/external/clutchlog/)
|
|
||||||
link_directories(${IOH_ROOT}/release/external/fmt/)
|
|
||||||
|
|
||||||
else()
|
|
||||||
if(NOT EXISTS ${IOH_HPP})
|
|
||||||
message(FATAL_ERROR "Could not find `ioh.hpp` in: ${IOH_ROOT}/include/")
|
|
||||||
endif()
|
|
||||||
# if(NOT EXISTS ${IOH_LIBRARIES})
|
|
||||||
# message(FATAL_ERROR "Could not find `libIOH` in: ${IOH_ROOT}/[release|debug|build] (did you forget to compile it?)")
|
|
||||||
# endif()
|
|
||||||
endif()
|
|
||||||
|
|
||||||
|
|
||||||
######################################################################################
|
|
||||||
# Start building
|
|
||||||
######################################################################################
|
|
||||||
|
|
||||||
add_executable(fastga fastga.cpp)
|
|
||||||
# Link to stdc++fs at the end because of an Ubuntu bug, see: https://stackoverflow.com/a/57760267
|
|
||||||
target_link_libraries(fastga ${PARADISEO_LIBRARIES} fmt stdc++fs)
|
|
||||||
|
|
||||||
add_executable(onlymutga onlymutga.cpp)
|
|
||||||
target_link_libraries(onlymutga ${PARADISEO_LIBRARIES} fmt)
|
|
||||||
|
|
||||||
|
|
@ -1,80 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
|
|
||||||
########################################################################
|
|
||||||
# This is an example of how to deal with complex builds,
|
|
||||||
# for instance on clusters with compilers provided as side modules.
|
|
||||||
########################################################################
|
|
||||||
|
|
||||||
# Run this script in a separate dir, e.g.
|
|
||||||
# mkdir -p code ; cd code ; ../build_fastga.sh
|
|
||||||
|
|
||||||
# exit when any command fails
|
|
||||||
set -e
|
|
||||||
|
|
||||||
# We need recent clang and cmake
|
|
||||||
module load LLVM/clang-llvm-10.0
|
|
||||||
module load cmake/3.18
|
|
||||||
|
|
||||||
# We are going to use a specific compiler, different from the system's one.
|
|
||||||
# Path toward the compiler:
|
|
||||||
C="/opt/dev/Compilers/LLVM/10.0.1/bin"
|
|
||||||
# Path toward the include for the std lib:
|
|
||||||
I="/opt/dev/Compilers/LLVM/10.0.1/include/c++/v1/"
|
|
||||||
# Path toward the compiled std lib:
|
|
||||||
L="/opt/dev/Compilers/LLVM/10.0.1/lib"
|
|
||||||
|
|
||||||
# As we use clang, we use its std lib (instead of gcc's "libstdc++")
|
|
||||||
S="libc++"
|
|
||||||
|
|
||||||
# Gather all those into a set of flags:
|
|
||||||
flags="-I${I} -stdlib=${S} -L${L}"
|
|
||||||
|
|
||||||
# Current dir, for further reference.
|
|
||||||
here=$(pwd)
|
|
||||||
|
|
||||||
# Compiler selection
|
|
||||||
export CC=${C}/clang
|
|
||||||
export CXX=${C}/clang++
|
|
||||||
|
|
||||||
# If the dir already exists
|
|
||||||
if cd IOHexperimenter ; then
|
|
||||||
# Just update the code
|
|
||||||
git pull
|
|
||||||
else
|
|
||||||
# Clone the repo
|
|
||||||
git clone --branch feat+EAF --single-branch --recurse-submodules https://github.com/jdreo/IOHexperimenter.git
|
|
||||||
cd IOHexperimenter
|
|
||||||
fi
|
|
||||||
# Clean build from scratch
|
|
||||||
rm -rf release
|
|
||||||
mkdir -p release
|
|
||||||
cd release
|
|
||||||
cmake -DCMAKE_CXX_FLAGS="${flags}" -D CMAKE_BUILD_TYPE=Release -D BUILD_TESTS=OFF -D BUILD_EXAMPLE=OFF ..
|
|
||||||
make -j
|
|
||||||
# Get back to the root dir
|
|
||||||
cd ${here}
|
|
||||||
|
|
||||||
|
|
||||||
if cd paradiseo ; then
|
|
||||||
git pull
|
|
||||||
else
|
|
||||||
git clone --branch feat+num_foundry --single-branch --recurse-submodules https://github.com/jdreo/paradiseo.git
|
|
||||||
cd paradiseo
|
|
||||||
touch LICENSE
|
|
||||||
fi
|
|
||||||
rm -rf release
|
|
||||||
mkdir -p release
|
|
||||||
cd release
|
|
||||||
cmake -DCMAKE_CXX_FLAGS="${flags}" -D CMAKE_BUILD_TYPE=Release ..
|
|
||||||
make -j
|
|
||||||
cd ${here}
|
|
||||||
|
|
||||||
|
|
||||||
cd paradiseo/eo/contrib/irace
|
|
||||||
rm -rf release
|
|
||||||
mkdir -p release
|
|
||||||
cd release
|
|
||||||
cmake -DCMAKE_CXX_FLAGS="${flags}" -D CMAKE_BUILD_TYPE=Release -D IOH_ROOT=${here}/IOHexperimenter/ -D PARADISEO_ROOT=${here}/paradiseo/ -D PARADISEO_BUILD=${here}/paradiseo/release/ ..
|
|
||||||
make -j
|
|
||||||
cd ${here}
|
|
||||||
|
|
||||||
|
|
@ -1,28 +0,0 @@
|
||||||
#!/usr/bin/env python3
|
|
||||||
|
|
||||||
import sys
|
|
||||||
|
|
||||||
print("algo,problem,seed,ECDF_AUC")
|
|
||||||
|
|
||||||
algos_names = {
|
|
||||||
str({"crossover-rate":0, "cross-selector":0, "crossover":0, "mutation-rate":0, "mut-selector":0, "mutation":1, "replacement":0}) : "EA",
|
|
||||||
str({"crossover-rate":0, "cross-selector":0, "crossover":0, "mutation-rate":0, "mut-selector":0, "mutation":5, "replacement":0}) : "fEA",
|
|
||||||
str({"crossover-rate":2, "cross-selector":2, "crossover":2, "mutation-rate":2, "mut-selector":2, "mutation":1, "replacement":0}) : "xGA",
|
|
||||||
str({"crossover-rate":2, "cross-selector":2, "crossover":5, "mutation-rate":2, "mut-selector":2, "mutation":1, "replacement":0}) : "1ptGA",
|
|
||||||
}
|
|
||||||
|
|
||||||
for fname in sys.argv[1:]:
|
|
||||||
|
|
||||||
run = {}
|
|
||||||
for f in fname.strip(".dat").split("_"):
|
|
||||||
kv = f.split("=")
|
|
||||||
assert(len(kv)==2),str(kv)+" "+str(len(kv))
|
|
||||||
key,idx = kv[0], int(kv[1])
|
|
||||||
run[key] = idx
|
|
||||||
|
|
||||||
with open(fname) as fd:
|
|
||||||
auc = int(fd.readlines()[0]) * -1
|
|
||||||
|
|
||||||
algo = str({"crossover-rate":run["crossover-rate"], "cross-selector":run["cross-selector"], "crossover":run["crossover"], "mutation-rate":run["mutation-rate"], "mut-selector":run["mut-selector"], "mutation":run["mutation"], "replacement":run["replacement"]})
|
|
||||||
|
|
||||||
print(algos_names[algo], run["pb"], run["seed"], auc, sep=",")
|
|
||||||
|
|
@ -1,49 +0,0 @@
|
||||||
#!/usr/bin/env python3
|
|
||||||
|
|
||||||
import sys
|
|
||||||
|
|
||||||
print("problem,EA,fEA,xGA,1ptGA")
|
|
||||||
|
|
||||||
algos_names = {
|
|
||||||
str({"crossover-rate":0, "cross-selector":0, "crossover":0, "mutation-rate":0, "mut-selector":0, "mutation":1, "replacement":0}) : "EA",
|
|
||||||
str({"crossover-rate":0, "cross-selector":0, "crossover":0, "mutation-rate":0, "mut-selector":0, "mutation":5, "replacement":0}) : "fEA",
|
|
||||||
str({"crossover-rate":2, "cross-selector":2, "crossover":2, "mutation-rate":2, "mut-selector":2, "mutation":1, "replacement":0}) : "xGA",
|
|
||||||
str({"crossover-rate":2, "cross-selector":2, "crossover":5, "mutation-rate":2, "mut-selector":2, "mutation":1, "replacement":0}) : "1ptGA",
|
|
||||||
}
|
|
||||||
|
|
||||||
data = {}
|
|
||||||
|
|
||||||
# Parse
|
|
||||||
for fname in sys.argv[1:]:
|
|
||||||
|
|
||||||
run = {}
|
|
||||||
for f in fname.strip(".dat").split("_"):
|
|
||||||
kv = f.split("=")
|
|
||||||
assert(len(kv)==2),str(kv)+" "+str(len(kv))
|
|
||||||
key,idx = kv[0], int(kv[1])
|
|
||||||
run[key] = idx
|
|
||||||
|
|
||||||
with open(fname) as fd:
|
|
||||||
auc = int(fd.readlines()[0]) * -1
|
|
||||||
|
|
||||||
algo = str({"crossover-rate":run["crossover-rate"], "cross-selector":run["cross-selector"], "crossover":run["crossover"], "mutation-rate":run["mutation-rate"], "mut-selector":run["mut-selector"], "mutation":run["mutation"], "replacement":run["replacement"]})
|
|
||||||
|
|
||||||
if run["pb"] in data:
|
|
||||||
data[run["pb"]][algos_names[algo]].append(auc)
|
|
||||||
else:
|
|
||||||
data[run["pb"]] = {
|
|
||||||
"EA" : [],
|
|
||||||
"fEA" : [],
|
|
||||||
"xGA" : [],
|
|
||||||
"1ptGA": [],
|
|
||||||
}
|
|
||||||
data[run["pb"]][algos_names[algo]].append(auc)
|
|
||||||
|
|
||||||
|
|
||||||
# Print CSV
|
|
||||||
for pb in sorted(data.keys()):
|
|
||||||
print(pb, end="")
|
|
||||||
for algo in ["EA","fEA","xGA","1ptGA"]:
|
|
||||||
res = data[pb][algo]
|
|
||||||
print(",", sum(res)/len(res), end="", sep="")
|
|
||||||
print()
|
|
||||||
|
|
@ -1,21 +0,0 @@
|
||||||
#!/usr/bin/env python3
|
|
||||||
|
|
||||||
import sys
|
|
||||||
|
|
||||||
print("algo,problem,seed,ECDF_AUC")
|
|
||||||
|
|
||||||
for fname in sys.argv[1:]:
|
|
||||||
|
|
||||||
run = {}
|
|
||||||
for f in fname.strip(".dat").split("_"):
|
|
||||||
kv = f.split("=")
|
|
||||||
assert(len(kv)==2),str(kv)+" "+str(len(kv))
|
|
||||||
key,idx = kv[0], int(kv[1])
|
|
||||||
run[key] = idx
|
|
||||||
|
|
||||||
with open(fname) as fd:
|
|
||||||
auc = int(fd.readlines()[0]) * -1
|
|
||||||
|
|
||||||
algo = "pc={}_c={}_C={}_pm={}_m={}_M={}_R={}".format(run["crossover-rate"],run["cross-selector"],run["crossover"],run["mutation-rate"],run["mut-selector"],run["mutation"],run["replacement"])
|
|
||||||
|
|
||||||
print(algo, run["pb"], run["seed"], auc, sep=",")
|
|
||||||
|
|
@ -1,30 +0,0 @@
|
||||||
#!/usr/bin/env python3
|
|
||||||
|
|
||||||
import os
|
|
||||||
import re
|
|
||||||
import sys
|
|
||||||
|
|
||||||
print("pb,ecdf,id,crossover-rate,cross-selector,crossover,mutation-rate,mut-selector,mutation,replacement")
|
|
||||||
for datadir in sys.argv[1:]:
|
|
||||||
|
|
||||||
for pb_dir in os.listdir(datadir):
|
|
||||||
if "results_problem" in pb_dir:
|
|
||||||
pb_id=pb_dir.replace("results_problem_","")
|
|
||||||
with open(os.path.join("./",datadir,pb_dir,"irace.log")) as fd:
|
|
||||||
data = fd.readlines()
|
|
||||||
|
|
||||||
# Find the last best configuration
|
|
||||||
bests = [line.strip() for line in data if "Best-so-far" in line]
|
|
||||||
best = bests[-1].split()
|
|
||||||
best_id, best_perf = best[2], best[5]
|
|
||||||
# print(best_id,best_perf)
|
|
||||||
|
|
||||||
# Filter the config detail
|
|
||||||
configs = [line.strip() for line in data if "--crossover-rate=" in line and best_id in line]
|
|
||||||
# print(configs)
|
|
||||||
|
|
||||||
# Format as CSV
|
|
||||||
for config in configs:
|
|
||||||
algo = re.sub("\-\-\S*=", ",", config)
|
|
||||||
csv_line = pb_id + "," + best_perf + "," + algo
|
|
||||||
print(csv_line.replace(" ",""))
|
|
||||||
|
|
@ -1,44 +0,0 @@
|
||||||
#!/usr/bin/env python3
|
|
||||||
|
|
||||||
import os
|
|
||||||
import numpy as np
|
|
||||||
import matplotlib.pyplot as plt
|
|
||||||
|
|
||||||
for p in range(18):
|
|
||||||
|
|
||||||
print("Pb",p,end=": ")
|
|
||||||
datadir="attain_mat_{pb}".format(pb=p)
|
|
||||||
|
|
||||||
try:
|
|
||||||
os.mkdir(datadir)
|
|
||||||
except FileExistsError:
|
|
||||||
pass
|
|
||||||
|
|
||||||
for i in range(50):
|
|
||||||
cmd="./release/fastga --seed={i} \
|
|
||||||
--crossover-rate=2 --cross-selector=2 --crossover=5 --mutation-rate=2 --mut-selector=2 --mutation=1 --replacement=0 \
|
|
||||||
--problem={pb} --buckets=20 --output-mat 2>/dev/null > {dir}/output_mat_{i}.csv"\
|
|
||||||
.format(dir=datadir, i=i, pb=p)
|
|
||||||
# print(cmd)
|
|
||||||
print(i,end=" ",flush=True)
|
|
||||||
os.system(cmd)
|
|
||||||
|
|
||||||
|
|
||||||
matrices=[]
|
|
||||||
for root, dirs, files in os.walk(datadir):
|
|
||||||
for filename in files:
|
|
||||||
matrices.append( np.genfromtxt(datadir+"/"+filename,delimiter=',') )
|
|
||||||
|
|
||||||
agg = matrices[0]
|
|
||||||
for mat in matrices[1:]:
|
|
||||||
agg += mat
|
|
||||||
|
|
||||||
# print(agg)
|
|
||||||
|
|
||||||
plt.rcParams["figure.figsize"] = (3,3)
|
|
||||||
plt.gca().pcolor(agg, edgecolors='grey', cmap="Blues")
|
|
||||||
plt.gca().set_xlabel("Time budget")
|
|
||||||
plt.gca().set_ylabel("Target")
|
|
||||||
plt.savefig("aittain_map_{pb}.png".format(pb=p), bbox_inches='tight')
|
|
||||||
|
|
||||||
print(".")
|
|
||||||
|
|
@ -1,43 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
# Number of runs (=seeds).
|
|
||||||
runs=50
|
|
||||||
|
|
||||||
# Array of problems.
|
|
||||||
# You may set something like: (0 2 5 17)
|
|
||||||
problems=($(seq 0 18))
|
|
||||||
|
|
||||||
# Capture anything passed to the script
|
|
||||||
outdir="$1"
|
|
||||||
algo="${@:2}"
|
|
||||||
|
|
||||||
# You most probably want to run on release builds.
|
|
||||||
exe="./release/fastga"
|
|
||||||
|
|
||||||
i=1 # Loop counter.
|
|
||||||
for pb in "${problems[@]}" ; do # Iterate over the problems array.
|
|
||||||
for seed in $(seq ${runs}) ; do # Iterates over runs/seeds.
|
|
||||||
# Forge a directory/log file name
|
|
||||||
# (remove double dashs and replace spaces with underscore).
|
|
||||||
name="pb=${pb}_seed=${seed}_$(echo "${algo}" | sed 's/--//g' | sed 's/ /_/g')"
|
|
||||||
|
|
||||||
# This is the command to be ran.
|
|
||||||
cmd="${exe} --problem=${pb} --seed=${seed} ${algo}"
|
|
||||||
echo ${cmd} # Print the command.
|
|
||||||
|
|
||||||
# Progress print.
|
|
||||||
echo -n "problem ${pb}, run ${seed}"
|
|
||||||
|
|
||||||
# Actually start the command.
|
|
||||||
${cmd} > "${outdir}/${name}.dat" 2> "${outdir}/${name}.log"
|
|
||||||
|
|
||||||
# Check for the most common problem in the log file.
|
|
||||||
cat "${outdir}/${name}.log" | grep "illogical performance"
|
|
||||||
|
|
||||||
perc=$(echo "scale=2;${i}/(${#problems[@]}*${runs})*100" | bc)
|
|
||||||
echo -e " -- ${perc}%"
|
|
||||||
i=$((i+1))
|
|
||||||
done
|
|
||||||
done
|
|
||||||
|
|
||||||
echo "Done $((${#problems[@]}*${runs})) runs, results in ${outdir}"
|
|
||||||
|
|
@ -1,30 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
outdir="$(date --iso-8601=minutes)_results_baselines"
|
|
||||||
mkdir ${outdir}
|
|
||||||
|
|
||||||
algos=(
|
|
||||||
# (λ+λ)EA
|
|
||||||
"--full-log=1 --crossover-rate=0 --cross-selector=0 --crossover=0 --mutation-rate=0 --mut-selector=0 --mutation=1 --replacement=0"
|
|
||||||
# (λ+λ)fEA
|
|
||||||
"--full-log=1 --crossover-rate=0 --cross-selector=0 --crossover=0 --mutation-rate=0 --mut-selector=0 --mutation=5 --replacement=0"
|
|
||||||
# (λ+λ)xGA
|
|
||||||
"--full-log=1 --crossover-rate=2 --cross-selector=2 --crossover=2 --mutation-rate=2 --mut-selector=2 --mutation=1 --replacement=0"
|
|
||||||
# (λ+λ)1ptGA
|
|
||||||
"--full-log=1 --crossover-rate=2 --cross-selector=2 --crossover=5 --mutation-rate=2 --mut-selector=2 --mutation=1 --replacement=0"
|
|
||||||
)
|
|
||||||
|
|
||||||
|
|
||||||
i=1 # Loop counter.
|
|
||||||
for algo in "${algos[@]}" ; do
|
|
||||||
echo "${algo}"
|
|
||||||
|
|
||||||
name="$(echo "${algo}" | sed 's/--//g' | sed 's/ /_/g')"
|
|
||||||
./run_algo.sh ${outdir} ${algo} &> "expe_${name}.log"
|
|
||||||
|
|
||||||
perc=$(echo "scale=2;${i}/${#algos[@]}*100" | bc)
|
|
||||||
echo -e "${perc}%\n"
|
|
||||||
i=$((i+1))
|
|
||||||
done
|
|
||||||
|
|
||||||
echo "Done"
|
|
||||||
|
|
@ -1,67 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
# Number of runs (=seeds).
|
|
||||||
runs=50
|
|
||||||
|
|
||||||
# You most probably want to run on release builds.
|
|
||||||
exe="./release/fastga"
|
|
||||||
|
|
||||||
outdir="$(date --iso-8601=minutes)_results_elites"
|
|
||||||
mkdir ${outdir}
|
|
||||||
|
|
||||||
# FIXME
|
|
||||||
algos=(
|
|
||||||
"--crossover-rate=1 --cross-selector=2 --crossover=1 --mutation-rate=2 --mut-selector=2 --mutation=8 --replacement=8"
|
|
||||||
"--crossover-rate=4 --cross-selector=5 --crossover=2 --mutation-rate=3 --mut-selector=4 --mutation=9 --replacement=9"
|
|
||||||
"--crossover-rate=1 --cross-selector=3 --crossover=8 --mutation-rate=2 --mut-selector=6 --mutation=3 --replacement=2"
|
|
||||||
"--crossover-rate=2 --cross-selector=1 --crossover=1 --mutation-rate=2 --mut-selector=6 --mutation=9 --replacement=0"
|
|
||||||
"--crossover-rate=4 --cross-selector=2 --crossover=2 --mutation-rate=4 --mut-selector=3 --mutation=7 --replacement=0"
|
|
||||||
"--crossover-rate=0 --cross-selector=3 --crossover=2 --mutation-rate=4 --mut-selector=2 --mutation=6 --replacement=0"
|
|
||||||
"--crossover-rate=3 --cross-selector=0 --crossover=3 --mutation-rate=4 --mut-selector=3 --mutation=10 --replacement=0"
|
|
||||||
"--crossover-rate=0 --cross-selector=1 --crossover=0 --mutation-rate=3 --mut-selector=2 --mutation=10 --replacement=0"
|
|
||||||
"--crossover-rate=2 --cross-selector=2 --crossover=2 --mutation-rate=4 --mut-selector=5 --mutation=10 --replacement=0"
|
|
||||||
"--crossover-rate=4 --cross-selector=2 --crossover=2 --mutation-rate=4 --mut-selector=5 --mutation=9 --replacement=0"
|
|
||||||
"--crossover-rate=3 --cross-selector=2 --crossover=10 --mutation-rate=4 --mut-selector=2 --mutation=10 --replacement=0"
|
|
||||||
"--crossover-rate=2 --cross-selector=2 --crossover=5 --mutation-rate=4 --mut-selector=3 --mutation=9 --replacement=0"
|
|
||||||
"--crossover-rate=3 --cross-selector=6 --crossover=2 --mutation-rate=4 --mut-selector=1 --mutation=10 --replacement=0"
|
|
||||||
"--crossover-rate=1 --cross-selector=5 --crossover=9 --mutation-rate=4 --mut-selector=2 --mutation=8 --replacement=0"
|
|
||||||
"--crossover-rate=2 --cross-selector=5 --crossover=2 --mutation-rate=4 --mut-selector=6 --mutation=8 --replacement=0"
|
|
||||||
"--crossover-rate=2 --cross-selector=2 --crossover=10 --mutation-rate=4 --mut-selector=6 --mutation=10 --replacement=0"
|
|
||||||
"--crossover-rate=3 --cross-selector=2 --crossover=2 --mutation-rate=4 --mut-selector=5 --mutation=10 --replacement=0"
|
|
||||||
"--crossover-rate=4 --cross-selector=2 --crossover=2 --mutation-rate=4 --mut-selector=1 --mutation=8 --replacement=0"
|
|
||||||
"--crossover-rate=4 --cross-selector=2 --crossover=2 --mutation-rate=4 --mut-selector=6 --mutation=9 --replacement=0"
|
|
||||||
)
|
|
||||||
|
|
||||||
pb=0 # Loop counter.
|
|
||||||
for algo in "${algos[@]}" ; do
|
|
||||||
echo "Problem ${pb}"
|
|
||||||
echo -n "Runs: "
|
|
||||||
|
|
||||||
for seed in $(seq ${runs}) ; do # Iterates over runs/seeds.
|
|
||||||
# This is the command to be ran.
|
|
||||||
cmd="${exe} --full-log=1 --problem=${pb} --seed=${seed} ${algo}"
|
|
||||||
# echo ${cmd} # Print the command.
|
|
||||||
|
|
||||||
# Forge a directory/log file name
|
|
||||||
# (remove double dashs and replace spaces with underscore).
|
|
||||||
name_run="pb=${pb}_seed=${seed}_$(echo "${algo}" | sed 's/--//g' | sed 's/ /_/g')"
|
|
||||||
# echo $name_run
|
|
||||||
|
|
||||||
# Progress print.
|
|
||||||
echo -n "${seed} "
|
|
||||||
|
|
||||||
# Actually start the command.
|
|
||||||
${cmd} > "${outdir}/${name_run}.dat" 2> "${outdir}/${name_run}.log"
|
|
||||||
|
|
||||||
# Check for the most common problem in the log file.
|
|
||||||
cat "${outdir}/${name_run}.log" | grep "illogical performance"
|
|
||||||
done
|
|
||||||
|
|
||||||
echo ""
|
|
||||||
perc=$(echo "scale=2;${pb}/${#algos[@]}*100" | bc)
|
|
||||||
echo -e "${perc}%\n"
|
|
||||||
pb=$((pb+1))
|
|
||||||
|
|
||||||
done
|
|
||||||
|
|
||||||
echo "Done"
|
|
||||||
|
|
@ -1,61 +0,0 @@
|
||||||
|
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
# Number of runs (=seeds).
|
|
||||||
runs=50
|
|
||||||
|
|
||||||
# You most probably want to run on release builds.
|
|
||||||
exe="./release/fastga"
|
|
||||||
|
|
||||||
outdir="$(date --iso-8601=minutes)_results_elites_all"
|
|
||||||
mkdir -p ${outdir}
|
|
||||||
mkdir -p ${outdir}/raw
|
|
||||||
mkdir -p ${outdir}/raw/data
|
|
||||||
mkdir -p ${outdir}/raw/logs
|
|
||||||
|
|
||||||
n=0
|
|
||||||
algoid=0
|
|
||||||
for line in $(cat results_irace_100k.csv|cut -s -d"," -f4-10); do
|
|
||||||
echo ""
|
|
||||||
date
|
|
||||||
|
|
||||||
a=($(echo $line | sed "s/,/ /g"))
|
|
||||||
algo="--crossover-rate=${a[0]} --cross-selector=${a[1]} --crossover=${a[2]} --mutation-rate=${a[3]} --mut-selector=${a[4]} --mutation=${a[5]} --replacement=${a[6]}"
|
|
||||||
|
|
||||||
for pb in $(seq 0 18) ; do
|
|
||||||
perc=$(echo "scale=3;${n}/(285*18)*100.0" | bc)
|
|
||||||
echo "${perc}% : algo ${algoid}/285, problem ${pb}/18"
|
|
||||||
# echo -n "Runs: "
|
|
||||||
|
|
||||||
for seed in $(seq ${runs}) ; do # Iterates over runs/seeds.
|
|
||||||
# This is the command to be ran.
|
|
||||||
cmd="${exe} --full-log=1 --problem=${pb} --seed=${seed} ${algo}"
|
|
||||||
# echo ${cmd} # Print the command.
|
|
||||||
|
|
||||||
# Forge a directory/log file name
|
|
||||||
# (remove double dashs and replace spaces with underscore).
|
|
||||||
name_run="pb=${pb}_seed=${seed}_$(echo "${algo}" | sed 's/--//g' | sed 's/ /_/g')"
|
|
||||||
# echo $name_run
|
|
||||||
|
|
||||||
# Progress print.
|
|
||||||
# echo -n "${seed} "
|
|
||||||
|
|
||||||
# Actually start the command.
|
|
||||||
${cmd} > "${outdir}/raw/data/${name_run}.dat" 2> "${outdir}/raw/logs/${name_run}.log"
|
|
||||||
|
|
||||||
# Check for the most common problem in the log file.
|
|
||||||
cat "${outdir}/raw/logs/${name_run}.log" | grep "illogical performance"
|
|
||||||
done # seed
|
|
||||||
# echo ""
|
|
||||||
|
|
||||||
n=$(($n+1))
|
|
||||||
done # pb
|
|
||||||
|
|
||||||
algoid=$(($algoid+1))
|
|
||||||
done
|
|
||||||
|
|
||||||
# Move IOH logs in the results directory.
|
|
||||||
mv ./FastGA_* ${outdir}
|
|
||||||
|
|
||||||
echo "Done"
|
|
||||||
date
|
|
||||||
|
|
@ -1,27 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
outdir="$(date --iso-8601=minutes)_results_irace"
|
|
||||||
mkdir ${outdir}
|
|
||||||
cd ${outdir}
|
|
||||||
|
|
||||||
for p in $(seq 0 18) ; do
|
|
||||||
echo -n "Problem ${p}... "
|
|
||||||
res="results_problem_${p}"
|
|
||||||
mkdir ${res}
|
|
||||||
cd ${res}
|
|
||||||
|
|
||||||
# Fore some reason, irace absolutely need those files...
|
|
||||||
cp ../../irace-config/example.scen .
|
|
||||||
cp ../../irace-config/default.instances .
|
|
||||||
cp ../../release/fastga .
|
|
||||||
cat ../../irace-config/target-runner | sed "s/{{PROBLEM}}/${p}/" > ./target-runner
|
|
||||||
chmod u+x target-runner
|
|
||||||
|
|
||||||
# Generate the parameter list file.
|
|
||||||
./fastga -h > fastga.param 2>/dev/null
|
|
||||||
# /usr/lib/R/site-library/irace/bin/irace --scenario example.scen 2>&1 | tee irace.log
|
|
||||||
/usr/lib/R/site-library/irace/bin/irace --scenario example.scen &> irace.log
|
|
||||||
|
|
||||||
cd ..
|
|
||||||
echo " done"
|
|
||||||
done
|
|
||||||
|
|
@ -1,14 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
date -Iseconds
|
|
||||||
echo "STARTS"
|
|
||||||
|
|
||||||
for r in $(seq 15); do
|
|
||||||
echo "Run $r/15";
|
|
||||||
date -Iseconds
|
|
||||||
./run_irace_parallel-batch.sh
|
|
||||||
date -Iseconds
|
|
||||||
done
|
|
||||||
|
|
||||||
echo "DONE"
|
|
||||||
date -Iseconds
|
|
||||||
|
|
@ -1,38 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
outdir="$(date --iso-8601=ns)_results_irace"
|
|
||||||
mkdir ${outdir}
|
|
||||||
cd ${outdir}
|
|
||||||
|
|
||||||
run(){
|
|
||||||
p="$1"
|
|
||||||
|
|
||||||
echo "Problem ${p}"
|
|
||||||
res="results_problem_${p}"
|
|
||||||
mkdir ${res}
|
|
||||||
cd ${res}
|
|
||||||
|
|
||||||
# Fore some reason, irace absolutely need those files...
|
|
||||||
cp ../../irace-config/example.scen .
|
|
||||||
cp ../../irace-config/default.instances .
|
|
||||||
cp ../../release/fastga .
|
|
||||||
cat ../../irace-config/target-runner | sed "s/{{PROBLEM}}/${p}/" > ./target-runner
|
|
||||||
chmod u+x target-runner
|
|
||||||
|
|
||||||
# Generate the parameter list file.
|
|
||||||
./fastga -h > fastga.param 2>/dev/null
|
|
||||||
# /usr/lib/R/site-library/irace/bin/irace --scenario example.scen 2>&1 | tee irace.log
|
|
||||||
/usr/lib/R/site-library/irace/bin/irace --scenario example.scen &> irace.log
|
|
||||||
|
|
||||||
cd ..
|
|
||||||
echo "Done problem ${p}"
|
|
||||||
}
|
|
||||||
|
|
||||||
N=5 # Somehow 5 is the fastest on my 4-cores machine.
|
|
||||||
(
|
|
||||||
for pb in $(seq 0 18); do
|
|
||||||
((i=i%N)); ((i++==0)) && wait
|
|
||||||
run "$pb" &
|
|
||||||
done
|
|
||||||
wait
|
|
||||||
)
|
|
||||||
|
|
@ -1,61 +0,0 @@
|
||||||
|
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
# Number of runs (=seeds).
|
|
||||||
runs=50
|
|
||||||
|
|
||||||
# You most probably want to run on release builds.
|
|
||||||
exe="./release/fastga"
|
|
||||||
|
|
||||||
outdir="$(date --iso-8601=minutes)_results_randoms"
|
|
||||||
mkdir -p ${outdir}
|
|
||||||
mkdir -p ${outdir}/raw
|
|
||||||
mkdir -p ${outdir}/raw/data
|
|
||||||
mkdir -p ${outdir}/raw/logs
|
|
||||||
|
|
||||||
n=1
|
|
||||||
algoid=0
|
|
||||||
for algoid in $(seq 0 100); do
|
|
||||||
echo ""
|
|
||||||
date
|
|
||||||
|
|
||||||
a=( $((RANDOM%5)) $((RANDOM%7)) $((RANDOM%11)) $((RANDOM%5)) $((RANDOM%7)) $((RANDOM%11)) $((RANDOM%11)) )
|
|
||||||
algo="--crossover-rate=${a[0]} --cross-selector=${a[1]} --crossover=${a[2]} --mutation-rate=${a[3]} --mut-selector=${a[4]} --mutation=${a[5]} --replacement=${a[6]}"
|
|
||||||
|
|
||||||
for pb in $(seq 0 18) ; do
|
|
||||||
perc=$(echo "scale=3;${n}/(100*18)*100.0" | bc)
|
|
||||||
echo "${perc}% : algo ${algoid}/100, problem ${pb}/18"
|
|
||||||
# echo -n "Runs: "
|
|
||||||
|
|
||||||
for seed in $(seq ${runs}) ; do # Iterates over runs/seeds.
|
|
||||||
# This is the command to be ran.
|
|
||||||
cmd="${exe} --full-log=1 --problem=${pb} --seed=${seed} ${algo}"
|
|
||||||
# echo ${cmd} # Print the command.
|
|
||||||
|
|
||||||
# Forge a directory/log file name
|
|
||||||
# (remove double dashs and replace spaces with underscore).
|
|
||||||
name_run="pb=${pb}_seed=${seed}_$(echo "${algo}" | sed 's/--//g' | sed 's/ /_/g')"
|
|
||||||
# echo $name_run
|
|
||||||
|
|
||||||
# Progress print.
|
|
||||||
# echo -n "${seed} "
|
|
||||||
|
|
||||||
# Actually start the command.
|
|
||||||
${cmd} > "${outdir}/raw/data/${name_run}.dat" 2> "${outdir}/raw/logs/${name_run}.log"
|
|
||||||
|
|
||||||
# Check for the most common problem in the log file.
|
|
||||||
cat "${outdir}/raw/logs/${name_run}.log" | grep "illogical performance"
|
|
||||||
done # seed
|
|
||||||
# echo ""
|
|
||||||
|
|
||||||
n=$(($n+1))
|
|
||||||
done # pb
|
|
||||||
|
|
||||||
algoid=$(($algoid+1))
|
|
||||||
done
|
|
||||||
|
|
||||||
# Move IOH logs in the results directory.
|
|
||||||
mv ./FastGA_* ${outdir}
|
|
||||||
|
|
||||||
echo "Done"
|
|
||||||
date
|
|
||||||
|
|
@ -1,86 +0,0 @@
|
||||||
#!/usr/bin/env python3
|
|
||||||
import sys
|
|
||||||
import os
|
|
||||||
import numpy as np
|
|
||||||
import matplotlib.pyplot as plt
|
|
||||||
#cmd eg :
|
|
||||||
#python3 best_out_of_elites.py ./fastga_results_all/fastga_results_planO/planO_maxExp=50000_maxEv=5n_2021-08-13T19:16+02:00_results_elites_all
|
|
||||||
#python3 best_out_of_elites.py ./fastga_results_all/fastga_results_random/maxEv=10000_nbAlgo=15_2021-08-21T20:53+02:00_results_randoms
|
|
||||||
|
|
||||||
|
|
||||||
#get the configuration of the best out of the elite
|
|
||||||
# recommendation suggested by 15 independant runs of irace
|
|
||||||
|
|
||||||
figdir=sys.argv[1] # directory of a result of one experiment
|
|
||||||
#eg : ./fastga_results_all/fastga_results_plan1/plan1_maxExp\=100000_maxEv\=5n_2021-08-13T19\:04+02\:00_results_elites_all/
|
|
||||||
#print(figdir.split('/')[-2], figdir.split('/'))
|
|
||||||
if("plan" in figdir.split('/')[-2]):
|
|
||||||
print("Operator,","op. ,",",".join(map(str,range(1,20))))
|
|
||||||
|
|
||||||
column={"pc" : 101, "SelectC": 7, "Crossover" : 10, "pm": 101,"SelectM" : 7, "Mutation": 11, "Replacement" : 11, "pop-size": 50, "offspring-size" : 50}
|
|
||||||
nbparam=(len(os.listdir(os.path.join(figdir,"raw/data"))[0].split("_"))-1) #-1 car il y a le pb
|
|
||||||
|
|
||||||
if( nbparam<len(column)):
|
|
||||||
del column["pop-size"]
|
|
||||||
del column["offspring-size"]
|
|
||||||
configs=[(-1,-1)]*19 #tuple(auc,config)
|
|
||||||
res=np.zeros((nbparam,19))
|
|
||||||
for fastgadir in os.listdir(os.path.join(figdir,"raw/data")): #fastgadir : directory of 50 runs of an elite configuration
|
|
||||||
#cum=np.cumsum([0.1]*10)
|
|
||||||
average=[]
|
|
||||||
for fname in os.listdir(os.path.join(figdir,"raw/data",fastgadir)):
|
|
||||||
with open(os.path.join(figdir,"raw/data",fastgadir,fname)) as fd:
|
|
||||||
auc = float(fd.readlines()[0]) * -1
|
|
||||||
average.append(auc)
|
|
||||||
pb=int(fastgadir.split("_")[0].split("=")[1])
|
|
||||||
new_auc=np.mean(average)
|
|
||||||
if(configs[pb][0]<new_auc):
|
|
||||||
configs[pb]=(new_auc,fastgadir)
|
|
||||||
|
|
||||||
|
|
||||||
for pb in range(19):
|
|
||||||
config=configs[pb][1].split("_")
|
|
||||||
configparam=[p.split("=")[1] for p in config[1:]]
|
|
||||||
res[:,pb]=configparam
|
|
||||||
|
|
||||||
ind=0 #index of param_name
|
|
||||||
for param_name in column.keys():
|
|
||||||
#print(map(str,res[ind]),res[ind], ",".join(map(str,res[ind])))
|
|
||||||
print(param_name+","+str(column[param_name])+",", ",".join(map(str,res[ind])))
|
|
||||||
ind+=1
|
|
||||||
#print(str(i)+",",",".join(map(str,np.mean(aucs[i],1))))
|
|
||||||
|
|
||||||
if("maxEv" in figdir.split('/')[-2]):
|
|
||||||
print("Operator,","op. ,",",".join(map(str,range(1,20))))
|
|
||||||
|
|
||||||
column={"pc" : 101, "SelectC": 7, "Crossover" : 10, "pm": 101,"SelectM" : 7, "Mutation": 11, "Replacement" : 11, "pop-size": 50, "offspring-size" : 50}
|
|
||||||
nbparam=(len(os.listdir(figdir)[0].split("_")))
|
|
||||||
if( nbparam<len(column)):
|
|
||||||
del column["pop-size"]
|
|
||||||
del column["offspring-size"]
|
|
||||||
configs=[(-1,-1)]*19 #tuple(auc,config)
|
|
||||||
bests=np.zeros((nbparam,19))
|
|
||||||
|
|
||||||
for algodir in os.listdir(figdir): #algodir : directory of one random algo
|
|
||||||
for fname in os.listdir(os.path.join(figdir,algodir,"data")): #fname : directory of 50 runs of fastga for one pb
|
|
||||||
average=[]
|
|
||||||
for res in os.listdir(os.path.join(figdir,algodir,"data",fname)):
|
|
||||||
with open(os.path.join(figdir,algodir,"data",fname,res)) as fd:
|
|
||||||
auc = float(fd.readlines()[0]) * -1
|
|
||||||
average.append(auc)
|
|
||||||
pb=int(fname.split("_")[0].split("=")[1])
|
|
||||||
new_auc=np.mean(average)
|
|
||||||
if(configs[pb][0]<new_auc):
|
|
||||||
configs[pb]=(new_auc,algodir)
|
|
||||||
|
|
||||||
|
|
||||||
for pb in range(19):
|
|
||||||
config=configs[pb][1].split("_")
|
|
||||||
configparam=[p.split("=")[1] for p in config]
|
|
||||||
bests[:,pb]=configparam
|
|
||||||
|
|
||||||
ind=0 #index of param_name
|
|
||||||
for param_name in column.keys():
|
|
||||||
#print(map(str,res[ind]),res[ind], ",".join(map(str,res[ind])))
|
|
||||||
print(param_name+","+str(column[param_name])+",", ",".join(map(str,bests[ind])))
|
|
||||||
ind+=1
|
|
||||||
|
|
@ -1,40 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
ldata="./fastga_results_all/" #fastga_results_all
|
|
||||||
figpath="./hist_and_csv/" #hist_and_csv
|
|
||||||
|
|
||||||
#get distribution of operators variants of all problems of each plan of fastga_results_all
|
|
||||||
#fastga_results_all contains all experiments of all plans
|
|
||||||
|
|
||||||
ldir=$(echo $(ls ${ldata})) #list of directory of each plan
|
|
||||||
for plan in ${ldir[@]} ; do #get the directory of each plan
|
|
||||||
lexperiment=$(echo $(ls ${ldata}/${plan}))
|
|
||||||
|
|
||||||
for experiments in ${lexperiment[@]} ; do
|
|
||||||
path="${ldata}/${plan}/${experiments}"
|
|
||||||
|
|
||||||
#----------------average aucs of each algo for each pb only for plan A,F,O ---------------
|
|
||||||
#myfig=${figpath}/auc_average_${plan}
|
|
||||||
#mkdir -p ${myfig}
|
|
||||||
#cmd="python3 parse_auc_average.py ${path} "
|
|
||||||
#$cmd > "${myfig}/auc_average_${experiments}.csv"
|
|
||||||
#--------------distribution of operators by pb and for all pb only for plan A,F,O ------
|
|
||||||
#myfig=${figpath}/distribution_op_${plan}
|
|
||||||
#mkdir -p ${myfig}
|
|
||||||
#cmd="python3 distribution_op_all.py ${path} ${myfig} "
|
|
||||||
#$cmd
|
|
||||||
#--------------best out csv--------
|
|
||||||
cmd="python3 best_out_of_elites.py ${path}"
|
|
||||||
myfig=${figpath}/best_out_${plan}
|
|
||||||
mkdir -p ${myfig}
|
|
||||||
$cmd > ${myfig}/best_out_all_pb_${experiments}.csv
|
|
||||||
echo ${cmd}
|
|
||||||
|
|
||||||
done
|
|
||||||
done
|
|
||||||
|
|
||||||
#---------------distribution of operators of randoma algo------------------
|
|
||||||
#rpath=${ldata}/fastga_results_random
|
|
||||||
#cmd="python3 dist_op_random.py ${rpath} ${figpath}"
|
|
||||||
#$cmd
|
|
||||||
#---------------random---------------
|
|
||||||
|
|
@ -1,16 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
ldata=$1
|
|
||||||
file_py=$2
|
|
||||||
csvdir="csv_FAO"
|
|
||||||
ldir=$(echo $(ls ${ldata}))
|
|
||||||
for data in ${ldir[@]} ; do
|
|
||||||
path="${ldata}/${data}"
|
|
||||||
cmd="python3 ${file_py} ${path}"
|
|
||||||
plan_name=$(echo ${data} | sed "s/data//")
|
|
||||||
mexp=$(echo ${data[@]} | cut -d _ -f2)
|
|
||||||
mevals=$(echo ${data[@]} | cut -d _ -f3)
|
|
||||||
ddate=$(echo ${data[@]} | cut -d _ -f4)
|
|
||||||
name="results_irace_plan${plan_name[@]:0:1}_${mexp}_${mevals}_${ddate}"
|
|
||||||
mkdir -p "${csvdir}/csv_plan${plan_name[@]:0:1}"
|
|
||||||
${cmd} > "${csvdir}/csv_plan${plan_name[@]:0:1}/${name}.csv"
|
|
||||||
done
|
|
||||||
|
|
@ -1,78 +0,0 @@
|
||||||
#!/usr/bin/env python3
|
|
||||||
import sys
|
|
||||||
import os
|
|
||||||
import numpy as np
|
|
||||||
import matplotlib.pyplot as plt
|
|
||||||
|
|
||||||
#cmd eg : python3 ./dist_op_random.py ./fastga_results_all/fastga_results_random/ ./hist_and_csv/
|
|
||||||
#get the distribution of operators variants recommended by 15 random algo for each maxEv
|
|
||||||
#pc and pm 10 possibilities : [0-0.1[ [0.1-0.2[ [0.2-0.3[ [0.3-0.4[ [0-0.5[ [0.5-0.6[ ...[0.9-1[
|
|
||||||
#pop-size and offspring-size 10 possibilities : 0-5 5-10, 10-15 15-20 20-25 25-30 30-35- 35-40 40-45 45-50
|
|
||||||
|
|
||||||
path=sys.argv[1] # directory of a result of one experiment
|
|
||||||
#eg : ./fastga_results_all/fastga_results_random/
|
|
||||||
figdir=sys.argv[2] #directory of where you want to store the data
|
|
||||||
if("random" in path):
|
|
||||||
#column : [operator : nbpossibilities]
|
|
||||||
distdir=figdir+"/distribution_random"
|
|
||||||
try:
|
|
||||||
os.makedirs(distdir)
|
|
||||||
except FileExistsError:
|
|
||||||
pass
|
|
||||||
|
|
||||||
nbparam=9 #-1 car il y a le pb
|
|
||||||
|
|
||||||
res=[]
|
|
||||||
|
|
||||||
for maxEvdir in os.listdir(path):
|
|
||||||
res.append({"crossover-rate":["pc" , np.zeros(10, dtype=int)],
|
|
||||||
"cross-selector":["SelectC", np.zeros(7, dtype=int)],
|
|
||||||
"crossover":["Crossover" , np.zeros(10, dtype=int)],
|
|
||||||
"mutation-rate":["pm",np.zeros(10, dtype=int)],
|
|
||||||
"mut-selector":["SelectM",np.zeros(10, dtype=int)],
|
|
||||||
"mutation":["Mutation", np.zeros(11, dtype=int)],
|
|
||||||
"replacement":["Replacement" , np.zeros(11, dtype=int)],
|
|
||||||
"pop-size":["pop-size", np.zeros(10, dtype=int)],
|
|
||||||
"offspring-size":["offspring-size" , np.zeros(10, dtype=int)]})
|
|
||||||
for algodir in os.listdir(os.path.join(path,maxEvdir)): #fastgadir : directory of 50 runs of an elite configuration
|
|
||||||
algo=algodir.split("_")
|
|
||||||
for param in algo:
|
|
||||||
name,val=param.split("=")[0],float(param.split("=")[1])
|
|
||||||
if(name in {"pop-size" ,"offspring-size"}):
|
|
||||||
if(val%5==0):
|
|
||||||
res[-1][name][1][int(val//5) -1]+=1
|
|
||||||
else:
|
|
||||||
#print(res[-1][name][1],val//5)
|
|
||||||
res[-1][name][1][int(val//5)]+=1
|
|
||||||
|
|
||||||
elif(name in {"crossover-rate","mutation-rate"} ):
|
|
||||||
if(int(val*10)==10): #case of val=1
|
|
||||||
res[-1][name][1][-1]+=1
|
|
||||||
else :
|
|
||||||
#print(int(float(val)*10), name,pb,val)
|
|
||||||
res[-1][name][1][int(val*10)]+=1
|
|
||||||
else :
|
|
||||||
res[-1][name][1][int(val)]+=1
|
|
||||||
|
|
||||||
|
|
||||||
ind=0
|
|
||||||
for maxEvdir in os.listdir(path):
|
|
||||||
name="distribution_random_"+maxEvdir.split("_")[0]+".csv" #the end of the path must be /
|
|
||||||
with open(os.path.join(distdir,name),"w+") as csvfile:
|
|
||||||
csvfile.write("Op index, "+",".join(map(str,range(0,11)))+"\n")
|
|
||||||
with open(os.path.join(distdir,name),"a") as csvfile:
|
|
||||||
for param_name in res[ind].keys():
|
|
||||||
#print(map(str,res[ind]),res[ind], ",".join(map(str,res[ind])))
|
|
||||||
csvfile.write(res[ind][param_name][0]+","+ ",".join(map(str,res[ind][param_name][1]))+",-"*(11-len(res[ind][param_name][1])) +"\n")
|
|
||||||
#print(str(i)+",",",".join(map(str,np.mean(aucs[i],1))))
|
|
||||||
ind+=1
|
|
||||||
#all problems
|
|
||||||
name ="distribution_all_random_"+path.split("/")[-1]+".csv"
|
|
||||||
with open(os.path.join(distdir,name),'w+') as csvfile:
|
|
||||||
csvfile.write("Op index, "+",".join(map(str,range(0,11)))+"\n")
|
|
||||||
|
|
||||||
with open(os.path.join(distdir,name),'a') as csvfile:
|
|
||||||
for param_name in res[0].keys():
|
|
||||||
#print(map(str,res[ind]),res[ind], ",".join(map(str,res[ind])))
|
|
||||||
csvfile.write(res[0][param_name][0]+","+ ",".join(map(str,np.sum([res[i][param_name][1] for i in range(ind-1)],0)))+",-"*(11-len(res[0][param_name][1])) +"\n") #res[0] only for getting the name of parameters
|
|
||||||
#print(str(i)+",",",".join(map(str,np.mean(aucs[i],1))))
|
|
||||||
|
|
@ -1,87 +0,0 @@
|
||||||
#!/usr/bin/env python3
|
|
||||||
import sys
|
|
||||||
import os
|
|
||||||
import numpy as np
|
|
||||||
import matplotlib.pyplot as plt
|
|
||||||
|
|
||||||
#get the distribution of operators variants recommended by 15 runs of irace for all problems and each problem
|
|
||||||
#also get an csv file
|
|
||||||
#pc and pm 10 possibilities : [0-0.1[ [0.1-0.2[ [0.2-0.3[ [0.3-0.4[ [0-0.5[ [0.5-0.6[ ...[0.9-1[
|
|
||||||
#pop-size and offspring-size 10 possibilities : 0-5 5-10, 10-15 15-20 20-25 25-30 30-35- 35-40 40-45 45-50
|
|
||||||
|
|
||||||
path=sys.argv[1] # directory of a result of one experiment
|
|
||||||
#eg : ./fastga_results_all/fastga_results_planO/planO_maxExp\=100000_maxEv\=5n_2021-08-13T19\:04+02\:00_results_elites_all/
|
|
||||||
|
|
||||||
if("fastga_results_plan" in path):
|
|
||||||
#column : [operator : nbpossibilities]
|
|
||||||
distdir=sys.argv[2]
|
|
||||||
try:
|
|
||||||
os.makedirs(distdir)
|
|
||||||
except FileExistsError:
|
|
||||||
pass
|
|
||||||
|
|
||||||
nbparam=(len(os.listdir(os.path.join(path,"raw/data"))[0].split("_"))-1)
|
|
||||||
|
|
||||||
if( nbparam==7):
|
|
||||||
res=[{"crossover-rate":["pc" , np.zeros(10, dtype=int)],
|
|
||||||
"cross-selector":["SelectC", np.zeros(7, dtype=int)],
|
|
||||||
"crossover":["Crossover" , np.zeros(10, dtype=int)],
|
|
||||||
"mutation-rate":["pm",np.zeros(10, dtype=int)],
|
|
||||||
"mut-selector":["SelectM",np.zeros(7, dtype=int)],
|
|
||||||
"mutation":["Mutation", np.zeros(11, dtype=int)],
|
|
||||||
"replacement":["Replacement" ,np.zeros(11, dtype=int)]} for i in range(19)]
|
|
||||||
else:
|
|
||||||
res=[{"crossover-rate":["pc" , np.zeros(10, dtype=int)],
|
|
||||||
"cross-selector":["SelectC", np.zeros(7, dtype=int)],
|
|
||||||
"crossover":["Crossover" , np.zeros(10, dtype=int)],
|
|
||||||
"mutation-rate":["pm",np.zeros(10, dtype=int)],
|
|
||||||
"mut-selector":["SelectM",np.zeros(7, dtype=int)],
|
|
||||||
"mutation":["Mutation", np.zeros(11, dtype=int)],
|
|
||||||
"replacement":["Replacement" , np.zeros(11, dtype=int)],
|
|
||||||
"pop-size":["pop-size", np.zeros(10, dtype=int)],
|
|
||||||
"offspring-size":["offspring-size" , np.zeros(10, dtype=int)]} for i in range(19)]
|
|
||||||
|
|
||||||
|
|
||||||
for fastgadir in os.listdir(os.path.join(path,"raw/data")): #fastgadir : directory of 50 runs of an elite configuration
|
|
||||||
algo=fastgadir.split("_")
|
|
||||||
pb=int(fastgadir.split("_")[0].split("=")[1])
|
|
||||||
for param in algo[1:]:
|
|
||||||
name,val=param.split("=")[0],float(param.split("=")[1])
|
|
||||||
if(name in {"pop-size" ,"offspring-size"}):
|
|
||||||
if(val%5==0):
|
|
||||||
res[pb][name][1][int(val//5) -1]+=1
|
|
||||||
else:
|
|
||||||
#print(res[pb][name][1],val//5)
|
|
||||||
res[pb][name][1][int(val//5)]+=1
|
|
||||||
|
|
||||||
elif(name in {"crossover-rate","mutation-rate"} ):
|
|
||||||
if(int(val*10)==10): #case of val=1
|
|
||||||
res[pb][name][1][-1]+=1
|
|
||||||
else :
|
|
||||||
#print(int(float(val)*10), name,pb,val)
|
|
||||||
res[pb][name][1][int(val*10)]+=1
|
|
||||||
else :
|
|
||||||
res[pb][name][1][int(val)]+=1
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
for pb in range(19):
|
|
||||||
name="distribution_pb="+str(pb)+"_"+path.split("/")[-2]+".csv" #the end of the path must be /
|
|
||||||
with open(os.path.join(distdir,name),"w+") as csvfile:
|
|
||||||
csvfile.write("Op index, "+",".join(map(str,range(0,11)))+"\n")
|
|
||||||
with open(os.path.join(distdir,name),"a") as csvfile:
|
|
||||||
for param_name in res[pb].keys():
|
|
||||||
#print(map(str,res[ind]),res[ind], ",".join(map(str,res[ind])))
|
|
||||||
csvfile.write(res[pb][param_name][0]+","+ ",".join(map(str,res[pb][param_name][1]))+",-"*(11-len(res[pb][param_name][1])) +"\n")
|
|
||||||
#print(str(i)+",",",".join(map(str,np.mean(aucs[i],1))))
|
|
||||||
|
|
||||||
#all problems
|
|
||||||
name ="distribution_all_pb_"+path.split("/")[-1]+".csv"
|
|
||||||
with open(os.path.join(path,"raw",name),'w+') as csvfile:
|
|
||||||
csvfile.write("Op index, "+",".join(map(str,range(0,11)))+"\n")
|
|
||||||
|
|
||||||
with open(os.path.join(path,"raw",name),'a') as csvfile:
|
|
||||||
for param_name in res[0].keys():
|
|
||||||
#print(map(str,res[ind]),res[ind], ",".join(map(str,res[ind])))
|
|
||||||
csvfile.write(res[0][param_name][0]+","+ ",".join(map(str,np.sum([res[i][param_name][1] for i in range(19)],0)))+",-"*(11-len(res[0][param_name][1])) +"\n") #res[0] only for getting the name of parameters
|
|
||||||
#print(str(i)+",",",".join(map(str,np.mean(aucs[i],1))))
|
|
||||||
|
|
@ -1,23 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
ldata=$1
|
|
||||||
file_sh=$2
|
|
||||||
ldir=$(echo $(ls ${ldata}))
|
|
||||||
fastga_dir="fastga_results_all"
|
|
||||||
mkdir -p /scratchbeta/${USER}/${fatga_dir}
|
|
||||||
#mkdir -p "/home/${USER}/${fastga_dir}/fastga_results_plan1"
|
|
||||||
mkdir -p "/scratchbeta/${USER}/${fastga_dir}/fastga_results_planF"
|
|
||||||
mkdir -p "/scratchbeta/${USER}/${fastga_dir}/fastga_results_planA"
|
|
||||||
mkdir -p "/scratchbeta/${USER}/${fastga_dir}/fastga_results_planO"
|
|
||||||
|
|
||||||
for data in ${ldir[@]} ; do
|
|
||||||
path_csv="${ldata}/${data}"
|
|
||||||
plan_name=$(echo ${data} | sed "s/results_irace_plan//")
|
|
||||||
mexp=$(echo ${data[@]} | cut -d _ -f4)
|
|
||||||
mexp_id=$(echo ${mexp} | cut -d = -f2)
|
|
||||||
mevals=$(echo ${data[@]} | cut -d _ -f5)
|
|
||||||
mevals_id=$(echo ${mevals} | cut -d = -f2)
|
|
||||||
path="/scratchbeta/${USER}/${fastga_dir}/fastga_results_plan${plan_name[@]:0:1}"
|
|
||||||
cmd="bash ${file_sh} ${path_csv} ${mexp_id} ${mevals_id} ${path}"
|
|
||||||
name="fastga${plan_name[@]:0:1}_${mexp}_${mevals}_$(date -Iseconds)_results_elites_all"
|
|
||||||
${cmd} &> "${path}/output${plan_name[@]:0:1}_fastga_${mexp}_${mevals}_$(date -Iseconds).txt"
|
|
||||||
done
|
|
||||||
|
|
@ -1,34 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
ldata="./fastga_results_all" #fastga_results_all
|
|
||||||
figpath="./hist_and_csv" #hist_and_csv
|
|
||||||
|
|
||||||
ldir=$(echo $(ls ${ldata})) #list of directory of each plan
|
|
||||||
for plan in ${ldir[@]} ; do #get the directory of each plan
|
|
||||||
#------------hist by budget of a Plan (O,R or F)
|
|
||||||
#path="${ldata}/${plan}"
|
|
||||||
#cmd="python3 hist_join.py ${path} ${figpath}"
|
|
||||||
#echo $cmd
|
|
||||||
#$cmd
|
|
||||||
|
|
||||||
#---------------------------hist by pb by budget---------------
|
|
||||||
path="${ldata}/${plan}"
|
|
||||||
cmd="python3 hist_by_pb_budget_plan.py ${path} ${figpath}"
|
|
||||||
echo $cmd
|
|
||||||
$cmd
|
|
||||||
done
|
|
||||||
|
|
||||||
#---------------random------------------
|
|
||||||
#rpath=${ldata}/fastga_results_random
|
|
||||||
#cmd="python3 hist_join_random.py ${rpath} ${figpath}"
|
|
||||||
#---------------random---------------
|
|
||||||
|
|
||||||
#--------------------Choose a Budget irace and a budget fastga
|
|
||||||
mexp=100000
|
|
||||||
mevals=1000
|
|
||||||
#-------------------histogram join each plan F,A,R,O and join all algorithms for the budget chosen
|
|
||||||
cmd="python3 hist_by_FARO.py ${ldata} ${figdir} ${mexp} ${mevals}"
|
|
||||||
$cmd
|
|
||||||
#-------------------histogram by pb join each plan F,A,R,O and join all algorithms for the budget chosen
|
|
||||||
cmd="python3 hist_by_FARO_pb.py ${ldata} ${figdir} ${mexp} ${mevals}"
|
|
||||||
$cmd
|
|
||||||
|
|
@ -1,71 +0,0 @@
|
||||||
#!/usr/bin/env python3
|
|
||||||
import sys
|
|
||||||
import os
|
|
||||||
import numpy as np
|
|
||||||
import matplotlib.pyplot as plt
|
|
||||||
from scipy.stats import mannwhitneyu
|
|
||||||
|
|
||||||
##python3 hist_by_FARO.py ./fastga_results_all/ ./hist_and_csv/ 100000 1000
|
|
||||||
#one plot for one experiment plan for the same budget fastga, and the same budget irace if there is a budget irace (A,F)
|
|
||||||
path=sys.argv[1]
|
|
||||||
figpath=sys.argv[2]
|
|
||||||
maxExp=sys.argv[3]
|
|
||||||
maxEv=sys.argv[4]
|
|
||||||
|
|
||||||
indF=-1
|
|
||||||
indFO=-1
|
|
||||||
averageConfigs=[]
|
|
||||||
name=[]
|
|
||||||
for fastga in os.listdir(path): #ddir : directory of fastga_plan
|
|
||||||
if(fastga in {"fastga_results_planA","fastga_results_planF","fastga_results_planO"}):
|
|
||||||
for plan in os.listdir(os.path.join(path,fastga)):
|
|
||||||
print("maxExp="+str(maxExp)+"_maxEv="+str(maxEv) in plan,plan,"maxExp="+str(maxExp)+"_maxEv="+str(maxEv))
|
|
||||||
if("maxExp="+str(maxExp)+"_maxEv="+str(maxEv) in plan):
|
|
||||||
average=[]
|
|
||||||
|
|
||||||
for fastgadir in os.listdir(os.path.join(path,fastga,plan,"raw","data")): #fastgadir : directory of 50 runs of a configuration
|
|
||||||
for fname in os.listdir(os.path.join(path,fastga,plan,"raw","data",fastgadir)):
|
|
||||||
with open(os.path.join(path,fastga,plan,"raw","data",fastgadir,fname)) as fd:
|
|
||||||
auc = float(fd.readlines()[0]) *(-1)
|
|
||||||
average.append(auc)
|
|
||||||
averageConfigs.append(average)
|
|
||||||
nameid=plan.split("_")[0][-1]
|
|
||||||
name.append("plan"+nameid+"_"+"_".join(plan.split("_")[1:3]))
|
|
||||||
if("random" in fastga):
|
|
||||||
for randir in os.listdir(os.path.join(path,fastga)):
|
|
||||||
#eg path: maxEv=100_nbAlgo=15_2021-08-20T1511+0200_results_randoms
|
|
||||||
average=[]
|
|
||||||
if("maxEv="+str(maxEv)+"_" in randir):
|
|
||||||
for ddir in os.listdir(os.path.join(path,fastga,randir)): #ddir : directory of one run_elites_all or more
|
|
||||||
if("crossover" in ddir):
|
|
||||||
#name.append("_".join(ddir.split("_")[1:3]))
|
|
||||||
for fastgadir in os.listdir(os.path.join(path,fastga,randir,ddir,"data")): #fastgadir : directory of 50 runs of a configuration
|
|
||||||
for fname in os.listdir(os.path.join(path,fastga,randir,ddir,"data",fastgadir)):
|
|
||||||
with open(os.path.join(path,fastga,randir,ddir,"data",fastgadir,fname)) as fd:
|
|
||||||
auc = float(fd.readlines()[0]) *(-1)
|
|
||||||
average.append(auc)
|
|
||||||
#hist[belonging(auc,cum)]+=1
|
|
||||||
averageConfigs.append(average)
|
|
||||||
name.append(randir.split("_")[0]+"_random")
|
|
||||||
|
|
||||||
|
|
||||||
figdir=os.path.join(figpath,"hist_FARO_by_budget")
|
|
||||||
try:
|
|
||||||
os.makedirs(figdir)
|
|
||||||
except FileExistsError:
|
|
||||||
pass
|
|
||||||
|
|
||||||
#_,pv=mannwhitneyu(averageConfigs[indFO],averageConfigs[indF])
|
|
||||||
#print(name,len(averageConfigs))
|
|
||||||
plt.figure()
|
|
||||||
plt.hist(averageConfigs,bins=10,range=(0,1),align="mid",rwidth=0.9,label=name) #no label
|
|
||||||
plt.xlabel("performances")
|
|
||||||
plt.ylabel("Number of runs")
|
|
||||||
plt.xlim(0,1)
|
|
||||||
plt.ylim(0,8000)
|
|
||||||
plt.yticks(range(0,8000,500))
|
|
||||||
#plt.title("pvalue="+str(pv)+"\n medianeF="+str(np.median(averageConfigs[indF]))+", medianeFO="+str(np.median(averageConfigs[indFO])))
|
|
||||||
plt.legend()
|
|
||||||
plt.savefig(figdir+"/hist_planFARO"+"_maxExp="+str(maxExp)+"_maxEv="+str(maxEv)+".png")
|
|
||||||
plt.close()
|
|
||||||
|
|
||||||
|
|
@ -1,88 +0,0 @@
|
||||||
#!/usr/bin/env python3
|
|
||||||
import sys
|
|
||||||
import os
|
|
||||||
import numpy as np
|
|
||||||
import matplotlib.pyplot as plt
|
|
||||||
|
|
||||||
##python3 hist_by_FARO_pb.py ./fastga_results_all/ ./hist_and_csv/ 100000 1000
|
|
||||||
#19 histograms by plan F,A ,R O
|
|
||||||
path=sys.argv[1]
|
|
||||||
figpath=sys.argv[2]
|
|
||||||
maxExp=sys.argv[3]
|
|
||||||
maxEv=sys.argv[4]
|
|
||||||
|
|
||||||
hist_pb=[[] for i in range(19)]
|
|
||||||
name=[]
|
|
||||||
for fastga in os.listdir(path): #ddir : directory of fastga_plan
|
|
||||||
if(fastga in {"fastga_results_planA", "fastga_results_planF","fastga_results_planO"}):
|
|
||||||
for plan in os.listdir(os.path.join(path,fastga)):
|
|
||||||
#print("maxExp="+str(maxExp)+"_maxEv="+str(maxEv)+"_" in plan,plan,"maxExp="+str(maxExp)+"_maxEv="+str(maxEv))
|
|
||||||
#print("maxExp="+str(maxExp)+"_maxEv="+str(maxEv) in plan,plan,"maxExp="+str(maxExp)+"_maxEv="+str(maxEv))
|
|
||||||
if("maxExp="+str(maxExp)+"_maxEv="+str(maxEv)+"_" in plan):
|
|
||||||
nameid=fastga[-1]
|
|
||||||
name.append("plan"+nameid+"_".join(plan.split("_")[1:3]))
|
|
||||||
for fastgadir in os.listdir(os.path.join(path,fastga,plan,"raw","data")): #fastgadir : directory of 50 runs of a configuration
|
|
||||||
pb=int(fastgadir.split("_")[0].split("=")[1])
|
|
||||||
average_pb=[]
|
|
||||||
for fname in os.listdir(os.path.join(path,fastga,plan,"raw","data",fastgadir)):
|
|
||||||
with open(os.path.join(path,fastga,plan,"raw","data",fastgadir,fname)) as fd:
|
|
||||||
auc = float(fd.readlines()[0]) *(-1)
|
|
||||||
average_pb.append(auc)
|
|
||||||
if(hist_pb[pb]==[]): #first algo
|
|
||||||
hist_pb[pb].append(average_pb)
|
|
||||||
elif(len(hist_pb[pb])!=len(name)):
|
|
||||||
hist_pb[pb].append(average_pb)
|
|
||||||
else:
|
|
||||||
hist_pb[pb][len(name)-1]+=average_pb #another algo for the same plan
|
|
||||||
|
|
||||||
if("random" in fastga):
|
|
||||||
for randir in os.listdir(os.path.join(path,fastga)):
|
|
||||||
#eg path: maxEv=100_nbAlgo=15_2021-08-20T1511+0200_results_randoms
|
|
||||||
if(("maxEv="+str(maxEv)+"_") in randir):
|
|
||||||
#print("maxEv="+str(maxEv) in randir,randir)
|
|
||||||
name.append(randir.split("_")[0]+"_random")
|
|
||||||
for ddir in os.listdir(os.path.join(path,fastga,randir)): #ddir : directory of one run_elites_all or more
|
|
||||||
if("crossover" in ddir):
|
|
||||||
#name.append("_".join(ddir.split("_")[1:3]))
|
|
||||||
for fastgadir in os.listdir(os.path.join(path,fastga,randir,ddir,"data")): #fastgadir : directory of 50 runs of a configuration
|
|
||||||
average_pb=[]
|
|
||||||
pb=int(fastgadir.split("_")[0].split("=")[1])
|
|
||||||
for fname in os.listdir(os.path.join(path,fastga,randir,ddir,"data",fastgadir)):
|
|
||||||
with open(os.path.join(path,fastga,randir,ddir,"data",fastgadir,fname)) as fd:
|
|
||||||
auc = float(fd.readlines()[0]) *(-1)
|
|
||||||
average_pb.append(auc)
|
|
||||||
#print(len(hist_pb[pb]),len(name), pb)
|
|
||||||
if(hist_pb[pb]==[]): #first algo
|
|
||||||
#print("entrer random vide")
|
|
||||||
hist_pb[pb].append(average_pb)
|
|
||||||
elif(len(hist_pb[pb])!=len(name)):
|
|
||||||
#print("entrer random !=")
|
|
||||||
hist_pb[pb].append(average_pb)
|
|
||||||
else:
|
|
||||||
hist_pb[pb][len(name)-1]+=average_pb #another algo for the same plan
|
|
||||||
|
|
||||||
|
|
||||||
figdir=os.path.join(figpath,"hist_by_FARO_pb_maxExp={}_maxEv={}".format(maxExp,maxEv))
|
|
||||||
try:
|
|
||||||
os.makedirs(figdir)
|
|
||||||
except FileExistsError:
|
|
||||||
pass
|
|
||||||
#colors=['yellow', 'green',"blue","pink","purple","orange","magenta","gray","darkred","cyan","brown","olivedrab","thistle","stateblue"]
|
|
||||||
print(name)
|
|
||||||
for pb in range(19):
|
|
||||||
print(pb, len(hist_pb[pb]))
|
|
||||||
for i in hist_pb[pb]:
|
|
||||||
print(len(i))
|
|
||||||
plt.figure()
|
|
||||||
plt.hist(hist_pb[pb],bins=10,range=(0,1),align="mid",rwidth=0.9,edgecolor="red",label=name) #no label color=colors[:len(name)]
|
|
||||||
#for aucs in range(len(hist_pb[pb])):
|
|
||||||
#plt.hist(hist_pb[pb][aucs],bins=10,range=(0,1),align="mid",rwidth=0.9,edgecolor="red",label=name[aucs]) #no label
|
|
||||||
plt.xlabel("performances")
|
|
||||||
plt.ylabel("Number of runs")
|
|
||||||
plt.ylim(0,800)
|
|
||||||
plt.xlim(0,1)
|
|
||||||
plt.yticks(range(0,800,50))
|
|
||||||
#plt.xticks(np.cumsum([0.1]*10))
|
|
||||||
plt.legend()
|
|
||||||
plt.savefig(figdir+"/hist_FARO_pb={}_maxExp={}_maxEv={}.png".format(pb,maxExp,maxEv))
|
|
||||||
plt.close()
|
|
||||||
|
|
@ -1,90 +0,0 @@
|
||||||
#!/usr/bin/env python3
|
|
||||||
import sys
|
|
||||||
import os
|
|
||||||
import numpy as np
|
|
||||||
import matplotlib.pyplot as plt
|
|
||||||
|
|
||||||
# python3 hist_by_pb_budget_plan.py ./fastga_results_all/fastga_results_planF/ ./hist_and_csv/
|
|
||||||
#python3 hist_by_pb_budget_plan.py ./fastga_results_all/fastga_results_planO ./hist_and_csv
|
|
||||||
#get 19 histograms with number of budget bars, same as hist_join but now is by pb
|
|
||||||
|
|
||||||
#argv : list of elite results
|
|
||||||
path=sys.argv[1]
|
|
||||||
figpath=sys.argv[2]
|
|
||||||
#plan_name=sys.argv[3]
|
|
||||||
hist_pb=[[] for i in range(19)]
|
|
||||||
name=[]
|
|
||||||
if("random" in path):
|
|
||||||
plan_name="R"
|
|
||||||
else:
|
|
||||||
plan_name=path.strip("/").split("/")[-1][-1]
|
|
||||||
|
|
||||||
|
|
||||||
for plandir in os.listdir(path): #plandir: directory of an experiment of elite results
|
|
||||||
if("results_elites_all" in plandir):
|
|
||||||
#eg : plan2_maxExp=10000_maxEv=1000_2021-08-20T1347+0200_results_elites_all
|
|
||||||
budget_irace=plandir.split("_")[1].split("=")[1]
|
|
||||||
budget_fastga=plandir.split("_")[2].split("=")[1]
|
|
||||||
name.append("plan="+plan_name+"_"+"".join(plandir.split("_")[1:3])) #plan=*_maxExp=*_maxEv=*
|
|
||||||
|
|
||||||
for algodir in os.listdir(os.path.join(path,plandir,"raw","data")):
|
|
||||||
average_pb=[]
|
|
||||||
pb=int(algodir.split("_")[0].split("=")[1])
|
|
||||||
for algo in os.listdir(os.path.join(path,plandir,"raw","data",algodir)):
|
|
||||||
with open(os.path.join(path,plandir,"raw","data",algodir,algo)) as fd:
|
|
||||||
auc = float(fd.readlines()[0]) *(-1)
|
|
||||||
average_pb.append(auc)
|
|
||||||
if(hist_pb[pb]==[]): #first algo
|
|
||||||
hist_pb[pb].append(average_pb)
|
|
||||||
elif(len(hist_pb[pb])!=len(name)):
|
|
||||||
hist_pb[pb].append(average_pb)
|
|
||||||
else:
|
|
||||||
hist_pb[pb][len(name)-1]+=average_pb #another algo for the same plan
|
|
||||||
|
|
||||||
if("results_randoms" in plandir):
|
|
||||||
#eg : maxEv=1000_2021-08-20T1347+0200_results_random
|
|
||||||
budget_fastga=plandir.split("_")[0].split("=")[1]
|
|
||||||
name.append("plan="+plan_name+"_"+"".join(plandir.split("_")[0])) #plan=*_maxExp=*_maxEv=*
|
|
||||||
for algodir in os.listdir(os.path.join(path,plandir)):
|
|
||||||
|
|
||||||
for algo in os.listdir(os.path.join(path,plandir,algodir,"data")):
|
|
||||||
pb=int(algo.split("_")[0].split("=")[1])
|
|
||||||
average_pb=[]
|
|
||||||
for fname in os.listdir(os.path.join(path,plandir,algodir,"data",algo)):
|
|
||||||
with open(os.path.join(path,plandir,algodir,"data",algo,fname)) as fd:
|
|
||||||
auc = float(fd.readlines()[0]) *(-1)
|
|
||||||
average_pb.append(auc)
|
|
||||||
if(hist_pb[pb]==[]): #first algo
|
|
||||||
print("entrer")
|
|
||||||
hist_pb[pb].append(average_pb)
|
|
||||||
elif(len(hist_pb[pb])!=len(name)):
|
|
||||||
hist_pb[pb].append(average_pb)
|
|
||||||
else:
|
|
||||||
hist_pb[pb][len(name)-1]+=average_pb #another algo for the same plan
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
print(path.split("/")[-1][-1])
|
|
||||||
|
|
||||||
figdir=os.path.join(figpath,"hist_by_{}_pb_budget_plan".format(plan_name))
|
|
||||||
#figdir=os.path.join(figpath,"hist_by_{}_pb_irace_maxEv={}".format(plan_name,1000))
|
|
||||||
try:
|
|
||||||
os.makedirs(figdir)
|
|
||||||
except FileExistsError:
|
|
||||||
pass
|
|
||||||
|
|
||||||
|
|
||||||
for pb in range(19):
|
|
||||||
print(pb, len(hist_pb[pb]))
|
|
||||||
plt.figure()
|
|
||||||
plt.hist(hist_pb[pb],bins=10,range=(0,1),align="mid",rwidth=0.9,edgecolor="red",label=name) #no label color=colors[:len(name)]
|
|
||||||
#for aucs in range(len(hist_pb[pb])):
|
|
||||||
#plt.hist(hist_pb[pb][aucs],bins=10,range=(0,1),align="mid",rwidth=0.9,edgecolor="red",label=name[aucs]) #no label
|
|
||||||
plt.xlabel("performances")
|
|
||||||
plt.ylabel("Number of runs")
|
|
||||||
plt.ylim(0,750)
|
|
||||||
plt.yticks(range(0,750,50))
|
|
||||||
plt.xlim(0,1)
|
|
||||||
plt.legend()
|
|
||||||
plt.savefig(figdir+"/hist_plan={}_pb={}_budget.png".format(plan_name,pb))
|
|
||||||
plt.close()
|
|
||||||
|
|
@ -1,68 +0,0 @@
|
||||||
#!/usr/bin/env python3
|
|
||||||
import sys
|
|
||||||
import os
|
|
||||||
import numpy as np
|
|
||||||
import matplotlib.pyplot as plt
|
|
||||||
from scipy.stats import mannwhitneyu
|
|
||||||
|
|
||||||
#cmd : python3 hist_join.py ./fastga_results_all/fastga_results_planO/ ./hist_and_csv/
|
|
||||||
#histogram by plan for the budgets (irace and fastag)
|
|
||||||
|
|
||||||
|
|
||||||
path=sys.argv[1] #argv : directory of a Plan (O, A, F)
|
|
||||||
figpath=sys.argv[2] #path to store the histograms
|
|
||||||
averageConfigs=[]
|
|
||||||
name=[]
|
|
||||||
if("fastga_results_plan" in path):
|
|
||||||
for ddir in os.listdir(path): #ddir : directory of one run_elites_all or more
|
|
||||||
if("plan" in ddir):
|
|
||||||
average=[]
|
|
||||||
name.append("_".join(ddir.split("_")[1:3]))
|
|
||||||
for fastgadir in os.listdir(os.path.join(path,ddir,"raw","data")): #fastgadir : directory of 50 runs of a configuration
|
|
||||||
for fname in os.listdir(os.path.join(path,ddir,"raw","data",fastgadir)):
|
|
||||||
with open(os.path.join(path,ddir,"raw","data",fastgadir,fname)) as fd:
|
|
||||||
auc = float(fd.readlines()[0]) *(-1)
|
|
||||||
average.append(auc)
|
|
||||||
#hist[belonging(auc,cum)]+=1
|
|
||||||
averageConfigs.append(average)
|
|
||||||
#print(hist)
|
|
||||||
#print(average)
|
|
||||||
|
|
||||||
figdir=os.path.join(figpath,"hist_join")
|
|
||||||
try:
|
|
||||||
os.makedirs(figdir)
|
|
||||||
except FileExistsError:
|
|
||||||
pass
|
|
||||||
|
|
||||||
|
|
||||||
print(name,len(averageConfigs))
|
|
||||||
|
|
||||||
"""
|
|
||||||
idd0=name[0].split("_")[0].split("=")[1][:-3]+"k"
|
|
||||||
idd1=name[1].split("_")[0].split("=")[1][:-3]+"k"
|
|
||||||
idd2=name[2].split("_")[0].split("=")[1][:-3]+"k"
|
|
||||||
|
|
||||||
#only for Budget irace 10000, 50000, 100000 ie: only three experiment results
|
|
||||||
titlename="median"+idd0+"={:.3f}".format(np.median(averageConfigs[0]))+" , median"+idd1+"={:.3f}".format(np.median(averageConfigs[1]))+" , median"+idd2+"={:.3f}".format(np.median(averageConfigs[2]))
|
|
||||||
_,pv=mannwhitneyu(averageConfigs[0],averageConfigs[1])
|
|
||||||
titlename+="\n pvalue{}={:.3f}".format(idd0+idd1,pv)
|
|
||||||
_,pv=mannwhitneyu(averageConfigs[0],averageConfigs[2])
|
|
||||||
titlename+=" ,pvalue{}={:.3f}".format(idd0+idd2,pv)
|
|
||||||
_,pv=mannwhitneyu(averageConfigs[1],averageConfigs[2])
|
|
||||||
titlename+=" ,pvalue{}={:.3f}".format(idd1+idd2,pv)
|
|
||||||
print(titlename)
|
|
||||||
"""
|
|
||||||
plt.figure()
|
|
||||||
plt.hist(averageConfigs,bins=10,range=(0,1),align="mid",rwidth=0.9,label=name) #no label
|
|
||||||
plt.xlabel("performances")
|
|
||||||
plt.ylabel("Number of runs")
|
|
||||||
plt.xlim(0,1)
|
|
||||||
plt.ylim(0,7000)
|
|
||||||
plt.yticks(range(0,7000,500))
|
|
||||||
#plt.title(titlename)
|
|
||||||
plt.legend()
|
|
||||||
plt.savefig(figdir+"/hist_plan"+path.strip("/")[-1]+"_by_budget.png")
|
|
||||||
#plt.savefig(figpath+"/hist_plan"+path.strip("/")[-1]+"_by_budgetI.png")
|
|
||||||
plt.close()
|
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -1,46 +0,0 @@
|
||||||
#!/usr/bin/env python3
|
|
||||||
import sys
|
|
||||||
import os
|
|
||||||
import numpy as np
|
|
||||||
import matplotlib.pyplot as plt
|
|
||||||
|
|
||||||
##python3 hist_random.py ./dastga_results_all/fastga_results_random ./hist_and_csv/
|
|
||||||
#argv : list of elite results
|
|
||||||
data=sys.argv[1]
|
|
||||||
figpath=sys.argv[2]
|
|
||||||
averageConfigs=[]
|
|
||||||
name=[]
|
|
||||||
for path in os.listdir(data):
|
|
||||||
#eg path: maxEv=100_nbAlgo=15_2021-08-20T1511+0200_results_randoms
|
|
||||||
average=[]
|
|
||||||
if("maxEv" in path):
|
|
||||||
for ddir in os.listdir(os.path.join(data,path)): #ddir : directory of one run_elites_all or more
|
|
||||||
if("crossover" in ddir):
|
|
||||||
#name.append("_".join(ddir.split("_")[1:3]))
|
|
||||||
for fastgadir in os.listdir(os.path.join(data,path,ddir,"data")): #fastgadir : directory of 50 runs of a configuration
|
|
||||||
for fname in os.listdir(os.path.join(data,path,ddir,"data",fastgadir)):
|
|
||||||
with open(os.path.join(data,path,ddir,"data",fastgadir,fname)) as fd:
|
|
||||||
auc = float(fd.readlines()[0]) *(-1)
|
|
||||||
average.append(auc)
|
|
||||||
#hist[belonging(auc,cum)]+=1
|
|
||||||
averageConfigs.append(average)
|
|
||||||
name.append(path.split("_")[0])
|
|
||||||
|
|
||||||
figdir=os.path.join(figpath,"hist_join")
|
|
||||||
try:
|
|
||||||
os.makedirs(figdir)
|
|
||||||
except FileExistsError:
|
|
||||||
pass
|
|
||||||
|
|
||||||
colors=['yellow', 'green',"blue","pink","purple","orange","magenta","gray","darkred","cyan","brown","olivedrab","thistle","stateblue"]
|
|
||||||
plt.figure()
|
|
||||||
plt.hist(averageConfigs,bins=10,range=(0,1),align="mid",rwidth=0.5,label=name) #no label
|
|
||||||
plt.xlabel("performances")
|
|
||||||
plt.ylabel("Number of runs")
|
|
||||||
plt.ylim([0,8000])
|
|
||||||
plt.xlim(0,1)
|
|
||||||
plt.yticks(range(0,8000,500))
|
|
||||||
#plt.xticks(np.cumsum([0.1]*10))
|
|
||||||
plt.legend()
|
|
||||||
plt.savefig(figdir+"/hist_random_by_budget.png")
|
|
||||||
plt.close()
|
|
||||||
|
|
@ -1,27 +0,0 @@
|
||||||
## This is an example of specifying instances with a file.
|
|
||||||
|
|
||||||
# Each line is an instance relative to trainInstancesDir
|
|
||||||
# (see scenario.txt.tmpl) and an optional sequence of instance-specific
|
|
||||||
# parameters that will be passed to target-runnerx when invoked on that
|
|
||||||
# instance.
|
|
||||||
|
|
||||||
0
|
|
||||||
1
|
|
||||||
2
|
|
||||||
3
|
|
||||||
4
|
|
||||||
5
|
|
||||||
6
|
|
||||||
7
|
|
||||||
8
|
|
||||||
9
|
|
||||||
10
|
|
||||||
11
|
|
||||||
12
|
|
||||||
13
|
|
||||||
14
|
|
||||||
15
|
|
||||||
16
|
|
||||||
17
|
|
||||||
18
|
|
||||||
|
|
||||||
|
|
@ -1,227 +0,0 @@
|
||||||
###################################################### -*- mode: r -*- #####
|
|
||||||
## Scenario setup for Iterated Race (irace).
|
|
||||||
############################################################################
|
|
||||||
|
|
||||||
## To use the default value of a parameter of iRace, simply do not set
|
|
||||||
## the parameter (comment it out in this file, and do not give any
|
|
||||||
## value on the command line).
|
|
||||||
|
|
||||||
## File that contains the description of the parameters of the target
|
|
||||||
## algorithm.
|
|
||||||
parameterFile = "./fastga.param"
|
|
||||||
|
|
||||||
## Directory where the programs will be run.
|
|
||||||
execDir = "."
|
|
||||||
|
|
||||||
## File to save tuning results as an R dataset, either absolute path or
|
|
||||||
## relative to execDir.
|
|
||||||
# logFile = "./irace.Rdata"
|
|
||||||
|
|
||||||
## Previously saved log file to recover the execution of irace, either
|
|
||||||
## absolute path or relative to the current directory. If empty or NULL,
|
|
||||||
## recovery is not performed.
|
|
||||||
# recoveryFile = ""
|
|
||||||
|
|
||||||
## Directory where training instances are located; either absolute path or
|
|
||||||
## relative to current directory. If no trainInstancesFiles is provided,
|
|
||||||
## all the files in trainInstancesDir will be listed as instances.
|
|
||||||
trainInstancesDir = "."
|
|
||||||
|
|
||||||
## File that contains a list of training instances and optionally
|
|
||||||
## additional parameters for them. If trainInstancesDir is provided, irace
|
|
||||||
## will search for the files in this folder.
|
|
||||||
trainInstancesFile = "./default.instances"
|
|
||||||
|
|
||||||
## File that contains a table of initial configurations. If empty or NULL,
|
|
||||||
## all initial configurations are randomly generated.
|
|
||||||
# configurationsFile = ""
|
|
||||||
|
|
||||||
## File that contains a list of logical expressions that cannot be TRUE
|
|
||||||
## for any evaluated configuration. If empty or NULL, do not use forbidden
|
|
||||||
## expressions.
|
|
||||||
forbiddenFile = "./forbidden.txt"
|
|
||||||
|
|
||||||
## Script called for each configuration that executes the target algorithm
|
|
||||||
## to be tuned. See templates.
|
|
||||||
targetRunner = "./target-runner"
|
|
||||||
|
|
||||||
## Number of times to retry a call to targetRunner if the call failed.
|
|
||||||
# targetRunnerRetries = 0
|
|
||||||
|
|
||||||
## Optional data passed to targetRunner. This is ignored by the default
|
|
||||||
## targetRunner function, but it may be used by custom targetRunner
|
|
||||||
## functions to pass persistent data around.
|
|
||||||
# targetRunnerData = ""
|
|
||||||
|
|
||||||
## Optional R function to provide custom parallelization of targetRunner.
|
|
||||||
# targetRunnerParallel = ""
|
|
||||||
|
|
||||||
## Optional script or R function that provides a numeric value for each
|
|
||||||
## configuration. See templates/target-evaluator.tmpl
|
|
||||||
# targetEvaluator = ""
|
|
||||||
|
|
||||||
## Maximum number of runs (invocations of targetRunner) that will be
|
|
||||||
## performed. It determines the maximum budget of experiments for the
|
|
||||||
## tuning.
|
|
||||||
maxExperiments = 0 #100000
|
|
||||||
|
|
||||||
## Maximum total execution time in seconds for the executions of
|
|
||||||
## targetRunner. targetRunner must return two values: cost and time.
|
|
||||||
# maxTime = 60
|
|
||||||
|
|
||||||
## Fraction (smaller than 1) of the budget used to estimate the mean
|
|
||||||
## computation time of a configuration. Only used when maxTime > 0
|
|
||||||
# budgetEstimation = 0.02
|
|
||||||
|
|
||||||
## Maximum number of decimal places that are significant for numerical
|
|
||||||
## (real) parameters.
|
|
||||||
digits = 2
|
|
||||||
|
|
||||||
## Debug level of the output of irace. Set this to 0 to silence all debug
|
|
||||||
## messages. Higher values provide more verbose debug messages.
|
|
||||||
# debugLevel = 0
|
|
||||||
|
|
||||||
## Number of iterations.
|
|
||||||
# nbIterations = 0
|
|
||||||
|
|
||||||
## Number of runs of the target algorithm per iteration.
|
|
||||||
# nbExperimentsPerIteration = 0
|
|
||||||
|
|
||||||
## Randomly sample the training instances or use them in the order given.
|
|
||||||
# sampleInstances = 1
|
|
||||||
|
|
||||||
## Statistical test used for elimination. Default test is always F-test
|
|
||||||
## unless capping is enabled, in which case the default test is t-test.
|
|
||||||
## Valid values are: F-test (Friedman test), t-test (pairwise t-tests with
|
|
||||||
## no correction), t-test-bonferroni (t-test with Bonferroni's correction
|
|
||||||
## for multiple comparisons), t-test-holm (t-test with Holm's correction
|
|
||||||
## for multiple comparisons).
|
|
||||||
# testType = "F-test"
|
|
||||||
|
|
||||||
## Number of instances evaluated before the first elimination test. It
|
|
||||||
## must be a multiple of eachTest.
|
|
||||||
# firstTest = 5
|
|
||||||
|
|
||||||
## Number of instances evaluated between elimination tests.
|
|
||||||
# eachTest = 1
|
|
||||||
|
|
||||||
## Minimum number of configurations needed to continue the execution of
|
|
||||||
## each race (iteration).
|
|
||||||
# minNbSurvival = 0
|
|
||||||
|
|
||||||
## Number of configurations to be sampled and evaluated at each iteration.
|
|
||||||
# nbConfigurations = 0
|
|
||||||
|
|
||||||
## Parameter used to define the number of configurations sampled and
|
|
||||||
## evaluated at each iteration.
|
|
||||||
# mu = 5
|
|
||||||
|
|
||||||
## Confidence level for the elimination test.
|
|
||||||
# confidence = 0.95
|
|
||||||
|
|
||||||
## If the target algorithm is deterministic, configurations will be
|
|
||||||
## evaluated only once per instance.
|
|
||||||
# deterministic = 0
|
|
||||||
|
|
||||||
## Seed of the random number generator (by default, generate a random
|
|
||||||
## seed).
|
|
||||||
# seed = NA
|
|
||||||
|
|
||||||
## Number of calls to targetRunner to execute in parallel. Values 0 or 1
|
|
||||||
## mean no parallelization.
|
|
||||||
# parallel = 0
|
|
||||||
|
|
||||||
## Enable/disable load-balancing when executing experiments in parallel.
|
|
||||||
## Load-balancing makes better use of computing resources, but increases
|
|
||||||
## communication overhead. If this overhead is large, disabling
|
|
||||||
## load-balancing may be faster.
|
|
||||||
# loadBalancing = 1
|
|
||||||
|
|
||||||
## Enable/disable MPI. Use Rmpi to execute targetRunner in parallel
|
|
||||||
## (parameter parallel is the number of slaves).
|
|
||||||
# mpi = 0
|
|
||||||
|
|
||||||
## Specify how irace waits for jobs to finish when targetRunner submits
|
|
||||||
## jobs to a batch cluster: sge, pbs, torque or slurm. targetRunner must
|
|
||||||
## submit jobs to the cluster using, for example, qsub.
|
|
||||||
# batchmode = 0
|
|
||||||
|
|
||||||
## Enable/disable the soft restart strategy that avoids premature
|
|
||||||
## convergence of the probabilistic model.
|
|
||||||
# softRestart = 1
|
|
||||||
|
|
||||||
## Soft restart threshold value for numerical parameters. If NA, NULL or
|
|
||||||
## "", it is computed as 10^-digits.
|
|
||||||
# softRestartThreshold = ""
|
|
||||||
|
|
||||||
## Directory where testing instances are located, either absolute or
|
|
||||||
## relative to current directory.
|
|
||||||
# testInstancesDir = ""
|
|
||||||
|
|
||||||
## File containing a list of test instances and optionally additional
|
|
||||||
## parameters for them.
|
|
||||||
# testInstancesFile = ""
|
|
||||||
|
|
||||||
## Number of elite configurations returned by irace that will be tested if
|
|
||||||
## test instances are provided.
|
|
||||||
# testNbElites = 1
|
|
||||||
|
|
||||||
## Enable/disable testing the elite configurations found at each
|
|
||||||
## iteration.
|
|
||||||
# testIterationElites = 0
|
|
||||||
|
|
||||||
## Enable/disable elitist irace.
|
|
||||||
# elitist = 1
|
|
||||||
|
|
||||||
## Number of instances added to the execution list before previous
|
|
||||||
## instances in elitist irace.
|
|
||||||
# elitistNewInstances = 1
|
|
||||||
|
|
||||||
## In elitist irace, maximum number per race of elimination tests that do
|
|
||||||
## not eliminate a configuration. Use 0 for no limit.
|
|
||||||
# elitistLimit = 2
|
|
||||||
|
|
||||||
## User-defined R function that takes a configuration generated by irace
|
|
||||||
## and repairs it.
|
|
||||||
# repairConfiguration = ""
|
|
||||||
|
|
||||||
## Enable the use of adaptive capping, a technique designed for minimizing
|
|
||||||
## the computation time of configurations. This is only available when
|
|
||||||
## elitist is active.
|
|
||||||
# capping = 0
|
|
||||||
|
|
||||||
## Measure used to obtain the execution bound from the performance of the
|
|
||||||
## elite configurations: median, mean, worst, best.
|
|
||||||
# cappingType = "median"
|
|
||||||
|
|
||||||
## Method to calculate the mean performance of elite configurations:
|
|
||||||
## candidate or instance.
|
|
||||||
# boundType = "candidate"
|
|
||||||
|
|
||||||
## Maximum execution bound for targetRunner. It must be specified when
|
|
||||||
## capping is enabled.
|
|
||||||
# boundMax = 0
|
|
||||||
|
|
||||||
## Precision used for calculating the execution time. It must be specified
|
|
||||||
## when capping is enabled.
|
|
||||||
# boundDigits = 0
|
|
||||||
|
|
||||||
## Penalization constant for timed out executions (executions that reach
|
|
||||||
## boundMax execution time).
|
|
||||||
# boundPar = 1
|
|
||||||
|
|
||||||
## Replace the configuration cost of bounded executions with boundMax.
|
|
||||||
# boundAsTimeout = 1
|
|
||||||
|
|
||||||
## Percentage of the configuration budget used to perform a postselection
|
|
||||||
## race of the best configurations of each iteration after the execution
|
|
||||||
## of irace.
|
|
||||||
# postselection = 0
|
|
||||||
|
|
||||||
## Enable/disable AClib mode. This option enables compatibility with
|
|
||||||
## GenericWrapper4AC as targetRunner script.
|
|
||||||
# aclib = 0
|
|
||||||
|
|
||||||
## END of scenario file
|
|
||||||
############################################################################
|
|
||||||
|
|
||||||
|
|
@ -1,12 +0,0 @@
|
||||||
# name switch type range
|
|
||||||
# continuator "--continuator=" c (0)
|
|
||||||
crossoverrate "--crossover-rate=" r (0,1)
|
|
||||||
crossselector "--cross-selector=" c (0,1,2,3,4,5,6)
|
|
||||||
# aftercrossselector "--aftercross-selector=" c (0)
|
|
||||||
crossover "--crossover=" c (0,1,2,3,4,5,6,7,8,9)
|
|
||||||
mutationrate "--mutation-rate=" r (0,1)
|
|
||||||
mutselector "--mut-selector=" c (0,1,2,3,4,5,6)
|
|
||||||
mutation "--mutation=" c (0,1,2,3,4,5,6,7,8,9,10)
|
|
||||||
replacement "--replacement=" c (0,1,2,3,4,5,6,7,8,9,10)
|
|
||||||
popsize "--pop-size=" i (1,50)
|
|
||||||
offspringsize "--offspring-size=" i (1,50)
|
|
||||||
|
|
@ -1,13 +0,0 @@
|
||||||
## Template for specifying forbidden parameter configurations in irace.
|
|
||||||
##
|
|
||||||
## This filename must be specified via the --forbidden-file command-line option
|
|
||||||
## (or forbiddenFile in scenario.txt).
|
|
||||||
##
|
|
||||||
## The format is one constraint per line. Each constraint is a logical
|
|
||||||
## expression (in R syntax). If a parameter configuration
|
|
||||||
## is generated that makes the logical expression evaluate to TRUE,
|
|
||||||
## then the configuration is discarded.
|
|
||||||
##
|
|
||||||
## Examples of valid logical operators are: == != >= <= > < & | ! %in%
|
|
||||||
(replacement %in% c(2,3,4,5,6,7,8,9,10)) & (offspringsize > popsize)
|
|
||||||
(replacement %in% c(1)) & (offspringsize < popsize)
|
|
||||||
|
|
@ -1,89 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
###############################################################################
|
|
||||||
# This script is the command that is executed every run.
|
|
||||||
# Check the examples in examples/
|
|
||||||
#
|
|
||||||
# This script is run in the execution directory (execDir, --exec-dir).
|
|
||||||
#
|
|
||||||
# PARAMETERS:
|
|
||||||
# $1 is the candidate configuration number
|
|
||||||
# $2 is the instance ID
|
|
||||||
# $3 is the seed
|
|
||||||
# $4 is the instance name
|
|
||||||
# The rest ($* after `shift 4') are parameters to the run
|
|
||||||
#
|
|
||||||
# RETURN VALUE:
|
|
||||||
# This script should print one numerical value: the cost that must be minimized.
|
|
||||||
# Exit with 0 if no error, with 1 in case of error
|
|
||||||
###############################################################################
|
|
||||||
error() {
|
|
||||||
echo "`TZ=UTC date`: $0: error: $@"
|
|
||||||
exit 1
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
EXE="./fastga"
|
|
||||||
LOG_DIR="irace_logs"
|
|
||||||
|
|
||||||
#FIXED_PARAMS="--problem=0"
|
|
||||||
#
|
|
||||||
CONFIG_ID=$1
|
|
||||||
INSTANCE_ID=$2
|
|
||||||
SEED=$3
|
|
||||||
INSTANCE=$(echo $4 | sed 's/\//\n/g'|tail -n 1)
|
|
||||||
CROSSOVER_RATE=$5
|
|
||||||
CROSSOVER_SELECTOR=$6
|
|
||||||
CROSSOVER=$7
|
|
||||||
MUTATION_RATE=$8
|
|
||||||
MUT_SELECTOR=$9
|
|
||||||
MUTATION=${10}
|
|
||||||
REPLACEMENT=${11}
|
|
||||||
POPSIZE=${12}
|
|
||||||
OFFSPRINGSIZE=${13}
|
|
||||||
shift 13 || error "Not enough parameters"
|
|
||||||
|
|
||||||
INSTANCE_PARAMS=$*
|
|
||||||
buckets=0
|
|
||||||
# STDOUT=${LOG_DIR}/c${CONFIG_ID}_i${INSTANCE_ID}_s${SEED}.stdout
|
|
||||||
# STDERR=${LOG_DIR}/c${CONFIG_ID}_i${INSTANCE_ID}_s${SEED}.stderr
|
|
||||||
STDOUT="/dev/null"
|
|
||||||
STDERR="/dev/null"
|
|
||||||
|
|
||||||
if [ ! -x "${EXE}" ]; then
|
|
||||||
error "${EXE}: not found or not executable (pwd: $(pwd))"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# If the program just prints a number, we can use 'exec' to avoid
|
|
||||||
# creating another process, but there can be no other commands after exec.
|
|
||||||
#exec $EXE ${FIXED_PARAMS} -i $INSTANCE ${INSTANCE_PARAMS}
|
|
||||||
# exit 1
|
|
||||||
#
|
|
||||||
# Otherwise, save the output to a file, and parse the result from it.
|
|
||||||
# (If you wish to ignore segmentation faults you can use '{}' around
|
|
||||||
# the command.)
|
|
||||||
cmd="$EXE --problem=${INSTANCE} --instance=${INSTANCE} --seed=${SEED} ${CROSSOVER_RATE} ${CROSSOVER_SELECTOR} ${CROSSOVER} ${MUTATION_RATE} ${MUT_SELECTOR} ${MUTATION} ${REPLACEMENT} ${POPSIZE} ${OFFSPRINGSIZE} --max-evals=${buckets}"
|
|
||||||
# NOTE: irace seems to capture both stderr and stdout, so you should not output to stderr
|
|
||||||
echo ${cmd} > ${STDERR}
|
|
||||||
$cmd 2> ${STDERR} | tee ${STDOUT}
|
|
||||||
|
|
||||||
# The following code is useless if the binary only output a single number on stdout.
|
|
||||||
|
|
||||||
# This may be used to introduce a delay if there are filesystem
|
|
||||||
# issues.
|
|
||||||
# SLEEPTIME=1
|
|
||||||
# while [ ! -s "${STDOUT}" ]; do
|
|
||||||
# sleep $SLEEPTIME
|
|
||||||
# let "SLEEPTIME += 1"
|
|
||||||
# done
|
|
||||||
|
|
||||||
# This is an example of reading a number from the output.
|
|
||||||
# It assumes that the objective value is the first number in
|
|
||||||
# the first column of the last line of the output.
|
|
||||||
# if [ -s "${STDOUT}" ]; then
|
|
||||||
# COST=$(tail -n 1 ${STDOUT} | grep -e '^[[:space:]]*[+-]\?[0-9]' | cut -f1)
|
|
||||||
# echo "$COST"
|
|
||||||
# rm -f "${STDOUT}" "${STDERR}"
|
|
||||||
# exit 0
|
|
||||||
# else
|
|
||||||
# error "${STDOUT}: No such file or directory"
|
|
||||||
# fi
|
|
||||||
|
|
@ -1,48 +0,0 @@
|
||||||
## This is an example of specifying instances with a file.
|
|
||||||
|
|
||||||
# Each line is an instance relative to trainInstancesDir
|
|
||||||
# (see scenario.txt.tmpl) and an optional sequence of instance-specific
|
|
||||||
# parameters that will be passed to target-runnerx when invoked on that
|
|
||||||
# instance.
|
|
||||||
|
|
||||||
0
|
|
||||||
1
|
|
||||||
2
|
|
||||||
3
|
|
||||||
4
|
|
||||||
5
|
|
||||||
6
|
|
||||||
7
|
|
||||||
8
|
|
||||||
9
|
|
||||||
10
|
|
||||||
11
|
|
||||||
12
|
|
||||||
13
|
|
||||||
14
|
|
||||||
15
|
|
||||||
16
|
|
||||||
17
|
|
||||||
18
|
|
||||||
19
|
|
||||||
20
|
|
||||||
21
|
|
||||||
22
|
|
||||||
23
|
|
||||||
24
|
|
||||||
25
|
|
||||||
26
|
|
||||||
27
|
|
||||||
28
|
|
||||||
29
|
|
||||||
30
|
|
||||||
31
|
|
||||||
32
|
|
||||||
33
|
|
||||||
34
|
|
||||||
35
|
|
||||||
36
|
|
||||||
37
|
|
||||||
38
|
|
||||||
39
|
|
||||||
40
|
|
||||||
|
|
@ -1,227 +0,0 @@
|
||||||
###################################################### -*- mode: r -*- #####
|
|
||||||
## Scenario setup for Iterated Race (irace).
|
|
||||||
############################################################################
|
|
||||||
|
|
||||||
## To use the default value of a parameter of iRace, simply do not set
|
|
||||||
## the parameter (comment it out in this file, and do not give any
|
|
||||||
## value on the command line).
|
|
||||||
|
|
||||||
## File that contains the description of the parameters of the target
|
|
||||||
## algorithm.
|
|
||||||
parameterFile = "./fastga.param"
|
|
||||||
|
|
||||||
## Directory where the programs will be run.
|
|
||||||
execDir = "."
|
|
||||||
|
|
||||||
## File to save tuning results as an R dataset, either absolute path or
|
|
||||||
## relative to execDir.
|
|
||||||
# logFile = "./irace.Rdata"
|
|
||||||
|
|
||||||
## Previously saved log file to recover the execution of irace, either
|
|
||||||
## absolute path or relative to the current directory. If empty or NULL,
|
|
||||||
## recovery is not performed.
|
|
||||||
# recoveryFile = ""
|
|
||||||
|
|
||||||
## Directory where training instances are located; either absolute path or
|
|
||||||
## relative to current directory. If no trainInstancesFiles is provided,
|
|
||||||
## all the files in trainInstancesDir will be listed as instances.
|
|
||||||
trainInstancesDir = "."
|
|
||||||
|
|
||||||
## File that contains a list of training instances and optionally
|
|
||||||
## additional parameters for them. If trainInstancesDir is provided, irace
|
|
||||||
## will search for the files in this folder.
|
|
||||||
trainInstancesFile = "./default.instances"
|
|
||||||
|
|
||||||
## File that contains a table of initial configurations. If empty or NULL,
|
|
||||||
## all initial configurations are randomly generated.
|
|
||||||
# configurationsFile = ""
|
|
||||||
|
|
||||||
## File that contains a list of logical expressions that cannot be TRUE
|
|
||||||
## for any evaluated configuration. If empty or NULL, do not use forbidden
|
|
||||||
## expressions.
|
|
||||||
forbiddenFile = "./forbidden.txt"
|
|
||||||
|
|
||||||
## Script called for each configuration that executes the target algorithm
|
|
||||||
## to be tuned. See templates.
|
|
||||||
targetRunner = "./target-runner"
|
|
||||||
|
|
||||||
## Number of times to retry a call to targetRunner if the call failed.
|
|
||||||
# targetRunnerRetries = 0
|
|
||||||
|
|
||||||
## Optional data passed to targetRunner. This is ignored by the default
|
|
||||||
## targetRunner function, but it may be used by custom targetRunner
|
|
||||||
## functions to pass persistent data around.
|
|
||||||
# targetRunnerData = ""
|
|
||||||
|
|
||||||
## Optional R function to provide custom parallelization of targetRunner.
|
|
||||||
# targetRunnerParallel = ""
|
|
||||||
|
|
||||||
## Optional script or R function that provides a numeric value for each
|
|
||||||
## configuration. See templates/target-evaluator.tmpl
|
|
||||||
# targetEvaluator = ""
|
|
||||||
|
|
||||||
## Maximum number of runs (invocations of targetRunner) that will be
|
|
||||||
## performed. It determines the maximum budget of experiments for the
|
|
||||||
## tuning.
|
|
||||||
maxExperiments = 0 #100000
|
|
||||||
|
|
||||||
## Maximum total execution time in seconds for the executions of
|
|
||||||
## targetRunner. targetRunner must return two values: cost and time.
|
|
||||||
# maxTime = 60
|
|
||||||
|
|
||||||
## Fraction (smaller than 1) of the budget used to estimate the mean
|
|
||||||
## computation time of a configuration. Only used when maxTime > 0
|
|
||||||
# budgetEstimation = 0.02
|
|
||||||
|
|
||||||
## Maximum number of decimal places that are significant for numerical
|
|
||||||
## (real) parameters.
|
|
||||||
digits = 2
|
|
||||||
|
|
||||||
## Debug level of the output of irace. Set this to 0 to silence all debug
|
|
||||||
## messages. Higher values provide more verbose debug messages.
|
|
||||||
# debugLevel = 0
|
|
||||||
|
|
||||||
## Number of iterations.
|
|
||||||
# nbIterations = 0
|
|
||||||
|
|
||||||
## Number of runs of the target algorithm per iteration.
|
|
||||||
# nbExperimentsPerIteration = 0
|
|
||||||
|
|
||||||
## Randomly sample the training instances or use them in the order given.
|
|
||||||
# sampleInstances = 1
|
|
||||||
|
|
||||||
## Statistical test used for elimination. Default test is always F-test
|
|
||||||
## unless capping is enabled, in which case the default test is t-test.
|
|
||||||
## Valid values are: F-test (Friedman test), t-test (pairwise t-tests with
|
|
||||||
## no correction), t-test-bonferroni (t-test with Bonferroni's correction
|
|
||||||
## for multiple comparisons), t-test-holm (t-test with Holm's correction
|
|
||||||
## for multiple comparisons).
|
|
||||||
# testType = "F-test"
|
|
||||||
|
|
||||||
## Number of instances evaluated before the first elimination test. It
|
|
||||||
## must be a multiple of eachTest.
|
|
||||||
# firstTest = 5
|
|
||||||
|
|
||||||
## Number of instances evaluated between elimination tests.
|
|
||||||
# eachTest = 1
|
|
||||||
|
|
||||||
## Minimum number of configurations needed to continue the execution of
|
|
||||||
## each race (iteration).
|
|
||||||
# minNbSurvival = 0
|
|
||||||
|
|
||||||
## Number of configurations to be sampled and evaluated at each iteration.
|
|
||||||
# nbConfigurations = 0
|
|
||||||
|
|
||||||
## Parameter used to define the number of configurations sampled and
|
|
||||||
## evaluated at each iteration.
|
|
||||||
# mu = 5
|
|
||||||
|
|
||||||
## Confidence level for the elimination test.
|
|
||||||
# confidence = 0.95
|
|
||||||
|
|
||||||
## If the target algorithm is deterministic, configurations will be
|
|
||||||
## evaluated only once per instance.
|
|
||||||
# deterministic = 0
|
|
||||||
|
|
||||||
## Seed of the random number generator (by default, generate a random
|
|
||||||
## seed).
|
|
||||||
# seed = NA
|
|
||||||
|
|
||||||
## Number of calls to targetRunner to execute in parallel. Values 0 or 1
|
|
||||||
## mean no parallelization.
|
|
||||||
# parallel = 0
|
|
||||||
|
|
||||||
## Enable/disable load-balancing when executing experiments in parallel.
|
|
||||||
## Load-balancing makes better use of computing resources, but increases
|
|
||||||
## communication overhead. If this overhead is large, disabling
|
|
||||||
## load-balancing may be faster.
|
|
||||||
# loadBalancing = 1
|
|
||||||
|
|
||||||
## Enable/disable MPI. Use Rmpi to execute targetRunner in parallel
|
|
||||||
## (parameter parallel is the number of slaves).
|
|
||||||
# mpi = 0
|
|
||||||
|
|
||||||
## Specify how irace waits for jobs to finish when targetRunner submits
|
|
||||||
## jobs to a batch cluster: sge, pbs, torque or slurm. targetRunner must
|
|
||||||
## submit jobs to the cluster using, for example, qsub.
|
|
||||||
# batchmode = 0
|
|
||||||
|
|
||||||
## Enable/disable the soft restart strategy that avoids premature
|
|
||||||
## convergence of the probabilistic model.
|
|
||||||
# softRestart = 1
|
|
||||||
|
|
||||||
## Soft restart threshold value for numerical parameters. If NA, NULL or
|
|
||||||
## "", it is computed as 10^-digits.
|
|
||||||
# softRestartThreshold = ""
|
|
||||||
|
|
||||||
## Directory where testing instances are located, either absolute or
|
|
||||||
## relative to current directory.
|
|
||||||
# testInstancesDir = ""
|
|
||||||
|
|
||||||
## File containing a list of test instances and optionally additional
|
|
||||||
## parameters for them.
|
|
||||||
# testInstancesFile = ""
|
|
||||||
|
|
||||||
## Number of elite configurations returned by irace that will be tested if
|
|
||||||
## test instances are provided.
|
|
||||||
# testNbElites = 1
|
|
||||||
|
|
||||||
## Enable/disable testing the elite configurations found at each
|
|
||||||
## iteration.
|
|
||||||
# testIterationElites = 0
|
|
||||||
|
|
||||||
## Enable/disable elitist irace.
|
|
||||||
# elitist = 1
|
|
||||||
|
|
||||||
## Number of instances added to the execution list before previous
|
|
||||||
## instances in elitist irace.
|
|
||||||
# elitistNewInstances = 1
|
|
||||||
|
|
||||||
## In elitist irace, maximum number per race of elimination tests that do
|
|
||||||
## not eliminate a configuration. Use 0 for no limit.
|
|
||||||
# elitistLimit = 2
|
|
||||||
|
|
||||||
## User-defined R function that takes a configuration generated by irace
|
|
||||||
## and repairs it.
|
|
||||||
# repairConfiguration = ""
|
|
||||||
|
|
||||||
## Enable the use of adaptive capping, a technique designed for minimizing
|
|
||||||
## the computation time of configurations. This is only available when
|
|
||||||
## elitist is active.
|
|
||||||
# capping = 0
|
|
||||||
|
|
||||||
## Measure used to obtain the execution bound from the performance of the
|
|
||||||
## elite configurations: median, mean, worst, best.
|
|
||||||
# cappingType = "median"
|
|
||||||
|
|
||||||
## Method to calculate the mean performance of elite configurations:
|
|
||||||
## candidate or instance.
|
|
||||||
# boundType = "candidate"
|
|
||||||
|
|
||||||
## Maximum execution bound for targetRunner. It must be specified when
|
|
||||||
## capping is enabled.
|
|
||||||
# boundMax = 0
|
|
||||||
|
|
||||||
## Precision used for calculating the execution time. It must be specified
|
|
||||||
## when capping is enabled.
|
|
||||||
# boundDigits = 0
|
|
||||||
|
|
||||||
## Penalization constant for timed out executions (executions that reach
|
|
||||||
## boundMax execution time).
|
|
||||||
# boundPar = 1
|
|
||||||
|
|
||||||
## Replace the configuration cost of bounded executions with boundMax.
|
|
||||||
# boundAsTimeout = 1
|
|
||||||
|
|
||||||
## Percentage of the configuration budget used to perform a postselection
|
|
||||||
## race of the best configurations of each iteration after the execution
|
|
||||||
## of irace.
|
|
||||||
# postselection = 0
|
|
||||||
|
|
||||||
## Enable/disable AClib mode. This option enables compatibility with
|
|
||||||
## GenericWrapper4AC as targetRunner script.
|
|
||||||
# aclib = 0
|
|
||||||
|
|
||||||
## END of scenario file
|
|
||||||
############################################################################
|
|
||||||
|
|
||||||
|
|
@ -1,12 +0,0 @@
|
||||||
# name switch type range
|
|
||||||
# continuator "--continuator=" c (0)
|
|
||||||
crossoverrate "--crossover-rate=" r (0,1)
|
|
||||||
crossselector "--cross-selector=" c (0,1,2,3,4,5,6)
|
|
||||||
# aftercrossselector "--aftercross-selector=" c (0)
|
|
||||||
crossover "--crossover=" c (0,1,2,3,4,5,6,7,8,9)
|
|
||||||
mutationrate "--mutation-rate=" r (0,1)
|
|
||||||
mutselector "--mut-selector=" c (0,1,2,3,4,5,6)
|
|
||||||
mutation "--mutation=" c (0,1,2,3,4,5,6,7,8,9,10)
|
|
||||||
replacement "--replacement=" c (0,1,2,3,4,5,6,7,8,9,10)
|
|
||||||
popsize "--pop-size=" i (1,50)
|
|
||||||
offspringsize "--offspring-size=" i (1,50)
|
|
||||||
|
|
@ -1,15 +0,0 @@
|
||||||
## Template for specifying forbidden parameter configurations in irace.
|
|
||||||
##
|
|
||||||
## This filename must be specified via the --forbidden-file command-line option
|
|
||||||
## (or forbiddenFile in scenario.txt).
|
|
||||||
##
|
|
||||||
## The format is one constraint per line. Each constraint is a logical
|
|
||||||
## expression (in R syntax). If a parameter configuration
|
|
||||||
## is generated that makes the logical expression evaluate to TRUE,
|
|
||||||
## then the configuration is discarded.
|
|
||||||
##
|
|
||||||
## Examples of valid logical operators are: == != >= <= > < & | ! %in%
|
|
||||||
(replacement %in% c(2,3,4,5,6,7,8,9,10)) & (offspringsize > popsize)
|
|
||||||
(replacement %in% c(1)) & (offspringsize < popsize)
|
|
||||||
#(as.numeric(replacement) == 2) & (offspringsize > popsize)
|
|
||||||
#(as.numeric(replacement) == 3) & (offspringsize > popsize)
|
|
||||||
|
|
@ -1,96 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
###############################################################################
|
|
||||||
# This script is the command that is executed every run.
|
|
||||||
# Check the examples in examples/
|
|
||||||
#
|
|
||||||
# This script is run in the execution directory (execDir, --exec-dir).
|
|
||||||
#
|
|
||||||
# PARAMETERS:
|
|
||||||
# $1 is the candidate configuration number
|
|
||||||
# $2 is the instance ID
|
|
||||||
# $3 is the seed
|
|
||||||
# $4 is the instance name
|
|
||||||
# The rest ($* after `shift 4') are parameters to the run
|
|
||||||
#
|
|
||||||
# RETURN VALUE:
|
|
||||||
# This script should print one numerical value: the cost that must be minimized.
|
|
||||||
# Exit with 0 if no error, with 1 in case of error
|
|
||||||
###############################################################################
|
|
||||||
error() {
|
|
||||||
echo "`TZ=UTC date`: $0: error: $@"
|
|
||||||
exit 1
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
EXE="./fastga"
|
|
||||||
LOG_DIR="irace_logs"
|
|
||||||
|
|
||||||
FIXED_PARAMS="--problem=0"
|
|
||||||
#MAX_EVALS=2
|
|
||||||
#
|
|
||||||
CONFIG_ID=$1
|
|
||||||
INSTANCE_ID=$2
|
|
||||||
SEED=$3
|
|
||||||
INSTANCE=$(echo $4 | sed 's/\//\n/g'|tail -n 1)
|
|
||||||
CROSSOVER_RATE=$5
|
|
||||||
CROSSOVER_SELECTOR=$6
|
|
||||||
CROSSOVER=$7
|
|
||||||
MUTATION_RATE=$8
|
|
||||||
MUT_SELECTOR=$9
|
|
||||||
MUTATION=${10}
|
|
||||||
REPLACEMENT=${11}
|
|
||||||
POPSIZE=${12}
|
|
||||||
OFFSPRINGSIZE=${13}
|
|
||||||
shift 13 || error "Not enough parameters"
|
|
||||||
|
|
||||||
INSTANCE_PARAMS=$*
|
|
||||||
|
|
||||||
buckets=0
|
|
||||||
#dim=(20 20 16 48 25 32 128 128 128 50 100 150 128 192 192 192 256 75 150)
|
|
||||||
#size= $( echo $(echo $13 | cut -d'=' -f2))
|
|
||||||
#pb=$(echo $(echo $13 | cut -d'=' -f2))
|
|
||||||
#maxevals=$( echo ${dim[$pb]})
|
|
||||||
# STDOUT=${LOG_DIR}/c${CONFIG_ID}_i${INSTANCE_ID}_s${SEED}.stdout
|
|
||||||
# STDERR=${LOG_DIR}/c${CONFIG_ID}_i${INSTANCE_ID}_s${SEED}.stderr
|
|
||||||
STDOUT="/dev/null"
|
|
||||||
STDERR="/dev/null"
|
|
||||||
|
|
||||||
if [ ! -x "${EXE}" ]; then
|
|
||||||
error "${EXE}: not found or not executable (pwd: $(pwd))"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# If the program just prints a number, we can use 'exec' to avoid
|
|
||||||
# creating another process, but there can be no other commands after exec.
|
|
||||||
#exec $EXE ${FIXED_PARAMS} -i $INSTANCE ${INSTANCE_PARAMS}
|
|
||||||
# exit 1
|
|
||||||
#
|
|
||||||
# Otherwise, save the output to a file, and parse the result from it.
|
|
||||||
# (If you wish to ignore segmentation faults you can use '{}' around
|
|
||||||
# the command.)
|
|
||||||
|
|
||||||
cmd="$EXE ${FIXED_PARAMS} --instance=${INSTANCE} --seed=${SEED} ${CROSSOVER_RATE} ${CROSSOVER_SELECTOR} ${CROSSOVER} ${MUTATION_RATE} ${MUT_SELECTOR} ${MUTATION} ${REPLACEMENT} ${POPSIZE} ${OFFSPRINGSIZE} --max-evals=${buckets}"
|
|
||||||
# NOTE: irace seems to capture both stderr and stdout, so you should not output to stderr
|
|
||||||
echo ${cmd} > ${STDERR}
|
|
||||||
$cmd 2> ${STDERR} | tee ${STDOUT}
|
|
||||||
|
|
||||||
# The following code is useless if the binary only output a single number on stdout.
|
|
||||||
|
|
||||||
# This may be used to introduce a delay if there are filesystem
|
|
||||||
# issues.
|
|
||||||
# SLEEPTIME=1
|
|
||||||
# while [ ! -s "${STDOUT}" ]; do
|
|
||||||
# sleep $SLEEPTIME
|
|
||||||
# let "SLEEPTIME += 1"
|
|
||||||
# done
|
|
||||||
|
|
||||||
# This is an example of reading a number from the output.
|
|
||||||
# It assumes that the objective value is the first number in
|
|
||||||
# the first column of the last line of the output.
|
|
||||||
# if [ -s "${STDOUT}" ]; then
|
|
||||||
# COST=$(tail -n 1 ${STDOUT} | grep -e '^[[:space:]]*[+-]\?[0-9]' | cut -f1)
|
|
||||||
# echo "$COST"
|
|
||||||
# rm -f "${STDOUT}" "${STDERR}"
|
|
||||||
# exit 0
|
|
||||||
# else
|
|
||||||
# error "${STDOUT}: No such file or directory"
|
|
||||||
# fi
|
|
||||||
|
|
@ -1,48 +0,0 @@
|
||||||
## This is an example of specifying instances with a file.
|
|
||||||
|
|
||||||
# Each line is an instance relative to trainInstancesDir
|
|
||||||
# (see scenario.txt.tmpl) and an optional sequence of instance-specific
|
|
||||||
# parameters that will be passed to target-runnerx when invoked on that
|
|
||||||
# instance.
|
|
||||||
|
|
||||||
0
|
|
||||||
1
|
|
||||||
2
|
|
||||||
3
|
|
||||||
4
|
|
||||||
5
|
|
||||||
6
|
|
||||||
7
|
|
||||||
8
|
|
||||||
9
|
|
||||||
10
|
|
||||||
11
|
|
||||||
12
|
|
||||||
13
|
|
||||||
14
|
|
||||||
15
|
|
||||||
16
|
|
||||||
17
|
|
||||||
18
|
|
||||||
19
|
|
||||||
20
|
|
||||||
21
|
|
||||||
22
|
|
||||||
23
|
|
||||||
24
|
|
||||||
25
|
|
||||||
26
|
|
||||||
27
|
|
||||||
28
|
|
||||||
29
|
|
||||||
30
|
|
||||||
31
|
|
||||||
32
|
|
||||||
33
|
|
||||||
34
|
|
||||||
35
|
|
||||||
36
|
|
||||||
37
|
|
||||||
38
|
|
||||||
39
|
|
||||||
40
|
|
||||||
|
|
@ -1,228 +0,0 @@
|
||||||
###################################################### -*- mode: r -*- #####
|
|
||||||
## Scenario setup for Iterated Race (irace).
|
|
||||||
############################################################################
|
|
||||||
|
|
||||||
## To use the default value of a parameter of iRace, simply do not set
|
|
||||||
## the parameter (comment it out in this file, and do not give any
|
|
||||||
## value on the command line).
|
|
||||||
|
|
||||||
## File that contains the description of the parameters of the target
|
|
||||||
## algorithm.
|
|
||||||
parameterFile = "./fastga.param"
|
|
||||||
|
|
||||||
## Directory where the programs will be run.
|
|
||||||
execDir = "."
|
|
||||||
|
|
||||||
## File to save tuning results as an R dataset, either absolute path or
|
|
||||||
## relative to execDir.
|
|
||||||
# logFile = "./irace.Rdata"
|
|
||||||
|
|
||||||
## Previously saved log file to recover the execution of irace, either
|
|
||||||
## absolute path or relative to the current directory. If empty or NULL,
|
|
||||||
## recovery is not performed.
|
|
||||||
# recoveryFile = ""
|
|
||||||
|
|
||||||
## Directory where training instances are located; either absolute path or
|
|
||||||
## relative to current directory. If no trainInstancesFiles is provided,
|
|
||||||
## all the files in trainInstancesDir will be listed as instances.
|
|
||||||
trainInstancesDir = "."
|
|
||||||
|
|
||||||
## File that contains a list of training instances and optionally
|
|
||||||
## additional parameters for them. If trainInstancesDir is provided, irace
|
|
||||||
## will search for the files in this folder.
|
|
||||||
trainInstancesFile = "./default.instances"
|
|
||||||
|
|
||||||
## File that contains a table of initial configurations. If empty or NULL,
|
|
||||||
## all initial configurations are randomly generated.
|
|
||||||
# configurationsFile = ""
|
|
||||||
|
|
||||||
## File that contains a list of logical expressions that cannot be TRUE
|
|
||||||
## for any evaluated configuration. If empty or NULL, do not use forbidden
|
|
||||||
## expressions.
|
|
||||||
# forbiddenFile = ""
|
|
||||||
|
|
||||||
## Script called for each configuration that executes the target algorithm
|
|
||||||
## to be tuned. See templates.
|
|
||||||
targetRunner = "./target-runner"
|
|
||||||
|
|
||||||
## Number of times to retry a call to targetRunner if the call failed.
|
|
||||||
# targetRunnerRetries = 0
|
|
||||||
|
|
||||||
## Optional data passed to targetRunner. This is ignored by the default
|
|
||||||
## targetRunner function, but it may be used by custom targetRunner
|
|
||||||
## functions to pass persistent data around.
|
|
||||||
# targetRunnerData = ""
|
|
||||||
|
|
||||||
## Optional R function to provide custom parallelization of targetRunner.
|
|
||||||
# targetRunnerParallel = ""
|
|
||||||
|
|
||||||
## Optional script or R function that provides a numeric value for each
|
|
||||||
## configuration. See templates/target-evaluator.tmpl
|
|
||||||
# targetEvaluator = ""
|
|
||||||
|
|
||||||
## Maximum number of runs (invocations of targetRunner) that will be
|
|
||||||
## performed. It determines the maximum budget of experiments for the
|
|
||||||
## tuning.
|
|
||||||
maxExperiments = 0 #100000
|
|
||||||
|
|
||||||
|
|
||||||
## Maximum total execution time in seconds for the executions of
|
|
||||||
## targetRunner. targetRunner must return two values: cost and time.
|
|
||||||
# maxTime = 60
|
|
||||||
|
|
||||||
## Fraction (smaller than 1) of the budget used to estimate the mean
|
|
||||||
## computation time of a configuration. Only used when maxTime > 0
|
|
||||||
# budgetEstimation = 0.02
|
|
||||||
|
|
||||||
## Maximum number of decimal places that are significant for numerical
|
|
||||||
## (real) parameters.
|
|
||||||
digits = 2
|
|
||||||
|
|
||||||
## Debug level of the output of irace. Set this to 0 to silence all debug
|
|
||||||
## messages. Higher values provide more verbose debug messages.
|
|
||||||
# debugLevel = 0
|
|
||||||
|
|
||||||
## Number of iterations.
|
|
||||||
# nbIterations = 0
|
|
||||||
|
|
||||||
## Number of runs of the target algorithm per iteration.
|
|
||||||
# nbExperimentsPerIteration = 0
|
|
||||||
|
|
||||||
## Randomly sample the training instances or use them in the order given.
|
|
||||||
# sampleInstances = 1
|
|
||||||
|
|
||||||
## Statistical test used for elimination. Default test is always F-test
|
|
||||||
## unless capping is enabled, in which case the default test is t-test.
|
|
||||||
## Valid values are: F-test (Friedman test), t-test (pairwise t-tests with
|
|
||||||
## no correction), t-test-bonferroni (t-test with Bonferroni's correction
|
|
||||||
## for multiple comparisons), t-test-holm (t-test with Holm's correction
|
|
||||||
## for multiple comparisons).
|
|
||||||
# testType = "F-test"
|
|
||||||
|
|
||||||
## Number of instances evaluated before the first elimination test. It
|
|
||||||
## must be a multiple of eachTest.
|
|
||||||
# firstTest = 5
|
|
||||||
|
|
||||||
## Number of instances evaluated between elimination tests.
|
|
||||||
# eachTest = 1
|
|
||||||
|
|
||||||
## Minimum number of configurations needed to continue the execution of
|
|
||||||
## each race (iteration).
|
|
||||||
# minNbSurvival = 0
|
|
||||||
|
|
||||||
## Number of configurations to be sampled and evaluated at each iteration.
|
|
||||||
# nbConfigurations = 0
|
|
||||||
|
|
||||||
## Parameter used to define the number of configurations sampled and
|
|
||||||
## evaluated at each iteration.
|
|
||||||
# mu = 5
|
|
||||||
|
|
||||||
## Confidence level for the elimination test.
|
|
||||||
# confidence = 0.95
|
|
||||||
|
|
||||||
## If the target algorithm is deterministic, configurations will be
|
|
||||||
## evaluated only once per instance.
|
|
||||||
# deterministic = 0
|
|
||||||
|
|
||||||
## Seed of the random number generator (by default, generate a random
|
|
||||||
## seed).
|
|
||||||
# seed = NA
|
|
||||||
|
|
||||||
## Number of calls to targetRunner to execute in parallel. Values 0 or 1
|
|
||||||
## mean no parallelization.
|
|
||||||
# parallel = 0
|
|
||||||
|
|
||||||
## Enable/disable load-balancing when executing experiments in parallel.
|
|
||||||
## Load-balancing makes better use of computing resources, but increases
|
|
||||||
## communication overhead. If this overhead is large, disabling
|
|
||||||
## load-balancing may be faster.
|
|
||||||
# loadBalancing = 1
|
|
||||||
|
|
||||||
## Enable/disable MPI. Use Rmpi to execute targetRunner in parallel
|
|
||||||
## (parameter parallel is the number of slaves).
|
|
||||||
# mpi = 0
|
|
||||||
|
|
||||||
## Specify how irace waits for jobs to finish when targetRunner submits
|
|
||||||
## jobs to a batch cluster: sge, pbs, torque or slurm. targetRunner must
|
|
||||||
## submit jobs to the cluster using, for example, qsub.
|
|
||||||
# batchmode = 0
|
|
||||||
|
|
||||||
## Enable/disable the soft restart strategy that avoids premature
|
|
||||||
## convergence of the probabilistic model.
|
|
||||||
# softRestart = 1
|
|
||||||
|
|
||||||
## Soft restart threshold value for numerical parameters. If NA, NULL or
|
|
||||||
## "", it is computed as 10^-digits.
|
|
||||||
# softRestartThreshold = ""
|
|
||||||
|
|
||||||
## Directory where testing instances are located, either absolute or
|
|
||||||
## relative to current directory.
|
|
||||||
# testInstancesDir = ""
|
|
||||||
|
|
||||||
## File containing a list of test instances and optionally additional
|
|
||||||
## parameters for them.
|
|
||||||
# testInstancesFile = ""
|
|
||||||
|
|
||||||
## Number of elite configurations returned by irace that will be tested if
|
|
||||||
## test instances are provided.
|
|
||||||
# testNbElites = 1
|
|
||||||
|
|
||||||
## Enable/disable testing the elite configurations found at each
|
|
||||||
## iteration.
|
|
||||||
# testIterationElites = 0
|
|
||||||
|
|
||||||
## Enable/disable elitist irace.
|
|
||||||
# elitist = 1
|
|
||||||
|
|
||||||
## Number of instances added to the execution list before previous
|
|
||||||
## instances in elitist irace.
|
|
||||||
# elitistNewInstances = 1
|
|
||||||
|
|
||||||
## In elitist irace, maximum number per race of elimination tests that do
|
|
||||||
## not eliminate a configuration. Use 0 for no limit.
|
|
||||||
# elitistLimit = 2
|
|
||||||
|
|
||||||
## User-defined R function that takes a configuration generated by irace
|
|
||||||
## and repairs it.
|
|
||||||
# repairConfiguration = ""
|
|
||||||
|
|
||||||
## Enable the use of adaptive capping, a technique designed for minimizing
|
|
||||||
## the computation time of configurations. This is only available when
|
|
||||||
## elitist is active.
|
|
||||||
# capping = 0
|
|
||||||
|
|
||||||
## Measure used to obtain the execution bound from the performance of the
|
|
||||||
## elite configurations: median, mean, worst, best.
|
|
||||||
# cappingType = "median"
|
|
||||||
|
|
||||||
## Method to calculate the mean performance of elite configurations:
|
|
||||||
## candidate or instance.
|
|
||||||
# boundType = "candidate"
|
|
||||||
|
|
||||||
## Maximum execution bound for targetRunner. It must be specified when
|
|
||||||
## capping is enabled.
|
|
||||||
# boundMax = 0
|
|
||||||
|
|
||||||
## Precision used for calculating the execution time. It must be specified
|
|
||||||
## when capping is enabled.
|
|
||||||
# boundDigits = 0
|
|
||||||
|
|
||||||
## Penalization constant for timed out executions (executions that reach
|
|
||||||
## boundMax execution time).
|
|
||||||
# boundPar = 1
|
|
||||||
|
|
||||||
## Replace the configuration cost of bounded executions with boundMax.
|
|
||||||
# boundAsTimeout = 1
|
|
||||||
|
|
||||||
## Percentage of the configuration budget used to perform a postselection
|
|
||||||
## race of the best configurations of each iteration after the execution
|
|
||||||
## of irace.
|
|
||||||
# postselection = 0
|
|
||||||
|
|
||||||
## Enable/disable AClib mode. This option enables compatibility with
|
|
||||||
## GenericWrapper4AC as targetRunner script.
|
|
||||||
# aclib = 0
|
|
||||||
|
|
||||||
## END of scenario file
|
|
||||||
############################################################################
|
|
||||||
|
|
||||||
|
|
@ -1,10 +0,0 @@
|
||||||
# name switch type range
|
|
||||||
# continuator "--continuator=" c (0)
|
|
||||||
crossoverrate "--crossover-rate=" r (0,1)
|
|
||||||
crossselector "--cross-selector=" c (0,1,2,3,4,5,6)
|
|
||||||
# aftercrossselector "--aftercross-selector=" c (0)
|
|
||||||
crossover "--crossover=" c (0,1,2,3,4,5,6,7,8,9)
|
|
||||||
mutationrate "--mutation-rate=" r (0,1)
|
|
||||||
mutselector "--mut-selector=" c (0,1,2,3,4,5,6)
|
|
||||||
mutation "--mutation=" c (0,1,2,3,4,5,6,7,8,9,10)
|
|
||||||
replacement "--replacement=" c (0,1,2,3,4,5,6,7,8,9,10)
|
|
||||||