コード例 #1
0
 def test_braycurtis(self):
     reference = pdist(self.Xd, metric='braycurtis')
     testing = fast_pdist(self.Xd, metric='braycurtis')
     npt.assert_array_equal(reference, testing)
コード例 #2
0
ファイル: test_metrics.py プロジェクト: dvanatta/msmbuilder
 def test_chebychev(self):
     reference = pdist(self.Xd, metric='chebychev')
     testing = fast_pdist(self.Xd, metric='chebychev')
     eq(reference, testing)
コード例 #3
0
ファイル: test_metrics.py プロジェクト: dvanatta/msmbuilder
 def test_jaccard_2(self):
     reference = pdist(self.Xb, metric='jaccard')
     testing = fast_pdist(self.Xb, metric='jaccard')
     eq(reference, testing)
コード例 #4
0
 def test_chebychev(self):
     reference = pdist(self.Xd, metric='chebychev')
     testing = fast_pdist(self.Xd, metric='chebychev')
     npt.assert_array_equal(reference, testing)
コード例 #5
0
 def test_matching(self):
     reference = pdist(self.Xb, metric='matching')
     testing = fast_pdist(self.Xb, metric='matching')
     npt.assert_array_equal(reference, testing)
コード例 #6
0
 def test_sokalsneath(self):
     reference = pdist(self.Xb, metric='sokalsneath')
     testing = fast_pdist(self.Xb, metric='sokalsneath')
     npt.assert_array_equal(reference, testing)
コード例 #7
0
 def test_minkowski(self):
     p = np.random.randint(10)
     reference = pdist(self.Xd, metric='minkowski', p=p)
     testing = fast_pdist(self.Xd, metric='minkowski', p=p)
     npt.assert_array_equal(reference, testing)
コード例 #8
0
 def test_seuclidean_2(self):
     V = np.random.randn(self.Xd.shape[1])
     reference = pdist(self.Xd, metric='seuclidean', V=V)
     testing = fast_pdist(self.Xd, metric='seuclidean', V=V)
     npt.assert_array_equal(reference, testing)
コード例 #9
0
 def test_mahalanobis_1(self):
     reference = pdist(self.Xd, metric='mahalanobis')
     testing = fast_pdist(self.Xd, metric='mahalanobis')
     npt.assert_array_equal(reference, testing)
コード例 #10
0
 def test_russellrao(self):
     reference = pdist(self.Xb, metric='russellrao')
     testing = fast_pdist(self.Xb, metric='russellrao')
     npt.assert_array_equal(reference, testing)
コード例 #11
0
 def test_sokalsneath(self):
     reference = pdist(self.Xb, metric='sokalsneath')
     testing = fast_pdist(self.Xb, metric='sokalsneath')
     npt.assert_array_equal(reference, testing)
コード例 #12
0
 def test_rogerstanimoto(self):
     reference = pdist(self.Xb, metric='rogerstanimoto')
     testing = fast_pdist(self.Xb, metric='rogerstanimoto')
     npt.assert_array_equal(reference, testing)
コード例 #13
0
 def test_dice(self):
     reference = pdist(self.Xb, metric='dice')
     testing = fast_pdist(self.Xb, metric='dice')
     npt.assert_array_equal(reference, testing)
コード例 #14
0
 def test_kulsinski(self):
     reference = pdist(self.Xb, metric='kulsinski')
     testing = fast_pdist(self.Xb, metric='kulsinski')
     npt.assert_array_equal(reference, testing)
コード例 #15
0
 def test_kulsinski(self):
     reference = pdist(self.Xb, metric='kulsinski')
     testing = fast_pdist(self.Xb, metric='kulsinski')
     npt.assert_array_equal(reference, testing)
コード例 #16
0
 def test_mahalanobis_2(self):
     VI = np.random.randn(self.Xd.shape[0], self.Xd.shape[0])
     reference = pdist(self.Xd, metric='mahalanobis', VI=VI)
     testing = fast_pdist(self.Xd, metric='mahalanobis', VI=VI)
     npt.assert_array_equal(reference, testing)
