Skip to content

Commit

Permalink
migrate estimation cli scc to application layer
Browse files Browse the repository at this point in the history
  • Loading branch information
lassewesth committed Dec 3, 2024
1 parent d66c744 commit baeff69
Show file tree
Hide file tree
Showing 8 changed files with 7 additions and 366 deletions.
5 changes: 2 additions & 3 deletions algo/src/main/java/org/neo4j/gds/scc/Scc.java
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,8 @@
* specified in: http://code.activestate.com/recipes/578507-strongly-connected-components-of-a-directed-graph/
*/
public class Scc extends Algorithm<HugeLongArray> {
public static final int UNORDERED = -1;
public static final String SCC_DESCRIPTION = "The SCC algorithm finds sets of connected nodes in an directed graph, " +
"where all nodes in the same set form a connected component.";
private static final int UNORDERED = -1;

private final Graph graph;
private final HugeLongArrayStack boundaries;
private final HugeLongArray connectedComponents;
Expand Down
56 changes: 0 additions & 56 deletions algo/src/main/java/org/neo4j/gds/scc/SccAlgorithmFactory.java

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
import org.neo4j.gds.config.ConcurrencyConfig;
import org.neo4j.gds.core.concurrency.DefaultPool;
import org.neo4j.gds.core.utils.paged.dss.DisjointSetStruct;
import org.neo4j.gds.core.utils.progress.tasks.ProgressTracker;
import org.neo4j.gds.core.utils.progress.tasks.Task;
import org.neo4j.gds.core.utils.progress.tasks.Tasks;
import org.neo4j.gds.k1coloring.K1ColoringBaseConfig;
Expand Down Expand Up @@ -400,6 +401,10 @@ HugeLongArray scc(Graph graph, AlgoBaseConfig configuration) {
Tasks.leaf(AlgorithmLabel.SCC.asString(), graph.nodeCount())
);

return scc(graph, configuration, progressTracker);
}

public HugeLongArray scc(Graph graph, ConcurrencyConfig configuration, ProgressTracker progressTracker) {
var algorithm = new Scc(graph, progressTracker, terminationFlag);

return algorithmMachinery.runAlgorithmsAndManageProgressTracker(
Expand Down

0 comments on commit baeff69

Please sign in to comment.