uiz Space

January 2025 term · Deep Learning · BSCS3004

Deep Learning Quiz 2: 16 March 2025 (January 2025 term)

The IIT Madras BS Deep Learning (Deep Learning) Quiz 2 paper sat on 16 Mar 2025, in the January 2025 term: 23 questions for 40 marks in 120 minutes. Every question is below with its answer. Take it as a timed mock test to be marked, or read it through first.

Questions
23
Marks
40
Duration
120 min
MCQ
10
Numerical
13

Updated

Official paper: IIT M DEGREE AN EXAM QDB2 16 Mar 2025 · No negative marking.

Question 1

+3 marksOne correct option

What is the impact of using a sigmoid activation function on the gradients when the input to the neuron is a very large negative number?

  1. A

    The output approaches 0 and the gradient approaches 0.

  2. B

    The output approaches 0.5 and the gradient approaches 0.25.

  3. C

    The output approaches 1 and the gradient approaches 0.

  4. D

    The output approaches 0 and the gradient approaches 1.

Show answer

Correct answer

  • A

    The output approaches 0 and the gradient approaches 0.

Question 2

+3 marksOne correct option

Why is bias correction needed in the Adam optimizer?

  1. A

    To prevent the learning rate from becoming too large in the early iterations.

  2. B

    To correct the underestimated moving averages of the first and second moments at the beginning of training.

  3. C

    To increase the momentum effect for faster convergence.

  4. D

    To ensure the learning rate remains constant throughout training.

Show answer

Correct answer

  • B

    To correct the underestimated moving averages of the first and second moments at the beginning of training.

Question 3

+3 marksOne correct option

How do skip connections in ResNet work?

  1. A

    By incorporating element-wise addition of the input of a layer to its output

  2. B

    By concatenating the input and output of a layer

  3. C

    By multiplying the input and output of a layer

  4. D

    By removing the input from the output

Show answer

Correct answer

  • A

    By incorporating element-wise addition of the input of a layer to its output

Question 4

+3 marksOne correct option

What is the primary purpose of L2 regularization in machine learning models?

  1. A

    To prevent overfitting by adding the sum of absolute values of weights to the loss function

  2. B

    To encourage sparsity in the model by setting some weights to zero

  3. C

    To prevent overfitting by adding the sum of squared values of weights to the loss function

  4. D

    To increase the complexity of the model by penalizing small weights

Show answer

Correct answer

  • C

    To prevent overfitting by adding the sum of squared values of weights to the loss function

Question 5

+3 marksOne correct option

What is the soft target used when injecting noise at the output?

  1. A

    A label that is either 0 or 1, with no probability distribution

  2. B

    A target value that is continuous or probabilistic rather than discrete

  3. C

    A random label assigned to misclassified samples

  4. D

    A label that is always equal to the predicted output

Show answer

Correct answer

  • B

    A target value that is continuous or probabilistic rather than discrete

Question 6

+3 marksNumerical answer

Consider a neural network architecture for a regression task. Three distinct subsets of the training dataset are used to train three distinct models: A,B and C. Note that these models have the same architecture with different parameter values. Consider a test dataset of size four with true labels: y = [1,3,6,8]. The predictions of the models on this dataset is given below:
• Model A predictions: [1, 4, 7, 8]
• Model B predictions: [3, 5, 6, 9]
• Model C predictions: [2, 3, 5, 7]
Calculate the variance of these models averaged over all data-points in the test dataset. Enter your answer up to 2 decimal places.

Show answer

Correct answer: 0.67 (accepted within ±0.05)

Question 7

+3 marksNumerical answer

The weighted moving average (WMA) is used to smooth data by giving more importance to recent values. Suppose we compute a weighted moving average for a sequence of gradient values using the formula:

vt=βvt−1+(1−β)∇wtv_t = \beta v_{t-1} + (1 - \beta)\nabla w_t

where,

  • vtv_t is the weighted moving average at time step tt.
  • β=0.9\beta = 0.9 is the decay factor.
  • ∇wt\nabla w_t is the gradient value at time step tt.
  • v−1=0v_{-1} = 0

If the gradient values at t=0,1,2t = 0, 1, 2 are ∇w0=5,∇w1=3\nabla w_0 = 5, \nabla w_1 = 3 and ∇w2=4\nabla w_2 = 4. Compute v2v_2. Enter your answer correct up to 3 decimal places.

