Hi Danny, thanks very much for your fast reply!Yes at the first iteration, each edge weight has been set to 1/num_outedgess. However, the following iterations will set it to the pagerank/v.num_outedges();, as shown in https://github.com/GraphChi/graphchi-cpp/blob/master/example_apps/pagerank.cpp#L94-L104. So it seems that the edge weight has set to the pagerank of its starting vertex.Sorry, I might not state clearly about the weight. I tentatively want to build a weighted edgelist file with the format for each line as <src dst weight>. This weight is a permanent for each edge and conflicts with the contemporary 'weight' during the shard updating iterations. Thus shall I use the dynamic data to store both the permanent and contemporary 'weights'?
On Monday, January 27, 2014 11:42:31 PM UTC-7, Danny Bickson wrote:Hi,I guess you are asking about graphchi?The graph is considered undirected and at the first iteration each edge weight is set to 1/ num_of_neighbors, see the code here: https://github.com/GraphChi/graphchi-cpp/blob/master/example_apps/pagerank.cpp#L81-L82If you like to read weights from file you can use the following example: https://github.com/GraphChi/graphchi-cpp/blob/master/example_apps/matrix_factorization/als_vertices_inmem.cpp#L235which reads a matrix market format file (see documentation here: http://bickson.blogspot.co.il/2012/02/matrix-market-format.html)Regarding your question, edge->get_data() does not store the temporary pagerank value, but does get the edge value (which is 1/num_of_neighbors).Anyway the only change you have to do is change the way the weights are initialized since the rest of the algorithm takes the weights into account.Best,Danny BicksonCo-Founder
GraphLab Inc.On Tue, Jan 28, 2014 at 6:09 AM, <zhang...@gmail.com> wrote:Hi all, recently I am working on computing the pagerank value for the weighted directed graph, i.e., the edgelist format is "<src> <dst> <weight>". Instead treating each out-edge equally in unweighted graphs, Pagerank for weighted graph should assign the value proportional to the weight of each out-edge. It seems that the current example_apps/pagerank.cpp works for the unweighted graph, and graphchi_edge->get_data() has been used for store the temporary pagerank value. Any idea on include the pre-defined edge weight during the pagerank computation? Thanks very much!--To unsubscribe from this group and stop receiving emails from it, send an email to graphlab-kdd...@googlegroups.com.
You received this message because you are subscribed to the Google Groups "GraphLab Users" group.--
You received this message because you are subscribed to the Google Groups "GraphLab Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to graphlab-kdd...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.