MACHINE LEARNING
-WEEK 1-
김수진
Contents
1. Introduction
2. Model and Cost Function
3. Parameter Learning
4. Linear Algebra
2
What is Machine Learning?
 Arthur Samuel (1959).
Machine Learning: Field of study that gives
computers the ability to learn without being
explicitly programmed.
 Tom Mitchell (1998)
A computer program is said to learn from
experience E with respect to some task T and
some performance measure P, if its
performance on T, as measured by P,
improves with experience E.
3
What is Machine Learning?
 Examples:
-Database mining Large datasets from growth of
automation/web.
E.g., Web click data, medical records, biology,
engineering
-Applications can’t program by hand.
E.g., Autonomous helicopter, handwriting
recognition, most of Natural Language Processing
(NLP), Computer Vision.
-Self-customizing programs
E.g., Amazon, Netflix product recommendations
4
Machine learning algorithms
5
 -Supervised learning
In supervised learning, we already know what our
correct output should look like, having the idea
that there is a relationship between the input and
the output.
 -Unsupervised learning
Unsupervised learning allows us to approach
problems with little or no idea what our results
should look like. We can drive structure from data
where we don’t necessarily know the effect of the
variables.
Supervised learning
6
 Regression problem
Supervised learning
7
 Classification problem
환자의 나이나 종양의 특성 등의 요소를 추가적으로 고려함.
Unsupervised learning
8
 We can drive structure by clustering the data
based on relationships among the variables in
the data.
어느 것이 맞는 답인지 알려줌. Data set이 주어지지만 어떤 것인지, 무엇
알려주지 않음.
Unsupervised learning
9
 Clustering
데이터 내의 변수들의 관계에 기반한 클러스터링
으로 구조를 도출함.
Ex.
Unsupervised learning
10
Unsupervised learning
11
 Non-clustering
The “Cocktail Party Algorithm”, allows you to find
structure in a chaotic environment.
(i.e. identifying individual voices and music from
a mesh of sounds at a cocktail party)
Model and Cost Function
12
 Model representation
Model and Cost Function
13
Model and Cost Function
14
Model and Cost Function
15
 Cost Function : We can measure the accuracy
of our hypothesis function by using a cost
function. This takes an average difference
(actually a fancier version of an average) of all
the results of the hypothesis with inputs from
x's and the actual output y's.
 비용함수를 사용하면 주어진 데이터에 가장 가
까운 일차함수를 구할 수 있다.
개수
Model and Cost Function
16
Model and Cost Function
17
 Predicted value와 actual value의 차의 제곱의
평균을 구함
 X에 대한 함수 h, parameter theta에 대한 함수
J.
 Cost function J를 최소화하는 theta를 찾는 것
이 목표.
Model and Cost Function
18
Data1 = 0.5
Data1 = 0
Model and Cost Function
19
 2개의 parameter를 사용했을 때, 3차원 그래프,
등고선 모양을 띰.
Parameter Learning
20
 Gradient Descent 기울기 하강
: 비용함수 J의 최소값을 구하는 알고리즘
Parameter Learning
21
 가장 빠르게 언덕을 내려가는 길은?
: 각 지역 최적값을 도출
Parameter Learning
22
이 기호, := 는 할당받
는 것을 의미
α가 의미하는 바는
기본적으로
우리가 언덕을 내려
가기 위해 얼만큼 큰
걸음을 내딛어야하
는가 에 대한것
미분계수
값을 빼가면서 최적의 값을 도출.
주의! 계산할 때, theta0과 theta1은 값을
동시에 바꿔서 대입해야 한다.
Parameter Learning
23
기울기
양수
값을 줄여나감. Data1 이동하는 것을 의미.
음수 미분계수
증가 -> 최소값과 가까운 쪽으로 이동
Linear Algebra
24
 Matrices and Vectors
 Matrix : Rectangular array of numbers.
4*2 matrix
Linear Algebra
25
 Addition and scalar multiplication
Linear Algebra
26
 Matrix-vector multiplication
Linear Algebra
27
 Matrix-matrix multiplication
Linear Algebra
28
 Inverse and transpose

