Distributed GPU-Accelerated Framework for Evolutionary Computation. Comprehensive Library of Evolutionary Algorithms & Benchmark Problems.
Distributed GPU-Accelerated Framework for Evolutionary Computation. Comprehensive Library of Evolutionary Algorithms & Benchmark Problems.
EvoX is a distributed GPU-accelerated evolutionary computation framework compatible with PyTorch. With a user-friendly programming model, it offers a comprehensive suite of 140+ Evolutionary Algorithms (EAs) and 240+ Benchmark Problems/Environments across the EvoX ecosystem — 30+ algorithms and 30+ benchmark problems/environments built into this package, plus its sister libraries. For more details, please refer to our Paper and Documentation / 文档.
[!NOTE] Users of the previous JAX-based version can access it on the v0.9.0 branch.
| Category | Subcategory | Notable Algorithms / Benchmark Problems |
|---|---|---|
| Single-objective Optimization | Differential Evolution | CoDE, JaDE, SaDE, SHADE, IMODE, ... |
| Evolution Strategy | CMA-ES, PGPE, OpenES, CR-FM-NES, xNES, ... | |
| Particle Swarm Optimization | FIPS, CSO, CPSO, CLPSO, SL-PSO, ... | |
| Multi-objective Optimization | Dominance-based | NSGA-II, NSGA-III, SPEA2, BiGE, KnEA, ... |
| Decomposition-based | MOEA/D, RVEA, t-DEA, MOEAD-M2M, EAG-MOEAD, ... | |
| Indicator-based | IBEA, HypE, SRA, MaOEA-IGD, AR-MOEA, ... | |
| Benchmark Problems / Environments | Numerical | DTLZ, LSMOP, MaF, ZDT, CEC'22, ... |
| Neuroevolution / RL | Brax, TorchVision Dataset, ... |
For a comprehensive list and detailed descriptions of all algorithms, please check the Algorithms API, and for benchmark problems/environments, refer to the Problems API.
Install evox with default feature sets via pip:
pip install "evox[default]"Install the latest version from the source code for testing or development:
git clone https://github.com/EMI-Group/evox.git
cd evox
pip install -e .[!TIP] Windows users can use the win-install.bat script for installation.
Here are some examples to get you started with EvoX:
Solve the Ackley problem using the PSO algorithm:
import torch
from evox.algorithms import PSO
from evox.problems.numerical import Ackley
from evox.workflows import StdWorkflow, EvalMonitor
# torch.set_default_device("cuda") # Uncomment this line if you want to use GPU by default
algorithm = PSO(pop_size=100, lb=-32 * torch.ones(10), ub=32 * torch.ones(10))
problem = Ackley()
monitor = EvalMonitor()
workflow = StdWorkflow(algorithm, problem, monitor)
workflow.init_step()
for i in range(100):
workflow.step()
monitor.plot() # or monitor.plot().show() if you are using headless modeSolve the DTLZ2 problem using the RVEA algorithm:
import torch
from evox.algorithms import RVEA
from evox.problems.numerical import DTLZ2
from evox.workflows import StdWorkflow, EvalMonitor
# torch.set_default_device("cuda") # Uncomment this line if you want to use GPU by default
prob = DTLZ2(m=2)
pf = prob.pf()
algo = RVEA(
pop_size=100,
n_objs=2,
lb=-torch.zeros(12),
ub=torch.ones(12)
)
monitor = EvalMonitor()
workflow = StdWorkflow(algo, prob, monitor)
workflow.init_step()
for i in range(100):
workflow.step()
monitor.plot() # or monitor.plot().show() if you are using headless modeEvolving a simple MLP model to solve the Brax HalfCheetah environment:
…[!NOTE] For comprehensive guidance, please visit our Documentation, where you'll find detailed installation steps, tutorials, practical examples, and complete API references.
Together with EvoX, these and the other EvoX-related libraries published by the EMI-Group form an ecosystem providing 140+ algorithms and 240+ benchmark problems/environments.
Stay tuned - more exciting developments are on the way! ✨
If EvoX contributes to your research, please cite it:
@article{evox,
title = {{EvoX}: {A} {Distributed} {GPU}-accelerated {Framework} for {Scalable} {Evolutionary} {Computation}},
author = {Huang, Beichen and Cheng, Ran and Li, Zhuozhao and Jin, Yaochu and Tan, Kay Chen},
journal = {IEEE Transactions on Evolutionary Computation},
year = 2024,
doi = {10.1109/TEVC.2024.3388550}
}EvoX is licensed under the GNU General Public License v3.0 (GPL-3.0). For full terms and conditions, please refer to the LICENSE file.
No open issues yet, or sync has not completed.