I do define self.rho_prior before creating lamb_mu and lamb_sigma as well as all the layers.
When I print the values of lamb_mu and lamb_sigma within the forward method of my Lasso_layer constructor. I see that those values stay the same across layers and only change after the loss.backward step occurs in both the approaches (1) and (2). So, I think both ways might be correct but I want to be absolutely certain before I produce results from this code.