diff options
author | Anthony LaTorre <telatorre@gmail.com> | 2011-05-17 16:58:36 -0400 |
---|---|---|
committer | Anthony LaTorre <telatorre@gmail.com> | 2011-05-17 16:58:36 -0400 |
commit | 909309302c83423994e9c1dd36a3309890a67b90 (patch) | |
tree | ade31f97ba43172820efd7bb80d5dd70bffa87c5 /vector.py | |
parent | 8df5c2109151613d6ed1c124095c8e6e0f98f3af (diff) | |
download | chroma-909309302c83423994e9c1dd36a3309890a67b90.tar.gz chroma-909309302c83423994e9c1dd36a3309890a67b90.tar.bz2 chroma-909309302c83423994e9c1dd36a3309890a67b90.zip |
added documentation
Diffstat (limited to 'vector.py')
-rw-r--r-- | vector.py | 13 |
1 files changed, 0 insertions, 13 deletions
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 |