Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
|
@@ -8,15 +8,9 @@ import gradio as gr
|
|
| 8 |
from gradio import FileData
|
| 9 |
import time
|
| 10 |
|
| 11 |
-
processor = ChameleonProcessor.from_pretrained("facebook/chameleon-
|
| 12 |
|
| 13 |
-
|
| 14 |
-
load_in_4bit=True,
|
| 15 |
-
bnb_4bit_quant_type="nf4",
|
| 16 |
-
bnb_4bit_compute_dtype=torch.float16,
|
| 17 |
-
)
|
| 18 |
-
|
| 19 |
-
model = ChameleonForConditionalGeneration.from_pretrained("facebook/chameleon-30b", quantization_config=quantization_config).to("cuda")
|
| 20 |
|
| 21 |
@spaces.GPU
|
| 22 |
def bot_streaming(message, history):
|
|
|
|
| 8 |
from gradio import FileData
|
| 9 |
import time
|
| 10 |
|
| 11 |
+
processor = ChameleonProcessor.from_pretrained("facebook/chameleon-7b")
|
| 12 |
|
| 13 |
+
model = ChameleonForConditionalGeneration.from_pretrained("facebook/chameleon-7b", torch_dtype=torch.float16).to("cuda")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 14 |
|
| 15 |
@spaces.GPU
|
| 16 |
def bot_streaming(message, history):
|