SlowGuess/NeurIPS_2023_OCR huggingface dataset:
The CUTENC procedure is called in a bottom-up order to ensure that the representations of the grandchildren are already computed. We learn the cut node subtree representations instead of employing the hierarchical overrides that are present in the KHC algorithm, as the latter is not ideal in a learning algorithm. However, with sufficient layers, these representations are complete invariants.
UPDATE. Putting these altogether, we update the node representations  $h_u^{(\ell)}$  of each node  $u$  as:
$$
\begin{array}{l} \boldsymbol {h} _ {u} ^ {(\ell)} = f ^ {(\ell)} \left(g _ {1} ^ {(\ell)} \left(\boldsymbol {h} _ {u} ^ {(\ell - 1)} + \sum_ {v \in N _ {u}} \boldsymbol {h} _ {v} ^ {(\ell - 1)}\right) \| g _ {2} ^ {(\ell)} \left(\sum_ {v \in V} \boldsymbol {h} _ {v} ^ {(\ell - 1)}\right) \right\| \\ g _ {3} ^ {(\ell)} \left(\boldsymbol {h} _ {u} ^ {(\ell - 1)} + \sum_ {C \in \sigma_ {u} ^ {G}} \widehat {\boldsymbol {h}} _ {C} ^ {(\ell)}\right) \| g _ {4} ^ {(\ell)} \left(\boldsymbol {h} _ {u} ^ {(\ell - 1)} + \sum_ {B \in \pi_ {u} ^ {G}} \widetilde {\boldsymbol {h}} _ {B} ^ {(\ell)}\right) \| \overline {{\boldsymbol {h}}} _ {\delta_ {u}} ^ {(\ell)}\biggr), \\ \end{array}
$$
where  $f^{(\ell)}$  and  $g_{i}^{(\ell)}$  are either linear maps or two-layer MLPs. Finally, we pool as:
$$
\boldsymbol {z} _ {G} = \operatorname {M L P} \left(\left\| _ {\ell = 1} ^ {L} \left(\sum_ {u \in V ^ {G}} \boldsymbol {h} _ {u} ^ {(\ell)}\right)\right). \right.
$$
6 Expressive power and efficiency of BASEPLANE
We present the theoretical result of this paper, which states that BASEPLANE can distinguish any pair of planar graphs, even when using only a logarithmic number of layers in the size of the input graphs:
Theorem 6.1. For any planar graphs  $G_{1} = (V_{1},E_{1},\zeta_{1})$  and  $G_{2} = (V_{2},E_{2},\zeta_{2})$ , there exists a parametrization of BASEPLANE with at most  $L = \lceil \log_2(\max \{|V_1|,|V_2|\}) \rceil + 1$  layers, which computes a complete graph invariant, that is, the final graph-level embeddings satisfy  $z_{G_1}^{(L)} \neq z_{G_2}^{(L)}$  if and only if  $G_{1}$  and  $G_{2}$  are not isomorphic.
The construction is non-uniform, since the number of layers needed depends on the size of the input graphs. In this respect, our result is similar to other results aligning GNNs with 1-WL with sufficiently many layers [45, 63]. There are, however, two key differences: (i) BASEPLANE computes isomorphism-complete invariants over planar graphs and (ii) our construction requires only logarithmic number of layers in the size of the input graphs (as opposed to linear).
The theorem builds on the properties of each encoder being complete. We first show that a single application of TRIENC and BIENC is sufficient to encode all relevant components of an input graph in an isomorphism-complete way:
Lemma 6.2. Let  $G = (V, E, \zeta)$  be a planar graph. Then, for any biconnected components  $B, B'$  of  $G$ , and for any SPQR components  $C$  and  $C'$  of  $G$ , there exists a parametrization of the functions TRIENC and BIENC such that:
(i)  $\widetilde{\pmb{h}}_B\neq \widetilde{\pmb{h}}_{B'}$  if and only if  $B$  and  $B^{\prime}$  are not isomorphic, and
(ii)  $\widehat{\pmb{h}}_C\neq \widehat{\pmb{h}}_{C'}$  if and only if  $C$  and  $C^\prime$  are not isomorphic.
Intuitively, this result follows from a natural alignment to the procedures of the KHC algorithm: the existence of unique codes for different components is proven for the algorithm and we lift this result to the embeddings of the respective graphs, using the universality of MLPs [14, 31, 32].
Our main result rests on a key result related to CUTENC, which states that BASEPLANE computes complete graph invariants for all subtrees of the Block-Cut tree. We use an inductive proof, where the logarithmic bound stems from a single layer computing complete invariants for all subtrees induced by cut nodes that have at most one grandchild cut node, the induced subtree of which is incomplete.
Lemma 6.3. For a planar graph  $G = (V, E, \zeta)$  of order  $n$  and its associated Block-Cut tree  $\delta = \text{BLOCKCUT}(G)$ , there exists a  $L = \lceil \log_2(n) \rceil + 1$  layer parametrization of BASEPLANE that computes a complete graph invariant for each subtree  $\delta_u$  induced by each cut node  $u$ .
With Lemma 6.2 and Lemma 6.3 in place, Theorem 6.1 follows from the fact that every biconnected component and every cut node of the graph are encoded in an isomorphism-complete way, which is sufficient for distinguishing planar graphs.
Runtime efficiency. Theoretically, the runtime of one BasePlanE layer is  $\mathcal{O}(|V|d^2)$  with a (one-off) pre-processing time  $\mathcal{O}(|V|^2)$  as we elaborate in Appendix B. In practical terms, this makes BasePlanE linear in the number of graph nodes after preprocessing. This is very scalable as opposed to other complete algorithms based on 3-WL (or, oblivious 4-WL).
In this section, we evaluate BASEPLANE in three different settings. First, we conduct three experiments to evaluate the expressive power of BASEPLANE. Second, we evaluate a BASEPLANE variant using edge features on the MolHIV graph classification task from OGB [33, 61]. Finally, we evaluate this variant on graph regression over ZINC [18] and QM9 [12, 48]. We provide an additional experiment on the runtime of BASEPLANE in Appendix B, and an ablation study on ZINC in Appendix C. All experimental details, including hyperparameters, can be found in Appendix D<sup>5</sup>.
7.1 Expressiveness evaluation
7.1.1 Planar satisfiability benchmark: EXP
Experimental setup. We evaluate BASEPLANE on the planar EXP benchmark [1] and compare with standard MPNNs, MPNNs with random node initialization and (higher-order) 3-GCNs [45]. EXP consists of planar graphs which each represent a satisfiability problem (SAT) instance. These instances are grouped into pairs, such that these pairs cannot be distinguished by 1-WL, but lead to different SAT outcomes. The task in EXP is to predict the satisfiability of each instance. To obtain above-random performance on this dataset, a model must have a sufficiently strong expressive power (2-WL or more). To conduct this experiment, we use a 2-layer BASE-
Table 1: Accuracy results on EXP. Baselines are from Abboud et al. [1].
Model	Accuracy (%)
GCN	50.0±0.00
GCN-RNI(N)	98.0±1.85
3-GCN	99.7±0.004
BASEPLANE	100±0.00
PLANE model with 64-dimensional node embeddings. We instantiate the triconnected component encoder with 16-dimensional positional encodings, each computed using a periodicity of 64.
5Across all experiments, we present tabular results, and follow a convention in which the best result is bold in black, and the second best result is shown in bold in gray.
Results. All results are reported in Table 1. As expected, BASEPLANE perfectly solves the task, achieving a performance of  $100\%$  (despite not relying on any higher-order method). BASEPLANE solely relies on classical algorithmic component decompositions, and does not rely on explicitly selected and designed features, to achieve this performance gain. This experiment highlights that the general algorithmic decomposition effectively improves expressiveness in a practical setup, and leads to strong performance on EXP, where a standard MPNN would otherwise fail.
7.1.2 Planar 3-regular graphs: P3R
Experimental setup. We propose a new synthetic dataset P3R based on 3-regular planar graphs, and experiment with BASEPLANE, GIN and 2-WL-expressive PPGN [43]. For this experiment, we generated all 3-regular planar graphs of size 10, leading to exactly 9 non-isomorphic graphs. For each such graph, we generated 50 isomorphic graphs by permuting their nodes. The task is then to predict the correct class of an input graph, where the random accuracy is approximately  $11.1\%$ . This task is challenging given the regularity of the graphs.
Table 2: Accuracy results on P3R.
Model	Accuracy (%)
GIN	11.1 ±0.00
PPGN	100 ±0.00
BASEPLANE	100 ±0.00
Results. We report all results in Table 2. As expected, GIN struggles to go beyond a random guess, whereas BASEPLANE and PPGNs easily solve the task, achieving  $100\%$  accuracy.
7.1.3 Clustering coefficients of QM9 graphs:  $\mathrm{QM9}_{\mathrm{CC}}$
In this experiment, we evaluate the ability of BASEPLANE to detect structural graph signals without an explicit reference to the target structure. To this end, we propose a simple, yet challenging, synthetic task: given a subset of graphs from QM9, we aim to predict the graph-level clustering coefficient (CC). Computing CC requires counting triangles in the graph, which is impossible to solve with standard MPNNs [65].
Data. We select a subset  $\mathrm{QM9}_{\mathrm{CC}}$  of graphs from QM9 to obtain a diverse distribution of CCs. As most QM9 graphs have a CC of 0, we consider graphs with a CC in the interval [0.06, 0.16], as this range has high variability. We then normalize the CCs to the unit interval [0, 1]. We apply the earlier filtering on the original QM9 splits to obtain train/validation/test sets that are direct subsets of the full QM9 splits, and which consist of 44226, 3941 and 3921 graphs, respectively.
Experimental setup. Given the small size of QM9 and the locality of triangle counting, we use 32-dimensional node embeddings and 3 layers across all models. Moreover, we use a common 100 epoch training setup for fairness. For evaluation, we report mean absolute error (MAE) on the test set, averaged across 5 runs. For this experiment, our baselines are (i) an input-agnostic constant prediction that returns a minimal test MAE, (ii) the MPNNs GCNs [40] and GIN [63], (iii) ESAN [7], an MPNN that computes sub-structures through node and edge removals, but which does not explicitly extract triangles, and (iv) BASEPLANE, using 16-dimensional positional encoding vectors.
Results. Results on  $\mathrm{QM9}_{\mathrm{CC}}$  are provided in Table 3. BASE-PLANE comfortably outperforms standard MPNNs. Indeed, GCN performance is only marginally better than the constant baseline and GIN's MAE is over an order of magnitude behind BASEPLANE. This is a very substantial gap, and confirms that MPNNs are unable to accurately detect triangles to compute CCs. Moreover, BASEPLANE achieves an MAE over  $40\%$  lower than ESAN. Overall, BASEPLANE effectively detects triangle structures, despite these not being explicitly provided, and thus its underlying algorithmic decomposition effectively captures latent structural graph properties in this setting.
Table 3: MAE of BASEPLANE and baselines on the QM9cc dataset.
Model	MAE
Constant	0.1627 ±0.0000
GCN	0.1275 ±0.0012
GIN	0.0612 ±0.0018
ESAN	0.0038 ±0.0010
BASEPLANE	0.0023±0.0004
Performance analysis. To better understand our results, we visualize the predictions of BASEPLANE, GIN, and GCN using scatter plots in Figure 4. As expected, BASEPLANE follows the ideal regression line. By contrast, GIN and GCN are much less stable. Indeed, GIN struggles with CCs at the extremes of the  $[0,1]$  range, but is better at intermediate values, whereas GCN is consistently unreliable, and rarely returns predictions above 0.7. This highlights the structural limitation of GCNs, namely its self-loop mechanism for representation updates, which causes ambiguity for detecting triangles.
Figure 4: Scatter plots of BASEPLANE, GIN, and GCN predictions versus the true normalized CC. The red line represents ideal behavior where predictions match the true normalized CC.
7.2 Graph classification on MolHIV
Model setup. We use a BASEPLANE variant that uses edge features, called E-BASEPLANE (defined in the appendix), on OGB [33] MolHIV and compare against baselines. We instantiate E-BASEPLANE with an embedding dimension of 64, 16-dimensional positional encodings, and report the average ROC-AUC across 10 independent runs.
Results. The results for E-BASEPLANE and other baselines on MolHIV are shown in Table 4: Despite not explicitly extracting relevant cycles and/or molecular sub-structures, E-BASEPLANE outperforms standard MPNNs and the domain-specific HIMP model. It is also competitive with substructure-aware models CIN and GSN, which include dedicated structures for inference. Therefore, E-BASEPLANE performs strongly in practice with minimal design effort, and effectively uses its structural inductive bias to remain competitive with dedicated architectures.
Table 4: ROC-AUC of BASE-PLANE and baselines on MolHIV.
GCN [40]	75.58±0.97
GIN [63]	77.07±1.40
PNA [13]	79.05±1.32
ESAN [7]	78.00±1.42
GSN [11]	80.39±0.90
CIN [9]	80.94±0.57
HIMP [20]	78.80±0.82
E-BASEPLANE	80.04±0.50
7.3 Graph regression on QM9
Experimental setup. We map QM9 [48] edge types into features by defining a learnable embedding per edge type, and subsequently apply E-BASEPLANE to the dataset. We evaluate E-BASEPLANE on all 13 QM9 properties following the same splits and protocol (with MAE results averaged over 5 test set reruns) of GNN-FiLM [12]. We compare R-SPN against GNN-FiLM models and their fully adjacent (FA) variants [3], as well as shortest path networks (SPNs) [2]. We report results with an 3-layer E-BASEPLANE using 128-dimensional node embeddings and 32-dimensional positional encodings.
Results. E-BASEPLANE results on QM9 are provided in Table 5. In this table, E-BASEPLANE outperforms high-hop SPNs, despite being simpler and more efficient, achieving state-of-the-art results on 9 of the 13 tasks. The gains are particularly prominent on the first five properties, where R-SPNs originally provided relatively little improvement over FA models, suggesting that E-BASEPLANE offers complementary structural advantages to SPNs. This was corroborated in our experimental tuning: E-BASEPLANE performance peaks around 3 layers, whereas SPN performance continues to improve up to 8 (and potentially more) layers, which suggests that E-BASEPLANE is more efficient at directly communicating information, making further message passing redundant.
Overall, E-BASEPLANE maintains the performance levels of R-SPN with a smaller computational footprint. Indeed, messages for component representations efficiently propagate over trees in E-BASEPLANE, and the number of added components is small (see appendix for more details). Therefore E-BASEPLANE and the PLANE framework offer a more scalable alternative to explicit higher-hop neighborhood message passing over planar graphs.
Table 5: MAE of E-BASEPLANE and baselines on QM9. Other model results and their fully adjacent (FA) extensions are as previously reported [2, 3].
Property	R-GIN	R-GAT	R-SPN	BASEPLANE
base	+FA	base	+FA	k=5	k=10
mu	2.64±0.11	2.54±0.09	2.68±0.11	2.73±0.07	2.16±0.08	2.21±0.21	1.97±0.03
alpha	4.67±0.52	2.28±0.04	4.65±0.44	2.32±0.16	1.74±0.05	1.66±0.06	1.63±0.01
HOMO	1.42±0.01	1.26±0.02	1.48±0.03	1.43±0.02	1.19±0.04	1.20±0.08	1.15±0.01
LUMO	1.50±0.09	1.34±0.04	1.53±0.07	1.41±0.03	1.13±0.01	1.20±0.06	1.06±0.02
gap	2.27±0.09	1.96±0.04	2.31±0.06	2.08±0.05	1.76±0.03	1.77±0.06	1.73±0.02
R2	15.63±1.40	12.61±0.37	52.39±42.5	15.76±1.17	10.59±0.35	10.63±1.01	10.53±0.55
ZPVE	12.93±1.81	5.03±0.36	14.87±2.88	5.98±0.43	3.16±0.06	2.58±0.13	2.81±0.16
U0	5.88±1.01	2.21±0.12	7.61±0.46	2.19±0.25	1.10±0.03	0.89±0.05	0.95±0.04
U	18.71±23.36	2.32±0.18	6.86±0.53	2.11±0.10	1.09±0.05	0.93±0.03	0.94±0.04
H	5.62±0.81	2.26±0.19	7.64±0.92	2.27±0.29	1.10±0.03	0.92±0.03	0.92±0.04
G	5.38±0.75	2.04±0.24	6.54±0.36	2.07±0.07	1.04±0.04	0.83±0.05	0.88±0.04
Cv	3.53±0.37	1.86±0.03	4.11±0.27	2.03±0.14	1.34±0.03	1.23±0.06	1.20±0.06
Omega	1.05±0.11	0.80±0.04	1.48±0.87	0.73±0.04	0.53±0.02	0.52±0.02	0.45±0.01
7.4 Graph regression on ZINC
Experimental setup. We (i) evaluate BASEPLANE on the ZINC subset (12k graphs) without edge features, (ii) evaluate E-BASEPLANE on this subset and on the full ZINC dataset (500k graphs). To this end, we run BASEPLANE and E-BASEPLANE with 64 and 128-dimensional embeddings, 16-dimensional positional embeddings, and 3 layers. For evaluation, we compute MAE on the respective test sets, and report the best average of 10 runs across all experiments.
Results. Results on ZINC are shown in Table 6: Both BASEPLANE and E-BASEPLANE perform strongly, with E-BASEPLANE achieving state-of
the-art performance on ZINC12k with edge features and both models outperforming all but one baseline in the other two settings. These results are very promising, and highlight the robustness of (E-)BASEPLANE.
Table 6: MAE of (E-)BASEPLANE and baselines on ZINC.
Edge Features	ZINC(12k) No	ZINC(12k) Yes	ZINC(Full) Yes
GCN [40]	0.278±0.003	-	-
GIN(-E) [34, 63]	0.387±0.015	0.252±0.014	0.088±0.002
PNA [13]	0.320±0.032	0.188±0.004	0.320±0.032
GSN [11]	0.140±0.006	0.101±0.010	-
CIN [9]	0.115±0.003	0.079±0.006	0.022±0.002
ESAN [7]	-	0.102±0.003	-
HIMP [20]	-	0.151±0.006	0.036±0.002
(E-)BASEPLANE	0.124±0.004	0.076±0.003	0.028±0.002
8 Limitations, discussions, and outlook
Overall, both BASEPLANE and E-BASEPLANE perform strongly across all our experimental evaluation tasks, despite competing against specialized models in each setting. Moreover, both models are isomorphism-complete over planar graphs. This implies that these models benefit substantially from the structural inductive bias and expressiveness of classical planar algorithms, which in turn makes them a reliable, efficient, and robust solution for representation learning over planar graphs.
Though the PLANE framework is a highly effective and easy to use solution for planar graph representation learning, it is currently limited to planar graphs. Indeed, the classical algorithms underpinning PLANE do not naturally extend beyond the planar graph setting, which in turn limits the applicability of the approach. Thus, a very important avenue for future work is to explore alternative (potentially incomplete) graph decompositions that strike a balance between structural inductive bias, efficiency and expressiveness on more general classes of graphs.
The authors would like to thank the anonymous reviewers for their feedback which led to substantial improvements in the presentation of the paper. The authors would like to also acknowledge the use of the University of Oxford Advanced Research Computing (ARC) facility in carrying out this work (http://dx.doi.org/10.5281/zenodo.22558).
[1] Ralph Abboud, Ismail Ilkan Ceylan, Martin Grohe, and Thomas Lukasiewicz. The surprising power of graph neural networks with random node initialization. In Proceedings of the Thirtieth International Joint Conference on Artificial Intelligence, IJCAI, 2021.
[2] Ralph Abboud, Radoslav Dimitrov, and Ismail Ilkan Ceylan. Shortest path networks for graph property prediction. In Proceedings of the First Annual Learning on Graphs Conference, LoG, 2022.
[3] Uri Alon and Eran Yahav. On the bottleneck of graph neural networks and its practical implications. In Proceedings of the Ninth International Conference on Learning Representations, ICLR, 2021.
[4] László Babai. Graph isomorphism in quasipolynomial time. In Proceedings of the Forty-Eighth Annual ACM Symposium on Theory of Computing, STOC, 2016.
[5] Pablo Barceló, Egor V. Kostylev, Mikaël Monet, Jorge Pérez, Juan L. Reutter, and Juan Pablo Silva. The logical expressiveness of graph neural networks. In Proceedings of the Eighth International Conference on Learning Representations, ICLR, 2020.
[6] Peter W Battaglia, Jessica B Hamrick, Victor Bapst, Alvaro Sanchez-Gonzalez, Vinicius Zambaldi, Mateusz Malinowski, Andrea Tacchetti, David Raposo, Adam Santoro, Ryan Faulkner, et al. Relational inductive biases, deep learning, and graph networks. arXiv preprint:1806.01261, 2018.
[7] Beatrice Bevilacqua, Fabrizio Frasca, Derek Lim, Balasubramaniam Srinivasan, Chen Cai, Gopinath Balamurugan, Michael M. Bronstein, and Haggai Maron. Equivariant subgraph aggregation networks. In Proceedings of the Tenth International Conference on Learning Representations, ICLR, 2022.
[8] Sandeep N Bhatt and Frank Thomson Leighton. A framework for solving VLSI graph layout problems. Journal of Computer and System Sciences, 28(2):300-343, 1984.
[9] Cristian Bodnar, Fabrizio Frasca, Nina Otter, Yuguang Wang, Pietro Liò, Guido F. Montúfar, and Michael M. Bronstein. Weisfeiler and lehman go cellular: CW networks. In Proceedings of the Thirty-Fourth Annual Conference on Advances in Neural Information Processing Systems, NeurIPS, 2021.
[10] Kellogg S Booth and George S Lueker. Testing for the consecutive ones property, interval graphs, and graph planarity using pq-tree algorithms. Journal of Computer and System Sciences, 13(3):335-379, 1976.
[11] Giorgos Bouritsas, Fabrizio Frasca, Stefanos Zafeiriou, and Michael M. Bronstein. Improving graph neural network expressivity via subgraph isomorphism counting. IEEE Transactions on Pattern Analysis and Machine Intelligence, 45(1):657-668, 2023.
[12] Marc Brockschmidt. GNN-FiLM: Graph neural networks with feature-wise linear modulation. In Proceedings of the Thirty-Seventh International Conference on Machine Learning, ICML, 2020.
[13] Gabriele Corso, Luca Cavalleri, Dominique Beaini, Pietro Lio, and Petar Velickovic. Principal neighbourhood aggregation for graph nets. In Proceedings of the Thirty-Third Annual Conference on Advances in Neural Information Processing Systems, NeurIPS, 2020.
A Proofs of the statements
In this section, we provide the proofs of the statements from the main paper. Throughout the proofs, we make the standard assumption that the initial node features are from a compact space  $K \subseteq \mathbb{R}^d$ , for some  $d \in \mathbb{N}^+$ . We also often need to canonically map elements of finite sets to the integer domain: given a finite set  $S$ , and any element  $x \in S$  of this set, the function  $\Psi(S, x): S \to \{1, \ldots, |S|\}$  maps  $x$  to a unique integer index given by some fixed order over the set  $S$ . Furthermore, we also often need to injectively map sets into real numbers, which is given by the following lemma.
Lemma A.1. Given a finite set  $S$ , there exists an injective map  $g: \mathbb{P}(S) \to [0, 1]$ .
Proof. For each subset  $M \subseteq S$ , consider the mapping:
$$
g (M) = \frac {1}{1 + \sum_ {x \in M} \Psi (S , x) | S | ^ {\Psi (M , x)}},
$$
which clearly satisfies  $g(M_1) \neq g(M_2)$  for any  $M_1 \neq M_2 \subseteq S$ .
We now provide proofs for Lemma 6.2, Lemma 6.3 which are essential for Theorem 6.1. Let us first prove Lemma 6.2:
Lemma 6.2. Let  $G = (V, E, \zeta)$  be a planar graph. Then, for any biconnected components  $B, B'$  of  $G$ , and for any SPQR components  $C$  and  $C'$  of  $G$ , there exists a parameterization of the functions TRIENC and BIENC such that:
Proof. We show this by first giving a parameterization of TRIENC to distinguish all SPQR components, and then use this construction to give a parameterization of BIENC to distinguish all biconnected components. The proof aligns the encoders with the code generation procedure in the KHC algorithm. The parameterization needs only a single layer, so we will drop the superscripts in the node representations and write, e.g.,  $h_u$ , for brevity. The construction yields single-dimensional real-valued vectors, and, for notational convenience, we view the resulting representations as reals.
Parameterizing TRIENC. We initialize the node features as  $h_u = \zeta(u)$ , where  $\zeta: V \to \mathbb{R}^d$ . Given an SPQR component  $C$  and the initial node representations  $h_u$  of each node  $u$ , TRIENC encodes  $C$  based on the walk  $\omega$  given by Weinberg's algorithm, and its corresponding sequence  $\kappa$  as:
$$
\widehat {\boldsymbol {h}} _ {C} = \operatorname {M L P} \left(\sum_ {i = 1} ^ {| \omega |} \operatorname {M L P} \left(\boldsymbol {h} _ {\omega [ i ]} \| \boldsymbol {p} _ {\kappa [ i ]} \| \boldsymbol {p} _ {i}\right)\right). \tag {1}
$$
In other words, we rely on the walks  $\omega$  generated by Weinberg's algorithm: we create a walk on the triconnected components that visits each edge exactly twice. Let us fix  $n = 4(|V| + |E| + 1)$ , which serves as an upper bound for size of the walks  $\omega$ , and the size of the walk-induced sequence  $\kappa$ .
We show a bijection between the multiset of codes  $\mathcal{F}$  (given by the KHC algorithm), and the multiset of representations  $\mathcal{M}$  (given by TRIENC), where the respective multisets are defined, based on  $G$ , as follows: