db_clustering 0.1.11 → 0.1.12

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f960d170fbc8d820ad18016a4ce03943fd02de54
4
- data.tar.gz: c257769487f5a8efaa1d2a2606aa1aee51083453
3
+ metadata.gz: 6078139ca8ba91099618249c5eb9e01a08c3f402
4
+ data.tar.gz: 2d3c5e893176ef4d4f20db9835f858f2dab44def
5
5
  SHA512:
6
- metadata.gz: 6a02139c030777fdcd4ce942fad981682e50f641d5e99e76fd40859a77caa73199869f301b3bb272eae647f72b5a1c0cc967f4a9a535b5e9b229b8d1e25a246a
7
- data.tar.gz: 972a4d5b380333a128901d62dc7b28bf8d4f5240f3517e55eb0404e99ccb7e5164299edfb5a55a87e917d58608c45d15896c236caf56c993bbc161a94db65ab0
6
+ metadata.gz: ff195178f56ddaa3eac59f2e75a2ec5be23876685446d50a71a45514537d0130c1fde60ac3f88919323062b4a0f58b2528a4498e5ec1417afc0902dd8b49ab4d
7
+ data.tar.gz: 1fd241dcbf4b2b7774643437ad4c628e829d7ae3838ce27037fb54437725271b94e66d6128835a5cee800e92befb720bfef8a34cf50e97ceb67ceca09d69b2af
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.1.11
1
+ 0.1.12
@@ -12,7 +12,7 @@ module DbClustering
12
12
  @clusters = []
13
13
  end
14
14
 
15
- def cluster(max_distance:, min_neighbors:)
15
+ def cluster(max_distance:, min_neighbors:, debug: false)
16
16
  @clusters = []
17
17
  cluster = nil
18
18
 
@@ -33,6 +33,10 @@ module DbClustering
33
33
  if neighbor.cluster.nil?
34
34
  cluster.add(neighbor)
35
35
 
36
+ if debug
37
+ print "+"
38
+ end
39
+
36
40
  # add the neighbors of the neighbor to the neighbors to fully expand the cluster
37
41
  neighbors |= @datasource.neighbors(point: neighbor, distance_metric: @distance_metric, max_distance: max_distance)
38
42
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: db_clustering
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.11
4
+ version: 0.1.12
5
5
  platform: ruby
6
6
  authors:
7
7
  - Cihat Gündüz