Machine learning types and training
도입됨
13:04
인공지능이란 무엇인가
고양이와 개를 구분하는 규칙을 쓴 사람은 없다. 프로그래머가 "만일 족한 귀와 수염이 있다면"이라고 타이핑한 적도 없다. 그런데도你的手机는…한다.
영어 내레이션 · 영어와 중국어 자막 전환 가능
이 수업의 내용
| English | 의미 |
|---|---|
| machine learning/məˈʃiːn ˈlɜːnɪŋ/ | 머신러닝 |
| weights | Numbers that control how strongly inputs affect a network's outputs. |
| backpropagation/ˌbækprəpəˈɡeɪʃn/ | 역전파 |
| Supervised learning/ˈsuːpəvaɪzd ˈlɜːnɪŋ/ | A way of training a model using data with correct labels. |
| labels/ˈleɪblz/ | A symbolic name identifying an item; in assembly language, a name associated with an instruction or storage address. |
| model/ˈmɒdl/ | A simplified representation of a system used to explain, analyse or predict its behaviour. |
| classification/ˌklæsɪfɪˈkeɪʃn/ | 분류 |
| regression/rɪˈɡreʃn/ | A statistical method for modelling how a response variable is related to one or more explanatory variables. |
| Unsupervised learning/ʌnˈsuːpəvaɪzd ˈlɜːnɪŋ/ | A way of finding patterns in data without labels. |
| clustering/ˈklʌstərɪŋ/ | The process of grouping similar items without labels. |
| clusters/ˈklʌstəz/ | 클러스터링 |
| Reinforcement learning/ˌriːɪnˈfɔːsmənt ˈlɜːnɪŋ/ | A way of learning actions through rewards to increase total reward over time. |
| agent/ˈeɪdʒənt/ | 에이전트 |
| environment/enˈvaɪrənmənt/ | The surrounding conditions that affect an organism, system or activity. |
| action/ˈækʃn/ | Something a system does when an event causes a change of state. |
| state/steɪt/ | The saved information needed to continue a program from its current point. |
| reward/rɪˈwɔːd/ | 보상 |
| policy/ˈpɒlɪsi/ | 정책 |
| trial and error | A way of learning by trying actions and using their results. |
| reward signal | A number that tells an agent how good an outcome was. |
| targets | The correct outputs that a network's outputs are trained to match. |
| gradient descent/ˈɡreɪdɪənt dɪˈsent/ | 경사 하강법 |
| Forward pass | Feed an input through the network and get its output. Compute the error using a loss function , which measures how far the output is from the target. |
| loss function/lɒs ˈfʌŋkʃn/ | 손실 함수 |
| Backward pass | Propagate the error backwards through the layers to find each weight's gradient , the rate of change of the loss with respect to that weight. |
| layers/ˈleɪəz/ | Distinct levels arranged above, below or within one another in a structure or system. |
| gradient/ˈɡreɪdɪənt/ | The spatial rate and direction of change of a quantity; for a scalar field its gradient points towards the steepest increase. |
| learning rate/ˈlɜːnɪŋ reɪt/ | A setting that controls the size of parameter updates made during model training. |
| epoch/ˈiːpɒk/ | 에포크 |
| training set/ˈtreɪnɪŋ set/ | The collection of data used to train a model. |
인간이 한 번도 시도하지 않은 개시법을 스스로 배운 프로그램
- AlphaGo Zero was given the rules of Go and nothing else. No human games, no opening book, no advice. It played against itself, starting from random moves.
- In three days it surpassed the version that had beaten the world champion. Along the way it rediscovered centuries of human opening theory, and then discarded parts of it as inferior.
- 각 경기 후 한 개의 숫자(승 또는 패)만으로 학습했습니다. 이는 백만 장의 레이블이 붙은 사진을 보여주는 것과는 완전히 다른 유형의 학습입니다.
- 이 강의에서는 머신러닝의 세 가지 패러다임, 각자가 필요로 하는 데이터의 종류, 그리고 네트워크의 가중치가 역전파를 통해 실제로 어떻게 변경되는지를 다룹니다.
지도 학습
- 지도 학습은 레이블이 포함된 데이터를 기반으로 학습합니다: '고양이' 또는 '강아지' 태그가 달린 사진, 스팸인지 아닌지 표시된 이메일, 판매 가격이 명시된 주택 등.
- 모델은 입력부터 레이블까지의 매핑을 학습한 후, 본적 없는 새로운 입력을 주어 레이블을 생성하도록 요청받습니다.
- 출력 결과가 범주인 분류와, 출력 결과가 숫자인 회귀로 나뉩니다.
- 그 비용은 레이블 생성에 있습니다: 백만 장의 이미지를 위해 이를 만들어내는 것은 막대한 인력 작업이 필요합니다.

