3

I have an un-directed graph. Is there any efficient function to collect direct neighbors of specific vertex Id using Spark Graphframes? (This feature is available in GraphX [link])

If yes, how can we achieve neighbors of level 2, 3 and ... (It means that the neighbors reachable with shortest path of length more than 1)

As the best of my knowledge, only solution of this task is using find() and filter() combination (Motif Finding). but 2 issues arise:

  1. Is it efficient? Motif finding is build for un-anchored queries (query on patterns), not anchored (query on a specific vertex).
  2. Using join on dataframe is suitable for directed edge table. but my graph is un-directed.
MohsenIT
  • 304
  • 4
  • 10
  • See for example https://stackoverflow.com/q/37417469/1560062 – zero323 May 30 '17 at 07:53
  • 1
    but my graph is un-directed and the query is anchored. – MohsenIT May 30 '17 at 08:23
  • 1
    I have been able to use DataFrames and motif-finding patterns for this purpose. With DataFrame joins, it's a little bit easier to do things since you could follow a convention of "src" and "dst" for edges and "id" for vertices even for undirected graphs. – Kedar Mhaswade Jul 22 '17 at 19:45

0 Answers0