SciML/Optimization.jl

Add `sense` support for all algorithms

オープン

#976 opened on 2023/06/01

 (4 件のコメント) (1 件のリアクション) (1 人の担当者)Julia (99 件のフォーク)batch import
good first issue

Repository metrics

Stars
 (824 個のスター)
PR merge metrics
 (平均マージ 2d 1h) (30d で 20 merged PRs)

説明

Currently sense is only supported for a subset of algorithms. This breaks the common interface as some solvers solve min vs max. Furthermore, since sense is a kwarg for OptimizationProblem and not solve, the interface and docs give the impression that it is supported for all algorithms.

using Optimization, OptimizationBBO

J(x,p) = x

F = OptimizationFunction(J)
prob = Optimization.OptimizationProblem(F, 0.0; lb = -10, ub =10, sense = MaxSense)
solve(prob, BBO_adaptive_de_rand_1_bin_radiuslimited()).objective # -10.0

コントリビューターガイド