📄 setx_snn.m
字号:
function net = setx_snn(net, X)%SETX_SNN Set connection weights and biases of net from X.%% See also%% GETX_SNN%ind_1 = 1;for m = 1:net.numLayers [rows, columns] = size(net.weights{m}); ind_2 = ind_1 + rows*columns; net.weights{m} = reshape(X([ind_1:(ind_2-1)],1), rows, columns); ind_1 = ind_2 + rows; net.biases{m} = reshape(X([ind_2:(ind_1-1)],1), rows, 1);end
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -