1. Home
  2. Explore
  3. Computer Science
  4. Introduction to Machine Learning

Study methods

Flashcards
Quiz
Fill in the blanks
Written test
Lesson
Notes
Podcast
Content

Introduction to Machine Learning

  • 52Unfamiliar
  • 0Learning
  • 0Familiar
  • 0Mastered
Topic: Applications and Motivation

In the exoplanet example, what decision does the machine-learning method help make?

52 questions

  1. 1

    In the exoplanet example, what decision does the machine-learning method help make?

    1. A

      Which telescope should collect images from a particular region of space

    2. B

      How far each confirmed planet is from the edge of the solar system

    3. C

      Whether the instruments should be redesigned before collecting more data

    4. D

      Whether a telescope image contains a real exoplanet or another signal

    Correct answer
    D

    Whether a telescope image contains a real exoplanet or another signal

    Explanation

    The method evaluates candidate exoplanets identified from telescope data and helps distinguish real planets from other signals.

  2. 2

    What makes machine learning useful for recognizing neonatal seizures in the example?

    1. A

      It replaces EEG measurements with observations of the newborn’s appearance

    2. B

      It can help automate interpretation of EEG data to identify possible seizures

    3. C

      It determines which medical treatment should be used without clinical judgment

    4. D

      It guarantees that every newborn movement will be classified correctly

    Correct answer
    B

    It can help automate interpretation of EEG data to identify possible seizures

    Explanation

    EEG interpretation can be labor-intensive, so a method that identifies candidate seizures could help automate recognition and support medical care.

  3. 3

    Why was machine learning used to analyze Supreme Court petitions in the example?

    1. A

      To decide automatically which cases the Supreme Court must hear

    2. B

      To predict how each justice will vote on every petition

    3. C

      To identify topics in many petitions without requiring each one to be read manually

    4. D

      To replace the text of petitions with numerical descriptions for the public

    Correct answer
    C

    To identify topics in many petitions without requiring each one to be read manually

    Explanation

    The analysis used petition text to identify topics or themes in a large collection, a task that would be burdensome to do manually.

  4. 4

    What task was machine learning intended to support in the Bureau of Labor Statistics example?

    1. A

      Assigning codes to interview and survey text about occupations or workplace events

    2. B

      Selecting which occupations should be included in future surveys

    3. C

      Estimating the salaries of workers from their interview responses

    4. D

      Writing interview questions that produce more consistent responses

    Correct answer
    A

    Assigning codes to interview and survey text about occupations or workplace events

    Explanation

    The goal was to turn text about occupations and events, such as workplace injuries, into relevant codes.

  5. 5

    In the phishing-detection example, what information is used to classify an email?

    1. A

      The recipient’s password, which is checked against the sender’s identity

    2. B

      The sender’s device, which is used to decide whether the email is legitimate

    3. C

      The recipient’s location, which is compared with the email’s subject

    4. D

      The email’s text, which is used to decide whether it is phishing

    Correct answer
    D

    The email’s text, which is used to decide whether it is phishing

    Explanation

    The example describes using the text of an email to classify it as phishing or not phishing, ideally before it reaches an inbox.

  6. 6

    What is a central risk raised by the facial-recognition example?

    1. A

      Surveillance images could contain too many people for a camera to record

    2. B

      A person could be misidentified, potentially leading to serious consequences

    3. C

      A recognition system could be unable to store images at high resolution

    4. D

      A camera could identify a person without collecting any visual data

    Correct answer
    B

    A person could be misidentified, potentially leading to serious consequences

    Explanation

    The example emphasizes that a mistaken identity could have consequential effects, such as an innocent person being arrested.

  7. 7

    In the farm-loan example, what is the machine-learning method helping assess?

    1. A

      Whether information about a farm suggests it may earn enough to repay a loan

    2. B

      Whether satellite images can replace all financial records for a farmer

    3. C

      Whether weather information is more accurate than information about the farm

    4. D

      Whether a farmer should receive the same loan amount as every other farmer

    Correct answer
    A

    Whether information about a farm suggests it may earn enough to repay a loan

    Explanation

    Satellite imagery, weather information, and other data are used to assess whether a farm may generate enough income to repay a loan.

  8. 8

    Which statement best captures why machine learning should be studied in addition to being applied?

    1. A

      It guarantees that automated decisions will benefit everyone equally

    2. B

      It helps people understand, evaluate, and improve systems that can affect important decisions

    3. C

      It makes human judgment unnecessary whenever a decision involves data

    4. D

      It ensures that every system described as machine learning is scientifically valid

    Correct answer
    B

    It helps people understand, evaluate, and improve systems that can affect important decisions

    Explanation

    Understanding machine learning helps people assess what systems do, whether they work as intended, and how they affect areas such as medicine, finance, security, and government.

  9. 9

    What does the example of an unsuccessful prediction challenge illustrate about machine learning?

    1. A

      Prediction failures occur only when the data have not been labeled by experts

    2. B

      A large dataset guarantees accurate predictions about individuals’ futures

    3. C

      Machine learning succeeds whenever researchers use sufficiently powerful computers

    4. D

      Machine learning is a tool that may fail to predict well, even with extensive data and modern methods

    Correct answer
    D

    Machine learning is a tool that may fail to predict well, even with extensive data and modern methods

    Explanation

    The example shows that machine learning is not magic: even rich data and strong methods may fail to produce accurate predictions.

  10. 10

    In the newborn-seizure setup, what is the purpose of the training data?

    1. A

      To replace the need to define what a seizure label means

    2. B

      To provide the outcomes of all newborns who will enter the hospital in the future

    3. C

      To provide observed examples from which a method can be developed to predict outcomes for future newborns

    4. D

      To guarantee that every future newborn has the same features as an observed newborn

    Correct answer
    C

    To provide observed examples from which a method can be developed to predict outcomes for future newborns

    Explanation

    Training data are observed examples used to develop a method that will later make predictions for new data points.

  11. 11

    How is one labeled data point represented in the described setup?

    1. A

      As a training error paired with a test error

    2. B

      As a feature vector paired with an observed label

    3. C

      As a line paired with its distance from the origin

    4. D

      As a hypothesis paired with a learning algorithm

    Correct answer
    B

    As a feature vector paired with an observed label

    Explanation

    Each training example consists of its features, represented by a vector, and its label, represented by a value such as −1-1−1 or 111.

  12. 12

    What does the superscript in x(i)x^{(i)}x(i) indicate?

    1. A

      Which data point the feature vector belongs to

    2. B

      The number of dimensions in the feature space

    3. C

      The label assigned to the feature vector

    4. D

      Which feature within a vector is being measured

    Correct answer
    A

    Which data point the feature vector belongs to

    Explanation

    The superscript indexes the data point, distinguishing, for example, the feature vector for point 1 from the feature vector for point 2.

  13. 13

    If each feature vector has ddd components, what does ddd describe?

    1. A

      The number of hypotheses in a hypothesis class

    2. B

      The number of training examples in the dataset

    3. C

      The number of labels available to the classifier

    4. D

      The dimension of the feature space

    Correct answer
    D

    The dimension of the feature space

    Explanation

    The vector’s ddd components describe its dimensionality; a feature vector lies in a ddd-dimensional space.

  14. 14

    Why can a two-dimensional plot be only a cartoon of a real machine-learning dataset?

    1. A

      A two-dimensional plot can display labels but cannot display feature values

    2. B

      Real feature vectors may have more than two dimensions, such as 55 in the seizure study

    3. C

      Real feature vectors contain only labels and therefore have no dimensions

    4. D

      Real datasets always have exactly two features but cannot be plotted accurately

    Correct answer
    B

    Real feature vectors may have more than two dimensions, such as 55 in the seizure study

    Explanation

    A plot may show two coordinates for visualization, while an actual problem can have many more features; the seizure study’s representation had 55 dimensions.

  15. 15

    In the newborn cartoon, what do the labels −1-1−1 and 111 represent?

    1. A

      Whether the newborn had low or high oxygen levels, respectively

    2. B

      Whether the example belongs to training data or future data, respectively

    3. C

      Whether the newborn did not have a seizure or did have a seizure, respectively

    4. D

      Whether the feature vector has one or two dimensions, respectively

    Correct answer
    C

    Whether the newborn did not have a seizure or did have a seizure, respectively

    Explanation

    In the cartoon, −1-1−1 indicates no seizure and 111 indicates a seizure.

  16. 16

    Why should feature construction not be treated as a trivial step?

    1. A

      Features are always directly visible as simple measurements in the raw data

    2. B

      Turning complex observations such as EEG data into useful features can require substantial work

    3. C

      A feature vector can be constructed only after a classifier has predicted its label

    4. D

      Feature construction determines the labels without requiring any observed outcomes

    Correct answer
    B

    Turning complex observations such as EEG data into useful features can require substantial work

    Explanation

    The seizure example used complex EEG data to construct a 55-dimensional representation, illustrating that converting raw observations into features can be involved.

  17. 17

    What does the training dataset DnD_nDn​ collect?

    1. A

      The nnn hypotheses that have the lowest training error

    2. B

      The nnn feature-vector-and-label pairs used as training examples

    3. C

      The parameters that define a single classifier

    4. D

      The future observations whose labels are not yet known

    Correct answer
    B

    The nnn feature-vector-and-label pairs used as training examples

    Explanation

    DnD_nDn​ denotes the training data formed by collecting the observed feature-and-label pairs for the nnn examples.

  18. 18

    What is a hypothesis in the classification setup?

    1. A

      A line that is defined without assigning labels to points

    2. B

      A function that maps any possible feature vector to a label

    3. C

      A collection of labeled training examples with no prediction rule

    4. D

      A method that maps a dataset to a feature vector

    Correct answer
    B

    A function that maps any possible feature vector to a label

    Explanation

    A hypothesis is a function from feature vectors to labels, allowing it to label any possible input in the feature space.

  19. 19

    Why does the rule h(x)=1h(x)=1h(x)=1 qualify as a hypothesis even though it is a poor one for the example?

    1. A

      It defines a line that divides the feature space into two regions

    2. B

      It uses training data to choose a different label for each newborn

    3. C

      It is a function that assigns a label to every possible input

    4. D

      It correctly separates the observed seizure and non-seizure examples

    Correct answer
    C

    It is a function that assigns a label to every possible input

    Explanation

    Any function that maps every possible feature vector to an allowed label is a hypothesis. The constant rule is still a hypothesis, though predicting 111 for every case may be unhelpful.

  20. 20

    What is a hypothesis class?

    1. A

      A dataset containing only examples that a classifier gets wrong

    2. B

      A rule for deciding how labels are recorded in training data

    3. C

      A collection of possible hypotheses

    4. D

      A collection of possible feature measurements for one example

    Correct answer
    C

    A collection of possible hypotheses

    Explanation

    A hypothesis class is a set or collection of hypotheses from which a prediction rule may be chosen.

  21. 21

    What defines the linear-classifier hypothesis class described in the lecture?

    1. A

      Hypotheses that assign 111 on one side of a line and −1-1−1 on the other

    2. B

      Hypotheses that use only two features and ignore all other coordinates

    3. C

      Hypotheses that place every training example directly on a line

    4. D

      Hypotheses that assign the same label to every point in the feature space

    Correct answer
    A

    Hypotheses that assign 111 on one side of a line and −1-1−1 on the other

    Explanation

    The class consists of classifiers that divide the space with a line or hyperplane and assign opposite labels to its two sides.

  22. 22

    Why is a line by itself not yet a hypothesis?

    1. A

      It necessarily assigns the same label to both sides

    2. B

      It does not specify a label for every possible feature vector

    3. C

      It depends on the observed labels in the training dataset

    4. D

      It cannot be represented using feature coordinates

    Correct answer
    B

    It does not specify a label for every possible feature vector

    Explanation

    A hypothesis must be a function over the entire feature space. A line defines a boundary, but a labeling rule must also specify the labels on its sides.

  23. 23

    Does defining a linear classifier require access to training data?

    1. A

      Yes; every point on its boundary must be a labeled training example

    2. B

      No; but only if the classifier assigns the same label to every point

    3. C

      Yes; the feature vectors are required to define the classifier’s function

    4. D

      No; its parameters can define a classifier independently of any dataset

    Correct answer
    D

    No; its parameters can define a classifier independently of any dataset

    Explanation

    A linear classifier can be defined by choosing its parameters without using data; learning from data is a separate step.

  24. 24

    What is the difference between an individual linear classifier and the class of linear classifiers?

    1. A

      An individual classifier predicts only training labels, while the class predicts future labels

    2. B

      An individual classifier is a dataset, while the class is one labeled feature vector

    3. C

      An individual classifier uses particular parameters, while the class contains all classifiers of that form

    4. D

      An individual classifier is a learning algorithm, while the class is its output dataset

    Correct answer
    C

    An individual classifier uses particular parameters, while the class contains all classifiers of that form

    Explanation

    A particular choice of parameters specifies one linear classifier; collecting all allowed parameter choices gives the hypothesis class.

  25. 25

    If xxx and θ\thetaθ are each ddd-by-1 column vectors, what is the shape of θTx\theta^T xθTx?

    1. A

      A 111-by-111 scalar

    2. B

      A 111-by-ddd row vector

    3. C

      A ddd-by-1 column vector

    4. D

      A ddd-by-ddd matrix

    Correct answer
    A

    A 111-by-111 scalar

    Explanation

    The transpose θT\theta^TθT is 111-by-ddd, so multiplying it by the ddd-by-1 vector xxx produces a 111-by-1 scalar.

  26. 26

    What does θTx∥θ∥\frac{\theta^T x}{\|\theta\|}∥θ∥θTx​ represent geometrically?

    1. A

      The angle between xxx and θ\thetaθ measured in units of length

    2. B

      The distance from xxx to the origin in every direction

    3. C

      The number of coordinates shared by xxx and θ\thetaθ

    4. D

      The signed projection of xxx in the direction of θ\thetaθ

    Correct answer
    D

    The signed projection of xxx in the direction of θ\thetaθ

    Explanation

    Dividing the dot product by the length of θ\thetaθ gives the signed amount of xxx in the direction of θ\thetaθ.

  27. 27

    If xxx is perpendicular to θ\thetaθ, what is the value of θTx\theta^T xθTx?

    1. A

      A positive value that depends on the angle’s direction

    2. B

      The length of xxx

    3. C

      The length of θ\thetaθ

    4. D

      Zero

    Correct answer
    D

    Zero

    Explanation

    Perpendicular vectors have dot product zero, so the projection of xxx onto θ\thetaθ is also zero.

  28. 28

    What set of points is described by θTx=0\theta^T x=0θTx=0 for a fixed nonzero θ\thetaθ?

    1. A

      Points that are all a fixed positive distance from the direction of θ\thetaθ

    2. B

      Points whose vectors are perpendicular to θ\thetaθ, forming a boundary through the origin

    3. C

      Points whose vectors point in the same direction as θ\thetaθ, forming a ray

    4. D

      Points whose distance from the origin equals the length of θ\thetaθ

    Correct answer
    B

    Points whose vectors are perpendicular to θ\thetaθ, forming a boundary through the origin

    Explanation

    The points with zero projection onto θ\thetaθ are perpendicular to it; together they form a line in two dimensions or a hyperplane in higher dimensions, passing through the origin.

  29. 29

    What geometric effect does multiplying θ\thetaθ by a positive constant have on its direction?

    1. A

      It changes the feature space’s dimension

    2. B

      It changes the vector’s length but not its direction

    3. C

      It moves the decision boundary without changing the vector’s length

    4. D

      It reverses the vector’s direction while preserving its length

    Correct answer
    B

    It changes the vector’s length but not its direction

    Explanation

    Scaling θ\thetaθ by a positive constant changes its magnitude but leaves its direction unchanged, so the direction onto which xxx is projected remains the same.

  30. 30

    What does the equation θTx+θ0=0\theta^T x+\theta_0=0θTx+θ0​=0 specify?

    1. A

      The output label of the classifier for every point in the space

    2. B

      The decision boundary separating the two regions of a linear classifier

    3. C

      The average loss incurred across the training dataset

    4. D

      The set of all training points with the same feature vector

    Correct answer
    B

    The decision boundary separating the two regions of a linear classifier

    Explanation

    The equation defines the line or hyperplane that separates the regions labeled by a linear classifier.

  31. 31

    What role does θ0\theta_0θ0​ play in the boundary equation θTx+θ0=0\theta^T x+\theta_0=0θTx+θ0​=0?

    1. A

      It specifies which training example is used to evaluate the classifier

    2. B

      It replaces the vector θ\thetaθ as the direction of the boundary

    3. C

      It helps determine the boundary’s position along the direction set by θ\thetaθ

    4. D

      It determines the number of dimensions in the feature vector

    Correct answer
    C

    It helps determine the boundary’s position along the direction set by θ\thetaθ

    Explanation

    Together, θ\thetaθ and θ0\theta_0θ0​ define the boundary; changing θ0\theta_0θ0​ shifts its position relative to the origin.

  32. 32

    For the stated linear classifier, what label is assigned when θTx+θ0>0\theta^T x+\theta_0>0θTx+θ0​>0?

    1. A

      No label is assigned unless xxx is a training example

    2. B

      111

    3. C

      000

    4. D

      −1-1−1

    Correct answer
    B

    111

    Explanation

    The classifier assigns 111 on the side where θTx+θ0\theta^T x+\theta_0θTx+θ0​ is positive.

  33. 33

    How does the stated linear classifier handle a point exactly on the boundary?

    1. A

      It assigns the label 111

    2. B

      It assigns both labels with equal probability

    3. C

      It leaves the point unlabeled

    4. D

      It assigns the label −1-1−1

    Correct answer
    D

    It assigns the label −1-1−1

    Explanation

    The lecture makes the convention of assigning −1-1−1 on the boundary itself.

  34. 34

    Why are θ\thetaθ and θ0\theta_0θ0​ called parameters of a particular hypothesis?

    1. A

      They specify which classifier is being used but are not the input feature vector

    2. B

      They are the training examples used as input to a learning algorithm

    3. C

      They specify how many new data points will be collected

    4. D

      They are the labels that a classifier returns for its input

    Correct answer
    A

    They specify which classifier is being used but are not the input feature vector

    Explanation

    The parameters identify how a particular hypothesis is defined; the hypothesis still takes xxx as its input.

  35. 35

    What does a loss function compare in the classification setup?

    1. A

      A predicted guess and the actual observed value

    2. B

      A learning algorithm and its hyperparameter

    3. C

      A feature vector and the dimension of its space

    4. D

      A training dataset and a hypothesis class

    Correct answer
    A

    A predicted guess and the actual observed value

    Explanation

    The loss function takes a guess and an actual value and measures how bad their disagreement is.

  36. 36

    Under zero-one loss, what is the loss when the predicted label exactly matches the actual label?

    1. A

      The distance from the point to the decision boundary

    2. B

      Zero

    3. C

      One

    4. D

      The number of features in the example

    Correct answer
    B

    Zero

    Explanation

    Zero-one loss is zero for a correct prediction and one for an incorrect prediction.

  37. 37

    Why might zero-one loss be inadequate for neonatal seizure prediction?

    1. A

      It measures the distance between feature vectors rather than prediction quality

    2. B

      It treats false positives and false negatives as equally costly

    3. C

      It assigns a larger loss to every correct prediction than to an incorrect one

    4. D

      It cannot be used when labels have two possible values

    Correct answer
    B

    It treats false positives and false negatives as equally costly

    Explanation

    A missed seizure may have much more serious consequences than an unnecessary medical check, while zero-one loss gives both kinds of mistake the same penalty.

  38. 38

    In the seizure example, why might predicting a seizure when none occurs still incur some loss?

    1. A

      It may use medical time and resources that could have been spent elsewhere

    2. B

      It necessarily causes the newborn to experience a seizure

    3. C

      It prevents the system from assigning a label to future newborns

    4. D

      It makes the training dataset lose its feature vectors

    Correct answer
    A

    It may use medical time and resources that could have been spent elsewhere

    Explanation

    A false positive may prompt unnecessary attention or use resources, even though it may be less harmful than missing a seizure.

  39. 39

    How can a loss function be related to utility?

    1. A

      A loss can be viewed as negative utility, so larger loss is worse

    2. B

      A loss and utility must always assign equal values to every outcome

    3. C

      A loss is identical to utility, so larger loss is always better

    4. D

      A loss measures only computational time, while utility measures prediction accuracy

    Correct answer
    A

    A loss can be viewed as negative utility, so larger loss is worse

    Explanation

    Loss is analogous to negative utility: larger losses are undesirable, whereas larger utilities are desirable.

  40. 40

    Why is error on future data the desired measure of classifier quality?

    1. A

      It can be computed before future cases arrive because it depends only on the classifier’s parameters

    2. B

      It directly measures how well the classifier predicts the new cases it is meant to handle

    3. C

      It avoids needing the actual labels of future cases

    4. D

      It is always equal to the error measured on the training data

    Correct answer
    B

    It directly measures how well the classifier predicts the new cases it is meant to handle

    Explanation

    The practical goal is to predict well on future cases, whose outcomes determine whether the predictions were correct.

  41. 41

    Why can the error on future data not usually be calculated in advance?

    1. A

      The classifier cannot produce predictions for examples outside the training set

    2. B

      A loss function can only compare two hypotheses, not a guess and an outcome

    3. C

      Future data contain no feature vectors

    4. D

      The future examples and their actual labels are not yet available

    Correct answer
    D

    The future examples and their actual labels are not yet available

    Explanation

    Calculating future error requires knowing the future examples and their actual outcomes, which are not available beforehand.

  42. 42

    What does training error measure?

    1. A

      The number of distinct hypotheses in the classifier’s class

    2. B

      The average loss on future examples whose labels are not yet known

    3. C

      The distance between the classifier’s boundary and the origin

    4. D

      The average loss of a classifier on the labeled examples in its training dataset

    Correct answer
    D

    The average loss of a classifier on the labeled examples in its training dataset

    Explanation

    Training error aggregates the losses between predictions and actual labels on the training examples.

  43. 43

    Why should training error not automatically be treated as the final measure of success?

    1. A

      The real goal is performance on future data, and training error may not capture that

    2. B

      Training error cannot be calculated when examples have labels

    3. C

      Training error is always greater than every possible future error

    4. D

      The training dataset is not an input to a learning algorithm

    Correct answer
    A

    The real goal is performance on future data, and training error may not capture that

    Explanation

    Training error is computable and useful, but the desired outcome is good prediction on unseen future data; how to assess that is a separate problem.

  44. 44

    What is the key difference between a classifier and a learning algorithm?

    1. A

      A classifier maps a dataset to a label, while a learning algorithm maps a label to a feature vector

    2. B

      A classifier requires training data as its direct input, while a learning algorithm does not

    3. C

      A classifier maps a feature vector to a label, while a learning algorithm maps a dataset to a classifier

    4. D

      A classifier measures loss, while a learning algorithm defines the feature space

    Correct answer
    C

    A classifier maps a feature vector to a label, while a learning algorithm maps a dataset to a classifier

    Explanation

    A classifier is a function applied to individual feature vectors; a learning algorithm takes a dataset and produces a classifier.

  45. 45

    In the example candidate-search algorithm, what does the algorithm do with its candidate classifiers?

    1. A

      It calculates each candidate’s training error and returns one with the smallest error among those considered

    2. B

      It averages the parameters of every candidate and returns the resulting classifier

    3. C

      It changes the labels in the training data until all candidates agree

    4. D

      It chooses the candidate with the largest number of correctly labeled future examples

    Correct answer
    A

    It calculates each candidate’s training error and returns one with the smallest error among those considered

    Explanation

    The algorithm evaluates the training error of the first kkk candidates, finds an index achieving the minimum, and returns that candidate.

  46. 46

    What does the notation arg⁡min⁡\arg\minargmin identify in the candidate-search algorithm?

    1. A

      The average error across all possible classifiers

    2. B

      The numerical value of the largest candidate error

    3. C

      The feature vector that lies closest to the decision boundary

    4. D

      The index of a candidate whose error is smallest

    Correct answer
    D

    The index of a candidate whose error is smallest

    Explanation

    The minimum gives the smallest error value; the arg min identifies which candidate index attains that minimum.

  47. 47

    If the candidate-search algorithm uses k=1k=1k=1, which classifier does it return?

    1. A

      The first candidate classifier

    2. B

      A classifier that averages the first two candidates

    3. C

      No classifier, because one candidate is insufficient

    4. D

      The candidate with the lowest error among all candidates ever generated

    Correct answer
    A

    The first candidate classifier

    Explanation

    With k=1k=1k=1, there is only one candidate under consideration, so it is the minimum-error choice by default.

  48. 48

    For a fixed dataset and ordered list of candidates, how does the selected training error change when kkk increases from 1 to 2?

    1. A

      It must decrease strictly, because every new candidate has a different boundary

    2. B

      It stays exactly the same, because the first candidate is always returned

    3. C

      It cannot increase, because the algorithm can choose the better of the first two candidates

    4. D

      It must increase, because the algorithm considers an additional candidate

    Correct answer
    C

    It cannot increase, because the algorithm can choose the better of the first two candidates

    Explanation

    Adding a candidate expands the available choices, so the minimum training error among the considered candidates can stay the same or decrease, but cannot increase.

  49. 49

    What is a hyperparameter in the candidate-search example?

    1. A

      A parameter such as θ\thetaθ that defines the boundary of one hypothesis

    2. B

      A setting such as kkk that adjusts the learning algorithm rather than serving as the dataset input

    3. C

      A label that indicates whether an example was classified correctly

    4. D

      A feature coordinate that is an input to the classifier

    Correct answer
    B

    A setting such as kkk that adjusts the learning algorithm rather than serving as the dataset input

    Explanation

    A hyperparameter adjusts the learning algorithm itself; here, kkk determines how many candidate classifiers are considered.

  50. 50

    Which distinction between a parameter and a hyperparameter is correct?

    1. A

      A parameter helps define a hypothesis, while a hyperparameter adjusts the learning algorithm

    2. B

      A parameter is chosen only after prediction, while a hyperparameter defines the feature vector

    3. C

      A parameter is the dataset input, while a hyperparameter is always a predicted label

    4. D

      A parameter measures training error, while a hyperparameter measures future error

    Correct answer
    A

    A parameter helps define a hypothesis, while a hyperparameter adjusts the learning algorithm

    Explanation

    Parameters such as θ\thetaθ and θ0\theta_0θ0​ define a particular hypothesis, whereas a hyperparameter such as kkk changes how the learning algorithm operates.

  51. 51

    What does the candidate-search example demonstrate about training error as the number of candidates considered grows?

    1. A

      The minimum training error must increase to prevent overfitting

    2. B

      The selected classifier must become more accurate on future data

    3. C

      The training error becomes equal to zero once enough candidates are included

    4. D

      The minimum training error among the considered candidates is non-increasing

    Correct answer
    D

    The minimum training error among the considered candidates is non-increasing

    Explanation

    Considering more candidates cannot increase the minimum training error among the choices, although this alone does not establish better future performance.

  52. 52

    Why does selecting the candidate with the smallest training error not, by itself, prove that it is the best classifier for future cases?

    1. A

      Training error is measured on observed examples, while future performance concerns unseen cases

    2. B

      Training error ignores the labels in the training dataset

    3. C

      A learning algorithm does not return a classifier when candidates are compared

    4. D

      The candidate with the smallest training error cannot be applied to feature vectors

    Correct answer
    A

    Training error is measured on observed examples, while future performance concerns unseen cases

    Explanation

    The algorithm optimizes error on the available training examples, but the actual goal is accurate prediction on future data, which is not yet observed.

Question 1 of 52
Question 1 of 52

Ask anything

We've read this whole study set, so questions about it get the best answers.

FlashcardsQuizFill in the blanksWritten testLessonNotesPodcastContent