Code review

Code review


Job Description

I'm trying to implement Personalized PageRank. I wrote this code but I'm confused with something. I need someone to confirm whether it is correct or not. The code computes PageRank score exactly with an algebraic NOT iterative approach.

The code takes two input files:

1. nonUniformVection.csv << the personalization vector for non-uniform node weights

It is formatted so that the first column has the nodes and the second has the weight. [find it here][1]

2. linkmatrix.csv << the linkmatrix between nodes it is formatted as follows:

1st column has the weight of the link
2nd column has the from node (the node from which the link starts)
3rd column has the to node (the node to which the link is heading or pointing to)

so for example 173,$Er,$k means the link $Er --> $k has a weight of 183.
[find the file here][2]

That is the code I have [here][3]

I think line 16

A[inds[to_node], inds[from_node]] = weight

should be

A[inds[from_node], inds[to_node]] = weight

Am I correct?

I need an answer TODAY!