ウロチョロしていたら見つけました。
実体は、
と
Intel® Movidius™ Neural Networks HALは、Android NN APIのHAL。
TensorFlow Lite & Android 8.1 NN API ソースコード解析」独演会で紹介した、Sample Driverと同じようなもの。
TensorFlow Lite & Android 8.1 NN API ソースコード解析」独演会で紹介した、Sample Driverと同じようなもの。
[nn-hal/Intel_movidius_nn_hal/vpuhal/service.cpp service.cpp source.cpp]を見てみよう。
引用 #define LOG_TAG "neuralnetworks-vpu" #include "VpuUtils.h" #include <android-base/logging.h> #include <hidl/LegacySupport.h> #include <hidl/HidlTransportSupport.h> #include <thread> #include "VpuDriver.h" using android::hardware::configureRpcThreadpool; using android::hardware::joinRpcThreadpool; using android::hardware::neuralnetworks::V1_0::vpu_driver::VpuDriver; int main() { android::sp<VpuDriver> vpu = new VpuDriver(); configureRpcThreadpool(4, true); android::status_t status = vpu->registerAsService("vpudriver"); if (status == android::OK) { ALOGI("VPU HAL Ready."); joinRpcThreadpool(); } ALOGE("Cannot register VPU HAL service"); return 0; }
vpudriver っていうサービスを立ち上げているでしょ。
というのもあります。が、使い方は分かりません。
Android Neural Networks HAL for Intel® Movidius™ NCS and supporting NCSDK 2.xにも、同じように service.cpp があるよ。
引用 #include <hidl/HidlTransportSupport.h> #include <hidl/LegacySupport.h> #include "VpuDriver.h" using android::hardware::configureRpcThreadpool; using android::hardware::joinRpcThreadpool; using android::hardware::neuralnetworks::V1_0::vpu_driver::VpuDriver; int main(int /* argc */, char* /* argv */ []) { // android::sp<VpuDriver> vpu = new VpuDriver("vpu-driver"); android::sp<VpuDriver> vpu = new VpuDriver(); configureRpcThreadpool(4, true); android::status_t status = vpu->registerAsService("myriad-vpu"); LOG_ALWAYS_FATAL_IF( status != android::OK, "Error while registering as service: %d", status); joinRpcThreadpool(); return 0; }
こちらのサービスは、myriad-vpu だね。
追記)、2018.09.09
上記のIntel® Movidius™ Neural Networks HALは、The Intel® Movidius™ Neural Compute SDKの1.12.00.01:を使うようです。
ncsdk 2.05.00.02を公開されています。