1. LPU MCA Semester 1
  2. CAB107
  3. Unit 4

CAB107 · Unit 4: Machine learning fundamentals

Supervised, unsupervised and reinforcement learning

10 practice questions · in the ETE syllabus

Key points

  • Supervised learning needs labels
  • Unsupervised learning finds structure without labels
  • Reinforcement learning learns from rewards
  • Classification is discrete, regression is continuous

Machine learning has three main paradigms.

ParadigmDataGoalExample
SupervisedFeatures plus known labelsPredict the labelSpam detection, house prices
UnsupervisedFeatures onlyFind structureCustomer segmentation
ReinforcementAgent interacts, receives rewardsMaximise cumulative rewardA program learning chess by self-play

Supervised learning splits into classification, which predicts a discrete category, and regression, which predicts a continuous number. A weather model that outputs a probability of 0.7 for rain is still classification, because the target is the category rain or no rain and the probability is only a score.

Unsupervised learning includes clustering and dimensionality reduction; no target exists.

In reinforcement learning there is no labelled correct action at each step. The agent learns by acting and receiving rewards, for example +1 for a win and -1 for a loss, so a chess agent playing millions of self-games is reinforcement learning, not supervised learning.

Semi-supervised learning mixes a small labelled set with a large unlabelled one.

Exam trap: a numeric output does not make a task regression. Look at the target: continuous value means regression, category means classification.

Try two questions

Question 1 · Tier 2, Understand

How does reinforcement learning differ from supervised learning?

  1. An agent is told the correct action for every single state by a human teacher at each step of play
  2. The agent learns from a fixed table of labelled images that is prepared in advance by human annotators
  3. An agent learns by acting and receiving rewards, with no labelled correct action for each step
  4. The agent groups the data into clusters without any feedback, reward or goal being involved
Show the answer

C. Reinforcement learning optimises long-term reward through trial and error.

Why not A: Per-step correct answers describe supervised learning.

Why not B: A fixed labelled table describes supervised learning.

Why not D: Grouping without feedback describes unsupervised learning.

Question 2 · Tier 3, Apply

A retailer wants to split 10,000 customers into behaviour groups, but no group labels exist. Which approach fits?

  1. Supervised classification such as logistic regression
  2. Unsupervised clustering such as K-Means
  3. Linear regression on the group number
  4. Reinforcement learning with a reward for each purchase
Show the answer

B. Without labels, grouping by similarity is a clustering task.

Why not A: Classification needs labelled groups, which do not exist.

Why not C: There is no numeric target to regress on.

Why not D: Nothing here is an agent acting in an environment.