PyRADE Documentation๏
Welcome to PyRADE (Python Rapid Algorithm for Differential Evolution) - a high-performance, modular Differential Evolution optimization package.
Overview๏
PyRADE is a production-ready optimization library implementing Differential Evolution (DE), a powerful evolutionary algorithm for global optimization. Unlike traditional implementations that sacrifice code quality for performance, PyRADE proves you can have both through intelligent design.
Key Features๏
โก High Performance: 3-5x faster than traditional implementations through aggressive NumPy vectorization
๐๏ธ Clean Architecture: Strategy pattern for all operators - easy to understand and extend
๐ง Modular Design: Plug-and-play mutation, crossover, and selection strategies
๐ฆ Production Ready: Well-documented, tested, professional-quality code
๐ฏ Easy to Use: Simple, intuitive API similar to scikit-learn optimizers
๐งช Comprehensive: Includes 12 benchmark functions and multiple real-world examples
Quick Example๏
import numpy as np
from pyrade import DifferentialEvolution
# Define your objective function
def sphere(x):
return np.sum(x**2)
# Create optimizer
optimizer = DifferentialEvolution(
objective_func=sphere,
bounds=[(-100, 100)] * 10,
pop_size=50,
max_iter=200
)
# Run optimization
result = optimizer.optimize()
print(f"Best fitness: {result['best_fitness']:.6e}")