YongseopKim / ONE

On-device Neural Engine
Other
0 stars 0 forks source link

android #4

Closed YongseopKim closed 3 years ago

YongseopKim commented 4 years ago

build

prebuilt hdf5: http://npuarchive.mooo.com/archive/hdf_android/hdf5-1.10.0-android-aarch64.tar.gz

build nnpackage_run for android

OPTIONS="-DDOWNLOAD_BOOST=ON -DBUILD_BOOST=ON -DBUILD_NNPACKAGE_RUN=ON -DBUILD_TFLITE_RUN=ON" \
BUILD_TYPE=Release TARGET_OS=android CROSS_BUILD=1 \
NDK_DIR=`pwd`/tools/cross/ndk/r20/ndk \
EXT_HDF5_DIR=`pwd`/hdf5_prebuilt \
make -f Makefile.template configure build install
YongseopKim commented 4 years ago

logcat

logcat -c && logcat -s DEBUG:V Debug:V AndroidRuntime:V ONERT:V ONERT_NATIVE:V
YongseopKim commented 4 years ago

ONERT_LOG_ENABLE=1

infra/nnfw/cmake/buildtool/cross/toolchain_aarch64-android.cmake

...
set(ANDROID_STL c++_shared)

./tools/cross/ndk/r20/ndk/sources/cxx-stl/llvm-libc++/libs/arm64-v8a/libc++_shared.so

YongseopKim commented 4 years ago

Debug

https://github.com/Samsung/ONE/issues/2797 https://github.com/Samsung/ONE/issues/2769 https://github.com/Samsung/ONE/issues/2826

YongseopKim commented 3 years ago

tensorflow

ONE

Android SDK Build-Tools is a component of the Android SDK required for building Android apps. It's installed in the /build-tools/ directory.

$ ls ~/Android/Sdk/
build-tools : Sdk's build-tools. for android-app or android-lib
ndk : version specific 하게 모아놓은 디렉토리
ndk-bundle : bundle 로써의 ndk
platforms : android sdk api. such as android-27,28,29
platform-tools : android sdk tools. adb, fastboot, sqlite3,...