catastropiyush
commited on
Commit
•
d2db358
1
Parent(s):
340a6dd
Update app.py
Browse files
app.py
CHANGED
@@ -31,7 +31,7 @@ def bot_streaming(message, history):
|
|
31 |
inputs = processor(prompt, image, return_tensors="pt").to("cuda:0")
|
32 |
|
33 |
streamer = TextIteratorStreamer(processor, **{"skip_special_tokens": True})
|
34 |
-
generation_kwargs = dict(inputs, streamer=streamer, max_new_tokens=
|
35 |
generated_text = ""
|
36 |
|
37 |
thread = Thread(target=model.generate, kwargs=generation_kwargs)
|
|
|
31 |
inputs = processor(prompt, image, return_tensors="pt").to("cuda:0")
|
32 |
|
33 |
streamer = TextIteratorStreamer(processor, **{"skip_special_tokens": True})
|
34 |
+
generation_kwargs = dict(inputs, streamer=streamer, max_new_tokens=300)
|
35 |
generated_text = ""
|
36 |
|
37 |
thread = Thread(target=model.generate, kwargs=generation_kwargs)
|