disable autotestdict in cython
[liba.git] / python / src / a.pyx
blob1521e7f939a8b2fcbf0f3b274de4acff0cf9b2b7
1 #cython: autotestdict=False
2 #cython: auto_pickle=False
3 #cython: boundscheck=False
4 #cython: wraparound=False
5 from a cimport *
6 from cpython cimport *
7 from cpython.array cimport array
8 from cython.parallel import prange
10 cdef inline array_i8(object o):
11 return array('b', o)
13 cdef inline array_u8(object o):
14 return array('B', o)
16 cdef inline array_i16(object o):
17 return array('h', o)
19 cdef inline array_u16(object o):
20 return array('H', o)
22 cdef inline array_i32(object o):
23 if INT32_MAX == INT_MAX:
24 return array('i', o)
25 return array('l', o)
27 cdef inline array_u32(object o):
28 if UINT32_MAX == UINT_MAX:
29 return array('I', o)
30 return array('L', o)
32 cdef inline array_i64(object o):
33 if INT64_MAX == LONG_MAX:
34 return array('l', o)
35 return array('q', o)
37 cdef inline array_u64(object o):
38 if UINT64_MAX == ULONG_MAX:
39 return array('L', o)
40 return array('Q', o)
42 cdef inline array_f32(object o):
43 return array('f', o)
45 cdef inline array_f64(object o):
46 return array('d', o)
48 cdef inline array_num(object o):
49 if A_FLOAT_TYPE == A_FLOAT_SINGLE:
50 return array('f', o)
51 return array('d', o)
53 def hash_bkdr(bytes str, a_u32 val = 0) -> a_u32:
54 return a_hash_bkdr(str, val)
56 def hash_sdbm(bytes str, a_u32 val = 0) -> a_u32:
57 return a_hash_sdbm(str, val)
59 include "a/crc.pxi"
60 include "a/hpf.pxi"
61 include "a/lpf.pxi"
62 include "a/math.pxi"
63 include "a/mf.pxi"
64 include "a/pid.pxi"
65 include "a/pid_fuzzy.pxi"
66 include "a/pid_neuro.pxi"
67 include "a/poly.pxi"
68 include "a/tf.pxi"
69 include "a/trajbell.pxi"
70 include "a/trajpoly3.pxi"
71 include "a/trajpoly5.pxi"
72 include "a/trajpoly7.pxi"
73 include "a/trajtrap.pxi"
74 include "a/version.pxi"