Spaces:
Runtime error
Runtime error
Update model.py
Browse files
model.py
CHANGED
@@ -10,14 +10,14 @@ if torch.cuda.is_available():
|
|
10 |
model = AutoModelForCausalLM.from_pretrained(
|
11 |
model_id,
|
12 |
torch_dtype=torch.float16,
|
13 |
-
device_map='
|
14 |
|
15 |
-
)
|
16 |
else:
|
17 |
model = AutoModelForCausalLM.from_pretrained(
|
18 |
model_id,
|
19 |
-
torch_dtype=torch.
|
20 |
-
load_in_4bit=True,
|
21 |
device_map='auto',
|
22 |
use_safetensors=False,
|
23 |
)
|
|
|
10 |
model = AutoModelForCausalLM.from_pretrained(
|
11 |
model_id,
|
12 |
torch_dtype=torch.float16,
|
13 |
+
device_map='auto',
|
14 |
|
15 |
+
)
|
16 |
else:
|
17 |
model = AutoModelForCausalLM.from_pretrained(
|
18 |
model_id,
|
19 |
+
torch_dtype=torch.float32,
|
20 |
+
#load_in_4bit=True,
|
21 |
device_map='auto',
|
22 |
use_safetensors=False,
|
23 |
)
|