How can I access and extract weights from all cells in a LSTM / GRU layer?
davidmrau (David Rau) #1
hughperkins (Hugh Perkins) #2
In general, you can always do
list(r.parameters()), to get all the parameters of any model
anantguptadbl (Anant Gupta) #3
A better alternative would be list(r.named_parameters()). This would give you a dict kind of structure