IModelInferEnginePredict 方法
Performs model prediction/inference on the input tensor.
对输入张量执行模型预测/推理
命名空间: DeploySharp.Engine程序集: DeploySharp (在 DeploySharp.dll 中) 版本:0.0.4+6e8a2e904469617cd59619d666c0e272985c0e33
DataTensor Predict(
DataTensor input
)
- input DataTensor
-
Input data tensor containing properly formatted model inputs.
Must match the model's expected input shape and data type.
包含正确格式化模型输入的输入数据张量。
必须与模型预期的输入形状和数据类型匹配。
DataTensor
Output data tensor containing model predictions/results.
The shape and type depends on model architecture.
包含模型预测/结果的输出数据张量。
其形状和类型取决于模型架构。
using var engine = new OnnxRuntimeEngine();
engine.LoadModel(ref config);
var output = engine.Predict(inputTensor);