At 2014-08-02 21:29:33 +0530, Deep Pradhan <pradhandeep1...@gmail.com> wrote: > How should I run graphx codes?
At the moment it's a little more complicated to run the GraphX algorithms than the Spark examples due to SPARK-1986 [1]. There is a driver program in org.apache.spark.graphx.lib.Analytics which you can invoke using spark-submit: $SPARK_HOME/bin/spark-submit --master local[*] --class org.apache.spark.graphx.lib.Analytics \ $SPARK_HOME/assembly/target/scala-2.10/spark-assembly-*.jar \ pagerank /edge-list-file.txt --numEPart=8 --numIter=10 --partStrategy=EdgePartition2D This supports running PageRank, connected components, and triangle count. For the other algorithms, you can use the Spark shell: import org.apache.spark.graphx._ val graph = (GraphLoader.edgeListFile(sc, "/edge-list-file.txt", minEdgePartitions = 8) .partitionBy(PartitionStrategy.EdgePartition2D)) // Run algorithms on graph Ankur [1] https://issues.apache.org/jira/browse/SPARK-1986 --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscr...@spark.apache.org For additional commands, e-mail: user-h...@spark.apache.org