当前位置:网站首页>Matlab r2011b neural network toolbox precautions
Matlab r2011b neural network toolbox precautions
2022-07-03 15:08:00 【trium_ KW】
This is a record of the pit I encountered when using the neural network toolbox , For yourself and others . Write a little first , Update later .
1.
net = feedforwardnet;
net = train(net, attributes, targets);The first line creates a two-layer feedforward network , The number of hidden layer neurons is the default 10, It's no problem . After creating the network , If you use view(net) To view the network topology , You will find that there are no input vectors and output vectors , This is because... Has not been called yet configure function .configure By default, the function is called for the first time train Function is automatically called . There's a pit here . hypothesis :
X = [
1 1 2;
2 1 3;
3 1 1;
2 1 3]';
Y = [
0 1 1 0];That is, the input vector is 3 Dimension vector , Data sets X Contained in the 4 Samples , Training adopts batch training . after train After function call ,net.IW{1,1} The dimension of will become 10x2! Should not be 10x3 Do you ( notes : The number of neurons in the hidden layer 10, Input vector 3 dimension )? Because the dataset X The second attribute of all samples in is the same ( Values are 1), As a result, this attribute is Matlab Ignore it. , I don't know whether it was intentional or bug. resolvent
X(:,find(var(X,0,1) < eps)) = X(:,find(var(X,0,1))) + min(min(X))*1e-5*randn(size(X,1),length(find(var(X,0,1))));namely , Add a small white noise to the ignored columns to make their values different .
边栏推荐
- 使用Tengine解决负载均衡的Session问题
- Global and Chinese market of postal automation systems 2022-2028: Research Report on technology, participants, trends, market size and share
- [graphics] hair simulation in tressfx
- What is machine reading comprehension? What are the applications? Finally someone made it clear
- 零拷贝底层剖析
- Global and Chinese market of solder bars 2022-2028: Research Report on technology, participants, trends, market size and share
- 北京共有产权房出租新规实施的租赁案例
- Solve the problem that pushgateway data will be overwritten by multiple push
- Global and Chinese market of lighting control components 2022-2028: Research Report on technology, participants, trends, market size and share
- Composite type (custom type)
猜你喜欢
![[graphics] hair simulation in tressfx](/img/41/cef55811463d3a25a29ddab5278af0.jpg)
[graphics] hair simulation in tressfx

B2020 分糖果

【pytorch学习笔记】Datasets and Dataloaders
![[transform] [NLP] first proposed transformer. The 2017 paper](/img/33/f639ab527d5adedfdc39f8d8117c3e.png)
[transform] [NLP] first proposed transformer. The 2017 paper "attention is all you need" by Google brain team

How to color ordinary landscape photos, PS tutorial

链表有环,快慢指针走3步可以吗

Centos7 deployment sentry redis (with architecture diagram, clear and easy to understand)

What are the composite types of Blackhorse Clickhouse, an OLAP database recognized in the industry

【Transformer】入门篇-哈佛Harvard NLP的原作者在2018年初以逐行实现的形式呈现了论文The Annotated Transformer
![[ue4] HISM large scale vegetation rendering solution](/img/a2/2ff2462207e3c3e8364a092765040c.jpg)
[ue4] HISM large scale vegetation rendering solution
随机推荐
5.2-5.3
Série yolov5 (i) - - netron, un outil de visualisation de réseau
【日常训练】395. 至少有 K 个重复字符的最长子串
Introduction to opengl4.0 tutorial computing shaders
redis单线程问题强制梳理门外汉扫盲
Kubernetes带你从头到尾捋一遍
ASTC texture compression (adaptive scalable texture compression)
Troubleshooting method of CPU surge
Yolov5进阶之七目标追踪最新环境搭建(二)
【微信小程序】WXSS 模板样式
Use of Tex editor
Finally, someone explained the financial risk management clearly
Class part2
Mmdetection learning rate and batch_ Size relationship
零拷贝底层剖析
Tensor ellipsis (three points) slice
What is machine reading comprehension? What are the applications? Finally someone made it clear
Global and Chinese market of lighting control components 2022-2028: Research Report on technology, participants, trends, market size and share
[graphics] hair simulation in tressfx
4-33--4-35