コード例 #17
0
 def test_rogerstanimoto(self):
     reference = pdist(self.Xb, metric='rogerstanimoto')
     testing = fast_pdist(self.Xb, metric='rogerstanimoto')
     npt.assert_array_equal(reference, testing)
コード例 #18
0
 def test_minkowski(self):
     p = np.random.randint(10)
     reference = pdist(self.Xd, metric='minkowski', p=p)
     testing = fast_pdist(self.Xd, metric='minkowski', p=p)
     npt.assert_array_equal(reference, testing)
コード例 #19
0
 def test_mahalanobis_1(self):
     reference = pdist(self.Xd, metric='mahalanobis')
     testing = fast_pdist(self.Xd, metric='mahalanobis')
     npt.assert_array_equal(reference, testing)
コード例 #20
0
 def test_cityblock(self):
     reference = pdist(self.Xd, metric='cityblock')
     testing = fast_pdist(self.Xd, metric='cityblock')
     npt.assert_array_equal(reference, testing)
コード例 #21
0
 def test_correlation(self):
     reference = pdist(self.Xd, metric='correlation')
     testing = fast_pdist(self.Xd, metric='correlation')
     npt.assert_array_equal(reference, testing)
コード例 #22
0
 def test_correlation(self):
     reference = pdist(self.Xd, metric='correlation')
     testing = fast_pdist(self.Xd, metric='correlation')
     npt.assert_array_equal(reference, testing)
コード例 #23
0
 def test_jaccard_2(self):
     reference = pdist(self.Xb, metric='jaccard')
     testing = fast_pdist(self.Xb, metric='jaccard')
     npt.assert_array_equal(reference, testing)
コード例 #24
0
 def test_sqeuclidean(self):
     reference = pdist(self.Xd, metric='sqeuclidean')
     testing = fast_pdist(self.Xd, metric='sqeuclidean')
     npt.assert_array_equal(reference, testing)
コード例 #25
0
ファイル: test_metrics.py プロジェクト: dvanatta/msmbuilder
 def test_sqeuclidean(self):
     reference = pdist(self.Xd, metric='sqeuclidean')
     testing = fast_pdist(self.Xd, metric='sqeuclidean')
     eq(reference, testing)
コード例 #26
0
 def test_chebychev(self):
     reference = pdist(self.Xd, metric='chebychev')
     testing = fast_pdist(self.Xd, metric='chebychev')
     npt.assert_array_equal(reference, testing)
コード例 #27
0
ファイル: test_metrics.py プロジェクト: dvanatta/msmbuilder
 def test_hamming_2(self):
     reference = pdist(self.Xb, metric='hamming')
     testing = fast_pdist(self.Xb, metric='hamming')
     eq(reference, testing)
コード例 #28
0
 def test_hamming_2(self):
     reference = pdist(self.Xb, metric='hamming')
     testing = fast_pdist(self.Xb, metric='hamming')
     npt.assert_array_equal(reference, testing)
コード例 #29
0
ファイル: test_metrics.py プロジェクト: dvanatta/msmbuilder
 def test_canberra(self):
     reference = pdist(self.Xd, metric='canberra')
     testing = fast_pdist(self.Xd, metric='canberra')
     eq(reference, testing)
コード例 #30
0
 def test_jaccard_2(self):
     reference = pdist(self.Xb, metric='jaccard')
     testing = fast_pdist(self.Xb, metric='jaccard')
     npt.assert_array_equal(reference, testing)
コード例 #31
0
 def test_matching(self):
     reference = pdist(self.Xb, metric='matching')
     testing = fast_pdist(self.Xb, metric='matching')
     npt.assert_array_equal(reference, testing)
コード例 #32
0
 def test_canberra(self):
     reference = pdist(self.Xd, metric='canberra')
     testing = fast_pdist(self.Xd, metric='canberra')
     npt.assert_array_equal(reference, testing)
コード例 #33
0
 def test_dice(self):
     reference = pdist(self.Xb, metric='dice')
     testing = fast_pdist(self.Xb, metric='dice')
     npt.assert_array_equal(reference, testing)
