MCPcopy Create free account
hub / github.com/arrayfire/arrayfire / iir

Function iir

src/backend/cpu/iir.cpp:24–41  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

22
23template<typename T>
24Array<T> iir(const Array<T> &b, const Array<T> &a, const Array<T> &x) {
25 AF_BATCH_KIND type = x.ndims() == 1 ? AF_BATCH_NONE : AF_BATCH_SAME;
26 if (x.ndims() != b.ndims()) {
27 type = (x.ndims() < b.ndims()) ? AF_BATCH_RHS : AF_BATCH_LHS;
28 }
29
30 // Extract the first N elements
31 Array<T> c = convolve<T, T>(x, b, type, 1, true);
32 dim4 cdims = c.dims();
33 cdims[0] = x.dims()[0];
34 c.resetDims(cdims);
35
36 Array<T> y = createEmptyArray<T>(c.dims());
37
38 getQueue().enqueue(kernel::iir<T>, y, c, a);
39
40 return y;
41}
42
43#define INSTANTIATE(T) \
44 template Array<T> iir(const Array<T> &b, const Array<T> &a, \

Callers

nothing calls this directly

Calls 5

getQueueFunction · 0.50
ndimsMethod · 0.45
dimsMethod · 0.45
resetDimsMethod · 0.45
enqueueMethod · 0.45

Tested by

no test coverage detected