Skip to content
Snippets Groups Projects
Commit ac5426ec authored by Peter Lünenschloß's avatar Peter Lünenschloß
Browse files

minor nicemaking

parent 10f653bc
No related branches found
No related tags found
3 merge requests!193Release 1.4,!188Release 1.4,!96Anti drift clustering
Pipeline #7756 passed with stage
in 6 minutes and 42 seconds
......@@ -960,9 +960,8 @@ def flagDriftFromNorm(data, field, flagger, fields, segment_freq, norm_spread, n
for i, j in combs:
dist = metric(segment[1].iloc[:, i].values, segment[1].iloc[:, j].values)
dist_mat[i, j] = dist
dist_mat[j, i] = dist
condensed = np.array([np.abs(dist_mat[i[0], i[1]]) for i in combs])
condensed = np.abs(dist_mat[tuple(zip(*combs))])
Z = linkage(condensed, method=linkage_method)
cluster = fcluster(Z, norm_spread, criterion='distance')
counts = collections.Counter(cluster)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment