spark-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From HHB <hihellobo...@gmail.com>
Subject Re: Graphx traversal and merge interesting edges
Date Sat, 05 Jul 2014 10:26:55 GMT
Thanks Ankur,

Cannot thank you enough for this!!! I am reading your example still digesting & grokking
it though :-)

I was breaking my head over this for past few hours.....

In my last futile attempts over past few hours. I was looking at Pregel... E.g if that could
be used to see at what step of a path match the vertex is in and send message to next vertex
with the history of traversal.. then for merging message append the historical traversal path
of for each message :-P. 

--Gautam

On 05-Jul-2014, at 3:23 pm, Ankur Dave <ankurdave@gmail.com> wrote:

> Interesting problem! My understanding is that you want to (1) find paths matching a particular
pattern, and (2) add edges between the start and end vertices of the matched paths.
> 
> For (1), I implemented a pattern matcher for GraphX that iteratively accumulates partial
pattern matches. I used your example in the unit test.
> 
> For (2), you can take the output of the pattern matcher (the set of matching paths organized
by their terminal vertices) and construct a set of new edges using the initial and terminal
vertices of each path. Then you can make a new graph consisting of the union of the original
edge set and the new edges. Let me know if you'd like help with this.
> 
> Ankur
> 


Mime
View raw message