Created by: zeffii
solves the signature issue, does not solve auto compilation for later reuse.
- rewrites minor parts of the cubic function to match the subset of numpy that numba can reliably read
- adds decorator and faux decorator
adds automatic signature generation (compilation step for diskstorage does not work yet!)
turns out that you can generate a signature automatically ( why the docs aren't explicit about this is baffling) by doing
import numba
def make_signature_tuple(*params):
return tuple([numba.typeof(p) for p in params])
param_1 = np.array([[0.0, 0.1, 2.0], [1.0, 0.3, 2.0], [2.0, 0.1, 2.3]])
param_2 = 3
param_n = np.array([0, 2, 3, 4, 12, 14])
params = param_1, param_2, param_n
print(make_signature_tuple(*params)
>>> (array(float64, 2d, C), int64, array(int32, 1d, C))