课上习题 [1]线性回归 Answer: D A 特征缩放不起作用,B for all 不对,C zero error不对 [2]概率 Answer:A [3]预测图形 Answer:A 5 - x1 ≥ 0时,y = 1.即x1 ≤ 5时,y = 1 [4]凸函数 [5]代价函数 Answer:ABD 任何情况下都是 预测对时 cost为0,反之为正无穷 [6]代价函数 [7]向量化 Answer:A [8]高级优化算法 Answer:C [9]多分类 测验 AB Answer:BE 当有一个…
Lecture6 Logistic Regression 逻辑回归 6.1 分类问题 Classification6.2 假设表示 Hypothesis Representation6.3 决策边界 Decision Boundary6.4 代价函数 Cost Function6.5 简化的代价函数和梯度下降 Simplified Cost Function and Gradient Descent6.6 高级优化 Advanced Optimization6.7 多类别分类:一对多  Mult…
Question 1 Consider the problem of predicting how well a student does in her second year of college/university, given how well she did in her first year. Specifically, let x be equal to the number of “A” grades (including A-. A and A+ grades) that a…
Gradient Descent for Multiple Variables [1]多变量线性模型  代价函数 Answer:AB [2]Feature Scaling 特征缩放 Answer:D [3]学习速率 α Answer: B,因为第一个比第二个下降的快.第三个上升说明α太大 [4]Mean Normalization Answer:C [5]Normal Equation Answer:D Linear Regression with Multiple Variables [1]…
作业说明 Exercise 2,Week 3,使用Octave实现逻辑回归模型.数据集  ex2data1.txt ,ex2data2.txt 实现 Sigmoid .代价函数计算Computing Cost 和 梯度下降Gradient Descent. 文件清单 ex2.m - Octave/MATLAB script that steps you through the exercise ex2 reg.m - Octave/MATLAB script for the later part…
课上习题 [1]代价函数 [2]代价函数计算 [3] [4]矩阵的向量化 [5]梯度校验 Answer:(1.013 -0.993) / 0.02 = 3.001 [6]梯度校验 Answer:学习的时候要去掉梯度校验,不然会特别慢 [7]随机初始化 Answer:对于神经网络这种复杂模型来说,初始值都是同一个值 r,不然第二层会全都一样. [8]梯度下降 测验 Answer: A Answer:A Answer:D 3*(1.01)4 - 3*(0.99)4 / 0.02 Answer:ACE…
[1]机器学习管道 [2]滑动窗口 Answer:C ((200-20)/4)2 = 2025 [3]人工数据 [4]标记数据 Answer:B (10000-1000)*10 /(8*60*60) = 3.125 [5]上限分析 测验 Answer:D 忽略窗口的宽度,只考虑step:     (1000/2) * (1000/2) * 2 = 500000 Answer:B 10 * 10000 / (4*60) = 417 Answer:AB C 错误.上限分析不能提供增加训练数据. D…
[1]大规模数据 [2]随机梯度下降 [3]小批量梯度下降 [4]随机梯度下降的收敛 Answer:BD A 错误.学习率太小,算法容易很慢 B 正确.学习率小,效果更好 C 错误.应该是确定阈值吧 D 正确.曲线不下降,说明学习率选的太大 [5]在线学习 [6] Answer:BC A 错误.随机梯度下降,J(θ)不一定每次都减小 D 错误.随机梯度下降适合大数据量任务 Answer:CD A 错误. B 错误.不是因为使用parallelizaion Answer:AD B 错误.不需要保存…
[1]异常检测 [2]高斯分布 [3]高斯分布 [4] 异常检测 [5]特征选择 [6] [7]多变量高斯分布 Answer: ACD B 错误.需要矩阵Σ可逆,则要求m>n  测验1 Answer:AB Answer: A p(x) < ε  ,漏掉的比较多,说明应该增大ε Answer:A x1 应该接近 x2.  增加 x1/x2 这个feature 可以显示异常 Answer: BD A 错误.训练的时候需要标记哪些是异常. C 错误.如果有大量数据,表现应该没有SVM好(?) Ans…
[1]无监督算法 [2]聚类 [3]代价函数 [4] [5]K的选择 [6]降维 Answer:本来是 n 维,降维之后变成 k 维(k ≤ n) [7] [8] Answer: 斜率-1 [9] Answer: x 是一个向量 [10]PCA 降维 [11] [12]PCA 的作用 测验1 Answer:ABGH Answer:A Answer: BD Answer: C Answer: AD 测验2 Answer:AB  要找到投影距离最小的向量,是1和2,方向正还是负都是可以的 Answe…