Repository navigation
ParticleSwarm: clamp c2 to 3/2 when it falls below 3/2 - #1294
Merged
Merged
Conversation
Contributor
Benchmark Results (Julia vlts)Time benchmarks
Memory benchmarks
A plot of the benchmark results has been uploaded as an artifact at . |
Contributor
Benchmark Results (Julia v1)Time benchmarks
Memory benchmarks
A plot of the benchmark results has been uploaded as an artifact at . |
Member
|
Thanks |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #1294 +/- ##
==========================================
+ Coverage 87.51% 87.53% +0.01%
==========================================
Files 52 52
Lines 5032 5032
==========================================
+ Hits 4404 4405 +1
+ Misses 628 627 -1 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Contributor
Author
|
Thank you. The |
Member
|
shoudl work if you rebase |
inayatku
force-pushed
the
pso-c2-clamp
branch
from
October 21, 2026 16:51
f057a36 to
1976c6b
Compare
Contributor
Author
|
Rebased onto master. Thank you. |
Member
|
thanks! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #1203.
update_swarm_params!clamps the coefficientsc1andc2to[3/2, 5/2]. Forc1a value below3/2is set to3/2, but forc2it was set to5/2. So wheneverc2fell below3/2(it decreases in states 1, 2 and 4), it jumped to the upper end, and the rescaling forc1 + c2 > 4then also loweredc1.This sets
c2to3/2, as forc1.New test: starting from
c1 = c2 = 3/2, states 1 and 4 must leavec2at3/2. On master the test givesc2 = 2.46andc2 = 2.5. The particle swarm tests pass (10 of 10).