Discussing the article: "Competitive Swarm Optimizer (CSO)"

 

Check out the new article: Competitive Swarm Optimizer (CSO).

The article discusses the Competitive Swarm Optimizer — a swarm optimization algorithm based on an extremely simple idea: agents are randomly paired, and the loser learns from the winner and is drawn toward the center of the swarm. In addition to analyzing CSO, the article describes the modernization of the test bench: visualization of the algorithms’ operation has been moved into 3D space, making it possible to clearly observe the movement of the population on the surface of the test function.

Selecting parameters for a trading system is a task faced by everyone who works with algorithmic trading. Metaheuristics handle it quite well at the start: during the first few iterations, the population quickly finds a decent solution. But then a familiar pattern begins: the algorithm “sticks.” Agents converge on the global leader, population diversity drops sharply, and the remaining run budget is wasted: there are no improvements, and there is no way to escape the local extremum.

The cause of this pathology in the classic PSO is well known: at every step, each agent is directly attracted to the global leader. Information about the best solution spreads instantly throughout the entire population — and just as instantly kills exploratory activity. Our testable hypothesis is this: if we remove direct attraction toward the global leader and replace it with local competition between random pairs of agents, can we maintain population diversity long enough to keep the algorithm from getting stuck under a fixed computational budget?

This is precisely the mechanism proposed by the Competitive Swarm Optimizer (CSO), introduced in 2014 by Ran Cheng and Yaochu Jin. In each epoch, agents are randomly split into pairs; the loser learns from the winner and is gently drawn toward the swarm center — the only global reference point — while the winner is not changed at all. Information about good solutions isn't shared directly, but rather through a chain of meetings.

To test the hypothesis, we implemented CSO in MQL5 as a class compatible with the unified test bench and conducted reproducible experiments on a standard set of functions: Hilly, Forest, and Megacity in three dimensionality modes—5, 25, and 500 coordinates. The evaluation criteria are the quality of the solution with a fixed number of objective function evaluations and the stability of the result across repeated runs. In addition, the article describes the modernization of the test bench: the visualization of the algorithms’ operation has been transferred to a three-dimensional space, allowing for a clear observation of the population’s movement directly on the surface of the test function.


Author: Andrey Dik