Skip to content

Commit

Permalink
onnxruntime depends on architecture, not os
Browse files Browse the repository at this point in the history
Signed-off-by: HenryL27 <[email protected]>
  • Loading branch information
HenryL27 authored Mar 12, 2024
1 parent 2e0946a commit 1a0af3b
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions ml-algorithms/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,8 @@ dependencies {
implementation("ai.djl.onnxruntime:onnxruntime-engine:0.21.0") {
exclude group: "com.microsoft.onnxruntime", module: "onnxruntime"
}
def os = DefaultNativePlatform.currentOperatingSystem
//mac doesn't support GPU
if (os.macOsX) {
//arm doesn't support GPU
if (System.getProperty("os.arch") == "aarch64") {
dependencies {
implementation "com.microsoft.onnxruntime:onnxruntime:1.14.0"
}
Expand Down Expand Up @@ -122,4 +121,4 @@ spotless {

eclipse().configFile rootProject.file('.eclipseformat.xml')
}
}
}

0 comments on commit 1a0af3b

Please sign in to comment.