Skip to content

Collections of well known metaheuristic algorithms fully written in Python. Including Particle Swarm Optimization (PSO), Differential Evolution (DE), Evolution Strategies (ES), FIrefly Algorithm (FA), etc, and some of their variations.

License

Notifications You must be signed in to change notification settings

kanemasa1987/Meatpie

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Meatpie

Collections of well known metaheuristic algorithms fully written in Python. Including Particle Swarm Optimization (PSO), Differential Evolution (DE), Evolution Strategies (ES), FIrefly Algorithm (FA), etc, and some of their variations.

Constraints

Use penalty method for the constraints you have. The algorithm's initial points are set in x \in (0,1). Make sure you rescale the variables.

Code

import optlib.de

class ObjectiveFunction: def call(self,x): return sum(x) def dim(self): #dimension of optimization problem return 10

iteration=1000 population=20 opt = optlib.de.De(iteration,pop) vec = opt.run(ObjectiveFunction())

print(vec)

About

Collections of well known metaheuristic algorithms fully written in Python. Including Particle Swarm Optimization (PSO), Differential Evolution (DE), Evolution Strategies (ES), FIrefly Algorithm (FA), etc, and some of their variations.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages