Solved by kishanbala in post #2 
              
              
                update: output = model(images) 
print(output.size()) 
pred = torch.argmax(output, dim=0).detach().cpu() 
plt.imshow(pred.permute(1,2,0)) 
plt.show() 
This code snippet solved this issue