mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-07-14 18:12:05 +00:00
679 lines
28 KiB
HTML
679 lines
28 KiB
HTML
<!DOCTYPE HTML>
|
|
<!-- NewPage -->
|
|
<html lang="en">
|
|
<head>
|
|
<!-- Generated by javadoc -->
|
|
<title>OrtSession (onnxruntime 1.14.0 API)</title>
|
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
|
<link rel="stylesheet" type="text/css" href="../../stylesheet.css" title="Style">
|
|
<link rel="stylesheet" type="text/css" href="../../jquery/jquery-ui.min.css" title="Style">
|
|
<link rel="stylesheet" type="text/css" href="../../jquery-ui.overrides.css" title="Style">
|
|
<script type="text/javascript" src="../../script.js"></script>
|
|
<script type="text/javascript" src="../../jquery/jszip/dist/jszip.min.js"></script>
|
|
<script type="text/javascript" src="../../jquery/jszip-utils/dist/jszip-utils.min.js"></script>
|
|
<!--[if IE]>
|
|
<script type="text/javascript" src="../../jquery/jszip-utils/dist/jszip-utils-ie.min.js"></script>
|
|
<![endif]-->
|
|
<script type="text/javascript" src="../../jquery/jquery-3.6.0.min.js"></script>
|
|
<script type="text/javascript" src="../../jquery/jquery-ui.min.js"></script>
|
|
</head>
|
|
<body>
|
|
<script type="text/javascript"><!--
|
|
try {
|
|
if (location.href.indexOf('is-external=true') == -1) {
|
|
parent.document.title="OrtSession (onnxruntime 1.14.0 API)";
|
|
}
|
|
}
|
|
catch(err) {
|
|
}
|
|
//-->
|
|
var data = {"i0":10,"i1":10,"i2":10,"i3":10,"i4":10,"i5":10,"i6":10,"i7":10,"i8":10,"i9":10,"i10":10,"i11":10,"i12":10,"i13":10,"i14":10};
|
|
var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],8:["t4","Concrete Methods"]};
|
|
var altColor = "altColor";
|
|
var rowColor = "rowColor";
|
|
var tableTab = "tableTab";
|
|
var activeTableTab = "activeTableTab";
|
|
var pathtoroot = "../../";
|
|
var useModuleDirectories = true;
|
|
loadScripts(document, 'script');</script>
|
|
<noscript>
|
|
<div>JavaScript is disabled on your browser.</div>
|
|
</noscript>
|
|
<header role="banner">
|
|
<nav role="navigation">
|
|
<div class="fixedNav">
|
|
<!-- ========= START OF TOP NAVBAR ======= -->
|
|
<div class="topNav"><a id="navbar.top">
|
|
<!-- -->
|
|
</a>
|
|
<div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
|
|
<a id="navbar.top.firstrow">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="navList" title="Navigation">
|
|
<li><a href="../../index.html">Overview</a></li>
|
|
<li><a href="package-summary.html">Package</a></li>
|
|
<li class="navBarCell1Rev">Class</li>
|
|
<li><a href="package-tree.html">Tree</a></li>
|
|
<li><a href="../../deprecated-list.html">Deprecated</a></li>
|
|
<li><a href="../../index-all.html">Index</a></li>
|
|
<li><a href="../../help-doc.html">Help</a></li>
|
|
</ul>
|
|
</div>
|
|
<div class="subNav">
|
|
<ul class="navList" id="allclasses_navbar_top">
|
|
<li><a href="../../allclasses.html">All Classes</a></li>
|
|
</ul>
|
|
<ul class="navListSearch">
|
|
<li><label for="search">SEARCH:</label>
|
|
<input type="text" id="search" value="search" disabled="disabled">
|
|
<input type="reset" id="reset" value="reset" disabled="disabled">
|
|
</li>
|
|
</ul>
|
|
<div>
|
|
<script type="text/javascript"><!--
|
|
allClassesLink = document.getElementById("allclasses_navbar_top");
|
|
if(window==top) {
|
|
allClassesLink.style.display = "block";
|
|
}
|
|
else {
|
|
allClassesLink.style.display = "none";
|
|
}
|
|
//-->
|
|
</script>
|
|
<noscript>
|
|
<div>JavaScript is disabled on your browser.</div>
|
|
</noscript>
|
|
</div>
|
|
<div>
|
|
<ul class="subNavList">
|
|
<li>Summary: </li>
|
|
<li><a href="#nested.class.summary">Nested</a> | </li>
|
|
<li>Field | </li>
|
|
<li>Constr | </li>
|
|
<li><a href="#method.summary">Method</a></li>
|
|
</ul>
|
|
<ul class="subNavList">
|
|
<li>Detail: </li>
|
|
<li>Field | </li>
|
|
<li>Constr | </li>
|
|
<li><a href="#method.detail">Method</a></li>
|
|
</ul>
|
|
</div>
|
|
<a id="skip.navbar.top">
|
|
<!-- -->
|
|
</a></div>
|
|
<!-- ========= END OF TOP NAVBAR ========= -->
|
|
</div>
|
|
<div class="navPadding"> </div>
|
|
<script type="text/javascript"><!--
|
|
$('.navPadding').css('padding-top', $('.fixedNav').css("height"));
|
|
//-->
|
|
</script>
|
|
</nav>
|
|
</header>
|
|
<!-- ======== START OF CLASS DATA ======== -->
|
|
<main role="main">
|
|
<div class="header">
|
|
<div class="subTitle"><span class="packageLabelInType">Package</span> <a href="package-summary.html">ai.onnxruntime</a></div>
|
|
<h2 title="Class OrtSession" class="title">Class OrtSession</h2>
|
|
</div>
|
|
<div class="contentContainer">
|
|
<ul class="inheritance">
|
|
<li>java.lang.Object</li>
|
|
<li>
|
|
<ul class="inheritance">
|
|
<li>ai.onnxruntime.OrtSession</li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
<div class="description">
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<dl>
|
|
<dt>All Implemented Interfaces:</dt>
|
|
<dd><code>java.lang.AutoCloseable</code></dd>
|
|
</dl>
|
|
<hr>
|
|
<pre>public class <span class="typeNameLabel">OrtSession</span>
|
|
extends java.lang.Object
|
|
implements java.lang.AutoCloseable</pre>
|
|
<div class="block">Wraps an ONNX model and allows inference calls.
|
|
|
|
<p>Allows the inspection of the model's input and output nodes. Produced by an <a href="OrtEnvironment.html" title="class in ai.onnxruntime"><code>OrtEnvironment</code></a>.
|
|
|
|
<p>Most instance methods throw <code>IllegalStateException</code> if the session is closed and the
|
|
methods are called.</div>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
<div class="summary">
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<!-- ======== NESTED CLASS SUMMARY ======== -->
|
|
<section>
|
|
<ul class="blockList">
|
|
<li class="blockList"><a id="nested.class.summary">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Nested Class Summary</h3>
|
|
<table class="memberSummary">
|
|
<caption><span>Nested Classes</span><span class="tabEnd"> </span></caption>
|
|
<tr>
|
|
<th class="colFirst" scope="col">Modifier and Type</th>
|
|
<th class="colSecond" scope="col">Class</th>
|
|
<th class="colLast" scope="col">Description</th>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>static class </code></td>
|
|
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="OrtSession.Result.html" title="class in ai.onnxruntime">OrtSession.Result</a></span></code></th>
|
|
<td class="colLast">
|
|
<div class="block">An <code>AutoCloseable</code> wrapper around a <code>Map</code> containing <a href="OnnxValue.html" title="interface in ai.onnxruntime"><code>OnnxValue</code></a>s.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>static class </code></td>
|
|
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="OrtSession.RunOptions.html" title="class in ai.onnxruntime">OrtSession.RunOptions</a></span></code></th>
|
|
<td class="colLast">
|
|
<div class="block">Used to control logging and termination of a call to <a href="#run(java.util.Map)"><code>run(java.util.Map<java.lang.String, ? extends ai.onnxruntime.OnnxTensorLike>)</code></a>.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>static class </code></td>
|
|
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="OrtSession.SessionOptions.html" title="class in ai.onnxruntime">OrtSession.SessionOptions</a></span></code></th>
|
|
<td class="colLast">
|
|
<div class="block">Represents the options used to construct this session.</div>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
</li>
|
|
</ul>
|
|
</section>
|
|
<!-- ========== METHOD SUMMARY =========== -->
|
|
<section>
|
|
<ul class="blockList">
|
|
<li class="blockList"><a id="method.summary">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Method Summary</h3>
|
|
<table class="memberSummary">
|
|
<caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd"> </span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd"> </span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd"> </span></span></caption>
|
|
<tr>
|
|
<th class="colFirst" scope="col">Modifier and Type</th>
|
|
<th class="colSecond" scope="col">Method</th>
|
|
<th class="colLast" scope="col">Description</th>
|
|
</tr>
|
|
<tr id="i0" class="altColor">
|
|
<td class="colFirst"><code>void</code></td>
|
|
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#close()">close</a></span>()</code></th>
|
|
<td class="colLast">
|
|
<div class="block">Closes the session, releasing it's resources.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i1" class="rowColor">
|
|
<td class="colFirst"><code>java.lang.String</code></td>
|
|
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#endProfiling()">endProfiling</a></span>()</code></th>
|
|
<td class="colLast">
|
|
<div class="block">Ends the profiling session and returns the output of the profiler.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i2" class="altColor">
|
|
<td class="colFirst"><code>java.util.Map<java.lang.String,​<a href="NodeInfo.html" title="class in ai.onnxruntime">NodeInfo</a>></code></td>
|
|
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getInputInfo()">getInputInfo</a></span>()</code></th>
|
|
<td class="colLast">
|
|
<div class="block">Returns the info objects for the inputs, including their names and types.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i3" class="rowColor">
|
|
<td class="colFirst"><code>java.util.Set<java.lang.String></code></td>
|
|
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getInputNames()">getInputNames</a></span>()</code></th>
|
|
<td class="colLast">
|
|
<div class="block">Returns the input names.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i4" class="altColor">
|
|
<td class="colFirst"><code><a href="OnnxModelMetadata.html" title="class in ai.onnxruntime">OnnxModelMetadata</a></code></td>
|
|
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getMetadata()">getMetadata</a></span>()</code></th>
|
|
<td class="colLast">
|
|
<div class="block">Gets the metadata for the currently loaded model.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i5" class="rowColor">
|
|
<td class="colFirst"><code>long</code></td>
|
|
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getNumInputs()">getNumInputs</a></span>()</code></th>
|
|
<td class="colLast">
|
|
<div class="block">Returns the number of inputs this model expects.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i6" class="altColor">
|
|
<td class="colFirst"><code>long</code></td>
|
|
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getNumOutputs()">getNumOutputs</a></span>()</code></th>
|
|
<td class="colLast">
|
|
<div class="block">Returns the number of outputs this model expects.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i7" class="rowColor">
|
|
<td class="colFirst"><code>java.util.Map<java.lang.String,​<a href="NodeInfo.html" title="class in ai.onnxruntime">NodeInfo</a>></code></td>
|
|
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getOutputInfo()">getOutputInfo</a></span>()</code></th>
|
|
<td class="colLast">
|
|
<div class="block">Returns the info objects for the outputs, including their names and types.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i8" class="altColor">
|
|
<td class="colFirst"><code>java.util.Set<java.lang.String></code></td>
|
|
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getOutputNames()">getOutputNames</a></span>()</code></th>
|
|
<td class="colLast">
|
|
<div class="block">Returns the output names.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i9" class="rowColor">
|
|
<td class="colFirst"><code>long</code></td>
|
|
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getProfilingStartTimeInNs()">getProfilingStartTimeInNs</a></span>()</code></th>
|
|
<td class="colLast">
|
|
<div class="block">Returns the timestamp that profiling started in nanoseconds.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i10" class="altColor">
|
|
<td class="colFirst"><code><a href="OrtSession.Result.html" title="class in ai.onnxruntime">OrtSession.Result</a></code></td>
|
|
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#run(java.util.Map)">run</a></span>​(java.util.Map<java.lang.String,​? extends <a href="OnnxTensorLike.html" title="class in ai.onnxruntime">OnnxTensorLike</a>> inputs)</code></th>
|
|
<td class="colLast">
|
|
<div class="block">Scores an input feed dict, returning the map of all inferred outputs.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i11" class="rowColor">
|
|
<td class="colFirst"><code><a href="OrtSession.Result.html" title="class in ai.onnxruntime">OrtSession.Result</a></code></td>
|
|
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#run(java.util.Map,ai.onnxruntime.OrtSession.RunOptions)">run</a></span>​(java.util.Map<java.lang.String,​? extends <a href="OnnxTensorLike.html" title="class in ai.onnxruntime">OnnxTensorLike</a>> inputs,
|
|
<a href="OrtSession.RunOptions.html" title="class in ai.onnxruntime">OrtSession.RunOptions</a> runOptions)</code></th>
|
|
<td class="colLast">
|
|
<div class="block">Scores an input feed dict, returning the map of all inferred outputs.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i12" class="altColor">
|
|
<td class="colFirst"><code><a href="OrtSession.Result.html" title="class in ai.onnxruntime">OrtSession.Result</a></code></td>
|
|
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#run(java.util.Map,java.util.Set)">run</a></span>​(java.util.Map<java.lang.String,​? extends <a href="OnnxTensorLike.html" title="class in ai.onnxruntime">OnnxTensorLike</a>> inputs,
|
|
java.util.Set<java.lang.String> requestedOutputs)</code></th>
|
|
<td class="colLast">
|
|
<div class="block">Scores an input feed dict, returning the map of requested inferred outputs.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i13" class="rowColor">
|
|
<td class="colFirst"><code><a href="OrtSession.Result.html" title="class in ai.onnxruntime">OrtSession.Result</a></code></td>
|
|
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#run(java.util.Map,java.util.Set,ai.onnxruntime.OrtSession.RunOptions)">run</a></span>​(java.util.Map<java.lang.String,​? extends <a href="OnnxTensorLike.html" title="class in ai.onnxruntime">OnnxTensorLike</a>> inputs,
|
|
java.util.Set<java.lang.String> requestedOutputs,
|
|
<a href="OrtSession.RunOptions.html" title="class in ai.onnxruntime">OrtSession.RunOptions</a> runOptions)</code></th>
|
|
<td class="colLast">
|
|
<div class="block">Scores an input feed dict, returning the map of requested inferred outputs.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i14" class="altColor">
|
|
<td class="colFirst"><code>java.lang.String</code></td>
|
|
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#toString()">toString</a></span>()</code></th>
|
|
<td class="colLast"> </td>
|
|
</tr>
|
|
</table>
|
|
<ul class="blockList">
|
|
<li class="blockList"><a id="methods.inherited.from.class.java.lang.Object">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Methods inherited from class java.lang.Object</h3>
|
|
<code>clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait</code></li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
</section>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
<div class="details">
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<!-- ============ METHOD DETAIL ========== -->
|
|
<section>
|
|
<ul class="blockList">
|
|
<li class="blockList"><a id="method.detail">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Method Detail</h3>
|
|
<a id="getNumInputs()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>getNumInputs</h4>
|
|
<pre class="methodSignature">public long getNumInputs()</pre>
|
|
<div class="block">Returns the number of inputs this model expects.</div>
|
|
<dl>
|
|
<dt><span class="returnLabel">Returns:</span></dt>
|
|
<dd>The number of inputs.</dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a id="getNumOutputs()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>getNumOutputs</h4>
|
|
<pre class="methodSignature">public long getNumOutputs()</pre>
|
|
<div class="block">Returns the number of outputs this model expects.</div>
|
|
<dl>
|
|
<dt><span class="returnLabel">Returns:</span></dt>
|
|
<dd>The number of outputs.</dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a id="getInputNames()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>getInputNames</h4>
|
|
<pre class="methodSignature">public java.util.Set<java.lang.String> getInputNames()</pre>
|
|
<div class="block">Returns the input names. The underlying collection is sorted based on the input id number.</div>
|
|
<dl>
|
|
<dt><span class="returnLabel">Returns:</span></dt>
|
|
<dd>The input names.</dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a id="getOutputNames()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>getOutputNames</h4>
|
|
<pre class="methodSignature">public java.util.Set<java.lang.String> getOutputNames()</pre>
|
|
<div class="block">Returns the output names. The underlying collection is sorted based on the output id number.</div>
|
|
<dl>
|
|
<dt><span class="returnLabel">Returns:</span></dt>
|
|
<dd>The output names.</dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a id="getInputInfo()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>getInputInfo</h4>
|
|
<pre class="methodSignature">public java.util.Map<java.lang.String,​<a href="NodeInfo.html" title="class in ai.onnxruntime">NodeInfo</a>> getInputInfo()
|
|
throws <a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></pre>
|
|
<div class="block">Returns the info objects for the inputs, including their names and types. The underlying
|
|
collection is sorted based on the input id number.</div>
|
|
<dl>
|
|
<dt><span class="returnLabel">Returns:</span></dt>
|
|
<dd>The input information.</dd>
|
|
<dt><span class="throwsLabel">Throws:</span></dt>
|
|
<dd><code><a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></code> - If there was an error in native code.</dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a id="getOutputInfo()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>getOutputInfo</h4>
|
|
<pre class="methodSignature">public java.util.Map<java.lang.String,​<a href="NodeInfo.html" title="class in ai.onnxruntime">NodeInfo</a>> getOutputInfo()
|
|
throws <a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></pre>
|
|
<div class="block">Returns the info objects for the outputs, including their names and types. The underlying
|
|
collection is sorted based on the output id number.</div>
|
|
<dl>
|
|
<dt><span class="returnLabel">Returns:</span></dt>
|
|
<dd>The output information.</dd>
|
|
<dt><span class="throwsLabel">Throws:</span></dt>
|
|
<dd><code><a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></code> - If there was an error in native code.</dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a id="run(java.util.Map)">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>run</h4>
|
|
<pre class="methodSignature">public <a href="OrtSession.Result.html" title="class in ai.onnxruntime">OrtSession.Result</a> run​(java.util.Map<java.lang.String,​? extends <a href="OnnxTensorLike.html" title="class in ai.onnxruntime">OnnxTensorLike</a>> inputs)
|
|
throws <a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></pre>
|
|
<div class="block">Scores an input feed dict, returning the map of all inferred outputs.
|
|
|
|
<p>The outputs are sorted based on their id number.</div>
|
|
<dl>
|
|
<dt><span class="paramLabel">Parameters:</span></dt>
|
|
<dd><code>inputs</code> - The inputs to score.</dd>
|
|
<dt><span class="returnLabel">Returns:</span></dt>
|
|
<dd>The inferred outputs.</dd>
|
|
<dt><span class="throwsLabel">Throws:</span></dt>
|
|
<dd><code><a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></code> - If there was an error in native code, the input names are invalid, or if
|
|
there are zero or too many inputs.</dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a id="run(java.util.Map,ai.onnxruntime.OrtSession.RunOptions)">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>run</h4>
|
|
<pre class="methodSignature">public <a href="OrtSession.Result.html" title="class in ai.onnxruntime">OrtSession.Result</a> run​(java.util.Map<java.lang.String,​? extends <a href="OnnxTensorLike.html" title="class in ai.onnxruntime">OnnxTensorLike</a>> inputs,
|
|
<a href="OrtSession.RunOptions.html" title="class in ai.onnxruntime">OrtSession.RunOptions</a> runOptions)
|
|
throws <a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></pre>
|
|
<div class="block">Scores an input feed dict, returning the map of all inferred outputs.
|
|
|
|
<p>The outputs are sorted based on their id number.</div>
|
|
<dl>
|
|
<dt><span class="paramLabel">Parameters:</span></dt>
|
|
<dd><code>inputs</code> - The inputs to score.</dd>
|
|
<dd><code>runOptions</code> - The RunOptions to control this run.</dd>
|
|
<dt><span class="returnLabel">Returns:</span></dt>
|
|
<dd>The inferred outputs.</dd>
|
|
<dt><span class="throwsLabel">Throws:</span></dt>
|
|
<dd><code><a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></code> - If there was an error in native code, the input names are invalid, or if
|
|
there are zero or too many inputs.</dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a id="run(java.util.Map,java.util.Set)">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>run</h4>
|
|
<pre class="methodSignature">public <a href="OrtSession.Result.html" title="class in ai.onnxruntime">OrtSession.Result</a> run​(java.util.Map<java.lang.String,​? extends <a href="OnnxTensorLike.html" title="class in ai.onnxruntime">OnnxTensorLike</a>> inputs,
|
|
java.util.Set<java.lang.String> requestedOutputs)
|
|
throws <a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></pre>
|
|
<div class="block">Scores an input feed dict, returning the map of requested inferred outputs.
|
|
|
|
<p>The outputs are sorted based on the supplied set traversal order.</div>
|
|
<dl>
|
|
<dt><span class="paramLabel">Parameters:</span></dt>
|
|
<dd><code>inputs</code> - The inputs to score.</dd>
|
|
<dd><code>requestedOutputs</code> - The requested outputs.</dd>
|
|
<dt><span class="returnLabel">Returns:</span></dt>
|
|
<dd>The inferred outputs.</dd>
|
|
<dt><span class="throwsLabel">Throws:</span></dt>
|
|
<dd><code><a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></code> - If there was an error in native code, the input or output names are
|
|
invalid, or if there are zero or too many inputs or outputs.</dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a id="run(java.util.Map,java.util.Set,ai.onnxruntime.OrtSession.RunOptions)">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>run</h4>
|
|
<pre class="methodSignature">public <a href="OrtSession.Result.html" title="class in ai.onnxruntime">OrtSession.Result</a> run​(java.util.Map<java.lang.String,​? extends <a href="OnnxTensorLike.html" title="class in ai.onnxruntime">OnnxTensorLike</a>> inputs,
|
|
java.util.Set<java.lang.String> requestedOutputs,
|
|
<a href="OrtSession.RunOptions.html" title="class in ai.onnxruntime">OrtSession.RunOptions</a> runOptions)
|
|
throws <a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></pre>
|
|
<div class="block">Scores an input feed dict, returning the map of requested inferred outputs.
|
|
|
|
<p>The outputs are sorted based on the supplied set traversal order.</div>
|
|
<dl>
|
|
<dt><span class="paramLabel">Parameters:</span></dt>
|
|
<dd><code>inputs</code> - The inputs to score.</dd>
|
|
<dd><code>requestedOutputs</code> - The requested outputs.</dd>
|
|
<dd><code>runOptions</code> - The RunOptions to control this run.</dd>
|
|
<dt><span class="returnLabel">Returns:</span></dt>
|
|
<dd>The inferred outputs.</dd>
|
|
<dt><span class="throwsLabel">Throws:</span></dt>
|
|
<dd><code><a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></code> - If there was an error in native code, the input or output names are
|
|
invalid, or if there are zero or too many inputs or outputs.</dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a id="getMetadata()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>getMetadata</h4>
|
|
<pre class="methodSignature">public <a href="OnnxModelMetadata.html" title="class in ai.onnxruntime">OnnxModelMetadata</a> getMetadata()
|
|
throws <a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></pre>
|
|
<div class="block">Gets the metadata for the currently loaded model.</div>
|
|
<dl>
|
|
<dt><span class="returnLabel">Returns:</span></dt>
|
|
<dd>The metadata.</dd>
|
|
<dt><span class="throwsLabel">Throws:</span></dt>
|
|
<dd><code><a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></code> - If the native call failed.</dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a id="getProfilingStartTimeInNs()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>getProfilingStartTimeInNs</h4>
|
|
<pre class="methodSignature">public long getProfilingStartTimeInNs()
|
|
throws <a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></pre>
|
|
<div class="block">Returns the timestamp that profiling started in nanoseconds.</div>
|
|
<dl>
|
|
<dt><span class="returnLabel">Returns:</span></dt>
|
|
<dd>the profiling start time in ns.</dd>
|
|
<dt><span class="throwsLabel">Throws:</span></dt>
|
|
<dd><code><a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></code> - If the native call failed.</dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a id="endProfiling()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>endProfiling</h4>
|
|
<pre class="methodSignature">public java.lang.String endProfiling()
|
|
throws <a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></pre>
|
|
<div class="block">Ends the profiling session and returns the output of the profiler.
|
|
|
|
<p>Profiling should be enabled in the <a href="OrtSession.SessionOptions.html" title="class in ai.onnxruntime"><code>OrtSession.SessionOptions</code></a> used to construct this <code>
|
|
Session</code>.</div>
|
|
<dl>
|
|
<dt><span class="returnLabel">Returns:</span></dt>
|
|
<dd>The profiling output.</dd>
|
|
<dt><span class="throwsLabel">Throws:</span></dt>
|
|
<dd><code><a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></code> - If the native call failed.</dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a id="toString()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>toString</h4>
|
|
<pre class="methodSignature">public java.lang.String toString()</pre>
|
|
<dl>
|
|
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
|
|
<dd><code>toString</code> in class <code>java.lang.Object</code></dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a id="close()">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>close</h4>
|
|
<pre class="methodSignature">public void close()
|
|
throws <a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></pre>
|
|
<div class="block">Closes the session, releasing it's resources.</div>
|
|
<dl>
|
|
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
|
|
<dd><code>close</code> in interface <code>java.lang.AutoCloseable</code></dd>
|
|
<dt><span class="throwsLabel">Throws:</span></dt>
|
|
<dd><code><a href="OrtException.html" title="class in ai.onnxruntime">OrtException</a></code> - If it failed to close.</dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
</section>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
</main>
|
|
<!-- ========= END OF CLASS DATA ========= -->
|
|
<footer role="contentinfo">
|
|
<nav role="navigation">
|
|
<!-- ======= START OF BOTTOM NAVBAR ====== -->
|
|
<div class="bottomNav"><a id="navbar.bottom">
|
|
<!-- -->
|
|
</a>
|
|
<div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div>
|
|
<a id="navbar.bottom.firstrow">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="navList" title="Navigation">
|
|
<li><a href="../../index.html">Overview</a></li>
|
|
<li><a href="package-summary.html">Package</a></li>
|
|
<li class="navBarCell1Rev">Class</li>
|
|
<li><a href="package-tree.html">Tree</a></li>
|
|
<li><a href="../../deprecated-list.html">Deprecated</a></li>
|
|
<li><a href="../../index-all.html">Index</a></li>
|
|
<li><a href="../../help-doc.html">Help</a></li>
|
|
</ul>
|
|
</div>
|
|
<div class="subNav">
|
|
<ul class="navList" id="allclasses_navbar_bottom">
|
|
<li><a href="../../allclasses.html">All Classes</a></li>
|
|
</ul>
|
|
<div>
|
|
<script type="text/javascript"><!--
|
|
allClassesLink = document.getElementById("allclasses_navbar_bottom");
|
|
if(window==top) {
|
|
allClassesLink.style.display = "block";
|
|
}
|
|
else {
|
|
allClassesLink.style.display = "none";
|
|
}
|
|
//-->
|
|
</script>
|
|
<noscript>
|
|
<div>JavaScript is disabled on your browser.</div>
|
|
</noscript>
|
|
</div>
|
|
<div>
|
|
<ul class="subNavList">
|
|
<li>Summary: </li>
|
|
<li><a href="#nested.class.summary">Nested</a> | </li>
|
|
<li>Field | </li>
|
|
<li>Constr | </li>
|
|
<li><a href="#method.summary">Method</a></li>
|
|
</ul>
|
|
<ul class="subNavList">
|
|
<li>Detail: </li>
|
|
<li>Field | </li>
|
|
<li>Constr | </li>
|
|
<li><a href="#method.detail">Method</a></li>
|
|
</ul>
|
|
</div>
|
|
<a id="skip.navbar.bottom">
|
|
<!-- -->
|
|
</a></div>
|
|
<!-- ======== END OF BOTTOM NAVBAR ======= -->
|
|
</nav>
|
|
</footer>
|
|
</body>
|
|
</html>
|