Questions tagged [particle-swarm]

In computer science, particle swarm optimization (PSO) is a computational method that optimizes a problem by iteratively trying to improve a candidate solution with regard to a given measure of quality.

In computer science, particle swarm optimization (PSO) is a computational method that optimizes a problem by iteratively trying to improve a candidate solution with regard to a given measure of quality.

Algorithm:

Initialize all agents;
while (not maximum iterations nor minimum error )
{
    foreach(agent in agents) 
     {
        Calculate function value at agent position;
        If (value < best_value_in_history)
            best_value_in_history= value;
    }

    current_best_value= calculate best value of all current agents positions;

    foreach(agent in agents)
    { 
         agent current_velocity =
             w * current_velocity + 
             p * random_double() * (current_best_value.position - current_position) + 
             g * random_double * (best_value_in_history.position - current_position);
         update_agent_position(current_velocity);
    }

}

where w,p,g are selected by the practitioner and control the behaviour and efficacy of the PSO method.

Third party implementations:

  • RRSI is a C# project to simulate particle swarm optimization on communicating robots.
  • SwarmOps C# and ANSI C codes for several optimization methods, including a few global best PSO variants.
  • Java Based PSO Framework part of the open-source project CIlib (Computational Intelligence Library).
  • PSO visualisation applet randomly generated particle swarm of 12 particles attempts to find the "global maximum" on the landscape.
175 questions
1
vote
0 answers

How to optimize new test problem using PlatEMO?

I tried to follow the main tutorial of PlatEMO but I failed to compile it. I tried to modify an already existed function but I've got too many errors. This is the code I already tried: classdef counster < PROBLEM %HELP COUNSTER methods …
1
vote
0 answers

How can I implement clustering with PSO(Particle Swarm optimization) with a dataset in python?

I am try to implement pso in python with dataset I tried the code given below. But I am unable to use pso for a dataset(Iris /Wine). Can anyone help me?I want to implement clustering using pso in python. I am try to implement pso in python with…
1
vote
1 answer

What prevents Particle Swarm Optimization from wandering off?

I am using SAS to implement PSO, following the code given in this link I also saw the pseudo code both in Wikipedia and this website. In all three, I see that there are constrains on the location say -10 For example it can randomly happen that the…
impossibru
  • 11
  • 2
1
vote
1 answer

Integer, multi-objective optimization with Platypus (Python)

I am exploring the Platypus library for multi-objective optimization in Python. It appears to me that Platypus should support variables (optimization parameters) as integers out of the box, however this simple problem (two objectives, three…
1
vote
0 answers

Is there an accepted "current industry standard best" of stochastic optimization? (Simulated annealing, Particle swarm optimization, etc)

Sorting algorithms are well understood enough that Java Collections uses some flavor of MergeSort or Timsort. (Even though it is possible to hand-craft collections that "fight" the algorithm and perform poorly, those choices are "often enough…
Benjamin H
  • 5,164
  • 6
  • 34
  • 42
1
vote
0 answers

How to define equality constraints for integer variables in PSO

I'm using Matlab's global optimization toolbox to optimize a cost function using PSO. Some of my input variables are involved in equality constraints and they must be integers. How can I define that in PSO? I've tried to use a penalty function by…
Isra
  • 155
  • 1
  • 12
1
vote
1 answer

PSO ring topology - how does it work?

I know that the topology of the global optimum is searched for each particle and global for the entire swarm. The ring, I know that there are a few neighborhoods and searched a lbest, a local optimum. My question: Is there still a global optimum in…
Saint
  • 5,397
  • 22
  • 63
  • 107
1
vote
1 answer

How to use SwarmPackagePy in regression in python code of sklearn?

I'm able to draw a 3D animation of Firefly algorithm using SwarmPackagePy library. I want to use this algorithm to optimize the hyperparameter in Gaussian Process Regression(GPR). For this, I defined the optimizer of GPR as: alh =…
1
vote
1 answer

ANTLR3 python runtime not detected

I want to use fstpso package in python which needs ANTLR3 python runtime. I downloaded antlr_python_runtime-3.1.3.tar.gz from http://www.antlr3.org/download/Python/ and ran the command sudo python setup.py install. The output of the command…
1
vote
0 answers

Matlab and C++ yield different outcomes when optimizing Schwefel function by an algorithm similar to PSO

This question might be long and I really appreciate your patience. The core problem is I used matlab and c++ to implement an optimization algorithm but they provided me different results(matlab's better). I am recently studying some evolutionary…
ZZ32
  • 21
  • 4
1
vote
1 answer

How to choose best parameters with a differential evolution algorithm

for an assignment in class i need to optimize 4 10-dimensional functions, when implementing the differential evolution i noted that all the functions needed different parameter settings. By playing around it seemed that especially when choosing your…
1
vote
1 answer

PSO and K-means based Text Document Clustering in R

I am newbie to Particle Swarm Optimization. I read research paper on Clustering based on PSO and K-means but I did not found any working example of the same. Any kind of help is much appreciated. Thanks in advance! I want to perform text document…
Purva
  • 43
  • 1
  • 8
1
vote
1 answer

Swarm in particles swarm optimization (PSO) algorithm

In particles swarm optimization (PSO) algorithm, is it possible to use dataset to initialize the position of particles, instead of use uniform random numbers?
shdotcom
  • 125
  • 1
  • 1
  • 11
1
vote
1 answer

Huge nb of parameters, constraint and objective function : how to deal with this in Matlab?

I would like find the Alpha coefficients which minimize this objective function: fun_Obj = @(Alpha) norm(A- sum(Alpha.*B(:,:),2),2) With : A= vector 1d (69X1) B= matrice 2d (69X1000) Alpha_i a vector (1X1000) of unknown parameters, where 0 <…
1
vote
0 answers

TUNE THE PARAMETERS OF Particle swarm optimization (PSO)

To tune the parameters of Particle swarm optimization (PSO), there are two methods offline and online. In offline manner, the meta-optimization is used to tune the parameters of PSO by using another overlying optimizer. In the online manner, there…