Hi Guys
I have a problem when i want to make a graph for the training phase like between Epoch & Mini-batch Loss
Herein the code
load('gTruth.mat')smokedetection = selectLabels(gTruth,'car');if isfolder(fullfile('TrainingData')) cd TrainingDataelse mkdir TrainingDataend addpath('TrainingData');options = trainingOptions('sgdm', ... 'MiniBatchSize', 32, ... 'InitialLearnRate', 1e-6, ... 'MaxEpochs', 10);layers = [ imageInputLayer([32 32 3],"Name","imageinput") convolution2dLayer([5 5],32,"Name","conv","BiasLearnRateFactor",2,"Padding",[2 2 2 2],"WeightsInitializer","narrow-normal") maxPooling2dLayer([3 3],"Name","maxpool","Stride",[2 2]) reluLayer("Name","relu") averagePooling2dLayer([3 3],"Name","avgpool","Stride",[2 2]) fullyConnectedLayer(2,"Name","fc_rcnn","BiasL2Factor",1,"BiasLearnRateFactor",10,"WeightLearnRateFactor",20,"WeightsInitializer","narrow-normal") softmaxLayer("Name","softmax") classificationLayer("Name","classoutput")];trainingData = objectDetectorTrainingData(smokedetection,'SamplingFactor',1,...'WriteLocation','TrainingData');detector = trainRCNNObjectDetector(trainingData, layers, options, ... 'NegativeOverlapRange', [0 0.3]);save('Detector.mat','detector');[detector,info] = trainRCNNObjectDetector('Epoch','Mini-batch Loss','Training Accuracy','Base Learning Rate','Mini-batch Accuracy'); x = ('Epoch');y = ('Mini-batch Loss');figureplot(x,y)title('Training Phase')xlabel('Number of Epochs')ylabel('Training Loss')
Error
Error using trainRCNNObjectDetectorExpected input number 1, trainingData, to be one of these types:tableError in vision.internal.cnn.validation.checkGroundTruth (line 2)validateattributes(gt, {'table'},{'nonempty'}, name, 'trainingData',1);Error in trainRCNNObjectDetector>parseInputs (line 311)vision.internal.cnn.validation.checkGroundTruth(trainingData, fname);Error in trainRCNNObjectDetector (line 248)[network, params] = parseInputs(trainingData, network, options, mfilename, varargin{:});Error in TrainingSmokeDetectionwithRCNN (line 29)[detector,info] = trainRCNNObjectDetector('Epoch','Mini-batch Loss','Training Accuracy','BaseLearning Rate','Mini-batch Accuracy');
Best Answer