Skip to content

Commit a98b2ba

Browse files
committed
Fix a PSO bug in init_step
1 parent 5faa46c commit a98b2ba

File tree

1 file changed

+1
-1
lines changed
  • src/evox/algorithms/so/pso_variants

1 file changed

+1
-1
lines changed

src/evox/algorithms/so/pso_variants/pso.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,4 +112,4 @@ def init_step(self):
112112
"""
113113
self.fit = self.evaluate(self.pop)
114114
self.local_best_fit = self.fit
115-
self.global_best_fit = torch.min(self.fit)
115+
self.global_best_location, self.global_best_fit = min_by([self.pop], [self.fit])

0 commit comments

Comments
 (0)