Skip to content

Commit

Permalink
Testing ORT 1.15.0-rc1
Browse files Browse the repository at this point in the history
  • Loading branch information
Craigacp committed May 8, 2023
1 parent 3ba47e6 commit 8969ae2
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 2 deletions.
14 changes: 14 additions & 0 deletions Interop/ONNX/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,20 @@
<artifactId>tribuo-onnx</artifactId>
<packaging>jar</packaging>

<!-- staging repo for ORT release candidates -->
<repositories>
<repository>
<id>ORT-Nightly</id>
<url>https://aiinfra.pkgs.visualstudio.com/PublicPackages/_packaging/ORT-Nightly/maven/v1</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>

<dependencies>
<dependency>
<groupId>${project.groupId}</groupId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
package org.tribuo.interop.onnx;

import ai.onnxruntime.OnnxJavaType;
import ai.onnxruntime.OnnxMap;
import ai.onnxruntime.OnnxSequence;
import ai.onnxruntime.OnnxTensor;
import ai.onnxruntime.OnnxValue;
Expand Down Expand Up @@ -184,8 +185,9 @@ protected float[][] getBatchPredictions(List<OnnxValue> inputs, ImmutableOutputI
float[][] outputArray = new float[output.size()][outputIDInfo.size()];
int i = 0;
for (Object o : output) {
OnnxMap onnxMap = (OnnxMap) o;
@SuppressWarnings("unchecked") // guarded by the if on the mapInfo above.
Map<Long,Float> map = (Map<Long,Float>) o;
Map<Long,Float> map = (Map<Long,Float>) onnxMap.getValue();
if (map.size() == outputIDInfo.size()) {
for (Map.Entry<Long,Float> e : map.entrySet()) {
Long key = e.getKey();
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
<!-- 3rd party backend dependencies -->
<liblinear.version>2.44</liblinear.version>
<libsvm.version>3.25</libsvm.version>
<onnxruntime.version>1.12.1</onnxruntime.version>
<onnxruntime.version>1.15.0-rc1</onnxruntime.version>
<tensorflow.version>0.5.0</tensorflow.version>
<xgboost.version>1.6.2</xgboost.version>

Expand Down

0 comments on commit 8969ae2

Please sign in to comment.