Update app.py
Browse files
app.py
CHANGED
@@ -290,7 +290,7 @@ def bot(history, temperature, top_p, max_output_tokens):
|
|
290 |
if previous_image:
|
291 |
gr.Warning("Only one image can be uploaded in a conversation. Please reduce the number of images and start a new conversation.")
|
292 |
our_chatbot.conversation = conv_templates[our_chatbot.conv_mode].copy()
|
293 |
-
return
|
294 |
# print("### message[0]",message[0])
|
295 |
# if len(message[0])>1:
|
296 |
# gr.Warning("Only one image can be uploaded in a conversation. Please reduce the number of images and start a new conversation.")
|
@@ -314,6 +314,8 @@ def bot(history, temperature, top_p, max_output_tokens):
|
|
314 |
# images_this_term.append(message[0][0])
|
315 |
|
316 |
|
|
|
|
|
317 |
assert len(images_this_term) > 0, "must have an image"
|
318 |
# image_files = (args.image_file).split(',')
|
319 |
# image = [load_image(f) for f in images_this_term if f]
|
|
|
290 |
if previous_image:
|
291 |
gr.Warning("Only one image can be uploaded in a conversation. Please reduce the number of images and start a new conversation.")
|
292 |
our_chatbot.conversation = conv_templates[our_chatbot.conv_mode].copy()
|
293 |
+
return None
|
294 |
# print("### message[0]",message[0])
|
295 |
# if len(message[0])>1:
|
296 |
# gr.Warning("Only one image can be uploaded in a conversation. Please reduce the number of images and start a new conversation.")
|
|
|
314 |
# images_this_term.append(message[0][0])
|
315 |
|
316 |
|
317 |
+
|
318 |
+
|
319 |
assert len(images_this_term) > 0, "must have an image"
|
320 |
# image_files = (args.image_file).split(',')
|
321 |
# image = [load_image(f) for f in images_this_term if f]
|