Update app.py
Browse files
app.py
CHANGED
@@ -134,7 +134,7 @@ def inference(image, audio, video, task_type, instruction):
|
|
134 |
|
135 |
|
136 |
|
137 |
-
with torch.autocast(device_type=device_type, dtype=torch.
|
138 |
|
139 |
out = model(image=image, text=text_input, mode='generate', return_dict=True, max_length=max_length,
|
140 |
do_sample=do_sample, num_beams=num_beams)
|
|
|
134 |
|
135 |
|
136 |
|
137 |
+
with torch.autocast(device_type=device_type, dtype=torch.bfloat16, enabled=True):
|
138 |
|
139 |
out = model(image=image, text=text_input, mode='generate', return_dict=True, max_length=max_length,
|
140 |
do_sample=do_sample, num_beams=num_beams)
|