# Kernel Geometric Mean Metric Learning
## 3 Main Results
### Extension to Weighted Geometric Mean and Solution  
To incorporate the weighted geometric mean, it is necessary to take into account the determination of weights for the objective function. When assigning linear weights for \(S_{\Phi}{}^{-1}\) and \(D_{\Phi}\), only the metric matrix \(M_{\Phi}\) can be uniformly scaled by a constant factor. Consequently, it is illogical to assign linear weights to the two components in Equation (5). Nevertheless, by employing nonlinear weights derived from the SPD manifold Riemannian geometry, the weights can be transformed into trade-offs between the two terms. Thus, the Riemann distance \(\delta_{R}\) is introduced, and the problem of finding the minimum value of \(h(M_{\Phi})\) is equivalent to solving the minimum value of the following optimization problem:  
\[\min_{M_{\Phi}\succeq 0}\delta_{R}^{2}\Big{(}M_{\Phi},S_{\Phi}{}^{-1}\Big{)}+ \delta_{R}^{2}(M_{\Phi},D_{\Phi}), \tag{11}\]  
where the Riemannian distance between SPD matrices \(X\) and \(Y\) is denoted by \(\delta_{R}^{2}(X,Y)=\left\|\log\Big{(}Y^{-1/2}XY^{-1/2}\Big{)}\right\|_{F}\), and \(\left\|.\right\|_{F}\) is the Frobenius norm of a matrix. A linear parameter \(t\in[0,1]\) is introduced to trade off the relationship of the two terms in the formula:  
\[\min_{M_{\Phi}\succeq 0}\left(1-t\right)\delta_{R}^{2}\Big{(}M_{\Phi},S_{\Phi}{}^{ -1}\Big{)}+t\delta_{R}^{2}(M_{\Phi},D_{\Phi})\ \overset{\triangle}{=}\min_{M_{\Phi}>0}h_{t}(M_{\Phi}). \tag{12}\]Because \(h_{t}(M_{\Phi})\) is still geodesically convex [17], Equation (12) has a unique positive solution, that is,  
\[M_{\Phi}=S_{\Phi}{}^{-1}\sharp_{t}D_{\Phi}. \tag{13}\]  
The solution \(M_{\Phi}=S_{\Phi}{}^{-1}\sharp_{t}D_{\Phi}\) of the objective function (5) can be rewritten as  
\[M_{\Phi}=Q_{\Phi}\Big{(}K_{P\Q}{}^{\T}K_{PQ}\Big{)}^{t-1}Q_{\Phi}{}^{\T},\]  
where the kernel matrix \(K_{PQ}=P_{\Phi}{}^{\T}Q_{\Phi}=K_{P_{1}Q_{1}}-K_{P_{1}Q_{2}}-K_{P_{2}Q_{1}}+K _{P_{2}Q_{2}}\),  
\[P_{\Phi}=[\Phi(x_{11})\Phi(x_{12})\cdots\Phi(x_{1n})]-[\Phi(x_{21 })\Phi(x_{22})\cdots\Phi(x_{2n})]\stackrel{{\triangle}}{{=}}P_{ \Phi 1}-P_{\Phi 2},\] \[Q_{\Phi}=[\Phi(\bar{x}_{11})\Phi(\bar{x}_{12})\cdots\[PERSON](\bar{x }_{1m})]-[\[PERSON](\bar{x}_{21})\[PERSON](\bar{x}_{22})\cdots\[PERSON](\bar{x}_{2m})] \stackrel{{\triangle}}{{=}}Q_{\Phi 1}-Q_{\Phi 2},\text{and}\]  
\[K_{P_{1}Q_{1}}=P_{\Phi 1}{}^{\T}Q_{\Phi 1}=\left[ \begin{array}{ccc} \langle\[PERSON](x_{11}),\[PERSON](\bar{x}_{11})\rangle&\cdots&\langle\[PERSON](x_{11}),\[PERSON]( \bar{x}_{1m})\rangle\\ \vdots&\ddots&\vdots\\ \langle\[PERSON](x_{1n}),\[PERSON](\bar{x}_{11})\rangle&\cdots&\langle\[PERSON](x_{1n}),\[PERSON]( \bar{x}_{1m})\rangle\end{array} \right]=\left[ \begin{array}{ccc}k(x_{11}, \bar{x}_{11})&\cdots&k(x_{11},\bar{x}_{1m})\\ \vdots&\ddots&\vdots\\ k(x_{1n},\bar{x}_{11})&\cdots&k(x_{1m},\bar{x}_{1m})\end{array} \right]\] \[K_{P_{1}Q_{2}}=P_{\Phi 1}{}^{\T}Q_{\Phi 2}=\left[ \begin{array}{ccc} \langle\[PERSON](x_{11}),\[PERSON](\bar{x}_{21})\rangle&\cdots&\langle\[PERSON](x_{11}),\[PERSON]( \bar{x}_{2m})\rangle\\ \vdots&\ddots&\vdots\\ \langle\[PERSON](x_{1n}),\[PERSON](\bar{x}_{21})\rangle&\cdots&\langle\[PERSON](x_{1n}), \[PERSON](\bar{x}_{2m})\rangle\end{array} \right]=\left[ \begin{array}{ccc}k(x_{11}, \bar{x}_{21})&\cdots&k(x_{11},\bar{x}_{2m})\\ \vdots&\ddots&\vdots\\ k(x_{1n},\bar{x}_{21})&\cdots&k(x_{1n},\bar{x}_{2m})\end{array} \right]\] \[K_{P_{2}Q_{1}}=P_{\Phi 2}{}^{\T}Q_{\Phi 1}=\left[ \begin{array}{ccc} \langle\[PERSON](x_{21}),\[PERSON](\bar{x}_{11})\rangle&\cdots&\langle\[PERSON](x_{21}),\[PERSON]( \bar{x}_{1m})\rangle\\ \vdots&\ddots&\vdots\\ \langle\[PERSON](x_{2n}),\[PERSON](\bar{x}_{21})\rangle&\cdots&\langle\[PERSON](x_{2n}), \[PERSON](\bar{x}_{2m})\rangle\end{array} \right]=\left[ \begin{array}{ccc}k(x_{21},\bar{x}_{21})&\cdots&k(x_{21},\bar{x}_{2m})\\ \vdots&\ddots&\vdots\\ k(x_{2n},\bar{x}_{21})&\cdots&k(x_{2n},\bar{x}_{2m})\end{array} \right]\]  
According to Lemma 1,  
\[