You are on page 1of 11

OHT-1

Q1. Identify each of the following as a classification or regression problem. Only ONE answer is acceptable. [CLO1][2]

a. Recognition of Alphabets (A-Z).

Classifications
b. Predicting the weight of an individual from the number of cups of coffee he/she takes.
Regression
c. Signature Verification.
Classifications

Q2. An optical sensing based system needs to inspect and divide a bunch of 5 fish into 2 different species (classes). The measurable attributes
are the length and lightness of each fish and have the values as indicated in the following table. Design a perceptron (show its structure). Using
“0.5” value for all the weights and biases, show how can you optimize the values of weights by
performing the calculations for these 5 records. [CLO2][5]

Species F1 F2 F1 F2 F2
Length 3 8 4 1 6
Lightness 2 4 7 1 4
Solution

Q3. Consider the unit shown on Figure 1. Suppose that the weights corresponding to the three inputs have the values in Figure 2
and activation function is given by step function as Figure 3:

Figure 1 Figure 2 Figure 3

a. Calculate what will be the output value y of the unit for each of the following input patterns:

Solution 3a.

b. Using the Neural Network Unit of Figure 1; you have to make it perform LOGICAL OR function by adjusting the (i) weights, (ii) activation
function. Note: You do not need to show the optimization. Just show for which weights and function, it can work as LOGICAL OR

Solution 3b.
(i) Not Possible; There are no weights that can be put into Fig-1 to make it logical OR (given the activation function in
Fig 3

Activation Function =
OHT-2
Question 1: Give short answers of following questions: [CLO1] [6]
Solution:
a. Given that J (a,b,c) = 2(ab + c)’ calculate dj/dc. [1]
2
b. Given x = 0.8; calculate y using following functions [2]
y = sigmoid (x)

y = sign (x) y = +1

y = x y = 0.8
c. Let’s assume that, a neural network has 3 output variables with values 0.2, 1.1 and 0.8; calculate their (probability) values
using Softmax Function. [1]

d. Let’s suppose we have a training corpus having the following sentences: [2]
“the dog saw a cat”, “the dog chased the cat”, “the cat climbed a tree”
What is the vocabulary size? Make 1 hot encoding vectors of Cat and Tree

Solution:
Library
The Dog Saw A Cat Chased Climbed tree

Vocabulary Size = 8
CAT = 0 0 0 0 1 0 0 0

Tree = 0 0 0 0 0 0 0 1
Question 2: Let’s suppose a neural network for Skip-Gram as shown below. W1 is the resultant matrix of weights after training
(optimized weights). Calculate the Word2Vec embedding of the input word (vector). [CLO2] [2]

0.2 0.7
0.3 0.2
0.1 0.5

= [0.2 0.7]

Question 3: For a Network given below; compute the output at o1 and o2. The values of inputs, biases and weights are provided on
figure. Also calculate the new value of w7. Use Sigmoid function for activation. [CLO3] [7]

Solution

You might also like