The input matrix should ensure that the following conditions hold:
- directed graph
- No self edges
- No duplicate edges
- compressed sparse column (CSC) format
Note that this is not the “normalized” PageRank:
- The results are the same as some third-party graph databases, ex. Tigergraph
- The results are the same as some third-party graph databases after normalized of order 1, ex. Spark
- In the current version, the weighted PageRank algorithm is implemented by default.
- For the input unweighted graph, the user still needs to initialize the weight buffer manually to make the kernel work normally, as shown in the ./tests/host codes.
The algorithm implemention is shown as the figure below:
Figure 1 : PageRank calculate degree architecture on FPGA
Figure 2 : PageRank initiation module architecture on FPGA
Figure 3 : PageRank Adder architecture on FPGA
Figure 4 : PageRank calConvergence architecture on FPGA
As we can see from the figure:
- Module calculate degree: first get the vertex node’s outdegree and keep them in one DDR buffer.
- Module initiation: initiate PR DDR buffers and constant value buffer.
- Module Adder: calculate Sparse matrix multiplification.
- Module calConvergence: calculate convergence of pagerank iteration.