Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -129,10 +129,10 @@ class StopOnTokens(StoppingCriteria):
|
|
129 |
|
130 |
def initialize_model():
|
131 |
quantization_config = BitsAndBytesConfig(
|
132 |
-
|
133 |
-
|
134 |
-
|
135 |
-
|
136 |
)
|
137 |
|
138 |
tokenizer = AutoTokenizer.from_pretrained(MODEL_ID, trust_remote_code=True)
|
|
|
129 |
|
130 |
def initialize_model():
|
131 |
quantization_config = BitsAndBytesConfig(
|
132 |
+
load_in_4bit=True,
|
133 |
+
bnb_4bit_compute_dtype=torch.bfloat16,
|
134 |
+
bnb_4bit_quant_type="nf4",
|
135 |
+
bnb_4bit_use_double_quant=True,
|
136 |
)
|
137 |
|
138 |
tokenizer = AutoTokenizer.from_pretrained(MODEL_ID, trust_remote_code=True)
|