diff --git a/computer-algorithm/src/main/java/org/apache/hugegraph/computer/algorithm/sampling/RandomWalk.java b/computer-algorithm/src/main/java/org/apache/hugegraph/computer/algorithm/sampling/RandomWalk.java index 6dc8be87e..5c9a19057 100644 --- a/computer-algorithm/src/main/java/org/apache/hugegraph/computer/algorithm/sampling/RandomWalk.java +++ b/computer-algorithm/src/main/java/org/apache/hugegraph/computer/algorithm/sampling/RandomWalk.java @@ -73,6 +73,7 @@ public void init(Config config) { "actual got '%s'", OPTION_WALK_PER_NODE, this.walkPerNode); } + LOG.info("[RandomWalk] algorithm param, {}: {}", OPTION_WALK_PER_NODE, walkPerNode); this.walkLength = config.getInt(OPTION_WALK_LENGTH, 3); if (this.walkLength < 1) { @@ -80,6 +81,7 @@ public void init(Config config) { "actual got '%s'", OPTION_WALK_LENGTH, this.walkLength); } + LOG.info("[RandomWalk] algorithm param, {}: {}", OPTION_WALK_LENGTH, walkLength); this.random = new Random(); } @@ -93,7 +95,7 @@ public void compute0(ComputationContext context, Vertex vertex) { if (vertex.numEdges() <= 0) { // isolated vertex - vertex.value(message.path()); + this.savePath(vertex, message.path()); // save result vertex.inactivate(); return; } @@ -111,8 +113,7 @@ public void compute(ComputationContext context, Vertex vertex, Iterator