BAAI
/

BoyaWu10 commited on
Commit
8f4c803
1 Parent(s): a65ec98

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +1 -0
README.md CHANGED
@@ -47,6 +47,7 @@ warnings.filterwarnings('ignore')
47
 
48
  # set device
49
  device = 'cuda' # or cpu
 
50
 
51
  # create model
52
  model = AutoModelForCausalLM.from_pretrained(
 
47
 
48
  # set device
49
  device = 'cuda' # or cpu
50
+ torch.set_default_device(device)
51
 
52
  # create model
53
  model = AutoModelForCausalLM.from_pretrained(