Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -29,7 +29,7 @@ def show_n_generate(img, greedy = True, model = model_raw):
|
|
29 |
max_new_tokens = 30,
|
30 |
top_k=5)
|
31 |
generated_text = tokenizer.batch_decode(generated_ids, skip_special_tokens=True)[0]
|
32 |
-
|
33 |
|
34 |
device = "cpu"
|
35 |
clip_model, preprocess = clip.load("ViT-B/32", device=device, jit=False)
|
|
|
29 |
max_new_tokens = 30,
|
30 |
top_k=5)
|
31 |
generated_text = tokenizer.batch_decode(generated_ids, skip_special_tokens=True)[0]
|
32 |
+
return generated_text
|
33 |
|
34 |
device = "cpu"
|
35 |
clip_model, preprocess = clip.load("ViT-B/32", device=device, jit=False)
|