https://github.com/aresio/fst-pso

A settings-free global optimization method based on PSO and fuzzy logic

https://github.com/aresio/fst-pso

Science Score: 59.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
    Found 2 DOI reference(s) in README
  • Academic publication links
    Links to: sciencedirect.com, springer.com
  • Committers with academic emails
    1 of 3 committers (33.3%) from academic institutions
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (9.8%) to scientific vocabulary

Keywords

fuzzy-logic global-optimization-algorithms particle-swarm-optimization swarm-intelligence-algorithms
Last synced: 6 months ago · JSON representation

Repository

A settings-free global optimization method based on PSO and fuzzy logic

Basic Info
  • Host: GitHub
  • Owner: aresio
  • License: lgpl-3.0
  • Language: Python
  • Default Branch: master
  • Homepage:
  • Size: 128 KB
Statistics
  • Stars: 39
  • Watchers: 6
  • Forks: 22
  • Open Issues: 5
  • Releases: 1
Topics
fuzzy-logic global-optimization-algorithms particle-swarm-optimization swarm-intelligence-algorithms
Created over 8 years ago · Last pushed 9 months ago
Metadata Files
Readme Changelog License

README.md

FST-PSO

Fuzzy Self-Tuning PSO (FST-PSO) is a swarm intelligence global optimization method [1] based on Particle Swarm Optimization [2].

FST-PSO is designed for the optimization of real- or discrete-valued multi-dimensional minimization problems.

FST-PSO is settings-free version of PSO which exploits fuzzy logic to dynamically assign the functioning parameters to each particle in the swarm. Specifically, during each generation, FST-PSO determines the optimal choice for the cognitive factor, the social factor, the inertia value, the minimum velocity, and the maximum velocity. FST-PSO also uses an heuristics to choose the swarm size, so that the user must not select any functioning setting.

In order to use FST-PSO, the programmer must implement a custom fitness function and specify the boundaries of the search space for each dimension. The programmer can optionally specify the maximum number of iterations and the swarm size. When the stopping criterion is met, FST-PSO returns the best fitting solution found, along with its fitness value. In the case of discrete problems, FST-PSO also returns the probability distributions of the underlying generative model.

Example

FST-PSO can be used as follows:

from fstpso import FuzzyPSO 

def example_fitness( particle ):
    return sum(map(lambda x: x**2, particle))

if __name__ == '__main__':
    dims = 10
    FP = FuzzyPSO()
    FP.set_search_space( [[-10, 10]]*dims ) 
    FP.set_fitness(example_fitness)
    result =  FP.solve_with_fstpso()
    print("Best solution:", result[0])
    print("Whose fitness is:", result[1])

Installing FST-PSO

pip install fst-pso

FFT-PSO

Fuzzy Time Travel PSO (FFT-PSO) is a variant of FST-PSO that explores different optimization scenarios starting from the same initial population where only the particle that lead to the best solution found is randomly changed [3].

FFT-PSO works under the assumption that premature convergence could be prevented by backtracking to the beginning of an optimization and removing the particle that was ultimately responsible for leading the whole swarm to a stalling condition.

FFT-PSO provides the same interface of FST-PSO, with the only exception in the creation of the object. Indeed, in the object initializer the programmer can specify the additional paramter alpha, that is, either the number or iterations (if it is an int) or a percentage (if it is a float) of iterations after that the swarm is rewinded to the initial state and the particle leading to the stall is randomly re-initialized.

Example

FFT-PSO can be used as follows:

from fstpso import FFTPSO   

def example_fitness( particle ):
    return sum(map(lambda x: x**2, particle))

if __name__ == '__main__':
    dims = 10
    FP = FFTPSO()
    FP.set_search_space( [[-10, 10]]*dims ) 
    FP.set_fitness(example_fitness)
    result =  FP.solve_with_fstpso(max_iter=200)
    print("Best solution:", result[0])
    print("Whose fitness is:", result[1])

Further information

