'InitalLearnRate' is not an option for solver 'sgdm'.

9 次查看(过去 30 天)
options = trainingOptions('sgdm', ...
'MiniBatchSize',128, ...
'MaxEpochs',1, ...
'InitalLearnRate',1e-4);
I can not set InitalLearnRate
Error using nnet.cnn.TrainingOptionsSGDM (line 128)
'InitalLearnRate' is not an option for solver 'sgdm'.
Error in trainingOptions (line 440)
opts = nnet.cnn.TrainingOptionsSGDM(varargin{:});
Error in test3 (line 159)
options = trainingOptions('sgdm', ...
MATLAB version is R2023b
  1 个评论
KSSV
KSSV 2024-4-3
options = trainingOptions('sgdm')
options =
TrainingOptionsSGDM with properties: Momentum: 0.9000 InitialLearnRate: 0.0100 MaxEpochs: 30 LearnRateSchedule: 'none' LearnRateDropFactor: 0.1000 LearnRateDropPeriod: 10 MiniBatchSize: 128 Shuffle: 'once' CheckpointFrequency: 1 CheckpointFrequencyUnit: 'epoch' SequenceLength: 'longest' PreprocessingEnvironment: 'serial' L2Regularization: 1.0000e-04 GradientThresholdMethod: 'l2norm' GradientThreshold: Inf Verbose: 1 VerboseFrequency: 50 ValidationData: [] ValidationFrequency: 50 ValidationPatience: Inf ObjectiveMetricName: 'loss' CheckpointPath: '' ExecutionEnvironment: 'auto' OutputFcn: [] Metrics: [] Plots: 'none' SequencePaddingValue: 0 SequencePaddingDirection: 'right' InputDataFormats: "auto" TargetDataFormats: "auto" ResetInputNormalization: 1 BatchNormalizationStatistics: 'auto' OutputNetwork: 'auto' Acceleration: "auto"
sgdm supports InitalLearnRate.

请先登录,再进行评论。

采纳的回答

VBBV
VBBV 2024-4-3
      options = trainingOptions('sgdm', ...
        'MiniBatchSize',128, ...
        'MaxEpochs',1, ...
        'InitialLearnRate',1e-4);

There is a type error in the function

  2 个评论
VBBV
VBBV 2024-4-3
编辑:VBBV 2024-4-3

You have mistyped the spelling in the function. Check the spelling as InitalLearnRate there is a missing 'i'

请先登录,再进行评论。

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Sequence and Numeric Feature Data Workflows 的更多信息

产品


版本

R2023b

Community Treasure Hunt

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

Start Hunting!

Translated by