From 55bcf758f37969188cf737d1a6ff23fe803ebddd Mon Sep 17 00:00:00 2001 From: quillotm Date: Mon, 23 Aug 2021 21:18:16 +0200 Subject: [PATCH] By default, kmeans mahalanobis is with constrains --- volia/clustering_modules/kmeans_mahalanobis.py | 6 ------ 1 file changed, 6 deletions(-) diff --git a/volia/clustering_modules/kmeans_mahalanobis.py b/volia/clustering_modules/kmeans_mahalanobis.py index 2f84653..9321626 100644 --- a/volia/clustering_modules/kmeans_mahalanobis.py +++ b/volia/clustering_modules/kmeans_mahalanobis.py @@ -96,16 +96,10 @@ class kmeansMahalanobis(): fig = plt.figure() ax = fig.add_subplot(111) scatter = ax.scatter(points[:, 0], points[:, 1], c=clusters, s=50) - - #for center in centers: - # ax.scatter(center[0], center[1], s=50, c='red', marker='+') ax.scatter(centers[:, 0], centers[:, 1], s=50, c='red', marker='+') - ax.set_xlabel('x') ax.set_ylabel('y') plt.colorbar(scatter) - #plt.ylim(0, 1) - #plt.xlim(0, 1) plt.savefig("test_" + str(iteration) + ".pdf") def _train(self, features, K: int, tol: float, maxiter: int, debug: bool=False): -- 1.8.2.3