diff --git a/minisom.py b/minisom.py index 2380e0e..780f853 100644 --- a/minisom.py +++ b/minisom.py @@ -864,10 +864,10 @@ def test_random_weights_init(self): def test_pca_weights_init(self): som = MiniSom(2, 2, 2) som.pca_weights_init(array([[1., 0.], [0., 1.], [1., 0.], [0., 1.]])) - expected = array([[[-1.41421356, 0.], - [0., 1.41421356]], - [[0., -1.41421356], - [1.41421356, 0.]]]) + expected = array([[[1.57735027, -0.42264973], + [0.42264973, -1.57735027]], + [[-0.42264973, 1.57735027], + [-1.57735027, 0.42264973]]]) assert_array_almost_equal(som._weights, expected) def test_distance_map(self):