two_layer_net 代码学习笔记
2018-03-29 23:32
381 查看
1e-8 = 0.00000001
print(np.maximum(1e-8, 0 )) 1e-08
np.max:(a, axis=None, out=None, keepdims=False) 求序列的最值 最少接收一个参数 axis:默认为列向(也即 axis=0),axis = 1 时为行方向的最值; np.maximum:(X, Y, out=None) X 与 Y 逐位比较取其大者; 最少接收两个参数 np.max([-2, -1, 0, 1, 3]) 3 np.maximum([-1, -1, 0, 1, 2], 0) array([0, 0, 0, 1, 2])
Implementing a Neural Network 神经网络的实现 In this exercise we will develop a neural network with fully-connected layers to perform classification, and test it out on the CIFAR-10 dataset. 在这个练习中我们将建立一个神经网络完全连接的层进行分类,并测试它的cifar-10数据集。 A bit of setup 一点设置 for auto-reloading external modules 用于自动加载外部模块 returns relative error 回报率的相对误差 invalid syntax 无效语法
np.random.seed(0) 当我们设置相同的seed,每次生成的随机数相同。 如果不设置seed,则每次会生成不同的随机数
numpy.random.randn(d0, d1, …, dn)是从标准正态分布中返回一个或多个样本值。 numpy.random.rand(d0, d1, …, dn)的随机样本位于[0, 1)中。
周四看到这里,周五继续。
Forward pass: compute scores Open the file cs231n/classifiers/neural_net.py and look at the method TwoLayerNet.loss. This function is very similar to the loss functions you have written for the SVM and Softmax exercises: It takes the data and weights and computes the class scores, the loss, and the gradients on the parameters. Implement the first part of the forward pass which uses the weights and biases to compute the scores for all inputs.
相关文章推荐
- Asp.Net Ajax 学习笔记21 VS2008的JavaScript代码提示功能
- asp.net自定义控件代码学习笔记
- excoax_net学习笔记之eth_mac_v2 -----INIT 出口代码
- ASP.NET学习笔记2--自己写代码绑定Gridview
- BlogEngine.net 代码学习笔记(一)
- caffe学习笔记6:Blob,layer and net以及对应配置文件的编写
- BlogEngine.net 代码学习笔记
- 【学习笔记】〖ASP.NET〗在后台代码中取到控件旧值的解决办法
- ado.net 学习笔记,程序入口的代码
- 黑马程序员之ASP.NET学习笔记:Http状态代码及其含义
- [ASP.NET学习笔记之十二]ASP.NET 2.0中Theme、MasterPage和代码国际化
- ASP.NET学习笔记2--自己写代码绑定Gridview
- 黑马程序员之 ASP.NET学习笔记:jquery+ajax无刷新分页代码
- Linux netfilter 学习笔记 之十二 ip层netfilter的NAT模块代码分析
- cocos代码研究(2)Layer学习笔记
- asp.net 学习笔记 代码块标记
- [ASP.NET学习笔记之三十]ASP.NET 2.0的代码隐藏和编译模型
- Asp.net学习笔记之隐藏代码
- ado.net学习笔记(1)常用代码
- BlogEngine.net 代码学习笔记(二)