using neural network in Simulink

조회 수: 3 (최근 30일)
James Z
James Z 2021년 11월 9일
댓글: James Z 2021년 11월 10일
Hi,
I have trained a neural network using LSTM method for sequence classification and load it in Simulink blocks "stateful classify", "predict", "classify", and expect a category number for the outcome of the blocks when I apply same-type sequences, but I get only a decimal between 0 and 1 instead, as shown in below pic:
any idea what is wrong with the blocks I am using? I was going to attach the Simulink model and workspace data related to the trained neural network model and input time series required to run the Simulink model but they were over size limit. will appreciate your response.
With Regards

채택된 답변

David Willingham
David Willingham 2021년 11월 9일
Hi,
Are you asking why the "Predict" block is acting differently than the "Stateful Predict" block? IF so, are you specifying the same model in each?
If so, these block behave differently. The main difference is that if you are using a trained network with at least one recurrent layer (for example, an LSTM network), then Stateful predict is the block to use.
  댓글 수: 2
James Z
James Z 2021년 11월 10일
Hello,
Thanks for your response.
The issue is that I expected a class number, say 0 or 1 from the neural network model, not a continuous decimal which I don't know what it indicates and how to interpret.
With Regards
James Z
James Z 2021년 11월 10일
.. and yes, I loaded the same neural network in all blocks, stateful classify, predict, etc. The pattern recognition blocks are generated by hitting "Export to Simulink" button in neural network app interface which opens by typing "nnstart", or particularly "nprtool".

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

추가 답변 (0개)

카테고리

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

제품


릴리스

R2021a

Community Treasure Hunt

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

Start Hunting!

Translated by