Spaces:
Runtime error
Runtime error
update code
Browse files
app.py
CHANGED
|
@@ -40,8 +40,7 @@ if 'int4' in model_path:
|
|
| 40 |
if device == 'mps':
|
| 41 |
print('Error: running int4 model with bitsandbytes on Mac is not supported right now.')
|
| 42 |
exit()
|
| 43 |
-
|
| 44 |
-
model = AutoModel.from_pretrained(model_path, trust_remote_code=True)
|
| 45 |
else:
|
| 46 |
if args.multi_gpus:
|
| 47 |
from accelerate import load_checkpoint_and_dispatch, init_empty_weights, infer_auto_device_map
|
|
|
|
| 40 |
if device == 'mps':
|
| 41 |
print('Error: running int4 model with bitsandbytes on Mac is not supported right now.')
|
| 42 |
exit()
|
| 43 |
+
model = AutoModel.from_pretrained(model_path, trust_remote_code=True, attn_implementation='sdpa')
|
|
|
|
| 44 |
else:
|
| 45 |
if args.multi_gpus:
|
| 46 |
from accelerate import load_checkpoint_and_dispatch, init_empty_weights, infer_auto_device_map
|