We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b940322 commit 38b6821Copy full SHA for 38b6821
1 file changed
pufferlib/src/tensor.h
@@ -0,0 +1,33 @@
1
+#ifndef PUFFERLIB_TENSOR_H
2
+#define PUFFERLIB_TENSOR_H
3
+
4
+#include <stdint.h>
5
6
+#define PUF_MAX_DIMS 8
7
8
+typedef struct {
9
+ float* data;
10
+ int64_t shape[PUF_MAX_DIMS];
11
+} FloatTensor;
12
13
14
+ double* data;
15
16
+} DoubleTensor;
17
18
19
+ unsigned char* data;
20
21
+} ByteTensor;
22
23
24
+ long* data;
25
26
+} LongTensor;
27
28
29
+ int* data;
30
31
+} IntTensor;
32
33
+#endif // PUFFERLIB_TENSOR_H
0 commit comments