SlowGuess/NeurIPS_2023_OCR huggingface dataset:
$$
| w _ {i} \phi_ {i, x} - w _ {i} ^ {\prime} \phi_ {i, x} ^ {\prime} | \leq | w _ {i} - w _ {i} ^ {\prime} | \phi_ {i, x} + w _ {i} ^ {\prime} | \phi_ {i, x} - \phi_ {i, x} ^ {\prime} | \leq 2 (w _ {i} + w _ {i} ^ {\prime}) (d _ {\mathrm {B}} (\mathbb {M}, \mathbb {M} ^ {\prime}) \wedge \delta) / \delta
$$
$$
\left| \frac {1}{\sum_ {i} w _ {i}} - \frac {1}{\sum_ {i} w _ {i} ^ {\prime}} \right| \leq \frac {1}{\sum_ {i} w _ {i} ^ {\prime}} \left| \frac {\sum_ {i} w _ {i} ^ {\prime} - w _ {i}}{\sum_ {i} w _ {i}} \right| \leq \frac {m d _ {\mathrm {B}} (\mathbb {M} , \mathbb {M} ^ {\prime})}{(\sum_ {i} w _ {i} ^ {\prime}) (\sum_ {i} w _ {i})}.
$$
Finally,
$$
\begin{array}{l} | V _ {1, \delta} (\mathbb {M}) (x) - V _ {1, \delta} (\mathbb {M} ^ {\prime}) (x) | \leq \left[ \frac {\sum_ {i} w _ {i} + w _ {i} ^ {\prime}}{\sum_ {i} w _ {i} ^ {\prime}} + \frac {\sum_ {i} w _ {i}}{\frac {1}{m} (\sum_ {i} w _ {i}) (\sum_ {i} w _ {i} ^ {\prime})} \right] 2 (d _ {\mathrm {B}} (\mathbb {M}, \mathbb {M} ^ {\prime}) \wedge \delta) / \delta \\ \leq \left[ 4 + \frac {2}{C} \right] \left(d _ {\mathrm {B}} (\mathbb {M}, \mathbb {M} ^ {\prime}) \wedge \delta\right) / \delta . \\ \end{array}
$$
Inequality 4 can be proved using the proof of Inequality 5 by replacing every  $w_{i}$  by 1.
Inequality 6. Let us prove the inequality for (b). Let  $R \coloneqq R_{x - \delta, x + \delta}$ . One has:
$$
\begin{array}{l} V _ {\infty , \delta} (\mathbb {M}) (x) - V _ {\infty , \delta} (\mathbb {M} ^ {\prime}) (x) = \\ \sup  _ {i} \frac {2}{(2 \delta) ^ {n}} \int_ {\{y \in \mathbb {R} ^ {n}: y _ {n} = 0 \}} d _ {\mathrm {I}} \left(M _ {i} \mid_ {l _ {y} \cap R}, 0\right) \mathrm {d} \lambda^ {n - 1} (y) \\ - \sup  _ {j} \frac {2}{(2 \delta) ^ {n}} \int_ {\{y \in \mathbb {R} ^ {n}: y _ {n} = 0 \}} d _ {I} \left(M _ {j} ^ {\prime} \mid_ {l _ {y} \cap R}, 0\right) \mathrm {d} \lambda^ {n - 1} (y) \\ \end{array}
$$
$$
\begin{array}{l} (f o r a n y i n d e x j) \leq \sup _ {i} \frac {2}{(2 \delta) ^ {n}} \int_ {\{y \in \mathbb {R} ^ {n}: y _ {n} = 0 \}} d _ {\mathrm {I}} (M _ {i} | _ {l _ {y} \cap R}, 0) - d _ {\mathrm {I}} (M _ {j} ^ {\prime} | _ {l _ {y} \cap R}, 0) \mathrm {d} \lambda^ {n - 1} (y) \\ \leq \frac{2}{(2\delta)^{n}}\int_{\{y\in \mathbb{R}^{n}:y_{n} = 0\}}\sup_{i}\inf_{j}d_{\mathrm{I}}(M_{i}\big|_{l_{y}\cap R},M_{j}^{\prime}\big|_{l_{y}\cap R})  \mathrm{d}\lambda^{n - 1}(y) \\ \end{array}
$$
Now, as the interleaving distance is equal to the bottleneck distance for single parameter persistence [15, Theorem 5.14], one has:
$$
\sup _ {i} \inf _ {j} d _ {\mathrm {I}} (M _ {i} | _ {l _ {y} \cap R}, M _ {j} ^ {\prime} | _ {l _ {y} \cap R}) \leq d _ {\mathrm {B}} (\mathbb {M} | _ {l _ {y} \cap R}, \mathbb {M} ^ {\prime} | _ {l _ {y} \cap R}) = d _ {\mathrm {I}} (\mathbb {M} | _ {l _ {y} \cap R}, \mathbb {M} ^ {\prime} | _ {l _ {y} \cap R}) \leq d _ {\mathrm {I}} (\mathbb {M}, \mathbb {M} ^ {\prime}) \wedge \delta
$$
which leads to the desired inequality. The proofs for (a) and (c) follow the same lines (upper bound the suprema in the right hand term with either infima or appropriate choices in order to reduce to the single parameter case).
G An additional stability theorem
In this section, we define a new S-CDR, with a slightly different type of upper bound. It relies on the fibered barcode introduced in Appendix E. We also slightly abuse notations and use  $M_{i}$  to denote both an interval module and its support.
Proposition 2. Let  $\mathbb{M} \simeq \oplus_{i=1}^{m} M_i$  be a multiparameter persistence module that can be decomposed into interval modules. Let  $\sigma > 0$ , and let  $0 \leq \delta \leq \delta(\mathbb{M})$ , where
$\delta (\mathbb{M})\coloneqq \inf \{\delta \geq 0:\Gamma_{\mathbb{M}}$  achieves  $d_{\mathrm{B}}(B_{\mathbf{e}_{\Delta},x},B_{\mathbf{e}_{\Delta},x + \delta \mathbf{u}})$  for all  $x,\mathbf{u}$  s.t.  $\| \mathbf{u}\|_{\infty} = 1,\langle \mathbf{e}_{\Delta},\mathbf{u}\rangle = 0\}$ , where  $\Gamma_{\mathbb{M}}$  is the partial matching induced by the decomposition of  $\mathbb{M}$ . Let  $\mathcal{N}(x,\sigma)$  denote the function
$$
\begin{array}{l} \mathcal {N} (x, \sigma): \left\{ \begin{array}{l l} \mathbb {R} ^ {n} & \to \mathbb {R} \\ p & \mapsto \exp \left(- \frac {\| p - x \| ^ {2}}{2 \sigma^ {2}}\right) \end{array} \right. a n d l e t \\ V _ {\delta , \sigma} (\mathbb {M}): \left\{\begin{array}{l l}\mathbb {R} ^ {n}&\rightarrow \mathbb {R}\\x&\mapsto \max  _ {1 \leq i \leq m} \quad \max  _ {f \in \mathcal {C} (x, \delta , M _ {i})} \quad \| \mathcal {N} (x, \sigma) \cdot f \| _ {1}\end{array}\right. \tag {14} \\ \end{array}
$$
where  $\mathcal{C}(x,\delta,M_i)$  stands for the set of interval functions from  $\mathbb{R}^n$  to  $\{0,1\}$  whose support is  $T_{\delta}(\ell)\cap M_i$ , where  $\ell$  is a connecting component of  $\mathrm{im}(\ell_{\mathbf{e}_{\Delta},x})\cap M_i$  and  $\mathbf{e}_{\Delta} = [1,\dots ,1]\in \mathbb{R}^{n}$ , and where  $T_{\delta}(\ell)$  is the  $\delta$ -thickening of the line  $L(\ell)$  induced by  $\ell$ :  $T_{\delta}(\ell) = \{x\in \mathbb{R}^{k}:\| x,L(\ell)\|_{\infty}\leq \delta \}$ .
Then,  $V_{\delta ,\sigma}$  satisfies the following stability property:
$$
\left\| V _ {\delta , \sigma} (\mathbb {M}) - V _ {\delta , \sigma} \left(\mathbb {M} ^ {\prime}\right) \right\| _ {\infty} \leq (\sqrt {\pi} \sigma) ^ {n} \cdot \sqrt {2 ^ {n + 1} \delta^ {n - 1} d _ {\mathrm {I}} \left(\mathbb {M} , \mathbb {M} ^ {\prime}\right) + C _ {n} (\delta)}, \tag {15}
$$
where  $C_n(\cdot)$  is a continuous function such that  $C_n(\delta) \to 0$  when  $\delta \to 0$ .
Proof. Let  $\mathbb{M} = \oplus_{i=1}^{m} M_i$  and  $\mathbb{M}' = \oplus_{j=1}^{m'} M_j'$  be two persistence modules that are decomposable into intervals, let  $x \in \mathbb{R}^k$  and let  $0 \leq \delta \leq \min\{\delta(\mathbb{M}), \delta(\mathbb{M}')\}$ .
Notations. We first introduce some notations. Let  $N$  (resp.  $N^{\prime}$ ) be the number of bars in  $B_{\mathbf{e}_{\Delta},x}$  (resp.  $B_{\mathbf{e}_{\Delta},x}^{\prime}$ ), and assume without loss of generality that  $N \leq N^{\prime}$ . Let  $\Gamma$  be the partial matching achieving  $d_{\mathrm{B}}(B_{\mathbf{e}_{\Delta},x}, B_{\mathbf{e}_{\Delta},x}^{\prime})$ . Let  $N_{1}$  (resp.  $N_{2}$ ) be the number of bars in  $B_{\mathbf{e}_{\Delta},x}$  that are matched (resp. not matched) to a bar in  $B_{\mathbf{e}_{\Delta},x}^{\prime}$  under  $\Gamma$ , so that  $N = N_{1} + N_{2}$ . Finally, note that  $B_{\mathbf{e}_{\Delta},x} = \{\ell : \exists i$  such that  $\ell \in \mathcal{C}(\mathrm{im}(\ell_{\mathbf{e}_{\Delta},x}) \cap M_i)$  and  $\mathrm{im}(\ell_{\mathbf{e}_{\Delta},x}) \cap M_i \neq \emptyset\}$ , where  $\mathcal{C}$  stands for the set of connected components (and similarly for  $B_{\mathbf{e}_{\Delta},x}^{\prime}$ ), and let  $F_{\Gamma}: B_{\mathbf{e}_{\Delta},x} \to B_{\mathbf{e}_{\Delta},x}^{\prime}$  be a function defined on all bars of  $B_{\mathbf{e}_{\Delta},x}$  that coincides with  $\Gamma$  on the  $N_{1}$  bars of  $B_{\mathbf{e}_{\Delta},x}$  that have an associated bar in  $B_{\mathbf{e}_{\Delta},x}^{\prime}$ , and that maps the  $N_{2}$  remaining bars of  $B_{\mathbf{e}_{\Delta},x}$  to some arbitrary bars in the  $(N^{\prime} - N_{1})$  remaining bars of  $B_{\mathbf{e}_{\Delta},x}^{\prime}$ .
A reformulation of the problem with vectors. We now derive vectors that allow to reformulate the problem in a useful way. Let  $\hat{V}$  be the sorted vector of dimension  $N$  containing all weights  $\| \mathcal{N}(x,\sigma)\cdot f\| _1$ , where  $f$  is the interval function whose support is  $T_{\delta}(\ell)\cap M_i$  for some  $M_{i}$ , where  $\ell \in B_{\mathbf{e}_{\Delta},x}$  is a connected component of  $\mathrm{im}(\ell_{\mathbf{e}_{\Delta},x})\cap M_i$ . Now, let  $\hat{V}^{\prime}$  be the vector of dimension  $N^{\prime}$  obtained by concatenating the two following vectors:
- the vector  $\hat{V}_1'$  of dimension  $N$  whose  $i$ th coordinate is  $\|\mathcal{N}(x, \sigma) \cdot f'\|_1$ , where  $f'$  is the interval function whose support is  $T_{\delta}(\ell') \cap M_j'$  for some  $M_j'$ , and  $\ell' \in B_{\mathbf{e}_{\Delta}, x}'$  is the image under  $\Gamma$  of the bar  $\ell \in B_{\mathbf{e}_{\Delta}, x}$  corresponding to the  $i$ th coordinate of  $\hat{V}$ , i.e.,  $\ell' = F_{\Gamma}(\ell)$  where  $[\hat{V}]_i = \|\mathcal{N}(x, \sigma) \cdot f\|_1$  and  $f$  is the interval function whose support is  $T_{\delta}(\ell) \cap M_{i_0}$  for some  $M_{i_0}$ . In other words,  $\hat{V}_1'$  is the (not necessarily sorted) vector of weights computed on the bars of  $B_{\mathbf{e}_{\Delta}, x}'$  that are images (under the partial matching  $\Gamma$  achieving the bottleneck distance) of the bars of  $B_{\mathbf{e}_{\Delta}, x}$  that were used to generate the (sorted) vector  $\hat{V}$ .
- the vector  $\hat{V}_2'$  of dimension  $(N' - N)$  whose  $j$ th coordinate is  $\|\mathcal{N}(x, \sigma) \cdot f'\|_1$ , where  $f'$  is an interval function whose support is  $T_\delta(\ell') \cap M_j'$  for some  $M_j'$ , and  $\ell' \in B_{\mathbf{e}_{\Delta}, x}'$  satisfies  $\ell' \notin \mathrm{im}(F_\Gamma)$ . In other words,  $\hat{V}_2'$  is the vector of weights computed on the bars of  $B_{\mathbf{e}_{\Delta}, x}'$  (in an arbitrary order) that are not images of bars of  $B_{\mathbf{e}_{\Delta}, x}$  under  $\Gamma$ .
Finally, we let  $V$  be the vector of dimension  $N'$  obtained by filling  $\hat{V}$  (whose dimension is  $N \leq N'$ ) with null values until its dimension becomes  $N'$ , and we let  $V' = \operatorname{sort}(\hat{V}')$  be the vector obtained after sorting the coordinates of  $\hat{V}'$ . Observe that:
$$
\left| V _ {\delta , \sigma} (\mathbb {M}) (x) - V _ {\delta , \sigma} \left(\mathbb {M} ^ {\prime}\right) (x) \right| = \left[ V - V ^ {\prime} \right] _ {1} = \left[ V - \operatorname {s o r t} \left(\hat {V} ^ {\prime}\right) \right] _ {1} \tag {16}
$$
An upper bound. We now upper bound  $\left\| V - \hat{V}^{\prime}\right\|_{\infty}$ . Let  $q\in [[1,N^{\prime}]]$ . Then, one has  $[V]_q = \|\mathcal{N}(x,\sigma)\cdot f\|_1$ , where  $f$  is an interval function whose support is  $T_{\delta}(\ell)\cap M_i$  for some  $M_{i}$  with  $\ell \in B_{\mathbf{e}_{\Delta},x}$  if  $q\leq N$  and  $\ell = \emptyset$  otherwise; and similarly  $[\hat{V}^{\prime}]_{q} = \| \mathcal{N}(x,\sigma)\cdot f^{\prime}\|_{1}$ , where  $f^{\prime}$  is an interval function whose support is  $T_{\delta}(\ell^{\prime})\cap M_j^{\prime}$  for some  $M_j^\prime$  with  $\ell^{\prime}\in B_{\mathbf{e}_{\Delta},x}^{\prime}$ . Thus, one has:
$$
\begin{array}{l} [ V - \hat {V} ^ {\prime} ] _ {q} = | \| \mathcal {N} (x, \sigma) \cdot f \| _ {1} - \| \mathcal {N} (x, \sigma) \cdot f ^ {\prime} \| _ {1} | \\ \leq \| \mathcal {N} (x, \sigma) \cdot f - \mathcal {N} (x, \sigma) \cdot f ^ {\prime} \| _ {1} \text {b y} \\ = \| \mathcal {N} (x, \sigma) \cdot \left(f - f ^ {\prime}\right) \| _ {1} \text {b y} \\ \leq \| \mathcal {N} (x, \sigma) \| _ {2} \cdot \| f - f ^ {\prime} \| _ {2} \text {b y} \\ = (\sqrt {\pi} \sigma) ^ {k} \cdot \| f - f ^ {\prime} \| _ {2} \\ \end{array}
$$
Since  $(f - f^{\prime})$  is an interval function whose support is  $(T_{\delta}(\ell)\cap M_i)\triangle (T_{\delta}(\ell^{\prime})\cap M_j^{\prime})$ , one has  $\| f - f^{\prime}\|_{2} = \sqrt{|(T_{\delta}(\ell)\cap M_{i})\triangle(T_{\delta}(\ell^{\prime})\cap M_{j}^{\prime})|}$ . Given a segment  $\ell$  and a vector  $\mathbf{u}$ , we let  $\ell_{\mathbf{u}}$  denote the segment  $\mathbf{u} + \ell$ , and we let  $\ell^{\mathbf{u}}$  denote the (infinite) line induced by  $\ell_{\mathbf{u}}$ . More precisely:
$$
\begin{array}{l} \left\| f - f ^ {\prime} \right\| _ {2} ^ {2} = \left| \left(T _ {\delta} (\ell) \cap M _ {i}\right) \triangle \left(T _ {\delta} \left(\ell^ {\prime}\right) \cap M _ {j} ^ {\prime}\right) \right| \\ = \left| \bigcup_ {\mathbf {u}} \left(\ell^ {\mathbf {u}} \cap M _ {i}\right) \triangle \bigcup_ {\mathbf {u}} \left(\left(\ell^ {\prime}\right) ^ {\mathbf {u}} \cap M _ {j} ^ {\prime}\right) \right| \\ \end{array}
$$
where  $\mathbf{u}$  ranges over the vectors such that  $\| \mathbf{u}\|_{\infty}\leq \delta ,\langle \mathbf{u},\mathbf{e}_{\Delta}\rangle = 0$
$$
\begin{array}{l} \leq \int_ {\mathbf {u}} | (\ell^ {\mathbf {u}} \cap M _ {i}) \triangle ((\ell^ {\prime}) ^ {\mathbf {u}} \cap M _ {j} ^ {\prime}) | \mathrm {d} \mathbf {u} \\ \leq \int_ {\mathbf {u}} | (\ell^ {\mathbf {u}} \cap M _ {i}) \triangle (\ell \cap M _ {i}) _ {\mathbf {u}} | + | (\ell \cap M _ {i}) _ {\mathbf {u}} \triangle (\ell^ {\prime} \cap M _ {j} ^ {\prime}) _ {\mathbf {u}} | + | (\ell^ {\prime} \cap M _ {j} ^ {\prime}) _ {\mathbf {u}} \triangle ((\ell^ {\prime}) ^ {\mathbf {u}} \cap M _ {j} ^ {\prime}) | d \mathbf {u} \\ \leq \int_ {\mathbf {u}} 4 d _ {\mathrm {B}} \left(B _ {\mathbf {e} _ {\Delta}, x}, B _ {\mathbf {e} _ {\Delta}, x + \mathbf {u}}\right) + 4 d _ {\mathrm {B}} \left(B _ {\mathbf {e} _ {\Delta}, x}, B _ {\mathbf {e} _ {\Delta}, x} ^ {\prime}\right) + 4 d _ {\mathrm {B}} \left(B _ {\mathbf {e} _ {\Delta}, x} ^ {\prime}, B _ {\mathbf {e} _ {\Delta}, x + \mathbf {u}} ^ {\prime}\right) \mathrm {d} \mathbf {u} \tag {17} \\ \leq 4 \int_ {\mathbf {u}} \| \mathbf {u} \| _ {\infty} + d _ {\mathrm {I}} (\mathbb {M}, \mathbb {M} ^ {\prime}) + \| \mathbf {u} \| _ {\infty} \mathrm {d} \mathbf {u} \text {b y L e m m a 1 a n d 2} \\ \end{array}
$$
Inequality (17) comes from the fact that the symmetric difference between two bars (in two different barcodes) that are both matched (or unmatched) by the optimal partial matching is upper bounded by four times the bottleneck distance between the barcodes, and that (by assumption) the partial matchings achieving  $d_{\mathrm{B}}(B_{\mathbf{e}_{\Delta},x},B_{\mathbf{e}_{\Delta},x + \mathbf{u}})$  and  $d_{\mathrm{B}}(B_{\mathbf{e}_{\Delta},x}^{\prime},B_{\mathbf{e}_{\Delta},x + \mathbf{u}}^{\prime})$  are induced by  $\mathbb{M}$  and  $\mathbb{M}'$ .
Conclusion. Finally, one has
$$
\begin{array}{l} \left| V _ {\delta , \sigma} (\mathbb {M}) (x) - V _ {\delta , \sigma} \left(\mathbb {M} ^ {\prime}\right) (x) \right| = \left[ V - V ^ {\prime} \right] _ {1} = \left[ V - \operatorname {s o r t} \left(\hat {V} ^ {\prime}\right) \right] _ {1} \text {f r o m E q u a t i o n (1 6)} \\ \leq \left\| V - V ^ {\prime} \right\| _ {\infty} \\ \leq (\sqrt {\pi} \sigma) ^ {k} \cdot \sqrt {2 ^ {n + 1} \delta^ {n - 1} d _ {\mathrm {I}} (\mathbb {M} , \mathbb {M} ^ {\prime}) + C _ {n} (\delta)}, \tag {18} \\ \end{array}
$$
with  $C_n(\delta) = 8\int_{\mathbf{u}}\|\mathbf{u}\|_{\infty} \, \mathrm{d}\mathbf{u} \to 0$  when  $\delta \to 0$ . Inequality (18) comes from the fact that any upper bound for the norm of the difference between a given vector  $\hat{V}'$  and a sorted vector  $V$ , is also an upper bound for the norm of the difference between the sorted version  $V'$  of  $\hat{V}'$  and the same vector  $V$  (see Lemma 3.9 in [12]).
While the stability constant is not upper bounded by  $\delta$ ,  $V_{\delta, \sigma}$  is more difficult to compute than the S-CDRs presented in Definition 2.
H Pseudo-code for S-CDRs
In this section, we briefly present the pseudo-code that we use to compute S-CDRs. Our code is based on implicit descriptions of the candidate decompositions of multiparameter persistence modules (which are the inputs of S-CDRs) through their so-called birth and death corners. These corners can be obtained with, e.g., the public softwares MMA [29] and Rivet [28].
In order to compute our S-CDRs, we implement the following procedures:
1. Given an interval module  $M$  and a rectangle  $R \subset \mathbb{R}^n$ , compute the restriction  $M|_R$ .
2. Given an interval module  $M$  (or  $M|_{R}$ ), compute  $d_{\mathrm{I}}(M,0)$ . This allows to compute our weight function and first interval representation in Definition 2.
3. Given an interval module restricted to a rectangle, compute the volume of the biggest rectangle in the support of this module. This allows to compute the third interval representation in Definition 2.
For the first point, Algorithm 1 works by "pushing" the corners of the interval on the given rectangle in order to obtain the updated corners.
Algorithm 1: Restriction of an interval module to a rectangle
Data: birth and death corners of an interval module  $M$ , rectangle  $R = \{z \in \mathbb{R}^n : m \leq z \leq M\}$   
Result: new_interval_corners, the birth and death corners of  $M|_R$ .  
for interval = {interval_birth_corners, interval_death_corners} in  $M$  do  
    new_birth_list ← [];  
    for b in interval_birth_corners do  
        if b ≤ M then  
            b' = {max(b_i, m_i) for i ∈ [1, n]};
            Append b' to new_birth_list;  
        end  
    end  
    new_death_list ← [];  
    for d in interval_death_corners do  
        if d ≥ m then  
            d' = {min(d_i, M_i) for i ∈ [1, n)];
            Append d' to new_death_list;  
        end  
    end  
    new_interval_corners ← [new_birth_list, new_death_list];  
end
For the second point, we proved in Lemma 3 that our S-CDR weight function is equal to  $d_{\mathrm{I}}(M,0)$  and has a closed-form formula with corners, that we implement in Algorithm 2.
Algorithm 2: S-CDR weight function
Data: birth and death corners of an interval module M  
Result: distance, the interleaving distance  $d_{I}(M,0)$ .  
distance  $\leftarrow 0$ ;  
for  $b$  in  $M$  birthcorners do  
    for  $d$  in  $M$  deathcorners do  
    distance  $\leftarrow$  max (result,  $\frac{1}{2} \min_{i} (d_{i} - b_{i})_{+}$ );  
    end  
end
The third point also has a closed-form formula with corners, leading to Algorithm 3.
Algorithm 3: S-CDR interval representation
Data: birth and death corners of an interval module  $M$   
Result: volume, the volume of the biggest rectangle fitting in supp  $(M)$   
volume  $\leftarrow 0$ ;  
for  $b$  in  $M$ -birthcorners do  
for  $d$  in  $M$ -deathcorners do  
| volume  $\leftarrow$  max(result,  $\Pi_i(d_i - b_i)_+$ );  
end  
end
Finally, we show how to get the persistence barcodes corresponding to slices of an interval module solely from the corners of the interval module.
Algorithm 4: Restriction of an interval module to a line
Data: birth and death corners of an interval module  $M$ , a diagonal line  $l$   
Result: barcode, the persistence barcode associated to  $M|_l$   
barcode  $\leftarrow []$ ;  
 $y \gets$  an arbitrary point in  $l$ ;  
for interval = {interval_birth_corners, interval_death_corners} in M do  
    birth  $\leftarrow y + 1 \times \min_{b \in \text{interval\_birth\_corners}} \max_i b_i - y_i$ ;  
    death  $\leftarrow y + 1 \times \max_{d \in \text{interval\_death\_corners}} \min_i d_i - y_i$ ;  
    bar  $\leftarrow$  [birth, death];  
    Append bar to barcode;  
end
I UCR acronyms
Dataset	Acronym
DistalPhalanxOutlineAgeGroup	DPOAG
DistalPhalanxOutlineCorrect	DPOC
ProximalPhalanxOutlineAgeGroup	PPOAG
ProximalPhalanxOutlineCorrect	PPOC
ProximalPhalanxTW	PPTW
ItalyPowerDemand	IPD
GunPoint	GP
GunPointAgeSpan	GPAS
GunPointMaleVersusFemale	GPMVF
PowerCons	PC