Prooving a trained LSTM regression model
4 ビュー (過去 30 日間)
古いコメントを表示
Hello
I am interested in proving how to derive the output given a new input value through the trained LSTM model.
I already know how to predict with new input data such as :
output = model.predict(input);
or
output = predict(model, input);
However, I am interested in a formula that uses the optimized variables of the trained LSTM (the variables shown in the figure below) to derive the results.
If you know what kind of calculation formula the output is derived when a new input value is given in LSTM, please help me.
0 件のコメント
採用された回答
Ayush Aniket
2024 年 7 月 8 日
Hi James,
To find the output using the weights of your trained layers, you will have to implement the equations for all the layers in your model. For the LSTM layer, refer this document section which shows the equations used to compute the output for each time step:
You would have to repeat the process for all the Fully Connected layers as well keeping in mind the size of input for the respective layers. Refer the following documentation section which provides the respective formulae:
Note: You will also have to take care of the pre and post processing functions that MATLAB layers implicitly apply to better train the neural network. The following MATLAB answer can guide you: https://www.mathworks.com/matlabcentral/answers/2068661-using-the-trained-lstm-weight-parameters-in-matlab-the-results-obtained-by-calculating-with-a-formu
0 件のコメント
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Sequence and Numeric Feature Data Workflows についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!