Package org.apache.spark.graphx
Class EdgeRDD<ED>
- All Implemented Interfaces:
Serializable
,org.apache.spark.internal.Logging
- Direct Known Subclasses:
EdgeRDDImpl
EdgeRDD[ED, VD]
extends RDD[Edge[ED}
by storing the edges in columnar format on each
partition for performance. It may additionally store the vertex attributes associated with each
edge to provide the triplet view. Shipping of the vertex attributes is managed by
impl.ReplicatedVertexView
.- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.apache.spark.internal.Logging
org.apache.spark.internal.Logging.LogStringContext, org.apache.spark.internal.Logging.SparkShellLoggingFilter
-
Constructor Summary
ConstructorDescriptionEdgeRDD
(SparkContext sc, scala.collection.immutable.Seq<Dependency<?>> deps) -
Method Summary
Modifier and TypeMethodDescriptioncompute
(Partition part, TaskContext context) :: DeveloperApi :: Implemented by subclasses to compute a given partition.static <ED,
VD> EdgeRDDImpl<ED, VD> fromEdges
(RDD<Edge<ED>> edges, scala.reflect.ClassTag<ED> evidence$4, scala.reflect.ClassTag<VD> evidence$5) Creates an EdgeRDD from a set of edges.abstract <ED2,
ED3> EdgeRDD<ED3> innerJoin
(EdgeRDD<ED2> other, scala.Function4<Object, Object, ED, ED2, ED3> f, scala.reflect.ClassTag<ED2> evidence$2, scala.reflect.ClassTag<ED3> evidence$3) Inner joins this EdgeRDD with another EdgeRDD, assuming both are partitioned using the samePartitionStrategy
.abstract <ED2> EdgeRDD<ED2>
Map the values in an edge partitioning preserving the structure but changing the values.reverse()
Reverse all the edges in this RDD.Methods inherited from class org.apache.spark.rdd.RDD
aggregate, barrier, cache, cartesian, checkpoint, cleanShuffleDependencies, coalesce, collect, collect, context, count, countApprox, countApproxDistinct, countApproxDistinct, countByValue, countByValueApprox, dependencies, distinct, distinct, doubleRDDToDoubleRDDFunctions, filter, first, flatMap, fold, foreach, foreachPartition, getCheckpointFile, getNumPartitions, getResourceProfile, getStorageLevel, glom, groupBy, groupBy, groupBy, id, intersection, intersection, intersection, isCheckpointed, isEmpty, iterator, keyBy, localCheckpoint, map, mapPartitions, mapPartitionsWithEvaluator, mapPartitionsWithIndex, max, min, name, numericRDDToDoubleRDDFunctions, partitioner, partitions, persist, persist, pipe, pipe, pipe, preferredLocations, randomSplit, rddToAsyncRDDActions, rddToOrderedRDDFunctions, rddToPairRDDFunctions, rddToSequenceFileRDDFunctions, reduce, repartition, sample, saveAsObjectFile, saveAsTextFile, saveAsTextFile, setName, sortBy, sparkContext, subtract, subtract, subtract, take, takeOrdered, takeSample, toDebugString, toJavaRDD, toLocalIterator, top, toString, treeAggregate, treeAggregate, treeReduce, union, unpersist, withResources, zip, zipPartitions, zipPartitions, zipPartitions, zipPartitions, zipPartitions, zipPartitions, zipPartitionsWithEvaluator, zipWithIndex, zipWithUniqueId
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.apache.spark.internal.Logging
initializeForcefully, initializeLogIfNecessary, initializeLogIfNecessary, initializeLogIfNecessary$default$2, isTraceEnabled, log, logDebug, logDebug, logDebug, logDebug, logError, logError, logError, logError, logInfo, logInfo, logInfo, logInfo, logName, LogStringContext, logTrace, logTrace, logTrace, logTrace, logWarning, logWarning, logWarning, logWarning, org$apache$spark$internal$Logging$$log_, org$apache$spark$internal$Logging$$log__$eq, withLogContext
-
Constructor Details
-
EdgeRDD
-
-
Method Details
-
fromEdges
public static <ED,VD> EdgeRDDImpl<ED,VD> fromEdges(RDD<Edge<ED>> edges, scala.reflect.ClassTag<ED> evidence$4, scala.reflect.ClassTag<VD> evidence$5) Creates an EdgeRDD from a set of edges.- Parameters:
edges
- (undocumented)evidence$4
- (undocumented)evidence$5
- (undocumented)- Returns:
- (undocumented)
-
compute
Description copied from class:RDD
:: DeveloperApi :: Implemented by subclasses to compute a given partition. -
mapValues
public abstract <ED2> EdgeRDD<ED2> mapValues(scala.Function1<Edge<ED>, ED2> f, scala.reflect.ClassTag<ED2> evidence$1) Map the values in an edge partitioning preserving the structure but changing the values.- Parameters:
f
- the function from an edge to a new edge valueevidence$1
- (undocumented)- Returns:
- a new EdgeRDD containing the new edge values
-
reverse
Reverse all the edges in this RDD.- Returns:
- a new EdgeRDD containing all the edges reversed
-
innerJoin
public abstract <ED2,ED3> EdgeRDD<ED3> innerJoin(EdgeRDD<ED2> other, scala.Function4<Object, Object, ED, ED2, ED3> f, scala.reflect.ClassTag<ED2> evidence$2, scala.reflect.ClassTag<ED3> evidence$3) Inner joins this EdgeRDD with another EdgeRDD, assuming both are partitioned using the samePartitionStrategy
.- Parameters:
other
- the EdgeRDD to join withf
- the join function applied to corresponding values ofthis
andother
evidence$2
- (undocumented)evidence$3
- (undocumented)- Returns:
- a new EdgeRDD containing only edges that appear in both
this
andother
, with values supplied byf
-