how do i convert this code to HDL using hdl coder?

1 次查看(过去 30 天)
clc
clear all
warning off
imds = imageDatastore('E:\BACK UP\matlab','Includesubfolders',true,'Labelsource','foldernames')
[traindata,testdata] = splitEachLabel(imds, 0.7);
layers = [imageInputLayer([25, 25,3]);
convolution2dLayer(5,20)
reluLayer
maxPooling2dLayer(2,'Stride',2)
fullyConnectedLayer(2)
softmaxLayer
classificationLayer()];
options = trainingOptions('sgdm',...
'LearnRateSchedule', 'piecewise', ...
'LearnRateDropFactor', 0.2, ...
'LearnRateDropPeriod', 5, ...
'MaxEpoch',110,...
'MiniBatchSize', 100,...
'InitialLearnRate',0.0001,...
'Plots','training-progress');
[net,info] =trainNetwork(traindata,layers,options);
save net net;
hdlcfg.GenerateHDLTestBench = true;

回答(1 个)

Kiran Kintali
Kiran Kintali 2022-12-29
You can follow these examples in Deep Learning HDL Toolbox.

类别

Help CenterFile Exchange 中查找有关 HDL Coder 的更多信息

产品


版本

R2020b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by