public class EuclideanGraphWeighing extends Object implements org.apache.flink.api.common.ProgramDescription
Graph.getTriplets() and
Graph.joinWithEdges(DataSet, EdgeJoinFunction) methods.
Given a directed, unweighted graph, with vertex values representing points in a plan,
return a weighted graph where the edge weights are equal to the Euclidean distance between the
src and the trg vertex values.
Input files are plain text files and must be formatted as follows:
1,1.0,1.0\n2,2.0,2.0\n3,3.0,3.0\n defines a data set of three vertices
1,2\n1,3\n defines two edges 1-2 and 1-3.
EuclideanGraphWeighing <vertex path> <edge path> <result path>EuclideanGraphData| Modifier and Type | Class and Description |
|---|---|
static class |
EuclideanGraphWeighing.Point
A simple two-dimensional point.
|
| Constructor and Description |
|---|
EuclideanGraphWeighing() |
| Modifier and Type | Method and Description |
|---|---|
String |
getDescription() |
static void |
main(String[] args) |
Copyright © 2014–2016 The Apache Software Foundation. All rights reserved.