Ejemplo n.º 1
0
 def test_one(self):
     a = core.ndarray((1, ), dtype=cupy.int32)
     self.assertEqual(core._get_strides_for_nocopy_reshape(a, (1, 1, 1)),
                      [4, 4, 4])
Ejemplo n.º 2
0
 def test_one(self):
     a = core.ndarray((1,), dtype=cupy.int32)
     self.assertEqual(core._get_strides_for_nocopy_reshape(a, (1, 1, 1)),
                      [4, 4, 4])
Ejemplo n.º 3
0
 def test_different_size(self):
     a = core.ndarray((2, 3))
     self.assertEqual(core._get_strides_for_nocopy_reshape(a, (1, 5)), [])
Ejemplo n.º 4
0
 def test_different_size(self):
     a = core.ndarray((2, 3))
     self.assertEqual(core._get_strides_for_nocopy_reshape(a, (1, 5)),
                      [])