giraph-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sardeshmukh, Vivek" <vivek-sardeshm...@uiowa.edu>
Subject Vertex with no outgoing edges doesn't execute Compute in Superstep 0
Date Thu, 28 Aug 2014 19:56:10 GMT
Hello all,


I was playing around with Shortest path example. I decided to write my own input format to
match with SNAP's LJ dataset (

<http://snap.stanford.edu/data/soc-LiveJournal1.html)>http://snap.stanford.edu/data/soc-LiveJournal1.html
). This is an edge format so I wrote LongFloatTextEdgeInputFormat (which is similar to IntNullTextEdgeInputFormat
given in io/formats directory).

To test this I had following input :


0 1

0 2

0 3

1 2

2 0

2 3


And all edges have weight 1.

I tried running ShortestPath example by specifying the edge input format and the above input
file and I got the following output :

0 2.0

1 0

2 1.0

3 0


Notice that for vertex 3 it should be 2 (source is vertex 1). I thought there is some problem
with my input format, so went back to vertex input format as specified in the quick start
guide. Here is my vertex input in JSON format :

[0,0,[[1,1],[2,1],[3,1]]]
[1,0,[[2,1]]]
[2,0,[[3,1],[0,1]]]


Notice that vertex 3 doesn't have any outgoing edge so I didn't added an entry for it. Even
with this I got the same output. Then I enabled debug and found that

Vertex 3 doesn't execute Superstep 0 at all. It only executed Superstep 3 and 4 (in Superstep
3 it receives a message from vertex 2). Also, in Superstep 3 it shows that it has vertex value
= 0.

Does it mean that vertices with no outgoing edges are not "active" in the beginning? Is there
any way to fix this?


A quick and dirty fix will be adding a line to vertex input file - [3, 0, []]

but what if I don't want to use vertex input format and use edge input format as described
above?


Thank you.

Sincerely,
Vivek

Mime
View raw message