Check `gradInput`s

Is there a way one can inspect the gradInputs of the network?
Or there is no more such a thing?
I mean, I just computed my loss J and would like to check what’s the signal that is driven into the network.

net = Net()
h = net(x)
J = loss(h, y)
J.backward()

What’s a signal driven to a network? You want to inspect gradients w.r.t. intermediate outputs? Use module or variable hooks.

1 Like

Signal: derivative of the loss w.r.t. the output of the network.
OK, I’ll check these hooks. Thank you.

In that case Variable hooks (on the output) should do it.

1 Like