레이블이 있는 예제 입력 → 모델 출력 → 이후 레이블 없는 입력

Supervised learning uses:
난이도 1/5 · 100코인 + 오늘 첫 완료 시 작은 보너스 추가
Supervised learning trains on labelled examples (e.g. images tagged cat/dog).
비지도 학습
- Unsupervised learning is given data with no labels and asked to find structure in it.
- 가장 흔한 용도는 클러스터링입니다: 미리 그룹을 정의하지 않고 유사한 항목들을 클러스터로 묶어내며, 예를 들어 유사한 물건을 구매하는 고객을 묶는 경우입니다.
- That is its strength and its weakness: it can discover a grouping nobody suspected, and it cannot tell you what the grouping means.

Unsupervised learning is used to:
난이도 1/5 · 100코인 + 오늘 첫 완료 시 작은 보너스 추가
With no labels, unsupervised learning discovers patterns/clusters in the data.
강화 학습
- 강화 학습에서는 에이전트가 환경 속에서 행동합니다. 각 행동은 상태를 변경하고 보상(reward) 을 반환하며, 이 보상이 오랫동안 0일 수도 있습니다.
- 에이전트는 정책(policy) 을 학습하는데, 이는 행동을 선택하는 전략으로 시간에 따른 총 보상을 극대화합니다. 레이블이 달린 예시 없이 실패를 통한 학습(trial and error) 방식으로 배워냅니다.
- 이는 올바른 선이 최종 결과로만 드러나는 결정의 연속에 적합한 문제(게임, 로봇 제어, 자율주행 자동차 등)에 적합합니다. 이것이 바로 AlphaGo Zero의 경우입니다.
In reinforcement learning, the agent learns by:
난이도 1/5 · 100코인 + 오늘 첫 완료 시 작은 보너스 추가
The agent tries actions, receives rewards, and learns a policy that maximises long-term reward.
In reinforcement learning the agent learns a ____ that maximises its total reward over time.
난이도 1/5 · 100코인 + 오늘 첫 완료 시 작은 보너스 추가
It learns by trial and error from rewards, with no labelled examples at all, which is why it suits sequences of decisions.
풀이 예제: 패러다임 선택하기
- Ten thousand medical scans, each labelled by a doctor as showing a tumour or not, are used to train a system to flag new scans. Supervised: the data has labels and the task is to learn input to label, specifically a classification.
- 매장은 고객들이 미리 정해진 범위가 아닌 자연스러운 그룹으로 나뉘는지 알고 싶습니다. Unsupervised(비 supervised learning): 레이블이 없으며, 구조를 찾아내는 clustering(클러스터링) 작업을 수행합니다.
- 로봇 팔이 부품을 배치해야 하는데, 시도의 성공 여부만으로 평가받습니다. Reinforcement(강화 학습): 에이전트, 행동의 연속, 그리고 레이블 대신 보상을 사용합니다.
- 패러다임을 명시하고, 데이터(레이블 있음, 레이블 없음, 또는 보상 신호)에 근거하여 정당성을 설명하십시오.
AI learning type lab
Classify AI examples by the type of learning or concern involved.
Match each ML paradigm to its data.
난이도 2/5 · 140코인 + 오늘 첫 완료 시 작은 보너스 추가
Supervised = labels; unsupervised = no labels; reinforcement = reward feedback.
Match each situation to the machine-learning paradigm it needs.
난이도 2/5 · 140코인 + 오늘 첫 완료 시 작은 보너스 추가
Labels, no labels, or a reward. The data decides the paradigm, not the difficulty of the task.
역전파(backpropagation)를 통한 학습
- 학습이란 네트워크의 출력이 목표값과 일치하도록 가중치(weights) 를 조정하는 것입니다. 이 방법은 경사 하강법(gradient descent) 과 함께 적용되는 역전파(backpropagation) 기법입니다.
- 전진 전파(forward pass) : 입력을 네트워크에 전달하여 출력을 얻습니다. 손실 함수(loss function) 를 사용하여 오차를 계산하는데, 이는 출력과 목표값 사이의 차이를 측정합니다.
- 후진 전파(backward pass) : 그 오차를 계층을 거슬러 올라가 전파하여 각 가중치의 기울기(gradient), 즉 해당 가중치가 오차에 얼마나 기여했는지를 찾습니다.
- 업데이트: 기울기의 반대 방향으로 각 가중치를 작은 단계만큼 변경합니다. 이 단계 크기를 학습률(learning rate) 이라고 합니다.

