ONE - On-device Neural Engine
Loading...
Searching...
No Matches
SpaceToBatchND.cpp
Go to the documentation of this file.
1/*
2 * Copyright (c) 2024 Samsung Electronics Co., Ltd. All Rights Reserved
3 *
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
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
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.
15 */
16
18#include "PALSpaceToBatchND.h"
19
20using namespace onert_micro;
21using namespace onert_micro::execute;
22
23namespace onert_micro
24{
25namespace execute
26{
27
30{
31 auto batch_to_space_float_lambda =
32 [](const core::OMRuntimeShape &input1_shape, const float *input1_data,
33 const core::OMRuntimeShape &input2_shape, const int32_t *block_shape_data,
34 const core::OMRuntimeShape &input3_shape, const int32_t *crops_data,
35 const core::OMRuntimeShape &output_shape, float *output_data) {
36 return pal::SpaceToBatchND<float>(input1_shape, input1_data, input2_shape, block_shape_data,
37 input3_shape, crops_data, output_shape, output_data);
38 };
39
40 return execute_spaces_batches_nd_common(execute_args, batch_to_space_float_lambda);
41}
42
43} // namespace execute
44} // namespace onert_micro
const luci_interpreter::RuntimeShape output_shape
OMStatus execute_kernel_CircleSpaceToBatchND(const onert_micro::execute::OMExecuteArgs &execute_args)
OMStatus execute_spaces_batches_nd_common(const OMExecuteArgs &execute_args, const std::function< OMStatus(const core::OMRuntimeShape &unextended_input1_shape, const float *input1_data, const core::OMRuntimeShape &unextended_input2_shape, const int32_t *block_shape_data, const core::OMRuntimeShape &unextended_input3_shape, const int32_t *crops_data, const core::OMRuntimeShape &unextended_output_shape, float *output_data)> &f)