How can I do that? I am using this->
model_ensemb = MyEnsemble(model_vgg, model_dense)
model_ensemb.to('cuda')
x1, x2 = torch.randn(20, 3,224,224), torch.randn(20,3,224,224)
x1.to('cuda')
x2.to('cuda')
output = model_ensemb(x1, x2)

Edit->Thanks for your answer, I got it.