windows-machine-learning-“找不到适用于op Add的合适的内核定义”

时间:2018-09-17 16:51:42

标签: windows-machine-learning

正在运行最新的WinMLRunning,但出现错误:

  

没有为op Add找到合适的内核定义(节点InceptionV1 / InceptionV1 / Conv2d_1a_7x7 / BatchNorm / FusedBatchNorm)

我使用VS或mmdnn将自定义推理冻结的Inception模型转换为ONNX。从头开始编写新的Win32 WinML桌面应用程序时出现类似错误。

OS: 17758 insider preview
SDK : 17754 insider preview
VS: 15.8.4

WinML Runner
GPU: Intel(R) UHD Graphics 620

=================================================================
Name: tf2onnx
Author: tf2onnx
Version: 9223372036854775807
Domain:
Description:
Path: test3.onnx
Support FP16: false

Input Feature Info:
Name: input:0
Feature Kind: Float

Output Feature Info:
Name: InceptionV1/Logits/Predictions/Reshape_1:0
Feature Kind: Float

=================================================================

Loading model...[SUCCESS]
Creating session [FAILED]
No suitable kernel definition found for op Add (node InceptionV1/InceptionV1/Conv2d_1a_7x7/BatchNorm/FusedBatchNorm)

=================================================================
Name: tf2onnx
Author: tf2onnx
Version: 9223372036854775807
Domain:
Description:
Path: test3.onnx
Support FP16: false

Input Feature Info:
Name: input:0
Feature Kind: Float

Output Feature Info:
Name: InceptionV1/Logits/Predictions/Reshape_1:0
Feature Kind: Float

=================================================================

Loading model...[SUCCESS]
Creating session [FAILED]
No suitable kernel definition found for op Add (node InceptionV1/InceptionV1/Conv2d_1a_7x7/BatchNorm/FusedBatchNorm)

1 个答案:

答案 0 :(得分:3)

请确保您的操作员版本是最新的。要检查版本,请使用Netron打开模型,单击输入节点并检查Imports字段。

我们希望: ai.onnx v7 用于ONNX Operator Set 7,这是Windows Machine Learning API支持的最低版本。

尝试使用tf2onnx转换工具从tensorflow转换。您可能还需要更新ONNX python软件包。我们支持 ONNX 1.2.2或更高版本https://github.com/onnx/tensorflow-onnx

此问题已在此处解决:https://github.com/Microsoft/Windows-Machine-Learning/issues/50