2 * Copyright (c) 2018 Samsung Electronics Co., Ltd. All Rights Reserved
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
17 #include "internal/op/Unpack.h"
18 #include "internal/op/NodeVisitor.h"
31 void Node::accept(NodeVisitor &&v) const { v.visit(*this); }
36 } // namespace internal
46 // There are three inputs: tensor which is to be unpacked,
47 // axis along which tensor needs to be unpacked
48 // and number of splits along the axis.
50 Param::Param(uint32_t inputCount, const uint32_t *inputs, uint32_t outputCount,
51 const uint32_t *outputs)
53 assert(inputCount == 3);
55 ifm_index = inputs[0];
57 for (uint32_t n = 0; n < outputCount; ++n)
59 ofm_indexes.emplace_back(outputs[n]);
61 num_split_index = inputs[1];
62 axis_index = inputs[2];
68 } // namespace internal