Skip to content
Snippets Groups Projects
Commit 065ddaa7 authored by Hamid Shojanazeri's avatar Hamid Shojanazeri
Browse files

fixing the condition for moving to cuda

parent 20b061e0
Branches
Tags
No related merge requests found
......@@ -85,7 +85,7 @@ def train(model, train_dataloader,eval_dataloader, tokenizer, optimizer, lr_sche
for key in batch.keys():
if train_config.enable_fsdp:
batch[key] = batch[key].to(local_rank)
elif not train_config.quantization:
else:
batch[key] = batch[key].to('cuda')
outputs = model(**batch)
loss = outputs.loss
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment