Unverified Commit 3ccff0d4 authored by Kyungmin Lee's avatar Kyungmin Lee Committed by GitHub
Browse files

Remove duplicate code (#17708)

parent 26a6a426
......@@ -1408,8 +1408,7 @@ class T5Model(T5PreTrainedModel):
)
hidden_states = encoder_outputs[0]
if self.model_parallel:
torch.cuda.set_device(self.decoder.first_device)
# Set device for model parallelism
if self.model_parallel:
torch.cuda.set_device(self.decoder.first_device)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment