| 39 | |
| 40 | namespace { |
| 41 | std::vector<int64_t> get_permutation(instruction_ref ins, const layout_convolution& lc) |
| 42 | { |
| 43 | std::vector<int64_t> perm(ins->get_shape().ndim()); |
| 44 | if(lc.channels_last) |
| 45 | { |
| 46 | std::iota(perm.begin() + 1, perm.end() - 1, 2); |
| 47 | perm.back() = 1; |
| 48 | } |
| 49 | else |
| 50 | { |
| 51 | std::iota(perm.begin(), perm.end(), 0); |
| 52 | } |
| 53 | return perm; |
| 54 | } |
| 55 | |
| 56 | std::vector<int64_t> get_default_permutation(instruction_ref ins) |
| 57 | { |