Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
@@ -1,5 +1,22 @@
|
|
1 |
import gradio as gr
|
2 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3 |
from llava.constants import DEFAULT_IMAGE_TOKEN, IMAGE_TOKEN_INDEX
|
4 |
from llava.conversation import SeparatorStyle, conv_templates
|
5 |
from llava.mm_utils import (
|
|
|
1 |
import gradio as gr
|
2 |
|
3 |
+
import textwrap
|
4 |
+
from io import BytesIO
|
5 |
+
|
6 |
+
import requests
|
7 |
+
import torch
|
8 |
+
from llava.constants import DEFAULT_IMAGE_TOKEN, IMAGE_TOKEN_INDEX
|
9 |
+
from llava.conversation import SeparatorStyle, conv_templates
|
10 |
+
from llava.mm_utils import (
|
11 |
+
KeywordsStoppingCriteria,
|
12 |
+
get_model_name_from_path,
|
13 |
+
process_images,
|
14 |
+
tokenizer_image_token,
|
15 |
+
)
|
16 |
+
from llava.model.builder import load_pretrained_model
|
17 |
+
from llava.utils import disable_torch_init
|
18 |
+
from PIL import Image
|
19 |
+
|
20 |
from llava.constants import DEFAULT_IMAGE_TOKEN, IMAGE_TOKEN_INDEX
|
21 |
from llava.conversation import SeparatorStyle, conv_templates
|
22 |
from llava.mm_utils import (
|