| 22 | namespace oneapi { |
| 23 | template<typename T> |
| 24 | Array<T> range(const dim4& dim, const int seq_dim) { |
| 25 | // Set dimension along which the sequence should be |
| 26 | // Other dimensions are simply tiled |
| 27 | int _seq_dim = seq_dim; |
| 28 | if (seq_dim < 0) { |
| 29 | _seq_dim = 0; // column wise sequence |
| 30 | } |
| 31 | |
| 32 | if (_seq_dim < 0 || _seq_dim > 3) { |
| 33 | AF_ERROR("Invalid rep selection", AF_ERR_ARG); |
| 34 | } |
| 35 | |
| 36 | Array<T> out = createEmptyArray<T>(dim); |
| 37 | kernel::range<T>(out, _seq_dim); |
| 38 | |
| 39 | return out; |
| 40 | } |
| 41 | |
| 42 | #define INSTANTIATE(T) \ |
| 43 | template Array<T> range<T>(const af::dim4& dims, const int seq_dims); |
no outgoing calls
no test coverage detected