Example #1
0
    def testCuVectorNewFromSize(self):
        vec = CuVector()
        self.assertIsNotNone(vec)
        self.assertEqual(0, vec.dim())

        for i in range(10):
            dim = 10 * i
            vec = CuVector.new_from_size(dim)
            self.assertIsNotNone(vec)
            self.assertEqual(dim, vec.dim())
Example #2
0
 def testCuVectorResize(self):
     for i in range(10):
         dim = 10 * i
         vec = CuVector()
         vec.resize(dim)
         self.assertEqual(dim, vec.dim())