A Reference Vector Guided Evolutionary Algorithm for Many-objective Optimization
- 目标函数
- 预备知识
- 参考向量引导选择
- 更新参考向量
- 流程
- 整体框架
- 参考向量引导选择
- 参考向量自适应
for Many-objective Optimization)
目标函数
min X f ( X ) = ( f 1 ( X ) , f 2 ( X ) , . . . , f M ( X ) ) \min_{\small{X}} \pmb{f(\small{X})} = (f_1(\small{X}), f_2(\small{X}), ..., f_M(\small{X})) Xminf(X)=(f1(X),f2(X),...,fM(X))
预备知识
参考向量个数 N = C H + M − 1 M − 1 N = C_{H+M-1}^{M-1} N=CH+M−1M−1, H H H 为边长分成的份数, M M M是目标的个数
from pymoo.algorithms.moo.rvea import RVEA
from pymoo.optimize import minimize
from pymoo.problems import get_problem
from pymoo.util.ref_dirs import get_reference_directions
from pymoo.visualization.scatter import Scatter
problem = get_problem("dtlz1", n_obj=3)
ref_dirs = get_reference_directions("das-dennis", 3, n_partitions=12)
algorithm = RVEA(ref_dirs)
res = minimize(problem,
algorithm,
termination=('n_gen', 400),
seed=1,
verbose=False)
plot = Scatter()
plot.add(problem.pareto_front(ref_dirs), plot_type="surface", color="black", alpha=0.7)
plot.add(res.F, color="red")
plot.show(block=True)
此代码中 H = n _ p a r t i t i o n s = 12 M = n _ o b j = 3 H =n\_partitions = 12 \;\;\;\; M = n\_obj = 3 H=n_partitions=12M=n_obj=3
故最终的参考向量个数 N = C 12 + 3 − 1 3 − 1 = C 14 2 = 91 N = C_{12+3-1}^{3-1} = C_{14}^2 = 91 N=C12+3−13−1=C142=91
每个参考向量需要单位化: v i = u i ∣ ∣ u i ∣ ∣ v_i=\frac{u_i}{ ||u_i||} vi=∣∣ui∣∣ui
参考向量的相似度 c o s θ = v 1 ∙ v 2 ∣ ∣ v 1 ∣ ∣ ∣ ∣ v 2 ∣ ∣ cos \theta = \frac{\pmb{v_1} \bullet\pmb{ v_2}}{||\pmb{v_1} ||||\pmb{v_2}||} cosθ=∣∣v1∣∣∣∣v2∣∣v1∙v2
参考向量引导选择
-
理想向量: Z t m i n = ( Z t , 1 m i n , Z t , 2 m i n , . . . , Z t , m m i n ) \small{Z_t^{min}} = (\small{Z_{t, 1}^{min}}, \small{Z_{t, 2}^{min}}, ..., \small{Z_{t, m}^{min}}) Ztmin=(Zt,1min,Zt,2min,...,Zt,mmin)代表每个目标函数的最小值组成的向量
-
目标向量平移:因为参考向量是以坐标系原点为中心的,因此需要将目标函数都平移到坐标系原点: f t , i ′ = f t , i − Z t m i n \text{f}_{t, i}^{\prime} = \text{f}_{t, i} - \small{Z_t^{min}} ft,i′=ft,i−Ztmin, f t , i \text{f}_{t, i} ft,i表示第 t t t次迭代中第 i i i个个体的目标函数向量
-
种群划分:种群里面的每个个体按照到参考向量的最小夹角,与离得最近的目标向量归为一个集合体【与目标向量的余弦值最大】
c o s θ t , i , j = f t , i ′ ∙ v t , j ∣ ∣ f t , i ′ ∣ ∣ P ˉ t , k = { I t , i ∣ k = argmax i ∈ { 1 , 2 , . . . , N } c o s θ t , i , j } \begin{align} cos \theta_{t, i, j} &= \frac{\text{f}_{t, i}^{\prime} \bullet \pmb{v}_{t, j}}{||\text{f}_{t, i}^{\prime}||} \\ \bar{P}_{t, k} &= \{I_{t, i}|k = \underset{i \in \{1, 2, ..., N\}}{\text{argmax}} cos \theta_{t, i, j}\} \end{align} cosθt,i,jPˉt,k=∣∣ft,i′∣∣ft,i′∙vt,j={It,i∣k=i∈{1,2,...,N}argmaxcosθt,i,j} -
角度惩罚距离
d t , i , j = ( 1 + P ( θ t , i , j ) ) ∙ ∣ ∣ f t , i ′ ∣ ∣ P ( θ t , i , j ) = M . ( t t m a x ) α . θ t , i , j γ v t , j γ v t , j = min i ∈ { 1 , 2 , . . . , N } , i ≠ j < v t , i , v t , j > 最小角 \begin{align} d_{t, i, j} &= (1 + P(\theta_{t, i, j})) \bullet ||\text f_{t, i}^{\prime}|| \\ P(\theta_{t, i, j}) &= M . (\frac{t}{t_{max}}) ^\alpha . \frac{\theta_{t, i, j}}{\gamma_{\pmb v_{t, j}}} \\ \gamma_{\pmb v_{t, j}} &= \min_{i \in \{1, 2, ..., N\}, i \neq j} <\pmb v_{t, i}, \pmb v_{t, j}> \;\;\;\; \text{最小角} \end{align} dt,i,jP(θt,i,j)γvt,j=(1+P(θt,i,j))∙∣∣ft,i′∣∣=M.(tmaxt)α.γvt,jθt,i,j=i∈{1,2,...,N},i=jmin<vt,i,vt,j>最小角
更新参考向量
v t + 1 , i = v 0 , i ∘ ( Z t + 1 m a x − Z t + 1 m i n ) ∣ ∣ v 0 , i ∘ ( Z t + 1 m a x − Z t + 1 m i n ) ∣ ∣ \pmb v_{t+1, i} = \frac{\pmb v_{0, i} \circ (\small Z_{t+1}^{max} - Z_{t+1}^{min})}{||\pmb v_{0, i} \circ (\small Z_{t+1}^{max} - Z_{t+1}^{min})||} vt+1,i=∣∣v0,i∘(Zt+1max−Zt+1min)∣∣v0,i∘(Zt+1max−Zt+1min)
流程
整体框架
参考向量引导选择
参考向量自适应
fr
通常设置为
0.2
0.2
0.2