• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..03-May-2022-

deap/H21-Jan-2020-10,2437,475

deap.egg-info/H03-May-2022-174138

doc/H03-May-2022-6,3724,456

examples/H03-May-2022-20,80118,279

MANIFEST.inH A D21-Jan-2020224 98

PKG-INFOH A D21-Jan-202013.8 KiB174138

README.mdH A D21-Jan-202011.8 KiB153118

setup.cfgH A D21-Jan-202038 53

setup.pyH A D21-Jan-20203.7 KiB11186

README.md

1# DEAP
2
3[![Build status](https://travis-ci.org/DEAP/deap.svg?branch=master)](https://travis-ci.org/DEAP/deap) [![Download](https://img.shields.io/pypi/dm/deap.svg)](https://pypi.python.org/pypi/deap) [![Join the chat at https://gitter.im/DEAP/deap](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/DEAP/deap?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [![Build Status](https://dev.azure.com/fderainville/DEAP/_apis/build/status/DEAP.deap?branchName=master)](https://dev.azure.com/fderainville/DEAP/_build/latest?definitionId=1&branchName=master) [![Documentation Status](https://readthedocs.org/projects/deap/badge/?version=master)](https://deap.readthedocs.io/en/master/?badge=master)
4
5DEAP is a novel evolutionary computation framework for rapid prototyping and testing of
6ideas. It seeks to make algorithms explicit and data structures transparent. It works in perfect harmony with parallelisation mechanisms such as multiprocessing and [SCOOP](https://github.com/soravux/scoop).
7
8DEAP includes the following features:
9
10  * Genetic algorithm using any imaginable representation
11    * List, Array, Set, Dictionary, Tree, Numpy Array, etc.
12  * Genetic programing using prefix trees
13    * Loosely typed, Strongly typed
14    * Automatically defined functions
15  * Evolution strategies (including CMA-ES)
16  * Multi-objective optimisation (NSGA-II, NSGA-III, SPEA2, MO-CMA-ES)
17  * Co-evolution (cooperative and competitive) of multiple populations
18  * Parallelization of the evaluations (and more)
19  * Hall of Fame of the best individuals that lived in the population
20  * Checkpoints that take snapshots of a system regularly
21  * Benchmarks module containing most common test functions
22  * Genealogy of an evolution (that is compatible with [NetworkX](https://github.com/networkx/networkx))
23  * Examples of alternative algorithms : Particle Swarm Optimization, Differential Evolution, Estimation of Distribution Algorithm
24
25## Downloads
26
27Following acceptance of [PEP 438](http://www.python.org/dev/peps/pep-0438/) by the Python community, we have moved DEAP's source releases on [PyPI](https://pypi.python.org).
28
29You can find the most recent releases at: https://pypi.python.org/pypi/deap/.
30
31## Documentation
32See the [DEAP User's Guide](http://deap.readthedocs.org/) for DEAP documentation.
33
34In order to get the tip documentation, change directory to the `doc` subfolder and type in `make html`, the documentation will be under `_build/html`. You will need [Sphinx](http://sphinx.pocoo.org) to build the documentation.
35
36### Notebooks
37Also checkout our new [notebook examples](https://github.com/DEAP/notebooks). Using [Jupyter notebooks](http://jupyter.org)  you'll be able to navigate and execute each block of code individually and tell what every line is doing. Either, look at the notebooks online using the notebook viewer links at the botom of the page or download the notebooks, navigate to the you download directory and run
38
39```bash
40jupyter notebook
41```
42
43## Installation
44We encourage you to use easy_install or pip to install DEAP on your system. Other installation procedure like apt-get, yum, etc. usually provide an outdated version.
45```bash
46pip install deap
47```
48
49The latest version can be installed with
50```bash
51pip install git+https://github.com/DEAP/deap@master
52```
53
54If you wish to build from sources, download or clone the repository and type
55
56```bash
57python setup.py install
58```
59
60## Build Status
61DEAP build status is available on Travis-CI https://travis-ci.org/DEAP/deap.
62
63## Requirements
64The most basic features of DEAP requires Python2.6. In order to combine the toolbox and the multiprocessing module Python2.7 is needed for its support to pickle partial functions. CMA-ES requires Numpy, and we recommend matplotlib for visualization of results as it is fully compatible with DEAP's API.
65
66Since version 0.8, DEAP is compatible out of the box with Python 3. The installation procedure automatically translates the source to Python 3 with 2to3.
67
68## Example
69
70The following code gives a quick overview how simple it is to implement the Onemax problem optimization with genetic algorithm using DEAP.  More examples are provided [here](http://deap.readthedocs.org/en/master/examples/index.html).
71
72```python
73import random
74from deap import creator, base, tools, algorithms
75
76creator.create("FitnessMax", base.Fitness, weights=(1.0,))
77creator.create("Individual", list, fitness=creator.FitnessMax)
78
79toolbox = base.Toolbox()
80
81toolbox.register("attr_bool", random.randint, 0, 1)
82toolbox.register("individual", tools.initRepeat, creator.Individual, toolbox.attr_bool, n=100)
83toolbox.register("population", tools.initRepeat, list, toolbox.individual)
84
85def evalOneMax(individual):
86    return sum(individual),
87
88toolbox.register("evaluate", evalOneMax)
89toolbox.register("mate", tools.cxTwoPoint)
90toolbox.register("mutate", tools.mutFlipBit, indpb=0.05)
91toolbox.register("select", tools.selTournament, tournsize=3)
92
93population = toolbox.population(n=300)
94
95NGEN=40
96for gen in range(NGEN):
97    offspring = algorithms.varAnd(population, toolbox, cxpb=0.5, mutpb=0.1)
98    fits = toolbox.map(toolbox.evaluate, offspring)
99    for fit, ind in zip(fits, offspring):
100        ind.fitness.values = fit
101    population = toolbox.select(offspring, k=len(population))
102top10 = tools.selBest(population, k=10)
103```
104
105## How to cite DEAP
106Authors of scientific papers including results generated using DEAP are encouraged to cite the following paper.
107
108```xml
109@article{DEAP_JMLR2012,
110    author    = " F\'elix-Antoine Fortin and Fran\c{c}ois-Michel {De Rainville} and Marc-Andr\'e Gardner and Marc Parizeau and Christian Gagn\'e ",
111    title     = { {DEAP}: Evolutionary Algorithms Made Easy },
112    pages    = { 2171--2175 },
113    volume    = { 13 },
114    month     = { jul },
115    year      = { 2012 },
116    journal   = { Journal of Machine Learning Research }
117}
118```
119
120## Publications on DEAP
121
122  * François-Michel De Rainville, Félix-Antoine Fortin, Marc-André Gardner, Marc Parizeau and Christian Gagné, "DEAP -- Enabling Nimbler Evolutions", SIGEVOlution, vol. 6, no 2, pp. 17-26, February 2014. [Paper](http://goo.gl/tOrXTp)
123  * Félix-Antoine Fortin, François-Michel De Rainville, Marc-André Gardner, Marc Parizeau and Christian Gagné, "DEAP: Evolutionary Algorithms Made Easy", Journal of Machine Learning Research, vol. 13, pp. 2171-2175, jul 2012. [Paper](http://goo.gl/amJ3x)
124  * François-Michel De Rainville, Félix-Antoine Fortin, Marc-André Gardner, Marc Parizeau and Christian Gagné, "DEAP: A Python Framework for Evolutionary Algorithms", in !EvoSoft Workshop, Companion proc. of the Genetic and Evolutionary Computation Conference (GECCO 2012), July 07-11 2012. [Paper](http://goo.gl/pXXug)
125
126## Projects using DEAP
127  * Ribaric, T., & Houghten, S. (2017, June). Genetic programming for improved cryptanalysis of elliptic curve cryptosystems. In 2017 IEEE Congress on Evolutionary Computation (CEC) (pp. 419-426). IEEE.
128  * Ellefsen, Kai Olav, Herman Augusto Lepikson, and Jan C. Albiez. "Multiobjective coverage path planning: Enabling automated inspection of complex, real-world structures." Applied Soft Computing 61 (2017): 264-282.
129  * S. Chardon, B. Brangeon, E. Bozonnet, C. Inard (2016), Construction cost and energy performance of single family houses : From integrated design to automated optimization, Automation in Construction, Volume 70, p.1-13.
130  * B. Brangeon, E. Bozonnet, C. Inard (2016), Integrated refurbishment of collective housing and optimization process with real products databases, Building Simulation Optimization, pp. 531–538 Newcastle, England.
131  * Randal S. Olson, Ryan J. Urbanowicz, Peter C. Andrews, Nicole A. Lavender, La Creis Kidd, and Jason H. Moore (2016). Automating biomedical data science through tree-based pipeline optimization. Applications of Evolutionary Computation, pages 123-137.
132  * Randal S. Olson, Nathan Bartley, Ryan J. Urbanowicz, and Jason H. Moore (2016). Evaluation of a Tree-based Pipeline Optimization Tool for Automating Data Science. Proceedings of GECCO 2016, pages 485-492.
133  * Van Geit W, Gevaert M, Chindemi G, Rössert C, Courcol J, Muller EB, Schürmann F, Segev I and Markram H (2016). BluePyOpt: Leveraging open source software and cloud infrastructure to optimise model parameters in neuroscience. Front. Neuroinform. 10:17. doi: 10.3389/fninf.2016.00017 https://github.com/BlueBrain/BluePyOpt
134  * Lara-Cabrera, R., Cotta, C. and Fernández-Leiva, A.J. (2014). Geometrical vs topological measures for the evolution of aesthetic maps in a rts game, Entertainment Computing,
135  * Macret, M. and Pasquier, P. (2013). Automatic Tuning of the OP-1 Synthesizer Using a Multi-objective Genetic Algorithm. In Proceedings of the 10th Sound and Music Computing Conference (SMC). (pp 614-621).
136  * Fortin, F. A., Grenier, S., & Parizeau, M. (2013, July). Generalizing the improved run-time complexity algorithm for non-dominated sorting. In Proceeding of the fifteenth annual conference on Genetic and evolutionary computation conference (pp. 615-622). ACM.
137  * Fortin, F. A., & Parizeau, M. (2013, July). Revisiting the NSGA-II crowding-distance computation. In Proceeding of the fifteenth annual conference on Genetic and evolutionary computation conference (pp. 623-630). ACM.
138  * Marc-André Gardner, Christian Gagné, and Marc Parizeau. Estimation of Distribution Algorithm based on Hidden Markov Models for Combinatorial Optimization. in Comp. Proc. Genetic and Evolutionary Computation Conference (GECCO 2013), July 2013.
139  * J. T. Zhai, M. A. Bamakhrama, and T. Stefanov. "Exploiting Just-enough Parallelism when Mapping Streaming Applications in Hard Real-time Systems". Design Automation Conference (DAC 2013), 2013.
140  * V. Akbarzadeh, C. Gagné, M. Parizeau, M. Argany, M. A Mostafavi, "Probabilistic Sensing Model for Sensor Placement Optimization Based on Line-of-Sight Coverage", Accepted in IEEE Transactions on Instrumentation and Measurement, 2012.
141  * M. Reif, F. Shafait, and A. Dengel. "Dataset Generation for Meta-Learning". Proceedings of the German Conference on Artificial Intelligence (KI'12). 2012.
142  * M. T. Ribeiro, A. Lacerda, A. Veloso, and N. Ziviani. "Pareto-Efficient Hybridization for Multi-Objective Recommender Systems". Proceedings of the Conference on Recommanders Systems (!RecSys'12). 2012.
143  * M. Pérez-Ortiz, A. Arauzo-Azofra, C. Hervás-Martínez, L. García-Hernández and L. Salas-Morera. "A system learning user preferences for multiobjective optimization of facility layouts". Pr,oceedings on the Int. Conference on Soft Computing Models in Industrial and Environmental Applications (SOCO'12). 2012.
144  * Lévesque, J.C., Durand, A., Gagné, C., and Sabourin, R., Multi-Objective Evolutionary Optimization for Generating Ensembles of Classifiers in the ROC Space, Genetic and Evolutionary Computation Conference (GECCO 2012), 2012.
145  * Marc-André Gardner, Christian Gagné, and Marc Parizeau, "Bloat Control in Genetic Programming with Histogram-based Accept-Reject Method", in Proc. Genetic and Evolutionary Computation Conference (GECCO 2011), 2011.
146  * Vahab Akbarzadeh, Albert Ko, Christian Gagné, and Marc Parizeau, "Topography-Aware Sensor Deployment Optimization with CMA-ES", in Proc. of Parallel Problem Solving from Nature (PPSN 2010), Springer, 2010.
147  * DEAP is used in [TPOT](https://github.com/rhiever/tpot), an open source tool that uses genetic programming to optimize machine learning pipelines.
148  * DEAP is also used in ROS as an optimization package http://www.ros.org/wiki/deap.
149  * DEAP is an optional dependency for [PyXRD](https://github.com/mathijs-dumon/PyXRD), a Python implementation of the matrix algorithm developed for the X-ray diffraction analysis of disordered lamellar structures.
150  * DEAP is used in [glyph](https://github.com/Ambrosys/glyph), a library for symbolic regression with applications to [MLC](https://en.wikipedia.org/wiki/Machine_learning_control).
151
152If you want your project listed here, send us a link and a brief description and we'll be glad to add it.
153