Solved by Manuel_Alejandro_Dia in post #2 
              
              
                Try loading the model before wrapping it as a DataParallel object: 
device = torch.device(‘cuda’ if torch.cuda.is_available() else ‘cpu’)
model = Model(opt)
file_path=’/content/drive/MyDrive/VitSTR/vitstr_tiny_patch16_224_aug.pth’
model.load_state_dict(torch.load(file_path))
model = torch.nn.DataPar…