@@ -79,23 +79,23 @@ public static FilteredKnn create(
7979 var samplerSupplier = samplerSupplier (graph , config );
8080 return new FilteredKnn (
8181 context .progressTracker (),
82+ context .executor (),
83+ config .concurrency (),
8284 graph ,
83- config .maxIterations (),
84- sourceNodes ,
8585 similarityComputer ,
8686 neighborFilterFactory ,
87- context .executor (),
8887 splittableRandom ,
89- config . sampleRate () ,
88+ samplerSupplier ,
9089 config .deltaThreshold (),
91- config .similarityCutoff (),
92- config .topK (),
93- config .concurrency (),
90+ config .maxIterations (),
9491 config .minBatchSize (),
9592 config .perturbationRate (),
96- config .sampledK (graph .nodeCount ()),
9793 config .randomJoins (),
98- samplerSupplier
94+ config .sampledK (graph .nodeCount ()),
95+ config .sampleRate (),
96+ config .similarityCutoff (),
97+ sourceNodes ,
98+ config .topK ()
9999 );
100100 }
101101
@@ -120,45 +120,45 @@ private static SplittableRandom getSplittableRandom(Optional<Long> randomSeed) {
120120 return randomSeed .map (SplittableRandom ::new ).orElseGet (SplittableRandom ::new );
121121 }
122122
123- FilteredKnn (
123+ private FilteredKnn (
124124 ProgressTracker progressTracker ,
125+ ExecutorService executorService ,
126+ int concurrency ,
125127 Graph graph ,
126- int maxIterations ,
127- List <Long > sourceNodes ,
128128 SimilarityComputer similarityComputer ,
129129 FilteredNeighborFilterFactory neighborFilterFactory ,
130- ExecutorService executorService ,
131130 SplittableRandom splittableRandom ,
132- double sampleRate ,
131+ Function < SplittableRandom , FilteredKnnSampler > samplerSupplier ,
133132 double deltaThreshold ,
134- double similarityCutoff ,
135- int topK ,
136- int concurrency ,
133+ int maxIterations ,
137134 int minBatchSize ,
138135 double perturbationRate ,
139- int sampledK ,
140136 int randomJoins ,
141- Function <SplittableRandom , FilteredKnnSampler > samplerSupplier
137+ int sampledK ,
138+ double sampleRate ,
139+ double similarityCutoff ,
140+ List <Long > sourceNodes ,
141+ int topK
142142
143143 ) {
144144 super (progressTracker );
145+ this .executorService = executorService ;
146+ this .concurrency = concurrency ;
145147 this .graph = graph ;
146- this .sampleRate = sampleRate ;
148+ this .similarityComputer = similarityComputer ;
149+ this .neighborFilterFactory = neighborFilterFactory ;
150+ this .splittableRandom = splittableRandom ;
151+ this .samplerSupplier = samplerSupplier ;
147152 this .deltaThreshold = deltaThreshold ;
148- this .similarityCutoff = similarityCutoff ;
149- this .topK = topK ;
150- this .concurrency = concurrency ;
153+ this .maxIterations = maxIterations ;
151154 this .minBatchSize = minBatchSize ;
152155 this .perturbationRate = perturbationRate ;
153- this .sampledK = sampledK ;
154156 this .randomJoins = randomJoins ;
155- this .maxIterations = maxIterations ;
156- this .similarityComputer = similarityComputer ;
157- this .neighborFilterFactory = neighborFilterFactory ;
158- this .executorService = executorService ;
159- this .splittableRandom = splittableRandom ;
157+ this .sampledK = sampledK ;
158+ this .sampleRate = sampleRate ;
159+ this .similarityCutoff = similarityCutoff ;
160160 this .sourceNodes = sourceNodes ;
161- this .samplerSupplier = samplerSupplier ;
161+ this .topK = topK ;
162162 }
163163
164164 public long nodeCount () {
0 commit comments