why exportONNXNetwork will add additional "Sub" in onnx, how to remove this layer in onnx?
4 views (last 30 days)
Show older comments
Hi, i did the following:
>> baseNetwork = resnet50;
>> exportONNXNetwork(baseNetwork,'resnet50-matlab');
but when compare same model in Deep Network Designer and Netron (onnx reader), i found there is additional "Sub" in generated onnx
![resnet50-matlab.JPG](https://www.mathworks.com/matlabcentral/answers/uploaded_files/236958/resnet50-matlab.jpeg)
then i download the official resnet50 from onnx github, there are no "Sub"
![resnet50-github.JPG](https://www.mathworks.com/matlabcentral/answers/uploaded_files/236959/resnet50-github.jpeg)
this Sub will cause some issue in my enviroment, how to remove it? also is it a bug or why this Sub exist? thanks
Regards,
Owen
Answers (1)
Don Mathis
on 9 Sep 2019
The Sub operator is subtracting the mean image from the raw image input.
0 Comments
See Also
Categories
Find more on Deep Learning Toolbox in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!