| 73 | } |
| 74 | |
| 75 | TensorDescriptor StackLayerNode::configure_output(size_t idx) const |
| 76 | { |
| 77 | ARM_COMPUTE_UNUSED(idx); |
| 78 | ARM_COMPUTE_ERROR_ON(idx >= _outputs.size()); |
| 79 | |
| 80 | // Check if all input tensors are set |
| 81 | bool are_all_inputs_set = std::all_of(std::begin(_input_edges), std::end(_input_edges), |
| 82 | [](const EdgeID &eid) { return eid != EmptyEdgeID; }); |
| 83 | |
| 84 | TensorDescriptor output_info = {}; |
| 85 | |
| 86 | if (are_all_inputs_set) |
| 87 | { |
| 88 | std::vector<TensorDescriptor> inputs_descriptors; |
| 89 | for (unsigned int i = 0; i < _input_edges.size(); ++i) |
| 90 | { |
| 91 | const Tensor *t = _graph->tensor(input_id(i)); |
| 92 | ARM_COMPUTE_ERROR_ON(t == nullptr); |
| 93 | inputs_descriptors.push_back(t->desc()); |
| 94 | } |
| 95 | output_info = compute_output_descriptor(inputs_descriptors, _axis); |
| 96 | } |
| 97 | |
| 98 | return output_info; |
| 99 | } |
| 100 | |
| 101 | NodeType StackLayerNode::type() const |
| 102 | { |