1

You train a learning algorithm, and find that it has unacceptably high error on the test set. You plot the learning curve, and obtain the figure below. Is the algorithm suffering from high bias, high variance, or neither?

Week 6 测验:Advice for Applying Machine Learning【Maching Learning】

A、High bias

B、High variance

C、Neither

正确答案:A 训练集误差和测试集误差接近,高偏差

 

2. 2 个问题

Suppose you have implemented regularized logistic regression to classify what object is in an image (i.e., to do object recognition). However, when you test your hypothesis on a new set of images, you find that it makes unacceptably large errors with its predictions on the new images. However, your hypothesis performs well (has low error) on the training set. Which of the following are promising steps to take? Check all that apply.

Get more training examples.

Try using a smaller set of features.

Use fewer training examples.

Try adding polynomial features.

正确答案:过拟合,还没选出来,当时只选了B,不对

1

3. 3 个问题

Suppose you have implemented regularized logistic regression to predict what items customers will purchase on a web shopping site. However, when you test your hypothesis on a new set of customers, you find that it makes unacceptably large errors in its predictions. Furthermore, the hypothesis performs poorly on the training set. Which of the following might be promising steps to take? Check all that apply.

A、Use fewer training examples.

B、Try adding polynomial features.

C、Try evaluating the hypothesis on a cross validation set rather than the test set.

D、Try decreasing the regularization parameter λ

正确答案:BD 欠拟合,高偏差,通过增加多项式项和减小lambda来解决问题

4.

Which of the following statements are true? Check all that apply.

A、Suppose you are training a logistic regression classifier using polynomial features and want to select what degree polynomial (denoted d in the lecture videos) to use. After training the classifier on the entire training set, you decide to use a subset of the training examples as a validation set. This will work just as well as having a validation set that is separate (disjoint) from the training set.

B、A typical split of a dataset into training, validation and test sets might be 60% training set, 20% validation set, and 20% test set.

C、Suppose you are using linear regression to predict housing prices, and your dataset comes sorted in order of increasing sizes of houses. It is then important to randomly shuffle the dataset before splitting it into training, validation and test sets, so that we don’t have all the smallest houses going into the training set, and all the largest houses going into the test set.

D、It is okay to use data from the test set to choose the regularization parameter λ, but not the model parameters (θ).

正确答案:BC  A的错误原因,验证集不能是训练集的子集,要不就没有意义了;

5.

Which of the following statements are true? Check all that apply.

A、When debugging learning algorithms, it is useful to plot a learning curve to understand if there is a high bias or high variance problem.

B、A model with more parameters is more prone to overfitting and typically has higher variance.

C、If a learning algorithm is suffering from high bias, only adding more training examples may not improve the test error significantly.

D、If a neural network has much lower training error than test error, then adding more layers will help bring the test error down because we can fit the test set better.

正确答案:ABC 。。D的错误原因:高方差,已经过拟合了,再增加层数,模型复杂度更大,更容易过拟合

 

相关文章: