Advice for applying machine learning Machine Learning Advice

  • Slides: 30
Download presentation
Advice for applying machine learning 다음에 무엇을 할 지 결정하기 Machine Learning

Advice for applying machine learning 다음에 무엇을 할 지 결정하기 Machine Learning

Advice for applying machine learning 가설(hypothesis) 을 평가하기 Machine Learning

Advice for applying machine learning 가설(hypothesis) 을 평가하기 Machine Learning

당신의 가설을 평가하기 price 훈련자료집합에 없는 새로운 자료에 일반화하는데 실패 size of house no.

당신의 가설을 평가하기 price 훈련자료집합에 없는 새로운 자료에 일반화하는데 실패 size of house no. of bedrooms no. of floors age of house average income in neighborhood kitchen size Andrew Ng

Evaluating your hypothesis Dataset: Size Price 2104 1600 2400 1416 3000 1985 1534 1427

Evaluating your hypothesis Dataset: Size Price 2104 1600 2400 1416 3000 1985 1534 1427 1380 1494 400 330 369 232 540 300 315 199 212 243 Andrew Ng

Advice for applying machine learning 모델 선택과 훈련/검증/ 시험 집합들 Machine Learning

Advice for applying machine learning 모델 선택과 훈련/검증/ 시험 집합들 Machine Learning

Evaluating your hypothesis Dataset: Size Price 2104 1600 2400 1416 3000 1985 1534 1427

Evaluating your hypothesis Dataset: Size Price 2104 1600 2400 1416 3000 1985 1534 1427 1380 1494 400 330 369 232 540 300 315 199 212 243 Andrew Ng

Train/validation/test error Training error: Cross Validation error: Test error: Andrew Ng

Train/validation/test error Training error: Cross Validation error: Test error: Andrew Ng

Model selection 1. 2. 3. 10. Pick Estimate generalization error for test set Andrew

Model selection 1. 2. 3. 10. Pick Estimate generalization error for test set Andrew Ng

Advice for applying machine learning bias vs. variance 를 진단하기 Machine Learning

Advice for applying machine learning bias vs. variance 를 진단하기 Machine Learning

Size High bias (underfit) Price Bias/variance Size “Just right” Size High variance (overfit) Andrew

Size High bias (underfit) Price Bias/variance Size “Just right” Size High variance (overfit) Andrew Ng

Bias/variance Training error: error Cross validation error: degree of polynomial d Andrew Ng

Bias/variance Training error: error Cross validation error: degree of polynomial d Andrew Ng

Diagnosing bias vs. variance 당신의 학습알고리즘이 당신이 기대하던 것 보다 못한 성능을 보인다 고

Diagnosing bias vs. variance 당신의 학습알고리즘이 당신이 기대하던 것 보다 못한 성능을 보인다 고 가정하자. ( 또는 가 크다. ) 이것은 바이어스(bias) 문제인가? 또는 분산(variance) 문제인가? error Bias (underfit): (cross validation error) Variance (overfit): (training error) degree of polynomial d Andrew Ng

Advice for applying machine learning Regularization and bias/variance Machine Learning

Advice for applying machine learning Regularization and bias/variance Machine Learning

Linear regression with regularization Price Model: Size Large xx High bias (underfit) Intermediate xx

Linear regression with regularization Price Model: Size Large xx High bias (underfit) Intermediate xx “Just right” Size Small xx High variance (overfit) Andrew Ng

Choosing the regularization parameter Andrew Ng

Choosing the regularization parameter Andrew Ng

Choosing the regularization parameter Model: 1. 2. 3. 4. 5. Try Try Try 12.

Choosing the regularization parameter Model: 1. 2. 3. 4. 5. Try Try Try 12. Try Pick (say) . Test error: Andrew Ng

Bias/variance as a function of the regularization parameter Andrew Ng

Bias/variance as a function of the regularization parameter Andrew Ng

Advice for applying machine learning Learning curves Machine Learning

Advice for applying machine learning Learning curves Machine Learning

error Learning curves (training set size) Andrew Ng

error Learning curves (training set size) Andrew Ng

Advice for applying machine learning Deciding what to try next (revisited) Machine Learning

Advice for applying machine learning Deciding what to try next (revisited) Machine Learning

Debugging a learning algorithm: Suppose you have implemented regularized linear regression to predict housing

Debugging a learning algorithm: Suppose you have implemented regularized linear regression to predict housing prices. However, when you test your hypothesis in a new set of houses, you find that it makes unacceptably large errors in its prediction. What should you try next? - Get more training examples Try smaller sets of features Try getting additional features Try adding polynomial features Try decreasing Try increasing Andrew Ng

Neural networks and overfitting “Small” neural network (fewer parameters; more prone to underfitting) Computationally

Neural networks and overfitting “Small” neural network (fewer parameters; more prone to underfitting) Computationally cheaper “Large” neural network (more parameters; more prone to overfitting) Computationally more expensive. Use regularization ( ) to address overfitting. Andrew Ng