ignition-monorepo / backend-onnx/src / runInference
Function: runInference()
runInference(
session,inputData,inputShape,inputName,outputName):Promise<Float32Array<ArrayBufferLike>>
Defined in: backend-onnx/src/runtime-universal.ts:55
Runs a forward pass through an ONNX session.
Parameters
session
InferenceSession
Active InferenceSession
inputData
Float32Array
Flat Float32Array of the input tensor
inputShape
number[]
Shape of the input tensor (e.g. [1, 4])
inputName
string
ONNX graph input tensor name
outputName
string
ONNX graph output tensor name
Returns
Promise<Float32Array<ArrayBufferLike>>
Flat Float32Array of the output tensor (e.g. Q-values)
Last updated on