Coalesce the temporal graph.
Coalesce the temporal graph. Some operations are known to have the potential to make the TGraph uncoalesced. If the graph is known to be coalesced, this is a no-op.
Structural zoom.
Structural zoom. Creates nodes from clusters of existing nodes, assigning them new ids. Edge ids remain unchanged and are all preserved.
The function to apply to node attributes when multiple nodes are mapped by a Skolem function to a single group. Any associative function can be supported, since the attribute aggregation is performed in pairs (ala reduce).
The Skolem function that assigns a new node id consistently
New tgraph with only the new nodes and edges connecting them. A multigraph.
Time zoom
Time zoom
The desired duration of time intervals in the temporal sequence in sematic units (days, months, years) or number of changes
The quantification over vertices -- how much of the window must a node appear in to be included.
The quantification over edges -- how much of the window must an edge appear in to be included.
The function to apply to vertex attributes when multiple values exist in a time window. Any associative function can be supported, since the attribute aggregation is performed in pairs.
New tgraph with a modified temporal resolution. Foreign key constraint is enforced.
The degree of each vertex in the graph by interval.
The degree of each vertex in the graph by interval.
Vertices with no edges are not returned in the resulting RDD.
An RDD containing the edges and their associated attributes.
An RDD containing the edges and their associated attributes.
an RDD containing the edges in this graph, across all intervals.
Select a subgraph based on the edge attributes.
Select a subgraph based on the edge attributes.
new TGraph, with only edges that pass the predicates, but all nodes, even if those nodes have 0 degree as a result.
Get a snapshot for a point in time.
Get a snapshot for a point in time.
Single GraphX org.apache.spark.graphx.Graph.
Unless in GraphX, each edge in TGraph has an EdgeId.
,If the time is outside the graph bounds, an empty graph is returned.
Get the temporal sequence for the representative graphs composing this tgraph.
Get the temporal sequence for the representative graphs composing this tgraph.
RDD of Interval. Intervals are consecutive, nonoverlapping, and not necessarily equally sized.
The call to materialize the data structure.
The call to materialize the data structure. This is a convenience operation for evaluation purposes.
The number of partitions this graph occupies
Repartition the edges in the graph according to the strategy.
Repartition the edges in the graph according to the strategy.
The partitioning object including strategy, runs, and number of partitions.
new partitioned graph
Caches the vertices and edges associated with this graph at the specified storage level, ignoring any target storage levels previously set.
Caches the vertices and edges associated with this graph at the specified storage level, ignoring any target storage levels previously set.
the level at which to cache the graph.
A reference to this graph for convenience.
Just as in GraphX, Execute a Pregel-like iterative vertex-parallel abstraction, but over each time instance of the TGraph.
Just as in GraphX, Execute a Pregel-like iterative
vertex-parallel abstraction, but over each time instance of the
TGraph. The user-defined vertex-program vprog
is executed in
parallel on each vertex receiving any inbound messages and
computing a new value for the vertex. The sendMsg
function is
then invoked on all out-edges and is used to compute an optional
message to the destination vertex. The mergeMsg
function is a
commutative associative function used to combine messages
destined to the same vertex. The computation is performed on all
time periods consecutively or all together, depending on the
implementation of the graph.
On the first iteration all vertices receive the initialMsg
and
on subsequent iterations if a vertex does not receive a message
then the vertex-program is not invoked.
This function iterates until there are no remaining messages, or
for maxIterations
iterations.
the Pregel message type
the message each vertex will receive at the on the first iteration
the maximum number of iterations to run for
the direction of edges incident to a vertex that received a message in
the previous round on which to run sendMsg
. For example, if this is EdgeDirection.Out
, only
out-edges of vertices that received a message in the previous round will run. The default is
EdgeDirection.Either
, which will run sendMsg
on edges where either side received a message
in the previous round. If this is EdgeDirection.Both
, sendMsg
will only run on edges where
*both* vertices received a message.
the user-defined vertex program which runs on each vertex and receives the inbound message and computes a new vertex value. On the first iteration the vertex program is invoked on all vertices and is passed the default message. On subsequent iterations the vertex program is only invoked on those vertices that receive messages.
a user supplied function that is applied to out edges of vertices that received messages in the current iteration
a user supplied function that takes two incoming messages of type A and merges them into a single message of type A. This function must be commutative and associative and ideally the size of A should not increase.
the resulting graph at the end of the computation
The duration the temporal sequence
The duration the temporal sequence
an Interval from the earliest graph change to the last
Select a temporal subset of the graph.
Select a temporal subset of the graph.
Time period to extract. Intervals are closed-open.
TGraph with the temporal intersection or empty graph if the requested interval is wholely outside of the graph bounds.
Uncaches both vertices and edges of this graph.
Uncaches both vertices and edges of this graph. This is useful in iterative algorithms that build a new graph in each iteration.
An RDD containing the vertices and their associated attributes.
An RDD containing the vertices and their associated attributes.
an RDD containing the vertices in this graph, across all intervals. The vertex attributes are a tuple of (Interval, value), which means that if the same vertex appears in multiple periods, it will appear multiple times in the RDD. The interval is maximal. This is the direct match to our model.
An RDD is returned rather than VertexRDD because VertexRDD cannot have duplicates for vid.
Select a subgraph based on the vertex attributes.
Select a subgraph based on the vertex attributes.
new TGraph, with only nodes that pass the predicate are retained. Foreign key constraint is enforced.
A friendly name for this TGraph
Assign a name to this TGraph
A TGraph abstractly represents a single evolving graph, consisting of nodes, node properties, edges, edge properties, and addition, modification, and deletion of these over time. The TGraph provides operations of the temporal algebra and accessors. Like Spark and GraphX, the TGraph is immutable -- operations return new TGraphs.
the node/vertex attribute type
the edge attribute type
GraphLoader contains convenience operations for loading TGraphs