Thanks for the reply! Yes, seems that I need to copy-paste all the modules like Linear to my code and add a constructor argument what device to create module’s parameters on. Not as elegant as I wish it were