How to use a neural network model generated using feedforwardnet in code generation?

조회 수: 10 (최근 30일)
I am getting an error: "Object type "Network" is not supported for code generation". I have tried using coder.loadDeepLearningNetwork but still not working.

채택된 답변

Sanjana
Sanjana 2023년 3월 30일
Hi,
I Understand that you are facing an issue with code generation of shallow neural networks.
“Coder.loadDeepLearningNetwork” can be used only with Deep Neural Networks. To achieve code generation for shallow neural networks, follow the below approach:
  • Use “genFunction” to generate a complete stand-alone MATLAB function for simulating a neural network including all settings, weight and bias values, module functions and calculations in one file.
  • You can then generate C/C++ code from this standalone MATLAB function.
Please refer the below link, for further information
Hope this helps!
  댓글 수: 2
天钾
天钾 2024년 11월 25일
But it seems that this function only supports trained networks. What whould I do if I want to train the network with a coder?

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Deep Learning Toolbox에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by