How to use a customized Loss function in a Shallow neural network
3 ビュー (過去 30 日間)
古いコメントを表示
Hello everyone. There are very useful functions like trainlm and traingd to train a NN, but they all use MSE loss function as default. How can I change that with a function MyLossFunction that I build?
I searched a bit but I am finding basically solution to program all network, when the command train was very quicker. And even if I have to do step by step, I found how to build a network, do the forward propagation, create my Loss function, but I miss the backpropagation part.
Thank you for the attention
0 件のコメント
回答 (1 件)
Srivardhan Gadila
2020 年 8 月 23 日
In case of Shallow Neural Networks you can refer to Custom Performance Function for Neural Networks Toolbox using +mse package & relevant MATLAB Answers.
If deep neural networks would help for your use case then you can refer to Define Custom Training Loops, Loss Functions, and Networks & Train Network Using Custom Training Loop
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!