SlowGuess/NeurIPS_2023_OCR huggingface dataset:
$$
\bar {F} _ {\theta_ {*} \circ \bar {X}, T} \circ \theta = \theta \circ \bar {F} _ {\bar {X}, T} \tag {20}
$$
$$
\bar {F} _ {d (\theta) _ {\mathbf {Y}} \bar {\mathrm {X}}, T} \circ \theta = \theta \circ \bar {F} _ {\bar {\mathrm {X}}, T} \tag {21}
$$
$$
\bar {F} _ {\bar {X} Q, T} (\boldsymbol {Y} \boldsymbol {Q}) = \bar {F} _ {\bar {X}, T} (\boldsymbol {Y}) \boldsymbol {Q}. \tag {22}
$$
Note that  $d(\theta)_{\mathbf{Y}}\overline{\mathbf{X}} = \overline{\mathbf{X}}\mathbf{Q}$  is derived from the Corollary 2 and (4) in Zhu & Sato (2021). This indicates that  $\overline{F}_{\overline{\mathsf{X}},T}\sim \overline{F}_{\overline{\mathsf{X}}',T}$  is true for any  $\overline{\mathbf{X}},\overline{\mathbf{X}}^{\prime}\in T^{\mathrm{h}}\operatorname {St}(k,D)$  that satisfies  $\overline{\mathbf{X}}\sim \overline{\mathbf{X}}^{\prime}$ . Thus, a new flow can be defined as  $F_{\mathsf{X},T}:= \left[\overline{F}_{\overline{\mathsf{X}},T}\right]$ . This is a flow on a  $\operatorname {Gr}(k,D)$ . Because  $\overline{\mathbf{X}}$  is a vector field in a horizontal bundle  $T^{\mathrm{h}}\operatorname {St}(k,D)$  on  $\operatorname {St}(k,D)$ , it is a horizontal lift of the vector field  $\mathsf{X}$  on  $\operatorname {Gr}(k,D)$  and is therefore unique for  $\mathsf{X}$ .
Thus, the proof is complete.
B.2 Proposition 2
Proof. Let  $\theta : \mathrm{St}(k, D) \times \mathcal{O}(k) \to \mathrm{St}(k, D) : (\mathbf{Y}, \mathbf{Q}) \mapsto \mathbf{Y}\mathbf{Q}$  be a map representing the right action of the orthogonal group.
$$
\begin{array}{l} \bar {p} _ {F} (\theta \circ \mathbf {Y}) = \bar {p} _ {F} (\theta \circ \mathbf {Y}) \frac {\left| \det  \left\{J _ {\theta} (\mathbf {Y}) \right\} \right|}{\left| \det  \left\{J _ {\theta} (\mathbf {Y}) \right\} \right|} = \frac {\bar {p} _ {\theta^ {- 1} \circ F} (\mathbf {Y})}{\left| \det  \left\{J _ {\theta} (\mathbf {Y}) \right\} \right|} (23) \\ = \bar {p} \left(\left(F ^ {- 1} \circ \theta\right) (\mathbf {Y})\right) \frac {\left| \det \left\{J _ {F ^ {- 1} \circ \theta} (\mathbf {Y}) \right\} \right|}{\left| \det \left\{J _ {\theta} (\mathbf {Y}) \right\} \right|} (24) \\ = (\bar {p} \circ F ^ {- 1}) \circ \theta (\mathbf {Y}) \frac {\left| \det  \left\{J _ {\theta \circ F ^ {- 1}} (\mathbf {Y}) \right\} \right|}{\left| \det  \left\{J _ {\theta} (\mathbf {Y}) \right\} \right|} (25) \\ = \theta \circ (\bar {p} \circ F ^ {- 1}) (\mathbf {Y}) \frac {\left| \det  \left\{J _ {\theta} \left(F ^ {- 1} (\mathbf {Y})\right) J _ {F ^ {- 1}} (\mathbf {Y}) \right\} \right|}{\left| \det  \left\{J _ {\theta} (\mathbf {Y}) \right\} \right|} (26) \\ = \theta \circ (\bar {p} \circ F ^ {- 1}) (\mathbf {Y}) \frac {\left| \det  \left\{J _ {\theta} \left(F ^ {- 1} (\mathbf {Y})\right) \right\} \right| | \det  \left\{J _ {F ^ {- 1}} (\mathbf {Y}) \right\} |}{| \det  \left\{J _ {\theta} (\mathbf {Y}) \right\} |} (27) \\ = \theta \circ \bar {p} (F ^ {- 1}) (\mathbf {Y}) | \det  \left\{J _ {F ^ {- 1}} (\mathbf {Y}) \right\} | \frac {\left| \det  \left\{J _ {\theta} (F ^ {- 1} (\mathbf {Y})) \right\} \right|}{\left| \det  \left\{J _ {\theta} (\mathbf {Y}) \right\} \right|} (28) \\ = \theta \circ \bar {p} _ {F} (\mathbf {Y}) \frac {\left| \det  \left\{J _ {\theta} \left(F ^ {- 1} (\mathbf {Y})\right) \right\} \right|}{\left| \det  \left\{J _ {\theta} (\mathbf {Y}) \right\} \right|} (29) \\ = \theta \circ \bar {p} _ {F} (\mathbf {Y}), (30) \\ \end{array}
$$
where  $|\operatorname{det}\{J_{\theta}(\mathbf{X})\}| = 1$  is true because  $\theta$  is the action of the orthogonal group. Therefore, as  $\overline{p}_F(\theta \circ \mathbf{Y}) = \theta \circ \overline{p}_F(\mathbf{Y})$  is true,  $\overline{p}_F \sim \overline{p}_F \mathbf{Q} \in p_F$  is true. Based on this, it can be concluded that the subject is satisfied.
B.3 Proposition 3
$$
p _ {\operatorname {G r} (k, D)} ([ \boldsymbol {X} ]; [ \boldsymbol {M} ], \boldsymbol {U}, \boldsymbol {V}) = V _ {\operatorname {G r} (k, D)} \mathcal {M N} \left(\overline {{\boldsymbol {\xi}}} _ {M} ^ {\mathrm {h}}; \boldsymbol {0}, \boldsymbol {U}, \boldsymbol {V}\right) \left| \det  \left(\nabla_ {\overline {{\boldsymbol {\xi}}} _ {M} ^ {\mathrm {h}}} \overline {{R}} _ {M}\right) \right|, \tag {31}
$$
where  $M$  is an orthonormal basis matrix denoting the mean of the distribution,  $U$  is a positive definite matrix denoting the row directional variance,  $V$  is a positive definite matrix denoting the column directional variance, and  $\overline{\xi}_M^{\mathrm{h}}$  is a random sample from  $\mathcal{MN}$  in an  $(D - k)\times k$ -dimensional horizontal space  $T_{M}^{\mathrm{h}}\operatorname {St}(k,D)$ .  $V_{\mathrm{Gr}(k,D)}$  denotes the total volume of  $\mathrm{Gr}(k,D)$  defined by (113),  $\overline{R}_M$  denotes the horizontal retraction at  $M$ , and  $\left|\operatorname *{det}\left(\nabla_{\overline{\xi}_M^{\mathrm{h}}}\overline{R}_M\right)\right|$  denotes the Jacobian.
Proof. Let  $p_{\mathrm{Gr}}([X])$  be a probability density function on a  $\operatorname{Gr}(k, D)$ . From (101), let  $(dX)$  be the invariant measure on  $\operatorname{Gr}(k, D)$  and  $d\overline{\xi}_M^{\mathrm{h}}$  be the Lebesgue measure on  $T_M^{\mathrm{h}}\mathrm{St}(k, D)$ . Subsequently, a change of variables was performed according to the following:
$$
p _ {\operatorname {G r} (k, D)} ([ \boldsymbol {X} ]) (d \boldsymbol {X}) = p _ {\operatorname {G r} (k, D)} \left(\left[ \bar {R} _ {M} (\bar {\boldsymbol {\xi}} _ {M} ^ {\mathrm {h}}) \right]\right) d \bar {\boldsymbol {\xi}} _ {M} ^ {\mathrm {h}} \tag {32}
$$
$$
p _ {\operatorname {G r} (k, D)} ([ \boldsymbol {X} ]) = p _ {\operatorname {G r} (k, D)} \left(\left[ \bar {R} _ {M} \left(\bar {\boldsymbol {\xi}} _ {M} ^ {\mathrm {h}}\right) \right]\right) \left| \det  \left(\frac {d \bar {\boldsymbol {\xi}} _ {M} ^ {\mathrm {h}}}{d R _ {M}}\right) \right| \tag {33}
$$
$$
p _ {\operatorname {G r} (k, D)} ([ \boldsymbol {X} ]) = p _ {\operatorname {G r} (k, D)} \left(\left[ \bar {R} _ {M} \left(\bar {\boldsymbol {\xi}} _ {M} ^ {\mathrm {h}}\right) \right]\right) \left| \det  \left(\nabla_ {\bar {\boldsymbol {\xi}} _ {M} ^ {\mathrm {h}}} \bar {R} _ {M}\right) \right| ^ {- 1}. \tag {34}
$$
Suppose  $p_{\mathrm{Gr}}([X])$  is integrable with the probability measure  $[dX]$  on  $\operatorname{Gr}(k, D)$  defined by (114). Then, we obtain the following relation.
$$
\begin{array}{l} \int_ {\operatorname {G r} (k, D)} p _ {\operatorname {G r} (k, D)} ([ \boldsymbol {X} ]) [ d \boldsymbol {X} ] (35) \\ = \frac {1}{V _ {\operatorname {G r} (k , D)}} \int_ {\operatorname {G r} (k, D)} p _ {\operatorname {G r} (k, D)} ([ X ]) (d X) (36) \\ = \frac {1}{V _ {\mathrm {G r} (k , D)}} \int_ {T _ {M} ^ {\mathrm {h}} \operatorname {S t} (k, D)} p _ {\mathrm {G r} (k, D)} \left(\left[ \bar {R} _ {M} \left(\bar {\boldsymbol {\xi}} _ {M} ^ {\mathrm {h}}\right) \right]\right) \left| \det  \left(\nabla_ {\bar {\boldsymbol {\xi}} _ {M} ^ {\mathrm {h}}} \bar {R} _ {M}\right) \right| ^ {- 1} d \bar {\boldsymbol {\xi}} _ {M} ^ {\mathrm {h}}. (37) \\ \end{array}
$$
In addition, we obtain the following equation based on  $[d\mathbf{X}]$ .
$$
\int_ {\operatorname {G r} (k, D)} p _ {\operatorname {G r} (k, D)} ([ \boldsymbol {X} ]) [ d \boldsymbol {X} ] = \int_ {T _ {M} ^ {\mathrm {h}} \operatorname {S t} (k, D)} \mathcal {M N} (\overline {{\boldsymbol {\xi}}} _ {M} ^ {\mathrm {h}}) d \overline {{\boldsymbol {\xi}}} _ {M} ^ {\mathrm {h}} = 1, \tag {38}
$$
where  $\mathcal{MN}\left(\overline{\pmb{\xi}}_M^{\mathrm{h}}\right)$  denotes the matrix-variate Gaussian distribution (Mathai et al. (2022)). Thus, the probability density function on  $\operatorname{Gr}(k,D)$  can be expressed as follows:
$$
\left. p _ {\operatorname {G r} (k, D)} \left(\left[ \bar {R} _ {M} \left(\bar {\boldsymbol {\xi}} _ {M} ^ {\mathrm {h}}\right) \right]\right)\right) = V _ {\operatorname {G r} (k, D)} \mathcal {M N} \left(\bar {\boldsymbol {\xi}} _ {M} ^ {\mathrm {h}}\right) \left| \det  \left(\nabla_ {\bar {\boldsymbol {\xi}} _ {M} ^ {\mathrm {h}}} \bar {R} _ {M}\right) \right|. \tag {39}
$$
The Jacobian can be represented as  $\left|\operatorname*{det}\left(\nabla_{\overline{\boldsymbol{\xi}}_M^{\mathrm{h}}}\overline{R}_M\right)\right| = \left|\operatorname*{det}\left\{\left(\partial \overline{R}_M\right)^\top \left(\partial \overline{R}_M\right)\right\} \right|^{\frac{1}{2}}$  from Evans & Ronald (2015), where  $\partial \overline{R}_M = \frac{\partial \overline{R}_M}{\partial \overline{\boldsymbol{\xi}}_M^{\mathrm{h}}}$ . Further,  $\partial \overline{R}_M$  can be computed as follows. First, we define the horizontal retraction  $\overline{R}_{Y}: T_{Y}^{\mathrm{h}} \operatorname{St}(k, D) \to \operatorname{St}(k, D)$  based on the Cayley transform from Zhu & Sato (2021).
$$
\boldsymbol {X} = \bar {R} _ {M} \left(\bar {\boldsymbol {\xi}} _ {M} ^ {\mathrm {h}}\right) = \boldsymbol {M} + \bar {\boldsymbol {\xi}} _ {M} ^ {\mathrm {h}} - \left(\frac {1}{2} \boldsymbol {M} + \frac {1}{4} \bar {\boldsymbol {\xi}} _ {M} ^ {\mathrm {h}}\right) \left(\boldsymbol {I} _ {k} + \frac {1}{4} \bar {\boldsymbol {\xi}} _ {M} ^ {\mathrm {h}} ^ {\top} \bar {\boldsymbol {\xi}} _ {M} ^ {\mathrm {h}}\right) ^ {- 1} \bar {\boldsymbol {\xi}} _ {M} ^ {\mathrm {h}} ^ {\top} \bar {\boldsymbol {\xi}} _ {M} ^ {\mathrm {h}}. \tag {40}
$$
This is a fixed time ( $t = 1$ ) version of (122). Next, for improved visibility in subsequent calculations, let  $\pmb{E} = \overline{\pmb{\xi}}_M^{\mathrm{h}}$ ,  $\pmb{F} = \frac{1}{2}\pmb{M} + \frac{1}{4}\pmb{E}$ ,  $\pmb{G} = \left(\pmb{I}_k + \frac{1}{4}\pmb{H}\right)^{-1}$ ,  $\pmb{H} = \pmb{E}^{\top}\pmb{E}$ . In addition, let  $\mathsf{D}$  be defined as the operator for the derivative of a matrix by a matrix. Then, the derivative  $\nabla_{\overline{\pmb{\xi}}_M^{\mathrm{h}}}\overline{R}_M = \mathsf{D}\pmb{X}$  by  $\pmb{E}$  is as follows:
$$
\nabla_ {\overline {{\boldsymbol {\xi}}} _ {M} ^ {\mathrm {h}}} \bar {R} _ {M} = \mathrm {D} \boldsymbol {X} = \mathrm {D} \boldsymbol {M} + \mathrm {D} \boldsymbol {E} - \mathrm {D} (\boldsymbol {F} \boldsymbol {G} \boldsymbol {H}). \tag {41}
$$
Finally, each derivative can be calculated as follows:
$$
D M = 0, \tag {42}
$$
$$
D E = I _ {D k}, \tag {43}
$$
$$
\begin{array}{l} D (F G H) = D (F (G H)) (44) \\ = \left\{\left(\boldsymbol {G} \boldsymbol {H}\right) ^ {\top} \otimes \boldsymbol {I} _ {D} \right\} \mathrm {D} \boldsymbol {F} + \left(\boldsymbol {I} _ {k} \otimes \boldsymbol {F}\right) \mathrm {D} (\boldsymbol {G} \boldsymbol {H}) (45) \\ = \left\{\left(\boldsymbol {G} \boldsymbol {H}\right) ^ {\top} \otimes \boldsymbol {I} _ {D} \right\} \mathrm {D} \boldsymbol {F} + \left(\boldsymbol {I} _ {k} \otimes \boldsymbol {F}\right) \left\{\left(\boldsymbol {H} ^ {\top} \otimes \boldsymbol {I} _ {k}\right) \mathrm {D} \boldsymbol {G} + \left(\boldsymbol {I} _ {k} \otimes \boldsymbol {G}\right) \mathrm {D} \boldsymbol {H} \right\} (46) \\ = \left\{\left(\boldsymbol {G} \boldsymbol {H}\right) ^ {\top} \otimes \boldsymbol {I} _ {D} \right\} \mathrm {D} \boldsymbol {F} \\ + \left(\boldsymbol {I} _ {k} \otimes \boldsymbol {F}\right) \left(\boldsymbol {H} ^ {\top} \otimes \boldsymbol {I} _ {k}\right) \mathrm {D} \boldsymbol {G} + \left(\boldsymbol {I} _ {k} \otimes \boldsymbol {F}\right) \left(\boldsymbol {I} _ {k} \otimes \boldsymbol {G}\right) \mathrm {D} \boldsymbol {H} (47) \\ = \left(\boldsymbol {G} ^ {\top} \boldsymbol {H} ^ {\top} \otimes \boldsymbol {I} _ {D}\right) \mathrm {D} \boldsymbol {F} + \left(\boldsymbol {H} ^ {\top} \otimes \boldsymbol {F}\right) \mathrm {D} \boldsymbol {G} + \left(\boldsymbol {I} _ {k} \otimes \boldsymbol {F G}\right) \mathrm {D} \boldsymbol {H}, (48) \\ \end{array}
$$
$$
\mathrm {D} \boldsymbol {F} = \mathrm {D} \left(\frac {1}{2} \boldsymbol {M}\right) + \mathrm {D} \left(\frac {1}{4} \boldsymbol {E}\right) = \frac {1}{4} \mathrm {D} \boldsymbol {E}, \tag {49}
$$
$$
\mathrm {D} \boldsymbol {G} = - \left(\boldsymbol {G} ^ {\top} \otimes \boldsymbol {G}\right) \mathrm {D} \boldsymbol {H}, \tag {50}
$$
$$
\mathrm {D} \boldsymbol {H} = \left(\boldsymbol {I} _ {k ^ {2}} + \boldsymbol {K} _ {k, k}\right) \left(\boldsymbol {I} _ {k} \otimes \boldsymbol {E} ^ {\top}\right) \mathrm {D} \boldsymbol {E}, \tag {51}
$$
where  $\otimes$  denotes the Kronecker product.  $K_{D,k}$  is a  $Dk\times Dk$  matrix  $K_{D,k} = \sum_{i = 1}^{m}\sum_{j = 1}^{n}\left(L_{i,j}\otimes L_{i,j}^{\top}\right)$  referred to as the commutation matrix, which denotes the transposition operation of  $D\times k$ . Further,  $L_{i,j}$  is a  $D\times k$  matrix whose  $(i,j)$  component is 1 whereas all other components are 0.
Figure 6:  $p_{\mathrm{Gr}(1,3)}([X])$  with  $M = (1.0,0.0,0.0)^{\top}$ ,  $U = \sigma^2 I_3$ ,  $V = I_1$ ,  $\sigma^2 = 0.5$ . Each sphere in the figure indicates  $\operatorname{Gr}(1,3)$ , with brighter spheres representing higher densities.
For details on the formulae for matrix derivatives used in this proof, please refer to Magnus & Neudecker (2019).
$p_{\mathrm{Gr}(k,D)}([X]) = p_{\mathrm{Gr}(k,D)}([X];[M],U,V)$  is a probability distribution following mean  $[M]$  and matrix variance  $U,V$ . Using  $\operatorname{Gr}(1,3)$  as an example, we qualitatively confirmed through visualization that  $p_{\mathrm{Gr}(1,3)}([X])$  is a density on  $\operatorname{Gr}(1,3)$ .  $\operatorname{Gr}(1,3)$  is a 1-dimensional subspace in a 3-dimensional space; that is, a space whose elements are lines passing through the origin in 3-dimensional space. For the visualization, we expressed  $\operatorname{Gr}(1,3)$  by mapping a 1-dimensional subspace to two points on a sphere (one point on the sphere and its antipodal point) of radius 1 centered at the origin.
Figure 6 shows the density of  $p_{\mathrm{Gr}(1,3)}([X])$  with  $M = (1.0,0.0,0.0)^{\top}$ ,  $U = \sigma^2 I_3$ ,  $V = I_1$ ,  $\sigma^2 = 0.5$ . Each sphere in the figure indicates  $\mathrm{Gr}(1,3)$ , with brighter spheres representing higher densities. The leftmost figure shows  $M$  as viewed from the front diagonally above, and the other figures present the views when the viewpoint is rotated clockwise around the  $z$ -axis by  $30^\circ$  to  $150^\circ$  with movement to the right. In the leftmost figure, the density is highly spread around  $M$ . In the other figures (particularly the rightmost one), the antipodal point  $(-M = (-1.0,0.0,0.0)^{\top})$  is densely spread out. This implies that when only one  $M$  is specified as the representative of the equivalence class  $[M]$ , the density around the other elements in the equivalence class  $[M]$  is as high as that around the representative. Thus, we can confirm that  $p_{\mathrm{Gr}(k,D)}([X])$  has a density of  $\mathrm{Gr}(1,3)$ .
C Experimental Details for Learning GrCNF
C.1 Details on ODE Solver with Orthogonal Integration
We explain in detail an ordinary differential equation (ODE) solver on  $\mathrm{Gr}(k, D)$ . Several studies on ODE solvers employed on a manifold  $\mathcal{M}$  have been reported (Munthe-Kaas (1999); Iserles et al. (2000); Hairer (2006)). Hairer (2006) proposed a simple projection method that projected onto the manifold at each step and the symmetric projection method suitable for long-time integration. However, this method requires  $\mathcal{M}$  to be a submanifold in Euclidean space, and thus cannot be applied on  $\mathrm{Gr}(k, D)$ . In contrast, Celledoni & Owren (2002) proposed an intrinsic ODE solver that was applicable to a Stiefel manifold and did not assume an outer Euclidean space. This solver works on a Stiefel manifold, thus it must be reformulated into a solver suitable for  $\mathrm{Gr}(k, D)$ , which is our problem setting. We introduce below a solver on  $\mathrm{Gr}(k, D)$  via ODE operating on the horizontal space  $T_{\pmb{Y}}^{\mathrm{h}}\mathrm{St}(k, D)$ , based on results from Celledoni & Owren (2002) and Section 4. This is an intrinsic approach regardless of whether  $\mathcal{M}$  has been embedded in a larger space with a corresponding extension of the vector field.
First, consider an ODE expressed using a vector field  $\mathsf{X}_{\theta}$  on a curve  $\gamma (t):[0,\infty)\to \mathrm{St}(k,D)$  such that for each time  $t$
$$
\frac {d \gamma (t)}{d t} = \mathbf {X} _ {\theta} (t, \gamma (t)), \quad \gamma (0) = \mathbf {Y}, \tag {52}
$$
where  $\mathsf{X}_{\theta}$  is constructed by a neural network with parameter  $\theta$ , as described in Section 5.3. Horizontal retraction  $\overline{R}_{\mathbf{Y}}$  which is defined as (122) and is described in Appendix D.6, defines local coordinates of  $\operatorname{Gr}(k, D)$  in a neighborhood of the point  $[\mathbf{Y}]$ . Thus, the solution of ODE can be expressed as:
$$
\gamma (t) = \bar {R} _ {\boldsymbol {Y}} (\epsilon (t)), \tag {53}
$$
where  $\epsilon :[0,\infty)\to T_{\mathbf{Y}}^{\mathrm{h}}\mathrm{St}(k,D)$  is the curve on  $T_{\mathbf{Y}}^{\mathrm{h}}\mathrm{St}(k,D)$ . By differentiating (53) with  $t$ , the following equation is obtained:
$$
\frac {d \gamma (t)}{d t} = \frac {d}{d t} \bar {R} _ {\boldsymbol {Y}} (\epsilon (t)) = \mathrm {X} _ {\theta} (t, \gamma (t)). \tag {54}
$$
Therefore, the ODE defined on  $T_{\mathbf{Y}}^{\mathrm{h}}\operatorname {St}(k,D)$  is obtained as (8):
$$
\begin{array}{l} \frac {d \operatorname {V e c} (\epsilon (t))}{d t} = \left(\nabla_ {\epsilon} \bar {R} _ {Y}\right) ^ {- 1} \operatorname {V e c} \left(X _ {\theta} (t, \bar {R} _ {Y} (\epsilon (t)))\right) \\ = \nabla_ {\gamma} \overline {{R}} _ {\boldsymbol {Y}} ^ {- 1} \mathsf {V e c} \left(\mathsf {X} _ {\theta} \left(t, \overline {{R}} _ {\boldsymbol {Y}} \left(\epsilon (t)\right)\right)\right), \\ \end{array}
$$
where  $\mathrm{Vec}$  denotes the map of vertically concatenating matrices and converting them into a single vector.  $\nabla_{\gamma}\overline{R}_{\mathbf{Y}}^{-1}$  can be calculated using the derivative of (123):
$$
\nabla_ {\gamma} \bar {R} _ {\mathbf {Y}} ^ {- 1} = 2 \left(\boldsymbol {N} ^ {- \top} \otimes \boldsymbol {I} _ {D}\right) \nabla \boldsymbol {M} + 2 \left(\boldsymbol {I} _ {k} \otimes \boldsymbol {M}\right) \nabla \boldsymbol {N} ^ {- 1}, \tag {55}
$$
where  $\mathbf{X} = \gamma (t), M = \mathbf{Y} - \mathbf{X}\mathbf{X}^{\top}\mathbf{Y}, \mathbf{N} = \mathbf{I}_k + \mathbf{X}^{\top}\mathbf{Y}, \nabla M = \mathbf{I}_{Dk} - \left(\mathbf{I}_k\otimes \mathbf{X}\mathbf{X}^{\top}\right)$  and  $\nabla N^{-1} = -\left(N^{-\top}\otimes N^{-1}\right)\left(I_k\otimes X^\top\right)$ . Because (8) is an ODE on  $T_{\mathbf{Y}}^{\mathrm{h}}\operatorname {St}(k,D)\cong \mathbb{R}^{(D - k)\times k}$  from Absil et al. (2008), it can be solved using an ODE solver such as Runge-Kutta methods that operate on Euclidean space. This study used Algorithm 5.1 presented in Celledoni & Owren (2002). In each step, first, (8) was solved using the Runge-Kutta method of order 5 as in Dormand & Prince (1980). Subsequently, the solution of ODE (52) was obtained by applying the solution  $\epsilon$  to (53).
C.2 Loss Function based on Variational Inference
In the setting in Section 6.3, we used orthonormalized data  $\mathbf{Y}$  as in  $PP^{\top} \simeq Y\Lambda Y^{\top}$ , where  $\Lambda$  is diagonal (Huang et al. (2015)), such that the  $k$ -dimensional point cloud data  $\mathbf{P}$  of  $N$  points  $N \times k$  matrix is a matrix with  $k$  orthonormal basis vectors. Thus, generating a complete point cloud requires the estimation of the scale parameters  $\sqrt{\Lambda}$  to be  $\mathbf{P} = \mathbf{Y}\sqrt{\Lambda}$  and a loss function that incorporates this. In this study, we approximated by maximizing the evidence lower bound (ELBO), which is the lower bound of the overall log-likelihood  $\log p_{\psi}(\mathbf{P})$  of  $p_{\psi}(\mathbf{P})$ , using a variational inference framework. The loss function is the variational energy - ELBO  $(\mathbf{P})$  with negative ELBO.
$$
\mathrm {N L L} = - \log p _ {\psi} (\boldsymbol {P}) \leq - \operatorname {E L B O} (\boldsymbol {P}) = \text {L o s s}. \tag {56}
$$
(b)
Figure 7: The proposed ODE solver on the Grassmann manifold and the ODE solver on the Stiefel manifold (Celledoni & Owren (2002)). (a) The proposed ODE solver working on a Grassmann manifold. The  $\overline{\xi}_{Y}^{\mathrm{h}}$  obtained by the proposed neural architecture NN is the horizontal lift (98), that is,  $d\pi(Y)\left[\overline{\xi}_{Y}^{\mathrm{h}}\right] = \xi_{[Y]}$ , of the tangent vector  $\xi_{[Y]}$  at the point  $[Y]$  on the Grassmann manifold. The proposed ODE solver maps and updates the tangent vector  $\xi_{[Y]}$  at the point  $[Y]$  onto the Grassmann manifold at each step using horizontal retraction (121). On the other hand, (b) the solver of Celledoni & Owren (2002), working on Stiefel manifolds, updates in each step by mapping the tangent vector  $\overline{\xi}_{Y}$  at the point  $Y$  onto the Stiefel manifold. In other words, the difference between the proposed ODE solver and the ODE solver on Stiefel manifolds is that the ODE solver on Stiefel manifolds works only on Stiefel manifolds, while the proposed ODE solver always updates in each step with the Stiefel manifold and Grassmann manifolds linked together.
ELBO  $(P)$  can be decomposed as follows.
$$
\begin{array}{l} \operatorname {E L B O} (\boldsymbol {P}) = \log p _ {\psi} (\boldsymbol {P}) - D _ {K L} \left(q _ {\phi} (\boldsymbol {Y} | \boldsymbol {P}) \| p _ {\psi} (\boldsymbol {Y} | \boldsymbol {P})\right) (57) \\ = \mathbb {E} _ {q _ {\phi} (\boldsymbol {Y} \mid \boldsymbol {P})} \left[ \log p _ {\psi} (\boldsymbol {P} \mid \boldsymbol {Y}) \right] - D _ {K L} \left(q _ {\phi} (\boldsymbol {Y} \mid \boldsymbol {P}) | | p _ {\theta} (\boldsymbol {Y})\right), (58) \\ \end{array}
$$
where  $q_{\phi}(\mathbf{Y}|\mathbf{P})$  is the inference model with parameter  $\phi$ ,  $p_{\psi}(\mathbf{P}|\mathbf{Y})$  is the decoder model with parameter  $\psi$ ,  $p_{\psi}(\mathbf{Y}|\mathbf{P})$  is the posterior distribution with parameter  $\psi$ , and  $p_{\theta}(\mathbf{Y})$  is the prior distribution with parameter  $\theta$ . Further,  $D_{KL}\left(q_{\phi}(\mathbf{Y}|\mathbf{P})||p_{\theta}(\mathbf{Y})\right)$  can be formulated using differential entropy as follows.
$$
D _ {K L} \left(q _ {\phi} (\boldsymbol {Y} \mid \boldsymbol {P}) \| p _ {\theta} (\boldsymbol {Y})\right) = - \mathbb {E} _ {q _ {\phi} (\boldsymbol {Y} \mid \boldsymbol {P})} \left[ p _ {\theta} (\boldsymbol {Y}) \right] - H \left[ q _ {\phi} (\boldsymbol {Y} \mid \boldsymbol {P}) \right]. \tag {59}
$$
Thus, the final loss function is as follows.
$$
\begin{array}{l} \operatorname {L o s s} = - \operatorname {E L B O} (\boldsymbol {P}) (60) \\ = - \mathbb {E} _ {q _ {\phi} (\boldsymbol {Y} \mid \boldsymbol {P})} [ \log p _ {\psi} (\boldsymbol {P} \mid \boldsymbol {Y}) ] - \mathbb {E} _ {q _ {\phi} (\boldsymbol {Y} \mid \boldsymbol {P})} [ p _ {\theta} (\boldsymbol {Y}) ] - H [ q _ {\phi} (\boldsymbol {Y} \mid \boldsymbol {P}) ]. (61) \\ \end{array}
$$
Each term of the loss function can be calculated as follows.
Expectation of log-likelihood  $\mathbb{E}_{q_{\psi}(\pmb{Y}|\pmb{P})}\left[\log p_{\psi}(\pmb{P}|\pmb{Y})\right]$  is the reconstruction log-likelihood of  $\pmb{P}$ . The expectation is estimated by Monte Carlo sampling.
Differential entropy In the decomposition of a point cloud  $P$ , there exists arbitrariness in the choice of  $Y$  and  $\Lambda$ , as in  $PP^{\top} \simeq Y \Lambda Y^{\top}$ . In this study, we assumed that the diagonal components of  $\Lambda$  are in descending order, and we restricted the decomposition arbitrariness to be an action  $Q \in \mathcal{O}(k)$ . If we suppose that the action  $Q$  follows a uniform distribution when  $Y = XQ$  holds, then  $Y$  also follows a uniform distribution in the  $k$ -dimensional subspace  $\operatorname{span}(Y)$ . Although this is a uniform distribution on  $\operatorname{St}(k,k)$ , we can consider a uniform distribution on  $\mathcal{O}(k)$  because  $\operatorname{St}(k,k) = \mathcal{O}(k)$ . The probability density function of  $Q$  is represented by  $U_{\mathcal{O}(k)}(Q)$  in (111).
Therefore, the differential entropy of the decoder model can be calculated as follows.