Fail to export net to ONNX
9 次查看(过去 30 天)
显示 更早的评论
I'm trying to use the exportONNXNetwork function, in order to load it later into CNTK, but I'm getting a lot of warnings that I don't understand. I was hoping to get some pointers on what they might mean.
>> load('netTry.mat')
>> netFileToOMX = 'netFileToOMX_try1';
>> exportONNXNetwork(net,netFileToOMX);
This is the code i'm using, and here are the warnings:
A bunch of these:
Warning: ONNX does not support layer 'nnet.cnn.layer.Image3DInputLayer'. Exporting to ONNX operator 'com.MathWorks.Placeholder'.
> In nnet.internal.cnn.onnx.NNTLayerConverter.makeLayerConverter (line 173)
In nnet.internal.cnn.onnx.ConverterForNetwork/networkToGraphProto (line 80)
In nnet.internal.cnn.onnx.ConverterForNetwork/toOnnx (line 44)
In nnet.internal.cnn.onnx.exportONNXNetwork (line 34)
In exportONNXNetwork (line 40)
Warning: ONNX does not support layer 'nnet.cnn.layer.Convolution3DLayer'. Exporting to ONNX operator 'com.MathWorks.Placeholder'.
> In nnet.internal.cnn.onnx.NNTLayerConverter.makeLayerConverter (line 173)
In nnet.internal.cnn.onnx.ConverterForNetwork/networkToGraphProto (line 80)
In nnet.internal.cnn.onnx.ConverterForNetwork/toOnnx (line 44)
In nnet.internal.cnn.onnx.exportONNXNetwork (line 34)
In exportONNXNetwork (line 40)
Warning: ONNX does not support layer 'nnet.cnn.layer.Convolution3DLayer'. Exporting to ONNX operator 'com.MathWorks.Placeholder'.
> In nnet.internal.cnn.onnx.NNTLayerConverter.makeLayerConverter (line 173)
In nnet.internal.cnn.onnx.ConverterForNetwork/networkToGraphProto (line 80)
In nnet.internal.cnn.onnx.ConverterForNetwork/toOnnx (line 44)
In nnet.internal.cnn.onnx.exportONNXNetwork (line 34)
In exportONNXNetwork (line 40)
And finally this:
Error using nnet.internal.cnn.onnx.ConverterForSoftmaxLayer/toOnnx (line 32)
Assertion failed.
Error in nnet.internal.cnn.onnx.ConverterForNetwork/networkToGraphProto (line 81)
[nodeProto, paramInitializers, paramInputs, netInputs, netOutputs, layerMap] = toOnnx(layerConverter, TensorNameMap);
Error in nnet.internal.cnn.onnx.ConverterForNetwork/toOnnx (line 44)
modelProto.graph = networkToGraphProto(this);
Error in nnet.internal.cnn.onnx.exportONNXNetwork (line 34)
modelProto = toOnnx(converter);
Error in exportONNXNetwork (line 40)
nnet.internal.cnn.onnx.exportONNXNetwork(Network, filename, varargin{:});
Any help appreciated.
0 个评论
采纳的回答
Don Mathis
2019-4-12
I don't think you'll be able to export 3d image networks until the support package supports it (expected later this year). If you're able to post your network here, I could see if there are any other potential issues besides the 3d Conv layers.
3 个评论
Don Mathis
2019-5-20
Yes, the ONNX Converter support package is being actively developed by MathWorks. However, we have a policy not to estimate when, or even if, specific future features will be available. So I can't make any promises beyond saying that exporting 3d networks is considered highly important to us.
更多回答(1 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Image Data Workflows 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!