Skip to content
/ xnn Public

Object classification and detection SDK.

Notifications You must be signed in to change notification settings

yicm/xnn

Repository files navigation

Build Action

Prerequisites

  • Linux-like System.
  • CMake 3.1+ installed.
  • Use a C++11 compiler(C++11 is optional).
  • For benchmark tests
    • OpenCV:sudo apt install libopencv-dev

Build & Install

$ mkdir build
$ cd build
$ cmake ..
$ make -j
$ make install DESTDIR={your destination}

Build Android JNI Library

Environment:

  • WSL,Ubuntu18.04
  • Bazel 3.3+
  • Android JNI Library
    • Local JDK 8+(just for using javah or javac to generate native headers)
      • sudo apt install openjdk-8-jdk-headless
    • Android sdkmanager (https://developer.android.com/studio#command-tools)
      • config the environment of sdkmanager
      • sdkmanager --sdk_root=$HOME/Android --list
      • sdkmanager --sdk_root=$HOME/Android 'build-tools;29.0.2'
      • sdkmanager --sdk_root=$HOME/Android 'platforms;android-28'
      • sdkmanager --sdk_root=$HOME/Android --install "ndk;18.1.5063045"

Build:

$ bazel build --platforms=//platforms:p_android_aarch64 android:jni_lib_shared

Cross-compiling & Install

$ mkdir build
$ cd build
$ cmake .. -DBUILD_BENCHMARKS=OFF -DCMAKE_TOOLCHAIN_FILE=../platforms/linux/mips32r2-linux-gnu.toolchain.cmake
$ make -j
$ make install DESTDIR={your destination}

Test

$ cd build/bin/tests
$ cp ../../../conf/config.json .
$ cp ../../../resource/4.gray .
$ ./test_mnn_clazz 4.gray

Benchmarks

$ cd build/bin/tests
$ cp ../../../conf/config.json .
$ ./test_mnn_clazz_benchmark {your_test_dataset}

Reference

Online Tools

About

Object classification and detection SDK.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published