바닥으로 내려가는 것, 한 번에 작은 걸음씩

Backpropagation trains a network by:
난이도 1/5 · 100코인 + 오늘 첫 완료 시 작은 보너스 추가
The error flows from the output back through the network (chain rule) so every weight's gradient is found, then weights step downhill.
Put one round of backpropagation training in order.
난이도 3/5 · 200코인 + 오늘 첫 완료 시 작은 보너스 추가
Forward, error, backward, update, repeated over many epochs until the error stops falling.
에포크와 학습률의 중요성
- 전체 훈련 데이터셋을 한 번 순회하는 것을 **에포크(epoch)**라고 합니다. 오차가 더 이상 감소하지 않을 때까지 여러 에포크에 걸쳐 반복적으로 훈련합니다.
- 학습률이 너무 크면 최소점을 넘어서 오차가 크게 변동하고, 너무 작으면 필요한 시간보다 훨씬 오래 걸립니다.
- 훈련이 완료된 후 모델 사용은 **전방_pass(forward pass)**만 수행하면 되므로, 훈련에 수일이 걸렸더라도 trained 네트워크는 즉시 답변을 생성할 수 있습니다.

In gradient descent the learning rate sets how big a step each weight update takes — too large overshoots the minimum, too small makes training slow.
난이도 1/5 · 100코인 + 오늘 첫 완료 시 작은 보너스 추가
Backpropagation finds each weight's gradient; the learning rate scales how far down that gradient the weight moves.
Which statements about training are correct? Select 모든 that apply.
난이도 2/5 · 140코인 + 오늘 첫 완료 시 작은 보너스 추가
The learning rate is the size of each weight update. That is why training can take days while a prediction takes milliseconds.
놓칠 수 있는 점
- 데이터에서 패러다임을 정당화하십시오: 라벨이 있으면 지도 학습, 라벨이 없으면 비지도 학습, 보상 신호가 있으면 강화 학습입니다.
- 강화 학습에는 라벨이 없습니다. 보상을 라벨로 부르는 것은 고전적인 혼동입니다.
- 역전파(backpropagation)는 전방_pass, 오차 계산, 후방_pass, 가중치 업데이트가 반복되는 과정입니다. "가중치를 조정한다"고만 설명하는 것은 반의 정답에 불과합니다.
- **학습률(learning rate)**은 각 단계의 크기이지, 훈련 속도나 에포크 수를 의미하지 않습니다.
이해했습니다
- 监督 learning은 라벨이 있는 데이터에서 입력부터 라벨까지 학습하여 분류(classification) 또는 회귀(regression)를 수행합니다. · unsupervised learning은 라벨이 없는 데이터에서 **클러스터(clusters)**와 같은 구조를.finds · 강화 학습은 **보상(rewards)**을 통해 시오error를 반복하며 **에이전트(agent)**가 **정책(policy)**을 학습합니다.
- 과제의 난이도가 아닌, 데이터가 제공하는 것에서 패러다임을 선택하세요.
- 역전파: 전파, 손실 함수로부터의 오차, 각 가중치에 대한 기울기를 제공하는 역전파, 그리고 학습률에 의해 결정되는 크기만큼의 업데이트
- 훈련은 여러 에포크에 걸쳐 반복되며, trained 모델을 사용하는 것은 단일 전방_pass입니다.
어떤 문제가 있었나요? 사이트 팀만 이 내용을 볼 수 있습니다.
Try it in the lab 32
All labs →- Teach a Perceptron
- Train a Network on Your Drawings
- Teach a Robot by Reward
- Build a Decision Tree
- Nearest Neighbours
- Roll Down the Loss
- Find the Groups
- Find the Shortest Route
- See Like a Computer
- Guess the Next Word
- Is the Computer Fair?
- Build an Expert System
- Evolve a Catapult
- Catch the Spam
- Think Ahead
- Inside a Neural Network
- Learning or Remembering? Overfitting
- Search the Maze
- What Should I Watch? A Recommender
- Teach a Car to Drive
- Matchbox Learner
- Build a Chatbot
- Fewer Colours
- Mood Meter
- Spot the Fraud
- Hear the Word
- Follow the Ants
- Plan the Delivery Round
- Squash the Data
- Explore or Exploit? Learning by Trying
- Mark the Model
- Ask Many Models