| /* |
| * Copyright (C) 2017 The Android Open Source Project |
| * |
| * Licensed under the Apache License, Version 2.0 (the "License"); |
| * you may not use this file except in compliance with the License. |
| * You may obtain a copy of the License at |
| * |
| * http://www.apache.org/licenses/LICENSE-2.0 |
| * |
| * Unless required by applicable law or agreed to in writing, software |
| * distributed under the License is distributed on an "AS IS" BASIS, |
| * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| * See the License for the specific language governing permissions and |
| * limitations under the License. |
| */ |
| |
| #ifndef ANDROID_PACKAGES_MODULES_NEURALNETWORKS_COMMON_HAL_INTERFACES_H |
| #define ANDROID_PACKAGES_MODULES_NEURALNETWORKS_COMMON_HAL_INTERFACES_H |
| |
| #include <android/hardware/neuralnetworks/1.0/IDevice.h> |
| #include <android/hardware/neuralnetworks/1.0/IExecutionCallback.h> |
| #include <android/hardware/neuralnetworks/1.0/IPreparedModel.h> |
| #include <android/hardware/neuralnetworks/1.0/IPreparedModelCallback.h> |
| #include <android/hardware/neuralnetworks/1.0/types.h> |
| #include <android/hardware/neuralnetworks/1.1/IDevice.h> |
| #include <android/hardware/neuralnetworks/1.1/types.h> |
| #include <android/hardware/neuralnetworks/1.2/IDevice.h> |
| #include <android/hardware/neuralnetworks/1.2/IExecutionCallback.h> |
| #include <android/hardware/neuralnetworks/1.2/IPreparedModel.h> |
| #include <android/hardware/neuralnetworks/1.2/IPreparedModelCallback.h> |
| #include <android/hardware/neuralnetworks/1.2/types.h> |
| #include <android/hardware/neuralnetworks/1.3/IDevice.h> |
| #include <android/hardware/neuralnetworks/1.3/IExecutionCallback.h> |
| #include <android/hardware/neuralnetworks/1.3/IFencedExecutionCallback.h> |
| #include <android/hardware/neuralnetworks/1.3/IPreparedModel.h> |
| #include <android/hardware/neuralnetworks/1.3/IPreparedModelCallback.h> |
| #include <android/hardware/neuralnetworks/1.3/types.h> |
| #include <android/hidl/memory/1.0/IMemory.h> |
| #include <hidlmemory/mapping.h> |
| |
| #include <functional> |
| |
| namespace android::nn { |
| |
| namespace V1_0 = ::android::hardware::neuralnetworks::V1_0; |
| namespace V1_1 = ::android::hardware::neuralnetworks::V1_1; |
| namespace V1_2 = ::android::hardware::neuralnetworks::V1_2; |
| namespace V1_3 = ::android::hardware::neuralnetworks::V1_3; |
| |
| using HalCacheToken = |
| hardware::hidl_array<uint8_t, |
| static_cast<uint32_t>(V1_2::Constant::BYTE_SIZE_OF_CACHE_TOKEN)>; |
| using HalDeviceFactory = std::function<sp<V1_0::IDevice>(bool blocking)>; |
| |
| inline constexpr V1_3::Priority kDefaultPriority13 = V1_3::Priority::MEDIUM; |
| |
| } // namespace android::nn |
| |
| #endif // ANDROID_PACKAGES_MODULES_NEURALNETWORKS_COMMON_HAL_INTERFACES_H |