batch = sample.unsqueeze(0) # (1, 3, 32, 32) output = model(batch) print(batch.shape) # torch.Size([1, 3, 32, 32]) print(output.shape) # torch.Size([1, 16, 30, 30])