# Structural Hierarchy-Enhanced Network Representation Learning
## 3 The Proposed SHE-NRL Model
hierarchy height. The \(\tau\) is automatically determined by repeatedly generating new communities from the previous level's graph until \(n_{h}<\rho\), where \(n_{h}\) is the number of communities in level-\(h\)'s graph \(H^{h}\). Phase 2: Intra-level NRL. Given level-\(h\) graph \(H^{h}\), we perform intra-level NRL. We allow any of NRL methods that preserves structural proximity between nodes in our SHE-NRL framework. That said, typical NRL methods, such as DeepWalk [1], LINE [2], and node2 vec [3], can be used for intra-level NRL. Let \(\mathbf{X}^{h}\) be the generated embedding matrix for all nodes in \(H^{h}\). The intra-level NRL is iteratively performed in a one-round circular manner. The bottom-up way is first executed, followed by the top-down way. Specifically, the intra-level NRL is performed one after another from \(H^{0}\), \(H^{1}\) to \(H^{\tau}\), i.e., the bottom-up way. Then we again iteratively perform the intra-level NRL from \(H^{\tau}\), \(H^{\tau-1}\) to \(H^{0}\), i.e., the top-down way. The bottom-up way brings fine-grained level's interactions between nodes into the intra-level NRLs at higher levels in the hierarchy. The top-down way of message passing makes the intra-level NRLs at lower levels be aware of coarse-grained community knowledge. All intra-level NRLs at level-\(h\) graphs \(H^{h}\) (\(0\leq h\leq\tau-1\)) are executed twice while the level-\(\tau\) NRL is executed only one time. In the next phase, we will discuss how \(\mathbf{X}^{h}\) can be used to initialize the node embeddings of graphs \(H^{h+1}\) and \(H^{h-1}\). We randomly initialize the embeddings of nodes for NRL in the original graph \(H^{0}=G\). Phase 3: Level-wise Pooling Mechanism. In order to bring fine-grained information of node interactions into higher-level NRLs, and make lower-level NRLs be aware of coarse-grained community knowledge at higher levels of the hierarchy, we propose the level-wise pooling mechanism. The pooling mechanism consists of bottom-up pooling and top-down pooling. The bottom-up pooling utilizes the node embeddings \(\mathbf{X}^{h}\) of \(H^{h}\) to initialize the node embeddings of \(H^{h+1}\)'s NRL. The max pooling is adopted as the bottom-up pooling. The max pooling is performed to initialize the embedding of node \(v_{j}^{h+1}\) at \(H^{h+1}\) from the corresponding \(i\)-th community \(C_{i}^{h}\) at \(H^{h}\). We exploit the most significant learned node embedding in community \(C_{i}^{h}\) at \(H^{h}\) to be the initial node embedding of node \(v_{j}^{h+1}\) at \(H^{h+1}\). On the other hand, the average pooling is adopted as the top-down pooling. The average pooling is performed to initialize the embeddings of all nodes in the \(i\)-th community \(C_{i}^{h}\) at \(H^{h}\) from the learned node embedding of node \(v_{j}^{h+1}\) at \(H^{h+1}\). That said, given the new-learned node embedding of node \(u_{j}^{h+1}\) at \(H^{h+1}\), denoted by \(\mathbf{x}_{u}^{h+1}\), and the previously-generated embedding of corresponding lower-level node \(v^{h}\in C_{i}^{h}\) at \(H^{h}\), denoted by \(\mathbf{x}_{v}^{h}\), we have the new initial embedding of node \(v^{h}\), denoted by \(\mathbf{x}_{v}^{h}\), based on the equation:  
\[\mathbf{x}_{v}^{h}=avg(\mathbf{x}_{v}^{h},\mathbf{x}_{u}^{h+1}). \tag{2}\]  
Utilizing the average pooling for the top-down way of NRLs is able to distribute coarse-grained community knowledge back to the NRLs at lower-level graphs. Note that we utilize two different letters \(v\) and \(u\) here is to better distinguish nodes at different levels, i.e., \(v\) refers to a node at level \(h\) and \(u\) refers to a node at level \(h+1\). Phase 2 and Phase 3 are iteratively adopted one after the other in first the bottom-up way, then the top-down way. In other words, in the bottom-up way, when node embeddings are generated by NRL in \(H^{h}\) (Phase 2), they are immediately brought to initialize the embeddings of nodes in \(H^{h+1}\) via max pooling (Phase 3).