FST-PSO has been created by M.S. Nobile, D. Besozzi, G. Pasi, G. Mauri, R. Colombo (University of Milan-Bicocca, Italy), and P. Cazzaniga (University of Bergamo, Italy). The source code is written and maintained by M.S. Nobile.

Please check out the Wiki for additional descriptions.

If you need any information about FST-PSO please write to: marco.nobile@unive.it

FST-PSO requires two packages: miniful and numpy.

[1] Nobile, Cazzaniga, Besozzi, Colombo, Mauri, Pasi, "Fuzzy Self-Tuning PSO: A Settings-Free Algorithm for Global Optimization", Swarm & Evolutionary Computation, 39:70-85, 2018 (doi:10.1016/j.swevo.2017.09.001)

[2] Kennedy, Eberhart, Particle swarm optimization, in: Proceedings IEEE International Conference on Neural Networks, Vol. 4, 1995, pp. 1942–1948

[3] Papetti, Tangherloni, Coelho, Besozzi, Cazzaniga, Nobile, "We Are Sending You Back... to the Optimum! Fuzzy Time Travel Particle Swarm Optimization", in: García-Sánchez, P., Hart, E., Thomson, S.L. (eds) Applications of Evolutionary Computation. EvoApplications 2025. Lecture Notes in Computer Science, vol 15613

http://www.sciencedirect.com/science/article/pii/S2210650216303534

https://link.springer.com/chapter/10.1007/978-3-031-90065-5_10

Owner

  • Name: Marco S. Nobile
  • Login: aresio
  • Kind: user
  • Location: Venice, Italy
  • Company: Ca' Foscari University

I have a BS, MS and Ph.D. in Computer Science. I am a Associate Professor at the Ca' Foscari University of Venice

GitHub Events

Total
  • Release event: 1
  • Member event: 1
  • Push event: 6
  • Create event: 1
Last Year
  • Release event: 1
  • Member event: 1
  • Push event: 6
  • Create event: 1

Committers

Last synced: almost 3 years ago

All Time
  • Total Commits: 46
  • Total Committers: 3
  • Avg Commits per committer: 15.333
  • Development Distribution Score (DDS): 0.304
Top Committers
Name Email Commits
Marco S. Nobile n****e@d****t 32
MSN m****e@t****l 13
Charly Empereur-mot 4****t@u****m 1
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: 6 months ago

All Time
  • Total issues: 21
  • Total pull requests: 2
  • Average time to close issues: 2 months
  • Average time to close pull requests: 9 months
  • Total issue authors: 10
  • Total pull request authors: 2
  • Average comments per issue: 4.29
  • Average comments per pull request: 1.5
  • Merged pull requests: 1
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 1
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 1
  • Pull request authors: 0
  • Average comments per issue: 0.0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • CharlyEmpereurmot (8)
  • haskarb (2)
  • eugenpar (2)
  • saeedsltm (2)
  • DManowitz (2)
  • mbassalbioinformatics (1)
  • UKonge (1)
  • BismeetSingh (1)
  • cristina-29 (1)
  • EliasHasle (1)
Pull Request Authors
  • radarsat1 (1)
  • CharlyEmpereurmot (1)
Top Labels
Issue Labels
Pull Request Labels

Packages

  • Total packages: 1
  • Total downloads:
    • pypi 34,132 last-month
  • Total docker downloads: 13,860
  • Total dependent packages: 1
  • Total dependent repositories: 62
  • Total versions: 53
  • Total maintainers: 1
pypi.org: fst-pso

Fuzzy Self-Tuning PSO global optimization library

  • Versions: 53
  • Dependent Packages: 1
  • Dependent Repositories: 62
  • Downloads: 34,132 Last month
  • Docker Downloads: 13,860
Rankings
Downloads: 1.2%
Docker downloads count: 1.4%
Dependent repos count: 1.9%
Average: 5.7%
Forks count: 8.6%
Dependent packages count: 10.0%
Stargazers count: 11.1%
Maintainers (1)
Last synced: 6 months ago

Dependencies

setup.py pypi
  • miniful *
  • numpy *