- Load your trained network.
- Prepare your sample input.
- Predict using the trained network.
- Save the prediction to a desired file.
How to create Prediction file in nnstart similar to nntool?
27 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Hi dears
I started with "nntool" and happily introduced my test sample (as input) and generate my prediction (as an output file- not known initially). I start learning "nnstart" and like all wonderfull plots but I cannot self define the output. The app requires the sample and the prediction simultaneously!
How can I use like "nntool" for "nnstart" by giving only sample and ask the trained model to predict and store the output in my desirable filename?
Thanks for you help me out.
0 commentaires
Réponses (2)
Ronit
le 28 Mar 2024
Hi Ahmad,
The ‘nntool’ interface is no longer supported and has been deprecated. The recommended alternative now is to use ‘nnstart’.
You have previously enjoyed using ‘nntool’ for inputting a sample and obtaining a prediction without the need to specify the actual output, I've found a workaround using MATLAB scripting. This method is designed to replicate that process as closely as possible, assuming you have a trained model ready.
Start by launching the ‘nnstart’ GUI. You can do this by typing nnstart in the MATLAB command window.
Create and Train the network by following the prompts in ‘nnstart’ to create and train your neural network. This will involve selecting the type of network, configuring its parameters, and training it using your dataset. You'll need to have both inputs and targets available for this step, as ‘nnstart’ is designed to guide you through the training process.
After training and exporting your network using ‘nnstart’, switch to scripting to make predictions using only your input samples.
load('trainedNetwork.mat'); % Use your filename
inputSample = ['/input comes here'/];
outputPrediction = predict(trainedNetwork, inputSample);
desiredFilename = 'predictionOutput.mat';
save(desiredFilename, 'outputPrediction');
If you need further customization or assistance with specific commands or steps, please refer to the following MATLAB documentation link:
Hope this helps!
2 commentaires
Ronit
le 2 Avr 2024
You can go ahead and save the MATLAB scripts and perform operations on that as it is recommended.
Voir également
Catégories
En savoir plus sur Modeling and Prediction with NARX and Time-Delay Networks dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!