A Graph Neural Network (GNN) extends CNN learning to graph data. A graph can be represented as a combination of nodes and edges, where nodes represent the features of the graph and edges joins adjacent nodes, as shown in the following image:
![](https://static.packt-cdn.com/products/9781838827069/graphics/assets/6a8aa8c8-a922-451d-a628-e4fe47a74170.png)
In this image, the nodes are illustrated by solid white points and the edges by the lines joining the points.
The following equations describe the key parameters of the graph:
The transformations of the graph into a vector consisting of nodes, edges, and the relationships between the nodes are called the graph embeddings. The embeddings vector can be represented by the following equation:
![](https://static.packt-cdn.com/products/9781838827069/graphics/assets/bf7c8f82-5f0e-4320-b0ad-d04d5784b777.png)
![](https://static.packt-cdn.com/products/9781838827069/graphics/assets/d7d40bb1-0130-4fcc-9d63-da235f6c1f83.png)
The following list describes the elements of the preceding equation:
- h[n] = State embedding for current node n
- hne[n] = State embedding of the neighborhood of the node n
- x[n] = Feature of the node n
- xe[n] = Feature of the edge of...