[solved] Getting batches of gradients

@Giuseppe_Castiglione: could you please elaborate your answer more?
How did you use torch.autograd.grad() to get the gradient of each individual input vector from a batch?
Some code snippet will be appreciated.

One relevant discussion is