SlowGuess/NeurIPS_2023_OCR huggingface dataset:
Remark 2.8. Our proposed REALM is a nontrivial extension of the exponential ALM from the Euclidean case [47, 20, 51, 52] to the Riemannian case. The following two differences distinguish our proposed REALM from the existing exponential ALM (e.g., the one proposed in [20]: (i) Measure of complementarity. The measure of complementarity used in our proposed REALM is motivated by the direct use of the complementarity condition adopted in the classical (quadratic) ALM, while that used in [20] is a variant of the measure for the exponential case. (ii) Conditions on global convergence. To guarantee the global convergence of the exponential ALMs, some (strong) constraint qualifications, the boundness of the iterates, and the feasibility of the limit point of the iterates generally need to be assumed; see Proposition 2.1 and Theorem 2.1 in [20] for the corresponding results. In contrast, for our considered PRW distance problem (6), we can prove the boundness of the iterates generated by REALM without making the assumption and establish the global convergence of REALM without explicitly dealing with the constraint qualification assumption. This advantage is mainly due to the essential changes in the proposed REALM (compared with the existing exponential ALMs), i.e., specific conditions (14) and (16) (motivated by (13b)) on the solution of subproblems and the adopted measure of complementarity.
Moreover, it would be possible to extend the analysis in [20] to prove that the penalty parameter  $\eta_{k}$  in Algorithm 1 is bounded away from zero if the Riemannian versions of the three conditions hold, including the linear independence constraint qualification, the strict complementarity condition, and the second-order sufficient condition. However, these three conditions might not be easy to check since we do not have prior knowledge of the solution.
Algorithm 1: REALM for solving problem (6).
1 Input: Choose  $\epsilon_c, \epsilon_1, \epsilon_2, \eta_1 > 0, \gamma_W, \gamma_\eta, \gamma_\epsilon \in (0,1), \epsilon_{1,1} \geq \epsilon_1, \epsilon_{1,2} \geq \epsilon_2$ . Choose  $\pi^1 = 11^\top$ ,  $\mathbf{x}^0 \in \mathcal{M}$  with  $r^\top \alpha^0 = c^\top \beta^0$ ,  $\|\zeta_{\eta_1}(\mathbf{x}^0, \pi^1)\|_1 = 1$ . Compute  $W^0$  with  $W_{ij}^0 = \min\{\eta_1, \varphi(\mathbf{x}^0)_{ij}\}$ .  
2 for  $k = 1, 2, \ldots$ , do  
3 Compute an  $(\epsilon_{k,1}, \epsilon_{k,2})$ -stationary point  $\mathbf{x}^k$  of (11) satisfying (14);  
4 Compute  $\tilde{\pi}^{k+1}$  according to (15) and compute  $W^k$ ;  
5 if  $\|W^k\|_{\mathsf{F}} \leq \epsilon_c$ ,  $\mathsf{e}_{\eta_k}^1(\mathbf{x}^k, \pi^k) \leq \epsilon_1$ ,  $\mathsf{e}_{\eta_k}^2(\mathbf{x}^k, \pi^k) \leq \epsilon_2$  then return  $\mathbf{x}^k$  and  $\pi^{k+1} = \tilde{\pi}^{k+1}$ ;  
6 if  $\|W^k\|_{\mathsf{F}} \leq \gamma_W\|W^{k-1}\|_{\mathsf{F}}$  then set  $\pi^{k+1} = \tilde{\pi}^{k+1}$ ,  $\eta_{k+1} = \eta_k$  else set  $\pi^{k+1} = \pi^k$  and update  $\eta_{k+1}$  via (16);  
7 Set  $\epsilon_{k+1,1} = \gamma_\epsilon \epsilon_{k,1}$  and  $\epsilon_{k+1,2} = \gamma_\epsilon \epsilon_{k,2}$ .
Remark 2.9. We cannot establish the iteration complexity of Algorithm 1 due to the following two main difficulties: (i) characterizing the connection between the two complementarity measures  $\| W^k\|_{\mathsf{F}}$  and  $e^{k}\coloneqq \langle \hat{\pi}^{k},Z(\mathbf{x}^{k})\rangle$  with  $\hat{\pi}^k\coloneqq \mathrm{Round}(\phi_{\eta_k}(\mathbf{x}^k,\pi^k),\Pi (r,c))$  at the approximate stationary point of the subproblem; (ii) establishing the relationship between  $\eta_k\tilde{\pi}_{ij}^{k + 1}$  and  $\varphi (\mathbf{x}^k)_{ij}$ . Thanks to Theorem 2.4, we can slightly modify Algorithm 1 to establish the iteration complexity. By modifying the "if" condition in Line 6 of Algorithm 1 as " $\| W^k\|_{\mathsf{F}}\leq \gamma_W\| W^{k - 1}\|_{\mathsf{F}}$  and  $e^k\leq \gamma_We^{k - 1}$ ", and leveraging the connection between the approximate stationary points of the subproblem and the original problem as proven in (13), we know that the modified Algorithm 1 will terminate within at most  $\mathcal{O}(\max \{\log \epsilon_1^{-1},\log \epsilon_2^{-1},T_k\})$  iterations, where  $T_{k}\coloneqq \min \{k\mid \varrho_{k}\leq \epsilon_{c}\}$ .
Remark 2.10. Problem (6) can also be solved by the Riemannian ALMs based on the quadratic penalty function [37, 55]. However, the subproblems therein have four blocks of the variable, i.e.,  $(\alpha, \beta, y, U)$ , and some customized solvers are needed to solve them. Moreover, the connections between the stationary points of problem (1) and the subproblems therein remain unclear.
3 A Practical iRBBS for Solving Subproblem (11)
At first glance, (11) is a three-block optimization problem and can be solved by R(A)BCD proposed by [28]. However, as stated therein, tuning the stepsizes for updating  $U$  is not easy for R(A)BCD. In sharp contrast, we understand (11) as optimization with only one variable  $U$  as follows:
$$
\min  _ {U \in \mathcal {U}} \left\{q (U) := \min  _ {\alpha \in \mathbb {R} ^ {n}, \beta \in \mathbb {R} ^ {n}} \mathcal {L} _ {\eta_ {k}} (\mathbf {x}, \pi^ {k}) \right\}. \tag {17}
$$
By [34, Lemma 3.1], we know that  $q(\cdot)$  is differentiable over  $\mathbb{R}^{d \times k}$ . Here, we give a new formulation of  $\operatorname{grad} q(U)$ , which can provide more insights into approximating  $\operatorname{grad} q(U)$ .
Lemma 3.1. Let  $(\alpha_U^*,\beta_U^*)\in \mathrm{argmin}_{\alpha \in \mathbb{R}^n,\beta \in \mathbb{R}^n}\mathcal{L}(\mathbf{x},\pi^k)$  and  $\mathbf{x}_U^* = (\alpha_U^*,\beta_U^*,U)$ . Then we have  $\operatorname {grad}q(U) = \operatorname {grad}_U\mathcal{L}_{\eta_k}(\mathbf{x}_U^*,\pi^k) = \operatorname{Proj}_{\mathrm{T}_U\mathcal{U}}(-2V_{\phi_{\eta_k}(\mathbf{x}_U^*,\pi^k)}U)$ .
Hence we could use the Riemannian gradient descent (RGD) method [2] to solve problem (11). Letting  $\tau_t > 0$  be some stepsize, the main iterations of RGD are given as
$$
U ^ {t + 1} = \operatorname {R e t r} _ {U ^ {t}} \left(- \tau_ {t} \operatorname {g r a d} q \left(U ^ {t}\right)\right). \tag {18}
$$
However, RGD (18) needs to calculate  $(\alpha_U^*, \beta_U^*)$  exactly, which can be challenging (or might be unnecessary) to do. Motivated by the well-established inexact gradient type methods for optimization in the Euclidean space [11, 26, 46, 17, 39, 7, 52], we propose an inexact RGD framework. Let  $\mathbf{x}^t = (\alpha^t, \beta^t, U^t)$  with  $(\alpha^t, \beta^t) \approx (\alpha_{U^t}^*, \beta_{U^t}^*)$ , wherein the inexactness level is determined by  $\mathsf{e}_{\eta_k}^2(\mathbf{x}^t, \pi^k) = \|\nabla_\alpha \mathcal{L}_{\eta_k}(\mathbf{x}^t, \pi^k)\|_1 + \|\nabla_\beta \mathcal{L}_{\eta_k}(\mathbf{x}^t, \pi^k)\|_1 \leq \theta_t$  for given  $\theta_t$ . By Lemma 3.1, we use
$$
\xi^ {t} := \operatorname {g r a d} _ {U} \mathcal {L} _ {\eta_ {k}} (\mathbf {x} ^ {t}, \pi^ {k}) = \operatorname {P r o j} _ {\mathrm {T} _ {U ^ {t}} \mathcal {U}} \left(- 2 V _ {\phi_ {\eta_ {k}} (\mathbf {x} ^ {t}, \pi^ {k})} U ^ {t}\right)
$$
to approximate  $\operatorname{grad} q(U^t)$ . Then, we perform an inexact RGD with  $\operatorname{grad} q(U^t)$  in (18) replaced by  $\xi^t$ . More specifically, given the inexactness parameter  $\theta_{t+1} \geq 0$  and the stepsize  $\tau_t \geq 0$ , we update  $\mathbf{x}^{t+1} = (\alpha^{t+1}, \beta^{t+1}, U^{t+1})$  with  $U^{t+1}$  and  $(\alpha^{t+1}, \beta^{t+1}) \approx (\alpha_{U^{t+1}}^*, \beta_{U^{t+1}}^*)$  satisfying
$$
U ^ {t + 1} = \operatorname {R e t r} _ {U ^ {t}} \left(- \tau_ {t} \xi^ {t}\right), \quad (\text {i n e x a c t R G D s t e p}) \tag {19a}
$$
$$
\mathrm {e} _ {\eta_ {k}} ^ {2} \left(\mathbf {x} ^ {t + 1}, \pi^ {k}\right) \leq \theta_ {t + 1}. \quad \text {(i n e x a c t n e s s c r i t e r i o n)} \tag {19b}
$$
To make iRGD (19) practical, the first main ingredient is how to compute  $(\alpha^{t + 1},\beta^{t + 1})$  such that (19b) holds. Given  $U^{t + 1}\in \mathcal{U}$ ,  $\alpha^{(0)} = \alpha^t$ , and  $\beta^{(0)} = \beta^t$ , for  $\ell = 0,1,\ldots$ , we adopt the block coordinate descent method to update
$$
\alpha^ {(\ell + 1)} = \underset {\alpha \in \mathbb {R} ^ {n}} {\operatorname {a r g m i n}} \mathcal {L} _ {\eta_ {k}} (\alpha , \beta^ {(\ell)}, U ^ {t + 1}, \pi^ {k}), \quad \beta^ {(\ell + 1)} = \underset {\beta \in \mathbb {R} ^ {n}} {\operatorname {a r g m i n}} \mathcal {L} _ {\eta_ {k}} (\alpha^ {(\ell + 1)}, \beta , U ^ {t + 1}, \pi^ {k}). \tag {20}
$$
Note that  $\alpha^{(\ell +1)}$  and  $\beta^{(\ell +1)}$  admit the closed-form solutions as follows:
$$
\alpha^ {(\ell + 1)} = \alpha^ {(\ell)} - \eta_ {k} \log r + \eta_ {k} \log \left(\zeta^ {(\ell)} \mathbf {1}\right), \quad \beta^ {(\ell + 1)} = \beta^ {(\ell)} - \eta_ {k} \log c + \eta_ {k} \log \left(\left(\zeta^ {(\ell + \frac {1}{2})}\right) ^ {\top} \mathbf {1}\right), \tag {21}
$$
where  $\zeta^{(\ell)}\coloneqq \zeta_{\eta_k}(\alpha^{(\ell)},\beta^{(\ell)},U^{t + 1},\pi^k)$  and  $\zeta^{(\ell +\frac{1}{2})}\coloneqq \zeta_{\eta_k}(\alpha^{(\ell +1)},\beta^{(\ell)},U^{t + 1},\pi^k)$  (see (7) for its definition). Note that for fixed  $U^{t + 1}$  and  $\pi^k = \mathbf{11}^\top$  , (21) reduces to the famous Sinkhorn iteration [15]. Therefore, we still name (21) as the Sinkhorn iteration. It is easy to verify that  $\| \zeta^{(\ell +\frac{1}{2})}\| _1 = \| \zeta^{(\ell +1)}\| _1 = 1$  (see also [28, Remark 3.1]). By (12), we have
$$
\pi^ {(\ell + \frac {1}{2})} := \phi_ {\eta_ {k}} (\alpha^ {(\ell + 1)}, \beta^ {(\ell)}, U ^ {t + 1}, \pi^ {k}) = \zeta^ {(\ell + \frac {1}{2})}, \pi^ {(\ell + 1)} := \phi_ {\eta_ {k}} (\alpha^ {(\ell + 1)}, \beta^ {(\ell + 1)}, U ^ {t + 1}, \pi^ {k}) = \zeta^ {(\ell + 1)}. \tag {22}
$$
From the update of  $\beta^{(\ell +1)}$ , we have  $(\pi^{(\ell +1)})^{\mathsf{T}}\mathbf{1} - c = 0$ . Therefore, to make condition (19b) hold, we stop the Sinkhorn iteration once
$$
\left\| \pi^ {(\ell + 1)} \mathbf {1} - r \right\| _ {1} \leq \theta_ {t + 1}, \tag {23}
$$
and set  $\alpha^{t + 1} = \alpha^{(\ell +1)},\beta^{t + 1} = \beta^{(\ell +1)}$ . Recalling the calculation of the gradient and the definition of  $\mathbf{e}_{\eta_k}^2 (\mathbf{x}^{t + 1},\pi^k)$  after (12), we have
$$
\mathsf {e} _ {\eta_ {k}} ^ {2} (\mathbf {x} ^ {t + 1}, \boldsymbol {\pi} ^ {k}) = \| \boldsymbol {\pi} ^ {(\ell + 1)} \mathbf {1} - r \| _ {1}.
$$
Next, we choose the stepsize  $\tau_{t}$  in (19a). Since the accurate function and gradient information of  $q(U^{t}) = \mathcal{L}_{\eta_{k}}(\mathbf{x}_{U^{t}}^{*},\pi^{k})$  is unavailable, we cannot expect to build the linesearch condition based on  $q(U^{t})$  and need to find some appropriate potential function instead. Considering that  $\mathcal{L}_{\eta_k}(\mathbf{x}^t,\pi^k)$  is an approximation of  $q(U^{t})$  and the approximation error is controlled by  $\mathsf{e}_{\eta_k}^2 (\mathbf{x}^t,\pi^k)$ , it is thus desirable that some combinations of  $\mathcal{L}_{\eta_k}(\mathbf{x}^t,\pi^k)$  and  $\mathsf{e}_{\eta_k}^2 (\mathbf{x}^t,\pi^k)$  will be smaller than the corresponding values at the previous iteration. Given  $\rho \in [0,\eta_k / 2)$ , we define the potential function as
$$
E _ {\rho} \left(\mathbf {x} ^ {t}\right) = \mathcal {L} _ {\eta_ {k}} \left(\mathbf {x} ^ {t}, \pi^ {k}\right) + \rho \left(\mathrm {e} _ {\eta_ {k}} ^ {2} \left(\mathbf {x} ^ {t}, \pi^ {k}\right)\right) ^ {2} \tag {24}
$$
and require the stepsize  $\tau_{t}$  to satisfy the following nonmonotone line search condition:
$$
E _ {\rho} \left(\mathbf {x} ^ {t + 1}\right) \leq E _ {t} ^ {r} - \delta_ {1} \tau_ {t} \| \xi^ {t} \| _ {\mathsf {F}} ^ {2} - \left(\frac {\eta_ {k}}{2} - \rho\right) \left(\mathrm {e} _ {\eta_ {k}} ^ {2} \left(\mathbf {x} ^ {t + 1}, \pi^ {k}\right)\right) ^ {2}, \tag {25}
$$
where  $E_{t + 1}^{r} = (\gamma Q_{t}E_{t}^{r} + E_{\rho}(\mathbf{x}^{t + 1})) / Q_{t + 1}$  and  $Q_{t + 1} = \gamma Q_{t} + 1$  with a constant  $\gamma \in [0,1)$  and  $E_0^r = E_\rho (\mathbf{x}^0),Q_0 = 1$ ; see [54]. Such  $\tau_{t}$  can be found by adopting the simple backtracking line search technique starting from an initial guess of the stepsize  $\tau_t^{(0)}$ . Owing to the excellent performance of the BB method in Riemannian optimization [50, 32, 23, 25, 31, 24], we choose the initial guess  $\tau_t^{(0)}$  for  $t\geq 1$  as a new Riemannian BB stepsize with safeguards:
$$
\tau_ {t} ^ {(0)} = \min  \left\{\max  \left\{\tau_ {t} ^ {\mathrm {B B}}, \tau_ {\min } \right\}, \tau_ {\max } \right\}, \tag {26}
$$
where  $\tau_{\mathrm{max}} > \tau_{\mathrm{min}} > 0$  are preselected stepsize safeguards and  $\tau_1^{\mathrm{BB}} = \tau_1^{\mathrm{BB2}}$  and for  $t\geq 2$  we set  $\tau_t^{\mathrm{BB}} = \min \{\tau_{t - 1}^{\mathrm{BB2}},\tau_t^{\mathrm{BB2}},\max \{\tau_t^{\mathrm{new}},0\} \}$  if  $\tau_t^{\mathrm{BB2}} <   \varkappa_t\tau_t^{\mathrm{BB1}}$  and set  $\tau_t^{\mathrm{BB}} = \tau_t^{\mathrm{BB1}}$  otherwise. Here,  $\tau_t^{\mathrm{BB1}} = \| U^t -U^{t - 1}\|_{\mathbb{F}}^2 /|\langle U^t -U^{t - 1},\xi^t -\xi^{t - 1}\rangle |,\tau_t^{\mathrm{BB2}} = |\langle U^t -U^{t - 1},\xi^t -\xi^{t - 1}\rangle | / \| \xi^t -\xi^{t - 1}\|_{\mathbb{F}}^2,$  and  $\tau_{t}^{\mathrm{new}}$  is chosen according to [30, Eq. (2.15)]. In our numerical tests, we set the initial  $\varkappa_{t}$  to be 0.05 and update  $\varkappa_{t + 1} = \varkappa_t / 1.02$  if  $\tau_t^{\mathrm{BB2}} / \tau_t^{\mathrm{BB1}} <   \varkappa_t$  and update  $\varkappa_{t + 1} = 1.02\varkappa_t$  otherwise.
We are ready to summarize the complete iRBBS in Algorithm 2. The overall complexity of Algorithm 2 to find an  $(\epsilon_1,\epsilon_2)$ -stationary point of problem (1) is in the same order as that of R(A)BCD.
Theorem 3.2. By choosing  $\epsilon_{1} = \epsilon_{1}^{\prime} / 2$ ,  $\epsilon_{2} = \min \{\epsilon_{1}^{\prime} / (4\| C\|_{\infty}),\epsilon_{2}^{\prime} / (4\eta_{k}\Psi +6\| C\|_{\infty})\}$  with  $\Psi = \|\log \pi^{k}\|_{\mathrm{var}} + \max \{\|\log r\|_{\mathrm{var}},\|\log c\|_{\mathrm{var}}\}$  and  $\eta_k = \epsilon_2' / (4\log n + 2\|\log \pi^k\|_{\mathrm{var}})$ , Algorithm 2 can return an  $(\epsilon_1',\epsilon_2')$ -stationary point of problem (1) in  $\mathcal{O}(T_{\epsilon_1',\epsilon_2'})$  iterations with
$$
T _ {\epsilon_ {1} ^ {\prime}, \epsilon_ {2} ^ {\prime}} = \max \left\{(\epsilon_ {1} ^ {\prime}) ^ {- 2}, (\epsilon_ {2} ^ {\prime}) ^ {- 2} \right\} (\epsilon_ {2} ^ {\prime}) ^ {- 1}.
$$
If  $\theta_t \geq 2R^t / (\eta_k(\ell_{\max} - 2 + \sqrt{2}))$  with  $\ell_{\mathrm{max}} \geq 1$  and  $R^t = \|C(U^t)\|_{\mathrm{var}} + \eta_k\Psi$ , the total number of Sinkhorn iterations is  $\mathcal{O}(\ell_{\max}T_{\epsilon_1',\epsilon_2'})$  and the total arithmetic operation complexity is  $\mathcal{O}((n^2(k + \ell_{\max}) + ndk + dk^2)T_{\epsilon_1',\epsilon_2'})$ .
Algorithm 2: A practical iRBBS for solving problem (11).
1. Input: Choose  $\tau_{\mathrm{max}} > \tau_{\mathrm{min}} > 0, \tau_0^{(0)} > 0, \epsilon_1, \epsilon_2 \geq 0, \sigma, \delta_1 \in (0,1), \rho \in [0,\eta_k / 2), \gamma \in [0,1)$  and  $(\alpha^{-1},\beta^{-1},U^0) \in \mathcal{M}$ . Set  $\alpha^{(0)} = \alpha^{-1},\beta^{(0)} = \beta^{-1}$  and perform the Sinkhorn iteration (21) at  $U^0$  until (23) holds with  $\theta_0 = 1$  for some  $\ell$ . Set  $\alpha^0 = \alpha^{(\ell +1)},\beta^0 = \beta^{(\ell +1)}$ .
2 for  $t = 0,1,\ldots$  do
3 Compute  $\xi^t = \mathrm{grad}_U\mathcal{L}_{\eta_k}(\mathbf{x}^t,\pi^k)$    
4 if  $\| \xi^t\| _F\leq \epsilon_1$  and  $\mathsf{e}_{\eta_k}^2 (\mathbf{x}^t,\pi^k)\leq \epsilon_2$  then return  $\mathbf{x}^t$  .   
5 for  $s = 0,1,\ldots$  do
6 Set  $U^{t + 1} = \mathrm{Retr}_{U^t}\left(-\tau_t\xi^t\right)$  with  $\tau_{t} = \tau_{t}^{(0)}\sigma^{s}$  and update  $\theta_{t + 1}$  (e.g., via (27) further ahead);  
7 Set  $\alpha^{(0)} = \alpha^t$  and  $\beta^{(0)} = \beta^t$  and perform the Sinkhorn iteration (21) at  $U^{t + 1}$  until (23) holds for some  $\ell$ ; set  $\alpha^{t + 1} = \alpha^{(\ell +1)}$  and  $\beta^{t + 1} = \beta^{(\ell +1)}$ .  
8 if (25) holds then break;
Remark 3.3. The basic idea of proposing Algorithm 2 is sharply different from that of R(A)BCD developed in [28]. Ours is based on the inexact RGD viewpoint, while the latter is based on the BCD approach. Such an inexact RGD viewpoint enables us to choose the stepsize adaptively via leveraging the efficient BB stepsize. Actually, tuning the best stepsize for the  $U$ -update in R(A)BCD is nontrivial. It is remarked in [28, Remark 4.1] that "the adaptive algorithms RABCD and RAGAS are also sensitive to the step size, though they are usually faster than their non-adaptive versions RBCD and RGAS." Numerical results in Section 4.1 show the higher efficiency of our iRBBS over R(A)BCD.
Remark 3.4. Although the inexact gradient type methods have been well explored in the Euclidean case [11, 26, 46, 17, 39, 7, 52], to our best knowledge, there are little results for the Riemannian case and on how to choose the step sizes adaptively for general nonlinear objective functions. One exception is R(A)GAS proposed in [34], which can be understood as the inexact RGD method. However, it needs to compute the inexact Riemannian gradient with relatively high accuracy and essentially uses the constant-like step sizes. In contrast, our iRBBS allows to compute the inexact Riemannian gradient with low accuracy and choose the step size adaptively.
Remark 3.5. It might be better to use possible multiple Sinkhorn iterations rather than only one iteration as done in R(A)BCD in updating  $\alpha$  and  $\beta$  from the computational point of view. The cost of updating  $\alpha^{(l + 1)}$  and  $\beta^{(\ell +1)}$  via one Sinkhorn iteration (21) is  $\mathcal{O}(n^2)$ . In contrast, the cost of updating  $U^{t + 1}$  via performing a RGD step (19a) is  $\mathcal{O}(ndk + n^2 k + dk^2)$ , wherein the main cost is to compute  $V_{\phi_k(\mathbf{x}^t,\pi^k)}U^t$ , which can be done by observing  $V_{\pi}U = X\operatorname {Diag}(\pi \mathbf{1})X^{\top}U + Y\operatorname {Diag}(\pi^{\top}\mathbf{1})Y^{\top}U - X\pi Y^{\top}U - Y\pi^{\top}X^{\top}U$ . Considering that the cost of updating  $\alpha$  and  $\beta$  is much less than that of updating  $U$ , it is reasonable to update  $\alpha$  and  $\beta$  multiple times and update  $U$  only once.
In this section, we conduct numerical experiments on six Shakespeare operas to evaluate the performance of our proposed approaches; see Dataset C.1 for a more detailed description of the dataset. All methods are implemented in MATLAB. More numerical results can be found in Appendix D. The codes are available from https://github.com/bjiangopt/ReALM.
4.1 Comparison with R(A)BCD on Solving Subproblem (11)
Subproblem (11) with  $\pi^k = 11^\top$  and a relatively small  $\eta_k = \eta$  is used to compute the PRW distance in [28]. We choose  $\eta = 0.1$  as done in [28]. Since [28] has shown the superiority of R(A)BCD over R(A)GAS proposed in [34], we mainly compare our proposed iRBBS, namely, Algorithm 2, with R(A)BCD. For iRBBS and R(A)BCD, we use the same stopping conditions with  $\epsilon_1 = 2\|C\|_{\infty}\epsilon_2$  (motivated by (13a)) and  $\epsilon_2 = 10^{-6}\max\{\|r\|_{\infty}, \|c\|_{\infty}\}$ . To make the residual error more comparable, we choose
$$
\theta_ {0} = 1, \quad \theta_ {t + 1} = \max  \left\{\theta \cdot \frac {\mathrm {e} _ {\eta_ {k}} ^ {1} \left(\mathbf {x} ^ {t} , \pi^ {k}\right)}{\epsilon_ {1}}, 1 \right\} \epsilon_ {2}, \quad t \geq 0, \tag {27}
$$
Table 1: Comparison results of R(A)BCD and iRBBS for Dataset C.1. Here, “a”, “b” stand for RBCD and RABCD, respectively; “c”, “d”, and “e” stand for iRBBS-inf, iRBBS-0.1, and iRBBS-0, respectively. For RBCD, RABCD, and iRBBS-inf, nGrad is equal to nSk.
data	\(\widehat{P}_{k}^{2}\)	nGrad/nSk	time
a	b	c	d	e	a	b	c	d	e	a	b	c	d	e
H5/H	0.049074	0.049074	0.049074	0.049074	0.049074	871	604	320	64/1296	61/3218	9.6	6.7	3.4	1.2	1.8
H5/JC	0.059576	0.059576	0.059576	0.059576	0.059576	904	497	193	63/1571	60/3047	5.3	2.9	1.2	0.6	0.7
H5/MV	0.062515	0.062515	0.062515	0.062515	0.062515	800	444	118	63/1373	61/2812	5.4	2.9	0.8	0.6	0.8
H5/O	0.049973	0.049973	0.049973	0.049973	0.049973	612	397	129	43/1084	45/2410	4.9	3.2	1.0	0.5	0.7
H5/RJ	0.180227	0.180227	0.180227	0.180227	0.180227	474	440	319	73/1670	69/3041	3.8	3.5	2.4	0.8	1.0
H/JC	0.050081	0.050081	0.050081	0.057156	0.057156	637	523	427	41/1049	42/2020	4.4	3.6	2.9	0.4	0.6
H/MV	0.038416	0.038416	0.038416	0.038416	0.038416	2794	1661	440	117/2045	125/5129	22.9	13.6	3.4	1.2	1.6
H/O	0.014042	0.014042	0.014042	0.014042	0.014042	796	503	212	49/1471	53/3093	7.7	4.7	2.0	0.8	1.2
H/RJ	0.189475	0.189475	0.189475	0.189475	0.189475	360	441	265	46/933	47/1763	3.4	4.2	2.3	0.6	0.8
JC/MV	0.013257	0.013257	0.013256	0.013257	0.013257	1816	975	216	66/1781	65/3742	7.2	3.8	0.9	0.4	0.6
JC/O	0.009835	0.009835	0.009835	0.009835	0.009835	1160	763	101	52/1402	45/2454	6.5	3.5	0.5	0.4	0.5
JC/RJ	0.110336	0.110336	0.110336	0.110336	0.110336	340	332	235	44/1016	53/2536	1.5	1.5	1.1	0.3	0.5
MV/O	0.010090	0.010090	0.010090	0.010090	0.010090	2222	1396	154	90/2448	88/5186	13.2	8.2	0.9	0.8	1.1
MV/RJ	0.168293	0.168293	0.168293	0.168293	0.168293	842	763	632	85/1688	95/4805	5.0	4.5	3.8	0.7	1.1
O/RJ	0.125614	0.125614	0.125614	0.124085	0.124085	376	372	210	55/1070	62/2749	2.5	2.4	1.4	0.5	0.8
AVG	0.075387	0.075387	0.075387	0.075757	0.075757	1000	674	265	63/1460	65/3200	6.89	4.62	1.86	0.66	0.90
where the parameter  $\theta$  is a preselected constant in the proposed iRBBS algorithm. We consider several different values of  $\theta$  and denote the corresponding version of iRBBS as iRBBS- $\theta$ . When  $\theta = 0$ , we have  $\theta_{t + 1} \equiv \epsilon_2$  for all  $t \geq 0$ , which means that we calculate  $\operatorname{grad} q(U^t)$  almost exactly; when  $\theta = +\infty$ , the Sinkhorn iteration always stops in one iteration. For numerical tests in this subsection, we can always perform an equivalent formulation of Sinkhorn iteration (21) as [15, 6]
$$
u ^ {(\ell + 1)} = r \oslash (A v ^ {(\ell)}), \quad v ^ {(\ell + 1)} = c \oslash (A ^ {\mathsf {T}} u ^ {(\ell + 1)}), \tag {28}
$$
where  $\varnothing$  denotes elementwise division,  $u^{(\ell)} = \exp (-\alpha^{(\ell)} / \eta_k)$ ,  $v^{(\ell)} = \exp (-\beta^{(\ell)} / \eta_k)$ , and  $A \in \mathbb{R}^{n \times n}$  with  $A_{ij} = \pi_{ij}^k \exp(-\langle M_{ij}, UU^\top \rangle / \eta_k)$ . More settings and details on the implementation can be found in Appendix C.
For each instance of Dataset C.1, we randomly generate 20 initial points and report the average performance in Table 1. The term "nGrad" means the total number of calculating  $\mathrm{grad}_U\mathcal{L}_{\eta_k}(\mathbf{x}^t,\pi^k)$ , "nSk" means the total number of Sinkhorn iterations, and "time" represents the running time in seconds evaluated by "tic-toc" commands. Moreover, since we aim to compute the PRW distance, with  $U^{t}$  returned by some method in hand, we invoke Gurobi 9.5/Mosek 9.3 to compute a more accurate PRW distance, denoted as  $\hat{\mathcal{P}}_k^2 = \min_{\pi \in \Pi (r,c)}\langle \pi ,C(U^t)\rangle$ . Note that a larger  $\hat{\mathcal{P}}_k^2$  means a higher solution quality of the corresponding  $U^{t}$ . In the last "AVG" line, we summarize the averaged performance.
From Table 1, we have the following observations: (i) as for the solution quality, iRBBS-0.1 performs the best among all methods; (ii) among iRBBS methods, iRBBS-0.1 is about  $2.8\mathrm{x}$  faster than iRBBSinf and about  $1.4\mathrm{x}$  faster than iRBBS-0; (iii) compared with R(A)BCD, iRBBS-0.1 can always take significantly less nGrad and may take a bit more nSk. This makes it about  $7\mathrm{x}$  faster than RABCD and about  $10.4\mathrm{x}$  faster than RBCD. The results show that iRBBS generally performs much better than R(A)BCD. More importantly, our methods adopt the adaptive stepsize without needing to tune the best stepsize as done in R(A)BCD.
4.2 Comparison on Computing the PRW Distance (1)