Show answer

Correct answer: 1.075 (accepted within ±0.01)

Question 8

+1 markOne correct option

Given an input array XX and a kernel/filter KK as follows:

X=[10−211201−1−1100101]X = \begin{bmatrix} 1 & 0 & -2 & 1 \\ 1 & 2 & 0 & 1 \\ -1 & -1 & 1 & 0 \\ 0 & 1 & 0 & 1 \end{bmatrix}

K=[101001101]K = \begin{bmatrix} 1 & 0 & 1 \\ 0 & 0 & 1 \\ 1 & 0 & 1 \end{bmatrix}

Based on the above data, answer the given subquestions.

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

Correct answer

  • A

Question 9

+1 markOne correct option

Given an input array XX and a kernel/filter KK as follows:

X=[10−211201−1−1100101]X = \begin{bmatrix} 1 & 0 & -2 & 1 \\ 1 & 2 & 0 & 1 \\ -1 & -1 & 1 & 0 \\ 0 & 1 & 0 & 1 \end{bmatrix}

K=[101001101]K = \begin{bmatrix} 1 & 0 & 1 \\ 0 & 0 & 1 \\ 1 & 0 & 1 \end{bmatrix}

Based on the above data, answer the given subquestions.

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

Correct answer

  • C

Question 10

+3 marksNumerical answer

Given an input array XX and a kernel/filter KK as follows:

X=[10−211201−1−1100101]X = \begin{bmatrix} 1 & 0 & -2 & 1 \\ 1 & 2 & 0 & 1 \\ -1 & -1 & 1 & 0 \\ 0 & 1 & 0 & 1 \end{bmatrix}

K=[101001101]K = \begin{bmatrix} 1 & 0 & 1 \\ 0 & 0 & 1 \\ 1 & 0 & 1 \end{bmatrix}

Based on the above data, answer the given subquestions.

Pass BB through the sigmoid (logistic) function with weight equal to 1 and no bias to get the final output y^\hat{y}.

LL is some loss function that depends on y^\hat{y}. Given that ∂L∂y^=−1\frac{\partial L}{\partial \hat{y}} = -1, determine the value of ∂L∂K00\frac{\partial L}{\partial K_{00}} where K00K_{00} is the element of KK at index (0,0)(0,0). Note that we use zero-indexing here.

Enter your answer correct up to 3 digits after the decimal.

Show answer

Correct answer: -0.126 (accepted within ±0.01)

Question 11

+1 markNumerical answer

Consider a loss function, L(w)=w3+2wL(w) = w^3 + 2w, where ww represents the model parameter. The AdaGrad optimizer is used to minimize this loss. The learning rate η\eta is set to 0.50.5, and at the initial iteration (t=0t = 0), the parameter ww has a starting value of w0=2w_0 = 2.

AdaGrad Update Rule:

vt=vt−1+(∇wt)2wt+1=wt−ηvt+ϵ∗∇wtv−1=0use ϵ=0\begin{aligned} v_t &= v_{t-1} + (\nabla w_t)^2 \\ w_{t+1} &= w_t - \frac{\eta}{\sqrt{v_t + \epsilon}} * \nabla w_t \\ v_{-1} &= 0 \\ \text{use } \epsilon &= 0 \end{aligned}

Enter your answer correct up to two decimal places for all sub-questions. For intermediate calculations, use three decimal places so that your final answer falls within the expected range.

Based on the above data, answer the given subquestions.

Show answer

Correct answer: 1.5 (accepted within ±0.1)

Question 12

+1 markNumerical answer

Consider a loss function, L(w)=w3+2wL(w) = w^3 + 2w, where ww represents the model parameter. The AdaGrad optimizer is used to minimize this loss. The learning rate η\eta is set to 0.50.5, and at the initial iteration (t=0t = 0), the parameter ww has a starting value of w0=2w_0 = 2.

AdaGrad Update Rule:

vt=vt−1+(∇wt)2wt+1=wt−ηvt+ϵ∗∇wtv−1=0use ϵ=0\begin{aligned} v_t &= v_{t-1} + (\nabla w_t)^2 \\ w_{t+1} &= w_t - \frac{\eta}{\sqrt{v_t + \epsilon}} * \nabla w_t \\ v_{-1} &= 0 \\ \text{use } \epsilon &= 0 \end{aligned}

