Пример #1
0
    def test_csc_with_dtype(self):

        A, B = self.data()

        actual = construct.hstack([A.tocsc(), B.tocsc()], dtype=self.dtype)
        assert actual.indices.dtype == cupy.int32
        assert actual.indptr.dtype == cupy.int32
Пример #2
0
 def test_csc(self):
     A, B = self.data()
     actual = construct.hstack([A.tocsc(), B.tocsc()],
                               dtype=self.dtype).todense()
     testing.assert_array_equal(actual, self.expected())
     assert actual.dtype == self.dtype
Пример #3
0
    def test_basic_hstack(self):

        A, B = self.data()
        actual = construct.hstack([A, B], dtype=self.dtype).todense()
        testing.assert_array_equal(actual, self.expected())
        self.assertEqual(actual.dtype, self.dtype)