Hello!
In Torch, I could use the following command:
cnn_params, cnn_grad_params = cnn:getParameters()
to get a 1D tensor of all the trainable parameters of a given model (and corresponding gradients).
Is it possible to do something like that in PyTorch so that cnn_params shares the same memory of the corresponding model? I should mention that I only care about the trainable parameters (i.e., weights and biases) and not their gradients.
Thanks a lot for any help!