Enter your answer correct up to two decimal places for all sub-questions. For intermediate calculations, use three decimal places so that your final answer falls within the expected range.

Based on the above data, answer the given subquestions.

Show answer

Correct answer: 272.56 (accepted within ±0.1)

Question 13

+1 markNumerical answer

Consider a loss function, L(w)=w3+2wL(w) = w^3 + 2w, where ww represents the model parameter. The AdaGrad optimizer is used to minimize this loss. The learning rate η\eta is set to 0.50.5, and at the initial iteration (t=0t = 0), the parameter ww has a starting value of w0=2w_0 = 2.

AdaGrad Update Rule:

vt=vt−1+(∇wt)2wt+1=wt−ηvt+ϵ∗∇wtv−1=0use ϵ=0\begin{aligned} v_t &= v_{t-1} + (\nabla w_t)^2 \\ w_{t+1} &= w_t - \frac{\eta}{\sqrt{v_t + \epsilon}} * \nabla w_t \\ v_{-1} &= 0 \\ \text{use } \epsilon &= 0 \end{aligned}

Enter your answer correct up to two decimal places for all sub-questions. For intermediate calculations, use three decimal places so that your final answer falls within the expected range.

Based on the above data, answer the given subquestions.

Show answer

Correct answer: 8.75 (accepted within ±0.15)

Question 14

+2 marksNumerical answer

Consider a loss function, L(w)=w3+2wL(w) = w^3 + 2w, where ww represents the model parameter. The AdaGrad optimizer is used to minimize this loss. The learning rate η\eta is set to 0.50.5, and at the initial iteration (t=0t = 0), the parameter ww has a starting value of w0=2w_0 = 2.

AdaGrad Update Rule:

vt=vt−1+(∇wt)2wt+1=wt−ηvt+ϵ∗∇wtv−1=0use ϵ=0\begin{aligned} v_t &= v_{t-1} + (\nabla w_t)^2 \\ w_{t+1} &= w_t - \frac{\eta}{\sqrt{v_t + \epsilon}} * \nabla w_t \\ v_{-1} &= 0 \\ \text{use } \epsilon &= 0 \end{aligned}

Enter your answer correct up to two decimal places for all sub-questions. For intermediate calculations, use three decimal places so that your final answer falls within the expected range.

Based on the above data, answer the given subquestions.

Show answer

Correct answer: 1.23 (accepted within ±0.15)

Question 15

+1 markNumerical answer

Based on the above data, answer the given subquestions.

Show answer

Correct answer: 100352

Question 16

+1 markNumerical answer

Based on the above data, answer the given subquestions.

Show answer

Correct answer: 32768

Question 17

+1 markNumerical answer

Based on the above data, answer the given subquestions.

Show answer

Correct answer: 150528

Question 18

+1 markNumerical answer

Based on the above data, answer the given subquestions.

Show answer

Correct answer: 253952

Question 19

+1 markOne correct option

Based on the above data, answer the given subquestions.

  1. A

    28 X 28 X 96

  2. B

    24 X 24 X 96

  3. C

    28 X 28 X 128

  4. D

    32 X 32 X 128

Show answer

Correct answer

  • A

    28 X 28 X 96

Question 20

+1 markNumerical answer

Based on the above data, answer the given subquestions.

Show answer

Correct answer: 84992

Question 21

+1 markOne correct option

Based on the above data, answer the given subquestions.

  1. A

    3 X 3 X 256

  2. B

    28 X 28 X 1

  3. C

    26 X 26 X 64

  4. D

    28 X 28 X 256

  5. E

    Insufficient Information

Show answer

Correct answer

  • D

    28 X 28 X 256

Question 22

+1 markNumerical answer

Based on the above data, answer the given subquestions.

Show answer

Correct answer: 0

Question 23

+1 markOne correct option

Based on the above data, answer the given subquestions.

  1. A

    28 X 28 X 192

  2. B

    28 X 28 X 256

  3. C

    28 X 28 X 480

  4. D

    Insufficient Information

Show answer

Correct answer

  • C

    28 X 28 X 480