Mz Pan
Results
2
issues of
Mz Pan
I try to get the gradient of the intermedia layer of model, so I use the backwards hook with functroch.grad to get the gradient of each image. When I used...
``` from functorch import make_functional_with_buffers, vmap, grad fmodel, params, buffers = make_functional_with_buffers(net,disable_autograd_tracking=True) def compute_loss_stateless_model (params, buffers, sample, target): batch = sample.unsqueeze(0) targets = target.unsqueeze(0) predictions = fmodel(params, buffers, batch) loss...