コード例 #34
0
ファイル: test_metrics.py プロジェクト: dvanatta/msmbuilder
 def test_seuclidean_2(self):
     V = np.random.randn(self.Xd.shape[1])
     reference = pdist(self.Xd, metric='seuclidean', V=V)
     testing = fast_pdist(self.Xd, metric='seuclidean', V=V)
     eq(reference, testing)
コード例 #35
0
 def test_russellrao(self):
     reference = pdist(self.Xb, metric='russellrao')
     testing = fast_pdist(self.Xb, metric='russellrao')
     npt.assert_array_equal(reference, testing)
コード例 #36
0
ファイル: test_metrics.py プロジェクト: dvanatta/msmbuilder
 def test_mahalanobis_1(self):
     reference = pdist(self.Xd, metric='mahalanobis')
     testing = fast_pdist(self.Xd, metric='mahalanobis')
     eq(reference, testing)
コード例 #37
0
 def test_seuclidean_2(self):
     V = np.random.randn(self.Xd.shape[1])
     reference = pdist(self.Xd, metric='seuclidean', V=V)
     testing = fast_pdist(self.Xd, metric='seuclidean', V=V)
     npt.assert_array_equal(reference, testing)
コード例 #38
0
ファイル: test_metrics.py プロジェクト: dvanatta/msmbuilder
 def test_mahalanobis_2(self):
     VI = np.random.randn(self.Xd.shape[0], self.Xd.shape[0])
     reference = pdist(self.Xd, metric='mahalanobis', VI=VI)
     testing = fast_pdist(self.Xd, metric='mahalanobis', VI=VI)
     eq(reference, testing)
コード例 #39
0
 def test_mahalanobis_2(self):
     VI = np.random.randn(self.Xd.shape[0], self.Xd.shape[0])
     reference = pdist(self.Xd, metric='mahalanobis', VI=VI)
     testing = fast_pdist(self.Xd, metric='mahalanobis', VI=VI)
     npt.assert_array_equal(reference, testing)
コード例 #40
0
ファイル: test_metrics.py プロジェクト: dvanatta/msmbuilder
 def test_minkowski(self):
     p = np.random.randint(10)
     reference = pdist(self.Xd, metric='minkowski', p=p)
     testing = fast_pdist(self.Xd, metric='minkowski', p=p)
     eq(reference, testing)
コード例 #41
0
 def test_cityblock(self):
     reference = pdist(self.Xd, metric='cityblock')
     testing = fast_pdist(self.Xd, metric='cityblock')
     npt.assert_array_equal(reference, testing)
コード例 #42
0
ファイル: test_metrics.py プロジェクト: dvanatta/msmbuilder
 def test_cosine(self):
     reference = pdist(self.Xd, metric='cosine')
     testing = fast_pdist(self.Xd, metric='cosine')
     eq(reference, testing)
コード例 #43
0
 def test_sqeuclidean(self):
     reference = pdist(self.Xd, metric='sqeuclidean')
     testing = fast_pdist(self.Xd, metric='sqeuclidean')
     npt.assert_array_equal(reference, testing)
コード例 #44
0
ファイル: test_metrics.py プロジェクト: dvanatta/msmbuilder
 def test_cityblock(self):
     reference = pdist(self.Xd, metric='cityblock')
     testing = fast_pdist(self.Xd, metric='cityblock')
     eq(reference, testing)
コード例 #45
0
 def test_hamming_2(self):
     reference = pdist(self.Xb, metric='hamming')
     testing = fast_pdist(self.Xb, metric='hamming')
     npt.assert_array_equal(reference, testing)
コード例 #46
0
ファイル: test_metrics.py プロジェクト: dvanatta/msmbuilder
 def test_correlation(self):
     reference = pdist(self.Xd, metric='correlation')
     testing = fast_pdist(self.Xd, metric='correlation')
     eq(reference, testing)
コード例 #47
0
 def test_canberra(self):
     reference = pdist(self.Xd, metric='canberra')
     testing = fast_pdist(self.Xd, metric='canberra')
     npt.assert_array_equal(reference, testing)
コード例 #48
0
 def test_braycurtis(self):
     reference = pdist(self.Xd, metric='braycurtis')
     testing = fast_pdist(self.Xd, metric='braycurtis')
     npt.assert_array_equal(reference, testing)