At 2014-10-25 08:56:34 +0530, Arpit Kumar <arp8...@gmail.com> wrote:
> GraphLoader1.scala:49: error: class EdgePartitionBuilder in package impl
> cannot be accessed in package org.apache.spark.graphx.impl
> [INFO]       val builder = new EdgePartitionBuilder[Int, Int]

Here's a workaround:

1. Copy and modify the GraphLoader source as you did, but keep it in the 
org.apache.spark.graphx.impl package to fix the package-private error.
2. In addition to changing the persistence level of the edges RDD in 
GraphLoader, construct the VertexRDD and EdgeRDD yourself.
3. Call GraphImpl.fromExistingRDDs to construct the graph. This function will 
respect the existing EdgeRDD storage level.
4. Use the graph as desired. Be sure to avoid Graph#partitionBy, the Pregel 
API, and all of the built-in algorithms, because they call Graph#cache() on 
intermediate graphs.

Here is a modified version of GraphLoader that does 1-3: 
https://gist.github.com/ankurdave/0394d47809297eea76ff

Ankur

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@spark.apache.org
For additional commands, e-mail: user-h...@spark.apache.org

Reply via email to