added a print for output_text
Browse files
app.py
CHANGED
@@ -32,7 +32,8 @@ def krypton(input_image):
|
|
32 |
"<|start_header_id|>assistant<|end_header_id|>\n\n")
|
33 |
inputs = processor(prompt, pil_image, return_tensors='pt').to('cuda', torch.float16)
|
34 |
outputs = model.generate(**inputs, max_new_tokens=200, do_sample=False)
|
35 |
-
output_text = processor.decode(outputs[0]
|
|
|
36 |
return output_text
|
37 |
|
38 |
with gr.Blocks(fill_height=True) as demo:
|
|
|
32 |
"<|start_header_id|>assistant<|end_header_id|>\n\n")
|
33 |
inputs = processor(prompt, pil_image, return_tensors='pt').to('cuda', torch.float16)
|
34 |
outputs = model.generate(**inputs, max_new_tokens=200, do_sample=False)
|
35 |
+
output_text = processor.decode(outputs[0], skip_special_tokens=True)
|
36 |
+
print(output_text)
|
37 |
return output_text
|
38 |
|
39 |
with gr.Blocks(fill_height=True) as demo:
|