# ML : Model Representation

Model Representation


 Regression Problem의 한 예로서, size에 따른 집 값(price)의 그래프를 보인다.
 이를 조금 더 보기 쉽게 표현하려면 다음과 같은 '표'를 만들어 사용할 수 있다.


1. Indexing

  •  - x(i) : input (여기서는 size)
  •  - y(i) : output, target variable that we are trying to predict (여기서는 price)
    •  x 예시 : x(1) = 2104, x(2) = 1416
    •  y 예시 : y(1) = 460, y(2) = 232

2. Training set

  •  - ( x(i) , y(i) ) : Training example
  •  - ( x(i) , y(i) ); i = 1, ......, m : Training set 
    • data set that we'll be using to learn, a list of training example

3. Hypothesis(h)

  • 위의 Training set 집합에 Learning Algorithm을 적용하여 h라는 학습된 가정을 생성
  • To describe the supervised learning problem slightly more formally, our goal is, given a training set, to learn a function h : X → Y so that h(x) is a “good” predictor for the corresponding value of y.
  • 최적의 결과 값을 보여주는 알고리즘(h)을 찾아내는 것이 목표


- When the target variable that we’re trying to predict is continuous, such as in our housing example, we call the learning problem a regression problem. 
: 주택의 예와 같이 연속적인 변수가 존재할 경우 = Regression Problem

- When y can take on only a small number of discrete values (such as if, given the living area, we wanted to predict if a dwelling is a house or an apartment, say), we call it a classification problem.
: y가 소수의 불연속적인 값을 취할 수 있는 경우(주거 형태가 주택인지 아파트인지 여부와 같이 정확하게 구분되는 경우) = Classification Problem


4. Univariate Linear Regression


  • h(x) = θ0 + θ1x (y = ax + b)
  • θ0 , θ1 의 값에 의해 값이 변경됨 = 그래프의 모양이 변경됨
  • 우리의 최종적인 목표는 'training set의 모든 점들로부터 직선까지의 거리가 가장 작은 '최소 차이'를 갖는 θ0 , θ1 값을 구하는 것
  • 이를 구하기 위한 함수(Cost Function)가 필요

댓글