Question: ( 4 points ) Derive d e l J d e l W i j . ( 2 points ) Write d e l J

(4 points) Derive delJdelWij.
(2 points) Write delJdelW as an outer product of two vectors. delJdelW is a matrix with the same dimen-
sions as W; it is just like a gradient, except that W and delJdelW are matrices rather than vectors.
(7 points) Derive delJdelVij. Problem 5
You want to train a neural network to recognize the age and sex based on the face image. Your
training data consists of grayscale 3232 pixel images. The training labels include the age and sex
of each person. Your neural network consists of an input layer with 3232=1,024 units, a hidden
layer with 2,048 units, and an output layer with 2 units. You use the ReLU activation function for
the hidden units and no activation function for the outputs (or inputs). You train your network
with the cost function J=12||y-z||2. Please use the following notations to answer questions:
x is a training image (input) vector with a 1 component appended to the end (as a bias),y is
a training label (input) vector, and z is the output vector. All vectors are column vectors.
r()=max{0,} is the ReLU activation function, r'() is its derivative (1 if >0,0 other-
wise), and r(v) is r(*) applied component-wise to a vector.
g is the vector of hidden unit values before the ReLU activation functions are applied, and
h=r(g) is the vector of hidden unit values after they are applied (but we append a 1 com-
ponent to the end of h as the bias term).
V is the weight matrix mapping the input layer to the hidden layer; g=Vx.
W is the weight matrix mapping the hidden layer to the output layer; z=Wh.
Questions:
(2 points) Calculate the number of parameters (weights) in this network. You can leave your
answer as an expression.
 (4 points) Derive delJdelWij. (2 points) Write delJdelW as an outer

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!