Quiz Space

September 2023 term · Machine Learning Techniques · BSCS2007

MLT End Term: 24 December 2023, Set FDB1 (September 2023 term)

The IIT Madras BS Machine Learning Techniques (MLT) End Term paper sat on 24 Dec 2023, in the September 2023 term, set FDB1: 18 questions for 100 marks in 180 minutes. Every question is below with its answer. Take it as a timed mock test to be marked, or read it through first.

Questions
18
Marks
100
Duration
180 min
MSQ
8
MCQ
4
Numerical
6

Updated

Official paper: IIT M DEGREE FN EXAM FDB1 24 Dec 2023 · No negative marking.

Question 1

+5 marksOne or more correct options

Select all that apply.

  1. A
  2. B
  3. C
  4. D
Show answer

Correct answers

  • A
  • D

Question 2

+5 marksOne correct option

Common Data:

A team was given a dataset X∈Rd×nX \in \mathbb{R}^{d \times n} where dd denotes the number of features and nn denotes the number of samples. They found that there are 10 samples in the dataset and each sample contains 100 features. Assume that the datapoints x4x_4 to x10x_{10} are all linear combination of linearly independent data points (x1,x2,x3)(x_1, x_2, x_3).

Based on the above data, answer the given subquestions.

Suppose the team applies linear PCA on the dataset and reconstructs the data points with zero error using k principal components (directions). For which value of k the reconstruction error would become zero?

  1. A

    1

  2. B

    2

  3. C

    3

  4. D

    5

  5. E

    10

  6. F

    100

Show answer

Correct answer

  • C

    3

Question 3

+6 marksOne or more correct options

Common Data:

A team was given a dataset X∈Rd×nX \in \mathbb{R}^{d \times n} where dd denotes the number of features and nn denotes the number of samples. They found that there are 10 samples in the dataset and each sample contains 100 features. Assume that the datapoints x4x_4 to x10x_{10} are all linear combination of linearly independent data points (x1,x2,x3)(x_1, x_2, x_3).

Based on the above data, answer the given subquestions.

Select all that apply.

  1. A
  2. B
  3. C
  4. D
Show answer

Correct answers

  • A
  • B

Question 4

+5 marksNumerical answer

(Enter your answer correctly to two decimal places)

Show answer

Correct answer: 43.15 (accepted within ±0.05)

Question 5

+6 marksNumerical answer

We wish to fit a GMM with K=2K = 2 for a dataset having 4 points. At the beginning of the ttht^{th} time step of the EM algorithm, we have θ(t)\theta^{(t)} as follows:

π1=0.3,π2=0.7μ1=2,σ12=1μ2=3,σ22=1\begin{gathered} \pi_1 = 0.3, \pi_2 = 0.7 \\ \mu_1 = 2, \sigma_1^2 = 1 \\ \mu_2 = 3, \sigma_2^2 = 1 \end{gathered}

The density of the points given a particular mixture is given to you for all four points. ff is the density of a Gaussian.

xix_if(xi∣zi=1)f(x_i \vert z_i = 1)f(xi∣zi=2)f(x_i \vert z_i = 2)
110.2420.2420.0540.054
220.3990.3990.2420.242
330.2420.2420.3990.399
440.0540.0540.2420.242

What is the value of λki\lambda_k^i for i=1i = 1 and k=2k = 2 after the E-step? Enter your answer correct to two decimal places

Show answer

Correct answer: 0.35 (accepted within ±0.03)

Question 6

+6 marksOne or more correct options

Consider a training set {X,y}\{X, y\}, where X∈Rd×nX \in \mathbb{R}^{d \times n} and the target y∈Rny \in \mathbb{R}^n. Suppose a team decided to use linear regression model, h=wTXh = w^T X where w∈Rd×1w \in \mathbb{R}^{d \times 1} that minimizes the objective function L(w)L(w) given below

L(w)=∑i=1n(wTxi−yi)2L(w) = \sum_{i=1}^{n} (w^T x_i - y_i)^2

Suppose we obtain w=w∗w = w^* such that L(w∗)=∑i=1n(w∗Txi−yi)2=0L(w^*) = \sum_{i=1}^{n} ({w^*}^T x_i - y_i)^2 = 0. Choose the following correct statements

Select all that apply.

  1. A
  2. B
  3. C
  4. D
  5. E
Show answer

Correct answers

  • A
  • D
  • E

Question 7

+6 marksOne correct option

Consider a Ridge Regression scenario where the feature vector x\mathbf{x} is given by x=[x1,x2,x3,x4]\mathbf{x} = [x_1, x_2, x_3, x_4], and the weight vector is determined using the formula:

wλ=(XTX+λI)−1XTy\mathbf{w}_\lambda = \left(\mathbf{X}^T\mathbf{X} + \lambda\mathbf{I}\right)^{-1}\mathbf{X}^T\mathbf{y}

Here, X\mathbf{X} is the design matrix, y\mathbf{y} is the target vector, and λ\lambda is the regularization parameter.

Suppose we obtain the weight vector wλ=4=[2,5,7,9]\mathbf{w}_{\lambda=4} = [2, 5, 7, 9] when λ\lambda is set to 44. If we increase λ\lambda to 88, which of the following is most likely to be the updated weight vector?

  1. A

    [2, 6, 9, 12]

  2. B

    [2, 4, 7, 10]

  3. C

    [3, 5, 8, 11]

  4. D

    [1, 3, 6, 8]

Show answer

Correct answer

  • D

    [1, 3, 6, 8]

Question 8

+6 marksNumerical answer
Show answer

Correct answer: 12

Question 9

+5 marksOne correct option
  1. A

    0

  2. B

    1

  3. C

    Insufficient information to make a prediction.

Show answer

Correct answer

  • C

    Insufficient information to make a prediction.

Question 10

+5 marksOne correct option

Consider the following 2D dataset with points in R2\mathbb{R}^2:

x1x_1x2x_2yy
1122−1-1
2233−1-1
−1-100−1-1
441111
33−1-111
0011−1-1
−2-2−2-211
−3-31111

Suppose we run the perceptron learning algorithm by initializing the weight vector to zero. Does the algorithm converge (with zero error) in a finite number of iterations?

  1. A

    Yes, it will converge.

  2. B

    No, it will never converge.

  3. C

    Insufficient data

Show answer

Correct answer

  • B

    No, it will never converge.

Question 11

+6 marksNumerical answer

Consider a logistic regression model that has been trained for a binary classification problem on a dataset in R2\mathbb{R}^2. The weight vector is [1/22/3]\begin{bmatrix} 1/2 \\ 2/3 \end{bmatrix}. Given a test data-point as input to the model, it returns 11 as the predicted label if the probability output by the model is greater than 0.600.60 and 00 otherwise. What is the predicted label for the test data-point [10]\begin{bmatrix} 1 \\ 0 \end{bmatrix}?

Note that the probability output by a logistic regression model is P(y=1∣x)P(y = 1 \mid \mathbf{x})

Show answer

Correct answer: 1

Question 12

+6 marksOne or more correct options

Based on the above data, answer the given subquestions.

What is the equation of the decision boundary? Select all options that are correct.

Select all that apply.

  1. A
  2. B
  3. C
  4. D
Show answer

Correct answers

  • A
  • C

Question 13

+5 marksNumerical answer

Based on the above data, answer the given subquestions.

Show answer

Correct answer: 5.38 (accepted within ±0.06)

Question 14

+6 marksOne or more correct options

Consider a soft-margin Support Vector Machine (SVM) for a binary classification problem with a dataset in a two-dimensional space. The optimization problem for the soft-margin SVM is formulated as:

Minimize 12∥w∥2+C∑i=1Nξi\text{Minimize } \frac{1}{2}\|\mathbf{w}\|^2 + C\sum_{i=1}^{N} \xi_i

subject to the constraints:

yi(w⋅xi+b)≥1−ξi and ξi≥0 for all iy_i(\mathbf{w} \cdot \mathbf{x}_i + b) \ge 1 - \xi_i \text{ and } \xi_i \ge 0 \text{ for all } i

Where CC is a positive constant.
Which of the following statements about the soft-margin SVM is correct?

Select all that apply.

  1. A
  2. B
  3. C
  4. D
Show answer

Correct answers

  • A
  • D

Question 15

+6 marksOne or more correct options

Which of the following statements are correct?

Select all that apply.

  1. A

    Overfitting models have high bias and low variance.

  2. B

    Underfitting models have low bias and high variance.

  3. C

    Generally, weak learners in the random forest tend to overfit.

  4. D

    If the performance of each estimator in the bagging algorithm is almost identical, the benefit of using bagging to combine them may be minimal or insignificant.

  5. E

    In random forests, multiple decision trees (estimators) are trained simultaneously, allowing for parallel processing and faster model training.

Show answer

Correct answers

  • C

    Generally, weak learners in the random forest tend to overfit.

  • D

    If the performance of each estimator in the bagging algorithm is almost identical, the benefit of using bagging to combine them may be minimal or insignificant.

  • E

    In random forests, multiple decision trees (estimators) are trained simultaneously, allowing for parallel processing and faster model training.

Question 16

+5 marksOne or more correct options

We have trained four models in the same dataset with different hyperparameters. In the following table, we have recorded the training and testing errors for each of the models.

ModelTraining errorTest error
10.21.8
21.01.1
30.50.7
45.96.3

Based on the above information, which of the following statement(s) is/are correct?

Select all that apply.

  1. A

    Model 4 tends to overfit.

  2. B

    Model 4 tends to underfit.

  3. C

    Model 1 tends to underfit.

  4. D

    Model 1 tends to overfit.

Show answer

Correct answers

  • B

    Model 4 tends to underfit.

  • D

    Model 1 tends to overfit.

Question 17

+5 marksOne or more correct options

Select all that apply.

  1. A
  2. B
  3. C
  4. D
Show answer

Correct answers

  • A
  • C
  • D

Question 18

+6 marksNumerical answer
Show answer

Correct answer: 4081