You are creating the parameters in the forward method only, which creates new leaf tensors without a history. This will detach the previous tensors from their computation graph and you’ll thus see None gradients for previous layers.
The proper approach is to initialize all parameters in the __init__ method and use them in forward.