The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

533674 (3) [Avatar] Offline
First of all, amazing book! I've learned so much from it. There is one thing I'm having trouble with though.

On page 174, layer_2_delta is calculated as follows
layer_2_delta = (labels[batch_start:batch_end] - layer_2) / (batch_size * layer_2.shape[0])

I'm confused on why the division is done. Running the code without the division tells me that it provides some moderation to the weight updates, but I don't understand the intuition behind picking that exact value of batch_size * layer_2.shape[0].