2 // Copyright © 2017 Arm Ltd. All rights reserved.
3 // SPDX-License-Identifier: MIT
6 #include "ClSoftmaxBaseWorkload.hpp"
8 #include <aclCommon/ArmComputeTensorUtils.hpp>
10 #include <arm_compute/runtime/CL/functions/CLSoftmaxLayer.h>
15 arm_compute::Status ClSoftmaxWorkloadValidate(const TensorInfo& input,
16 const TensorInfo& output)
18 // NOTE: We report 4D Softmax as unsupported until full support is added to ACL
19 if(input.GetShape().GetNumDimensions() >= 4u)
21 return arm_compute::Status(arm_compute::ErrorCode::RUNTIME_ERROR, "4d softmax is not supported");
24 const arm_compute::TensorInfo aclInputInfo = armcomputetensorutils::BuildArmComputeTensorInfo(input);
25 const arm_compute::TensorInfo aclOutputInfo = armcomputetensorutils::BuildArmComputeTensorInfo(output);
27 return arm_compute::CLSoftmaxLayer::validate(&aclInputInfo, &aclOutputInfo);