Hi,
As per my understanding, you want to pause the training of the Neural Network and resume it later again. Also, you want to train the existing trained network on some other dataset.
1.) You can stop the training of the Neural Network in the "training progress" dialogue box.
- Click on the button present on the right side of the progress bar in the "training progress" dialogue box. This will stop the trianing and save the current progress.
- Save the trained network as ".mat file "using "save" command.
save('trainedNetwork.mat', 'net');
net = load('trainedNetwork.mat');
- Begin the training again by using the saved network as initial weights. This can be achieved by setting the "layers" argument of the "trainNetwork" function as "net.Layers"
net = trainNetwork(XTrain,YTrain,net.Layers,options);
2.) It is possible to train the existing network with other data sets. This can be achieved by taking the existing network as initial weights and training the network with new data. Follow the below steps.
- Load the existing network.
- Set the "layers" argument of the "trainNetwork" function as "saveNet.Layers".
- Use new data in places of "Xtrain" and "Yrain" in the "trainNetwork" function.
Refer to the documentation link to know more about Neural Network layers in "trainNetwork" function.