Machine learning

  • 1.
  • 2.
    Contents 1. Introduction 2. Modeland Cost Function 3. Parameter Learning 4. Linear Algebra 2
  • 3.
    What is MachineLearning?  Arthur Samuel (1959). Machine Learning: Field of study that gives computers the ability to learn without being explicitly programmed.  Tom Mitchell (1998) A computer program is said to learn from experience E with respect to some task T and some performance measure P, if its performance on T, as measured by P, improves with experience E. 3
  • 4.
    What is MachineLearning?  Examples: -Database mining Large datasets from growth of automation/web. E.g., Web click data, medical records, biology, engineering -Applications can’t program by hand. E.g., Autonomous helicopter, handwriting recognition, most of Natural Language Processing (NLP), Computer Vision. -Self-customizing programs E.g., Amazon, Netflix product recommendations 4
  • 5.
    Machine learning algorithms 5 -Supervised learning In supervised learning, we already know what our correct output should look like, having the idea that there is a relationship between the input and the output.  -Unsupervised learning Unsupervised learning allows us to approach problems with little or no idea what our results should look like. We can drive structure from data where we don’t necessarily know the effect of the variables.
  • 6.
  • 7.
    Supervised learning 7  Classificationproblem 환자의 나이나 종양의 특성 등의 요소를 추가적으로 고려함.
  • 8.
    Unsupervised learning 8  Wecan drive structure by clustering the data based on relationships among the variables in the data. 어느 것이 맞는 답인지 알려줌. Data set이 주어지지만 어떤 것인지, 무엇 알려주지 않음.
  • 9.
    Unsupervised learning 9  Clustering 데이터내의 변수들의 관계에 기반한 클러스터링 으로 구조를 도출함. Ex.
  • 10.
  • 11.
    Unsupervised learning 11  Non-clustering The“Cocktail Party Algorithm”, allows you to find structure in a chaotic environment. (i.e. identifying individual voices and music from a mesh of sounds at a cocktail party)
  • 12.
    Model and CostFunction 12  Model representation
  • 13.
    Model and CostFunction 13
  • 14.
    Model and CostFunction 14
  • 15.
    Model and CostFunction 15  Cost Function : We can measure the accuracy of our hypothesis function by using a cost function. This takes an average difference (actually a fancier version of an average) of all the results of the hypothesis with inputs from x's and the actual output y's.  비용함수를 사용하면 주어진 데이터에 가장 가 까운 일차함수를 구할 수 있다. 개수
  • 16.
    Model and CostFunction 16
  • 17.
    Model and CostFunction 17  Predicted value와 actual value의 차의 제곱의 평균을 구함  X에 대한 함수 h, parameter theta에 대한 함수 J.  Cost function J를 최소화하는 theta를 찾는 것 이 목표.
  • 18.
    Model and CostFunction 18 Data1 = 0.5 Data1 = 0
  • 19.
    Model and CostFunction 19  2개의 parameter를 사용했을 때, 3차원 그래프, 등고선 모양을 띰.
  • 20.
    Parameter Learning 20  GradientDescent 기울기 하강 : 비용함수 J의 최소값을 구하는 알고리즘
  • 21.
    Parameter Learning 21  가장빠르게 언덕을 내려가는 길은? : 각 지역 최적값을 도출
  • 22.
    Parameter Learning 22 이 기호,:= 는 할당받 는 것을 의미 α가 의미하는 바는 기본적으로 우리가 언덕을 내려 가기 위해 얼만큼 큰 걸음을 내딛어야하 는가 에 대한것 미분계수 값을 빼가면서 최적의 값을 도출. 주의! 계산할 때, theta0과 theta1은 값을 동시에 바꿔서 대입해야 한다.
  • 23.
    Parameter Learning 23 기울기 양수 값을 줄여나감.Data1 이동하는 것을 의미. 음수 미분계수 증가 -> 최소값과 가까운 쪽으로 이동
  • 24.
    Linear Algebra 24  Matricesand Vectors  Matrix : Rectangular array of numbers. 4*2 matrix
  • 25.
    Linear Algebra 25  Additionand scalar multiplication
  • 26.
  • 27.
  • 28.