@Test public void testJoinWithBroadcastSet() throws Exception { /* * Join with broadcast set */ final ExecutionEnvironment env = ExecutionEnvironment.getExecutionEnvironment(); DataSet<Integer> intDs = CollectionDataSets.getIntegerDataSet(env); DataSet<Tuple3<Integer, Long, String>> ds1 = CollectionDataSets.getSmall3TupleDataSet(env); DataSet<Tuple5<Integer, Long, Integer, String, Long>> ds2 = CollectionDataSets.getSmall5TupleDataSet(env); DataSet<Tuple3<String, String, Integer>> joinDs = ds1.fullOuterJoin(ds2) .where(1) .equalTo(4) .with(new T3T5BCJoin()) .withBroadcastSet(intDs, "ints"); List<Tuple3<String, String, Integer>> result = joinDs.collect(); String expected = "Hi,Hallo,55\n" + "Hi,Hallo Welt wie,55\n" + "Hello,Hallo Welt,55\n" + "Hello world,Hallo Welt,55\n"; compareResultAsTuples(result, expected); }
appliedSet = appliedSet.withBroadcastSet(e.f1, e.f0); appliedSet = appliedSet.withBroadcastSet(numberOfVertices, "number of vertices");
.withBroadcastSet(input1, "bc2") .withBroadcastSet(result1, "bc3") .output(new DiscardingOutputFormat<String>());
.equalTo(0) .with(new JoinAndNormalizeHubAndAuthority<>()) .withBroadcastSet(hubbinessSumSquared, HUBBINESS_SUM_SQUARED) .withBroadcastSet(authoritySumSquared, AUTHORITY_SUM_SQUARED) .setParallelism(parallelism) .name("Join scores");
appliedSet = appliedSet.withBroadcastSet(e.f1, e.f0); appliedSet = appliedSet.withBroadcastSet(numberOfVertices, "number of vertices");
appliedSet = appliedSet.withBroadcastSet(e.f1, e.f0); appliedSet = appliedSet.withBroadcastSet(numberOfVertices, "number of vertices");
appliedSet = appliedSet.withBroadcastSet(e.f1, e.f0); appliedSet = appliedSet.withBroadcastSet(numberOfVertices, "number of vertices");
embeddings = join.withBroadcastSet(superstep, ExplorativePatternMatching.BC_SUPERSTEP); } else { embeddings = join;
embeddings = join.withBroadcastSet(superstep, ExplorativePatternMatching.BC_SUPERSTEP); } else { embeddings = join;
embeddings = join.withBroadcastSet(superstep, ExplorativePatternMatching.BC_SUPERSTEP); } else { embeddings = join;
embeddings = join.withBroadcastSet(superstep, ExplorativePatternMatching.BC_SUPERSTEP); } else { embeddings = join;
.equalTo(0) .with(new JoinAndNormalizeHubAndAuthority<>()) .withBroadcastSet(hubbinessSumSquared, HUBBINESS_SUM_SQUARED) .withBroadcastSet(authoritySumSquared, AUTHORITY_SUM_SQUARED) .setParallelism(parallelism) .name("Join scores");
.equalTo(0) .with(new JoinAndNormalizeHubAndAuthority<K>()) .withBroadcastSet(hubbinessSumSquared, HUBBINESS_SUM_SQUARED) .withBroadcastSet(authoritySumSquared, AUTHORITY_SUM_SQUARED) .setParallelism(parallelism) .name("Join scores");
.equalTo(0) .with(new JoinAndNormalizeHubAndAuthority<>()) .withBroadcastSet(hubbinessSumSquared, HUBBINESS_SUM_SQUARED) .withBroadcastSet(authoritySumSquared, AUTHORITY_SUM_SQUARED) .setParallelism(parallelism) .name("Join scores");