onnxruntime-extensions/java
Wenbing Li c9c11b4846
Fix the windows API missing issue and Linux shared library size issue for Java packaging. (#774)
* Fix the java packaging issues

* add the jar path example for Linux build with a default configuration
2024-07-29 16:03:58 -07:00
..
gradle/wrapper
src
README.md
build-android.gradle
build.gradle
gradle.properties
gradlew
gradlew.bat
ortx_jni.def Fix the windows API missing issue and Linux shared library size issue for Java packaging. (#774) 2024-07-29 16:03:58 -07:00
ortx_jni.ver Fix the windows API missing issue and Linux shared library size issue for Java packaging. (#774) 2024-07-29 16:03:58 -07:00
settings-android.gradle
settings.gradle

README.md

ONNXRuntime-Extensions Java/Android API and Package

This java and Android API and packaging principles were inspired by the https://github.com/microsoft/onnxruntime/tree/main/java, and openly share credits for API with the contributors in onnxruntime repo.


Building


Tools required

  1. install visual studio 2022 (with cmake, git, desktop C++)
  2. OpenJDK: https://docs.microsoft.com/en-us/java/openjdk/download (OpenJDK 11.0.15 LTS)

Build command

./build.sh -DOCOS_BUILD_JAVA=ON

and find onnxruntime-extensions-0.5.0.jar at out/$OS/$CMake_BUILD_TYPE/java/build/libs


Usage

There is a Java example project checked in tutorial folder, demo4j which provide a showcase how extensions package works with ONNXRuntime's Java API