File tree 2 files changed +8
-7
lines changed 2 files changed +8
-7
lines changed Original file line number Diff line number Diff line change @@ -12,7 +12,6 @@ now you will need to use our forks.
12
12
13
13
``` bash
14
14
deepspeed> =0.14.2
15
- git+git://github.com/Snowflake-Labs/transformers.git@arctic
16
15
git+git://github.com/Snowflake-Labs/vllm.git@arctic
17
16
huggingface_hub[hf_transfer]
18
17
```
@@ -38,15 +37,19 @@ os.environ["HF_HUB_ENABLE_HF_TRANSFER"] = "1"
38
37
39
38
import torch
40
39
from transformers import AutoModelForCausalLM, AutoTokenizer
41
- from transformers.models.arctic.configuration_arctic import ArcticQuantizationConfig
40
+ from deepspeed.linear.config import QuantizationConfig
42
41
43
- tokenizer = AutoTokenizer.from_pretrained(" Snowflake/snowflake-arctic-instruct" )
42
+ tokenizer = AutoTokenizer.from_pretrained(
43
+ " Snowflake/snowflake-arctic-instruct" ,
44
+ trust_remote_code = True
45
+ )
44
46
45
- quant_config = ArcticQuantizationConfig (q_bits = 8 )
47
+ quant_config = QuantizationConfig (q_bits = 8 )
46
48
47
49
model = AutoModelForCausalLM.from_pretrained(
48
50
" Snowflake/snowflake-arctic-instruct" ,
49
51
low_cpu_mem_usage = True ,
52
+ trust_remote_code = True ,
50
53
device_map = " auto" ,
51
54
ds_quantization_config = quant_config,
52
55
max_memory = {i: " 150GiB" for i in range (8 )},
Original file line number Diff line number Diff line change 1
1
deepspeed >= 0.14.2
2
- git+git://github.com/Snowflake-Labs/transformers.git@arctic
3
- git+git://github.com/Snowflake-Labs/vllm.git@arctic
4
- huggingface_hub [hf_transfer ]
2
+ huggingface_hub [hf_transfer ]
You can’t perform that action at this time.
0 commit comments