RuntimeError: expected backend CUDA and dtype Float but got backend CPU and dtype Float

I might have misunderstood your use case.
If you call .cuda() on an nn.Parameter, it won’t be a leaf variable anymore, which is explaiend here and thus won’t appear in the .parameters().