Clear Filters
Clear Filters

How is the number of weights in the first layer of fitcnet determined?

1 view (last 30 days)
I was looking at the ionosphere example in the fitcnet documentation. I can specify the number of neurons in the fully connected layers, say 25 and 20, and LayerWeights{2} yields 20x25, which makes sense. However, LayerWeights{1} is 25x34, and I have no idea where the 34 comes from. The second dimensions stays 34 even when the middle layers are changed. So why 34?

Accepted Answer

Taylor
Taylor on 2 Nov 2023
The matrix "X" in the ionosphere dataset contains 34 features. Your input layer must always have the same number of columns as features in your data.

More Answers (0)

Categories

Find more on Sequence and Numeric Feature Data Workflows in Help Center and File Exchange

Products


Release

R2023b

Community Treasure Hunt

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

Start Hunting!