From 909309302c83423994e9c1dd36a3309890a67b90 Mon Sep 17 00:00:00 2001 From: Anthony LaTorre Date: Tue, 17 May 2011 16:58:36 -0400 Subject: added documentation --- vector.py | 13 ------------- 1 file changed, 13 deletions(-) delete mode 100644 vector.py (limited to 'vector.py') diff --git a/vector.py b/vector.py deleted file mode 100644 index 7b36e07..0000000 --- a/vector.py +++ /dev/null @@ -1,13 +0,0 @@ -import numpy as np -from pycuda import gpuarray - -def make_vector(arr, dtype=gpuarray.vec.float3): - if len(arr.shape) != 2 or arr.shape[-1] != 3: - raise Exception('shape mismatch') - - x = np.empty(arr.shape[0], dtype) - x['x'] = arr[:,0] - x['y'] = arr[:,1] - x['z'] = arr[:,2] - - return x -- cgit