tmp: use `trust_remote_code=True` flag
Browse files
README.md
CHANGED
@@ -34,6 +34,7 @@ tokenizer = AutoTokenizer.from_pretrained("stabilityai/stablelm-2-12b")
|
|
34 |
model = AutoModelForCausalLM.from_pretrained(
|
35 |
"stabilityai/stablelm-2-12b",
|
36 |
torch_dtype="auto",
|
|
|
37 |
)
|
38 |
model.cuda()
|
39 |
inputs = tokenizer("The weather is always wonderful", return_tensors="pt").to(model.device)
|
@@ -59,6 +60,7 @@ model = AutoModelForCausalLM.from_pretrained(
|
|
59 |
"stabilityai/stablelm-2-12b",
|
60 |
torch_dtype="auto",
|
61 |
attn_implementation="flash_attention_2",
|
|
|
62 |
)
|
63 |
model.cuda()
|
64 |
inputs = tokenizer("The weather is always wonderful", return_tensors="pt").to(model.device)
|
|
|
34 |
model = AutoModelForCausalLM.from_pretrained(
|
35 |
"stabilityai/stablelm-2-12b",
|
36 |
torch_dtype="auto",
|
37 |
+
trust_remote_code=True
|
38 |
)
|
39 |
model.cuda()
|
40 |
inputs = tokenizer("The weather is always wonderful", return_tensors="pt").to(model.device)
|
|
|
60 |
"stabilityai/stablelm-2-12b",
|
61 |
torch_dtype="auto",
|
62 |
attn_implementation="flash_attention_2",
|
63 |
+
trust_remote_code=True
|
64 |
)
|
65 |
model.cuda()
|
66 |
inputs = tokenizer("The weather is always wonderful", return_tensors="pt").to(model.device)
|