zhangbofei
commited on
Commit
•
72b855c
1
Parent(s):
a40b44d
fix: code
Browse files- app.py +2 -0
- gradio_web_server.log +256 -0
- gradio_web_server_multi.log +10 -0
- src/__pycache__/conversation.cpython-310.pyc +0 -0
- src/conversation.py +3 -3
- src/model/__pycache__/__init__.cpython-310.pyc +0 -0
- src/model/__pycache__/model_falcon.cpython-310.pyc +0 -0
- src/model/__pycache__/model_yuan2.cpython-310.pyc +0 -0
- src/serve/__pycache__/api_provider.cpython-310.pyc +0 -0
- src/serve/__pycache__/gradio_block_arena_named.cpython-310.pyc +0 -0
- src/serve/__pycache__/gradio_block_arena_vision_named.cpython-310.pyc +0 -0
- src/serve/__pycache__/gradio_web_server.cpython-310.pyc +0 -0
- src/serve/gradio_web_server.py +59 -50
- vision-tmp-2024-07-10-conv.json +2 -0
app.py
CHANGED
@@ -3,10 +3,12 @@ from loguru import logger
|
|
3 |
logger.info("app start")
|
4 |
import gradio as gr
|
5 |
|
|
|
6 |
from src.serve.gradio_block_arena_vision_named import build_side_by_side_vision_ui_named
|
7 |
|
8 |
|
9 |
if __name__ == "__main__":
|
|
|
10 |
with gr.Blocks() as demo:
|
11 |
|
12 |
states = build_side_by_side_vision_ui_named(
|
|
|
3 |
logger.info("app start")
|
4 |
import gradio as gr
|
5 |
|
6 |
+
from src.model.model_llava import inference
|
7 |
from src.serve.gradio_block_arena_vision_named import build_side_by_side_vision_ui_named
|
8 |
|
9 |
|
10 |
if __name__ == "__main__":
|
11 |
+
logger.info("inference called!", inference())
|
12 |
with gr.Blocks() as demo:
|
13 |
|
14 |
states = build_side_by_side_vision_ui_named(
|
gradio_web_server.log
ADDED
@@ -0,0 +1,256 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
2024-07-10 11:44:38 | ERROR | stderr | Traceback (most recent call last):
|
2 |
+
2024-07-10 11:44:38 | ERROR | stderr | File "/home/bofei-zhang/Documents/Project/Projects/Multimodal-CL/nips_0601/FIRE/app.py", line 11, in <module>
|
3 |
+
2024-07-10 11:44:38 | ERROR | stderr | states = build_side_by_side_vision_ui_named(
|
4 |
+
2024-07-10 11:44:38 | ERROR | stderr | File "/home/bofei-zhang/Documents/Project/Projects/Multimodal-CL/nips_0601/FIRE/src/serve/gradio_block_arena_vision_named.py", line 319, in build_side_by_side_vision_ui_named
|
5 |
+
2024-07-10 11:44:38 | ERROR | stderr | textbox = gr.MultimodalTextbox(
|
6 |
+
2024-07-10 11:44:38 | ERROR | stderr | AttributeError: module 'gradio' has no attribute 'MultimodalTextbox'
|
7 |
+
2024-07-10 11:44:39 | INFO | stdout | IMPORTANT: You are using gradio version 4.16.0, however version 4.29.0 is available, please upgrade.
|
8 |
+
2024-07-10 11:44:39 | INFO | stdout | --------
|
9 |
+
2024-07-10 11:48:26 | INFO | stdout | Running on local URL: http://127.0.0.1:7860
|
10 |
+
2024-07-10 11:48:26 | INFO | stdout |
|
11 |
+
2024-07-10 11:48:26 | INFO | stdout | To create a public link, set `share=True` in `launch()`.
|
12 |
+
2024-07-10 11:53:22 | INFO | stdout | Keyboard interruption in main thread... closing server.
|
13 |
+
2024-07-10 11:53:25 | ERROR | stderr | Traceback (most recent call last):
|
14 |
+
2024-07-10 11:53:25 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 2553, in block_thread
|
15 |
+
2024-07-10 11:53:25 | ERROR | stderr | time.sleep(0.1)
|
16 |
+
2024-07-10 11:53:25 | ERROR | stderr | KeyboardInterrupt
|
17 |
+
2024-07-10 11:53:25 | ERROR | stderr |
|
18 |
+
2024-07-10 11:53:25 | ERROR | stderr | During handling of the above exception, another exception occurred:
|
19 |
+
2024-07-10 11:53:25 | ERROR | stderr |
|
20 |
+
2024-07-10 11:53:25 | ERROR | stderr | Traceback (most recent call last):
|
21 |
+
2024-07-10 11:53:25 | ERROR | stderr | File "/home/bofei-zhang/Documents/Project/Projects/Multimodal-CL/nips_0601/FIRE/app.py", line 16, in <module>
|
22 |
+
2024-07-10 11:53:25 | ERROR | stderr | demo.launch()
|
23 |
+
2024-07-10 11:53:25 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 2458, in launch
|
24 |
+
2024-07-10 11:53:25 | ERROR | stderr | self.block_thread()
|
25 |
+
2024-07-10 11:53:25 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 2557, in block_thread
|
26 |
+
2024-07-10 11:53:25 | ERROR | stderr | self.server.close()
|
27 |
+
2024-07-10 11:53:25 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/http_server.py", line 68, in close
|
28 |
+
2024-07-10 11:53:25 | ERROR | stderr | self.thread.join(timeout=5)
|
29 |
+
2024-07-10 11:53:25 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/threading.py", line 1100, in join
|
30 |
+
2024-07-10 11:53:25 | ERROR | stderr | self._wait_for_tstate_lock(timeout=max(timeout, 0))
|
31 |
+
2024-07-10 11:53:25 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/threading.py", line 1116, in _wait_for_tstate_lock
|
32 |
+
2024-07-10 11:53:25 | ERROR | stderr | if lock.acquire(block, timeout):
|
33 |
+
2024-07-10 11:53:25 | ERROR | stderr | KeyboardInterrupt
|
34 |
+
2024-07-10 11:53:29 | INFO | stdout | Running on local URL: http://127.0.0.1:7860
|
35 |
+
2024-07-10 11:53:29 | INFO | stdout |
|
36 |
+
2024-07-10 11:53:29 | INFO | stdout | To create a public link, set `share=True` in `launch()`.
|
37 |
+
2024-07-10 11:54:17 | INFO | gradio_web_server | bot_response. ip: 127.0.0.1
|
38 |
+
2024-07-10 11:54:17 | INFO | gradio_web_server | monitor error: Extra data: line 1 column 5 (char 4)
|
39 |
+
2024-07-10 11:54:17 | INFO | gradio_web_server | model_name: llava-fire
|
40 |
+
2024-07-10 11:54:17 | INFO | gradio_web_server | bot_response. ip: 127.0.0.1
|
41 |
+
2024-07-10 11:54:17 | INFO | gradio_web_server | monitor error: Extra data: line 1 column 5 (char 4)
|
42 |
+
2024-07-10 11:54:17 | INFO | gradio_web_server | model_name: llava-original
|
43 |
+
2024-07-10 11:56:25 | INFO | stdout | Keyboard interruption in main thread... closing server.
|
44 |
+
2024-07-10 11:56:27 | ERROR | stderr | Traceback (most recent call last):
|
45 |
+
2024-07-10 11:56:27 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 2553, in block_thread
|
46 |
+
2024-07-10 11:56:27 | ERROR | stderr | time.sleep(0.1)
|
47 |
+
2024-07-10 11:56:27 | ERROR | stderr | KeyboardInterrupt
|
48 |
+
2024-07-10 11:56:27 | ERROR | stderr |
|
49 |
+
2024-07-10 11:56:27 | ERROR | stderr | During handling of the above exception, another exception occurred:
|
50 |
+
2024-07-10 11:56:27 | ERROR | stderr |
|
51 |
+
2024-07-10 11:56:27 | ERROR | stderr | Traceback (most recent call last):
|
52 |
+
2024-07-10 11:56:27 | ERROR | stderr | File "/home/bofei-zhang/Documents/Project/Projects/Multimodal-CL/nips_0601/FIRE/app.py", line 16, in <module>
|
53 |
+
2024-07-10 11:56:27 | ERROR | stderr | demo.launch()
|
54 |
+
2024-07-10 11:56:27 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 2458, in launch
|
55 |
+
2024-07-10 11:56:27 | ERROR | stderr | self.block_thread()
|
56 |
+
2024-07-10 11:56:27 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 2557, in block_thread
|
57 |
+
2024-07-10 11:56:27 | ERROR | stderr | self.server.close()
|
58 |
+
2024-07-10 11:56:27 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/http_server.py", line 68, in close
|
59 |
+
2024-07-10 11:56:27 | ERROR | stderr | self.thread.join(timeout=5)
|
60 |
+
2024-07-10 11:56:27 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/threading.py", line 1100, in join
|
61 |
+
2024-07-10 11:56:27 | ERROR | stderr | self._wait_for_tstate_lock(timeout=max(timeout, 0))
|
62 |
+
2024-07-10 11:56:27 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/threading.py", line 1116, in _wait_for_tstate_lock
|
63 |
+
2024-07-10 11:56:27 | ERROR | stderr | if lock.acquire(block, timeout):
|
64 |
+
2024-07-10 11:56:27 | ERROR | stderr | KeyboardInterrupt
|
65 |
+
2024-07-10 11:56:32 | INFO | stdout | Running on local URL: http://127.0.0.1:7860
|
66 |
+
2024-07-10 11:56:32 | INFO | stdout |
|
67 |
+
2024-07-10 11:56:32 | INFO | stdout | To create a public link, set `share=True` in `launch()`.
|
68 |
+
2024-07-10 11:56:38 | INFO | gradio_web_server | bot_response. ip: 127.0.0.1
|
69 |
+
2024-07-10 11:56:38 | INFO | gradio_web_server | monitor error: Extra data: line 1 column 5 (char 4)
|
70 |
+
2024-07-10 11:56:38 | INFO | gradio_web_server | model_name: llava-fire;model_api_dict: None
|
71 |
+
2024-07-10 11:56:38 | INFO | gradio_web_server | bot_response. ip: 127.0.0.1
|
72 |
+
2024-07-10 11:56:38 | INFO | gradio_web_server | monitor error: Extra data: line 1 column 5 (char 4)
|
73 |
+
2024-07-10 11:56:38 | INFO | gradio_web_server | model_name: llava-original;model_api_dict: None
|
74 |
+
2024-07-10 11:57:09 | INFO | stdout | Keyboard interruption in main thread... closing server.
|
75 |
+
2024-07-10 11:57:11 | ERROR | stderr | Traceback (most recent call last):
|
76 |
+
2024-07-10 11:57:11 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 2553, in block_thread
|
77 |
+
2024-07-10 11:57:11 | ERROR | stderr | time.sleep(0.1)
|
78 |
+
2024-07-10 11:57:11 | ERROR | stderr | KeyboardInterrupt
|
79 |
+
2024-07-10 11:57:11 | ERROR | stderr |
|
80 |
+
2024-07-10 11:57:11 | ERROR | stderr | During handling of the above exception, another exception occurred:
|
81 |
+
2024-07-10 11:57:11 | ERROR | stderr |
|
82 |
+
2024-07-10 11:57:11 | ERROR | stderr | Traceback (most recent call last):
|
83 |
+
2024-07-10 11:57:11 | ERROR | stderr | File "/home/bofei-zhang/Documents/Project/Projects/Multimodal-CL/nips_0601/FIRE/app.py", line 16, in <module>
|
84 |
+
2024-07-10 11:57:11 | ERROR | stderr | demo.launch()
|
85 |
+
2024-07-10 11:57:11 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 2458, in launch
|
86 |
+
2024-07-10 11:57:11 | ERROR | stderr | self.block_thread()
|
87 |
+
2024-07-10 11:57:11 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 2557, in block_thread
|
88 |
+
2024-07-10 11:57:11 | ERROR | stderr | self.server.close()
|
89 |
+
2024-07-10 11:57:11 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/http_server.py", line 68, in close
|
90 |
+
2024-07-10 11:57:11 | ERROR | stderr | self.thread.join(timeout=5)
|
91 |
+
2024-07-10 11:57:11 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/threading.py", line 1100, in join
|
92 |
+
2024-07-10 11:57:11 | ERROR | stderr | self._wait_for_tstate_lock(timeout=max(timeout, 0))
|
93 |
+
2024-07-10 11:57:11 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/threading.py", line 1116, in _wait_for_tstate_lock
|
94 |
+
2024-07-10 11:57:11 | ERROR | stderr | if lock.acquire(block, timeout):
|
95 |
+
2024-07-10 11:57:11 | ERROR | stderr | KeyboardInterrupt
|
96 |
+
2024-07-10 11:57:15 | INFO | stdout | Running on local URL: http://127.0.0.1:7860
|
97 |
+
2024-07-10 11:57:15 | INFO | stdout |
|
98 |
+
2024-07-10 11:57:15 | INFO | stdout | To create a public link, set `share=True` in `launch()`.
|
99 |
+
2024-07-10 11:57:23 | INFO | gradio_web_server | bot_response. ip: 127.0.0.1
|
100 |
+
2024-07-10 11:57:23 | INFO | gradio_web_server | monitor error: Extra data: line 1 column 5 (char 4)
|
101 |
+
2024-07-10 11:57:23 | INFO | gradio_web_server | model_name: llava-fire;model_api_dict: None
|
102 |
+
2024-07-10 11:57:23 | INFO | gradio_web_server | bot_response. ip: 127.0.0.1
|
103 |
+
2024-07-10 11:57:23 | INFO | gradio_web_server | monitor error: Extra data: line 1 column 5 (char 4)
|
104 |
+
2024-07-10 11:57:23 | INFO | gradio_web_server | model_name: llava-original;model_api_dict: None
|
105 |
+
2024-07-10 11:57:23 | INFO | gradio_web_server | hello
|
106 |
+
2024-07-10 11:57:23 | ERROR | stderr | Traceback (most recent call last):
|
107 |
+
2024-07-10 11:57:23 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/queueing.py", line 566, in process_events
|
108 |
+
2024-07-10 11:57:23 | ERROR | stderr | response = await route_utils.call_process_api(
|
109 |
+
2024-07-10 11:57:23 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/route_utils.py", line 270, in call_process_api
|
110 |
+
2024-07-10 11:57:23 | ERROR | stderr | output = await app.get_blocks().process_api(
|
111 |
+
2024-07-10 11:57:23 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 1847, in process_api
|
112 |
+
2024-07-10 11:57:23 | ERROR | stderr | result = await self.call_function(
|
113 |
+
2024-07-10 11:57:23 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 1445, in call_function
|
114 |
+
2024-07-10 11:57:23 | ERROR | stderr | prediction = await utils.async_iteration(iterator)
|
115 |
+
2024-07-10 11:57:23 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/utils.py", line 629, in async_iteration
|
116 |
+
2024-07-10 11:57:23 | ERROR | stderr | return await iterator.__anext__()
|
117 |
+
2024-07-10 11:57:23 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/utils.py", line 622, in __anext__
|
118 |
+
2024-07-10 11:57:23 | ERROR | stderr | return await anyio.to_thread.run_sync(
|
119 |
+
2024-07-10 11:57:23 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/anyio/to_thread.py", line 56, in run_sync
|
120 |
+
2024-07-10 11:57:23 | ERROR | stderr | return await get_async_backend().run_sync_in_worker_thread(
|
121 |
+
2024-07-10 11:57:23 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 2177, in run_sync_in_worker_thread
|
122 |
+
2024-07-10 11:57:23 | ERROR | stderr | return await future
|
123 |
+
2024-07-10 11:57:23 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 859, in run
|
124 |
+
2024-07-10 11:57:23 | ERROR | stderr | result = context.run(func, *args)
|
125 |
+
2024-07-10 11:57:23 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/utils.py", line 605, in run_sync_iterator_async
|
126 |
+
2024-07-10 11:57:23 | ERROR | stderr | return next(iterator)
|
127 |
+
2024-07-10 11:57:23 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/utils.py", line 788, in gen_wrapper
|
128 |
+
2024-07-10 11:57:23 | ERROR | stderr | response = next(iterator)
|
129 |
+
2024-07-10 11:57:23 | ERROR | stderr | File "/home/bofei-zhang/Documents/Project/Projects/Multimodal-CL/nips_0601/FIRE/src/serve/gradio_block_arena_named.py", line 282, in bot_response_multi
|
130 |
+
2024-07-10 11:57:23 | ERROR | stderr | ret = next(gen[i])
|
131 |
+
2024-07-10 11:57:23 | ERROR | stderr | File "/home/bofei-zhang/Documents/Project/Projects/Multimodal-CL/nips_0601/FIRE/src/serve/gradio_web_server.py", line 582, in bot_response
|
132 |
+
2024-07-10 11:57:23 | ERROR | stderr | conv.save_new_images(
|
133 |
+
2024-07-10 11:57:23 | ERROR | stderr | File "/home/bofei-zhang/Documents/Project/Projects/Multimodal-CL/nips_0601/FIRE/src/conversation.py", line 608, in save_new_images
|
134 |
+
2024-07-10 11:57:23 | ERROR | stderr | from fastchat.constants import LOGDIR
|
135 |
+
2024-07-10 11:57:23 | ERROR | stderr | ModuleNotFoundError: No module named 'fastchat'
|
136 |
+
2024-07-10 11:58:13 | INFO | stdout | Keyboard interruption in main thread... closing server.
|
137 |
+
2024-07-10 11:58:15 | ERROR | stderr | Traceback (most recent call last):
|
138 |
+
2024-07-10 11:58:15 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 2553, in block_thread
|
139 |
+
2024-07-10 11:58:15 | ERROR | stderr | time.sleep(0.1)
|
140 |
+
2024-07-10 11:58:15 | ERROR | stderr | KeyboardInterrupt
|
141 |
+
2024-07-10 11:58:15 | ERROR | stderr |
|
142 |
+
2024-07-10 11:58:15 | ERROR | stderr | During handling of the above exception, another exception occurred:
|
143 |
+
2024-07-10 11:58:15 | ERROR | stderr |
|
144 |
+
2024-07-10 11:58:15 | ERROR | stderr | Traceback (most recent call last):
|
145 |
+
2024-07-10 11:58:15 | ERROR | stderr | File "/home/bofei-zhang/Documents/Project/Projects/Multimodal-CL/nips_0601/FIRE/app.py", line 16, in <module>
|
146 |
+
2024-07-10 11:58:15 | ERROR | stderr | demo.launch()
|
147 |
+
2024-07-10 11:58:15 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 2458, in launch
|
148 |
+
2024-07-10 11:58:15 | ERROR | stderr | self.block_thread()
|
149 |
+
2024-07-10 11:58:15 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 2557, in block_thread
|
150 |
+
2024-07-10 11:58:15 | ERROR | stderr | self.server.close()
|
151 |
+
2024-07-10 11:58:15 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/http_server.py", line 68, in close
|
152 |
+
2024-07-10 11:58:15 | ERROR | stderr | self.thread.join(timeout=5)
|
153 |
+
2024-07-10 11:58:15 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/threading.py", line 1100, in join
|
154 |
+
2024-07-10 11:58:15 | ERROR | stderr | self._wait_for_tstate_lock(timeout=max(timeout, 0))
|
155 |
+
2024-07-10 11:58:15 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/threading.py", line 1116, in _wait_for_tstate_lock
|
156 |
+
2024-07-10 11:58:15 | ERROR | stderr | if lock.acquire(block, timeout):
|
157 |
+
2024-07-10 11:58:15 | ERROR | stderr | KeyboardInterrupt
|
158 |
+
2024-07-10 11:58:20 | INFO | stdout | Running on local URL: http://127.0.0.1:7860
|
159 |
+
2024-07-10 11:58:20 | INFO | stdout |
|
160 |
+
2024-07-10 11:58:20 | INFO | stdout | To create a public link, set `share=True` in `launch()`.
|
161 |
+
2024-07-10 11:58:24 | INFO | gradio_web_server | bot_response. ip: 127.0.0.1
|
162 |
+
2024-07-10 11:58:24 | INFO | gradio_web_server | monitor error: Extra data: line 1 column 5 (char 4)
|
163 |
+
2024-07-10 11:58:24 | INFO | gradio_web_server | model_name: llava-fire;model_api_dict: None
|
164 |
+
2024-07-10 11:58:24 | INFO | gradio_web_server | bot_response. ip: 127.0.0.1
|
165 |
+
2024-07-10 11:58:24 | INFO | gradio_web_server | monitor error: Extra data: line 1 column 5 (char 4)
|
166 |
+
2024-07-10 11:58:24 | INFO | gradio_web_server | model_name: llava-original;model_api_dict: None
|
167 |
+
2024-07-10 11:58:24 | INFO | gradio_web_server | hello
|
168 |
+
2024-07-10 11:58:24 | ERROR | stderr | Traceback (most recent call last):
|
169 |
+
2024-07-10 11:58:24 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/queueing.py", line 566, in process_events
|
170 |
+
2024-07-10 11:58:24 | ERROR | stderr | response = await route_utils.call_process_api(
|
171 |
+
2024-07-10 11:58:24 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/route_utils.py", line 270, in call_process_api
|
172 |
+
2024-07-10 11:58:24 | ERROR | stderr | output = await app.get_blocks().process_api(
|
173 |
+
2024-07-10 11:58:24 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 1847, in process_api
|
174 |
+
2024-07-10 11:58:24 | ERROR | stderr | result = await self.call_function(
|
175 |
+
2024-07-10 11:58:24 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 1445, in call_function
|
176 |
+
2024-07-10 11:58:24 | ERROR | stderr | prediction = await utils.async_iteration(iterator)
|
177 |
+
2024-07-10 11:58:24 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/utils.py", line 629, in async_iteration
|
178 |
+
2024-07-10 11:58:24 | ERROR | stderr | return await iterator.__anext__()
|
179 |
+
2024-07-10 11:58:24 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/utils.py", line 622, in __anext__
|
180 |
+
2024-07-10 11:58:24 | ERROR | stderr | return await anyio.to_thread.run_sync(
|
181 |
+
2024-07-10 11:58:24 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/anyio/to_thread.py", line 56, in run_sync
|
182 |
+
2024-07-10 11:58:24 | ERROR | stderr | return await get_async_backend().run_sync_in_worker_thread(
|
183 |
+
2024-07-10 11:58:24 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 2177, in run_sync_in_worker_thread
|
184 |
+
2024-07-10 11:58:24 | ERROR | stderr | return await future
|
185 |
+
2024-07-10 11:58:24 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 859, in run
|
186 |
+
2024-07-10 11:58:24 | ERROR | stderr | result = context.run(func, *args)
|
187 |
+
2024-07-10 11:58:24 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/utils.py", line 605, in run_sync_iterator_async
|
188 |
+
2024-07-10 11:58:24 | ERROR | stderr | return next(iterator)
|
189 |
+
2024-07-10 11:58:24 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/utils.py", line 788, in gen_wrapper
|
190 |
+
2024-07-10 11:58:24 | ERROR | stderr | response = next(iterator)
|
191 |
+
2024-07-10 11:58:24 | ERROR | stderr | File "/home/bofei-zhang/Documents/Project/Projects/Multimodal-CL/nips_0601/FIRE/src/serve/gradio_block_arena_named.py", line 282, in bot_response_multi
|
192 |
+
2024-07-10 11:58:24 | ERROR | stderr | ret = next(gen[i])
|
193 |
+
2024-07-10 11:58:24 | ERROR | stderr | File "/home/bofei-zhang/Documents/Project/Projects/Multimodal-CL/nips_0601/FIRE/src/serve/gradio_web_server.py", line 602, in bot_response
|
194 |
+
2024-07-10 11:58:24 | ERROR | stderr | "state": state.dict(),
|
195 |
+
2024-07-10 11:58:24 | ERROR | stderr | File "/home/bofei-zhang/Documents/Project/Projects/Multimodal-CL/nips_0601/FIRE/src/serve/gradio_web_server.py", line 129, in dict
|
196 |
+
2024-07-10 11:58:24 | ERROR | stderr | base = self.conv.dict()
|
197 |
+
2024-07-10 11:58:24 | ERROR | stderr | File "/home/bofei-zhang/Documents/Project/Projects/Multimodal-CL/nips_0601/FIRE/src/conversation.py", line 685, in dict
|
198 |
+
2024-07-10 11:58:24 | ERROR | stderr | "messages": self.extract_text_and_image_hashes_from_messages(),
|
199 |
+
2024-07-10 11:58:24 | ERROR | stderr | File "/home/bofei-zhang/Documents/Project/Projects/Multimodal-CL/nips_0601/FIRE/src/conversation.py", line 641, in extract_text_and_image_hashes_from_messages
|
200 |
+
2024-07-10 11:58:24 | ERROR | stderr | from fastchat.utils import load_image
|
201 |
+
2024-07-10 11:58:24 | ERROR | stderr | ModuleNotFoundError: No module named 'fastchat'
|
202 |
+
2024-07-10 11:58:32 | INFO | stdout | Keyboard interruption in main thread... closing server.
|
203 |
+
2024-07-10 11:58:33 | ERROR | stderr | Traceback (most recent call last):
|
204 |
+
2024-07-10 11:58:33 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 2553, in block_thread
|
205 |
+
2024-07-10 11:58:33 | ERROR | stderr | time.sleep(0.1)
|
206 |
+
2024-07-10 11:58:33 | ERROR | stderr | KeyboardInterrupt
|
207 |
+
2024-07-10 11:58:33 | ERROR | stderr |
|
208 |
+
2024-07-10 11:58:33 | ERROR | stderr | During handling of the above exception, another exception occurred:
|
209 |
+
2024-07-10 11:58:33 | ERROR | stderr |
|
210 |
+
2024-07-10 11:58:33 | ERROR | stderr | Traceback (most recent call last):
|
211 |
+
2024-07-10 11:58:33 | ERROR | stderr | File "/home/bofei-zhang/Documents/Project/Projects/Multimodal-CL/nips_0601/FIRE/app.py", line 16, in <module>
|
212 |
+
2024-07-10 11:58:33 | ERROR | stderr | demo.launch()
|
213 |
+
2024-07-10 11:58:33 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 2458, in launch
|
214 |
+
2024-07-10 11:58:33 | ERROR | stderr | self.block_thread()
|
215 |
+
2024-07-10 11:58:33 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 2557, in block_thread
|
216 |
+
2024-07-10 11:58:33 | ERROR | stderr | self.server.close()
|
217 |
+
2024-07-10 11:58:33 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/http_server.py", line 68, in close
|
218 |
+
2024-07-10 11:58:33 | ERROR | stderr | self.thread.join(timeout=5)
|
219 |
+
2024-07-10 11:58:33 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/threading.py", line 1100, in join
|
220 |
+
2024-07-10 11:58:33 | ERROR | stderr | self._wait_for_tstate_lock(timeout=max(timeout, 0))
|
221 |
+
2024-07-10 11:58:33 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/threading.py", line 1116, in _wait_for_tstate_lock
|
222 |
+
2024-07-10 11:58:33 | ERROR | stderr | if lock.acquire(block, timeout):
|
223 |
+
2024-07-10 11:58:33 | ERROR | stderr | KeyboardInterrupt
|
224 |
+
2024-07-10 11:58:38 | INFO | stdout | Running on local URL: http://127.0.0.1:7860
|
225 |
+
2024-07-10 11:58:38 | INFO | stdout |
|
226 |
+
2024-07-10 11:58:38 | INFO | stdout | To create a public link, set `share=True` in `launch()`.
|
227 |
+
2024-07-10 11:58:46 | INFO | gradio_web_server | bot_response. ip: 127.0.0.1
|
228 |
+
2024-07-10 11:58:46 | INFO | gradio_web_server | monitor error: Extra data: line 1 column 5 (char 4)
|
229 |
+
2024-07-10 11:58:46 | INFO | gradio_web_server | model_name: llava-fire;model_api_dict: None
|
230 |
+
2024-07-10 11:58:46 | INFO | gradio_web_server | bot_response. ip: 127.0.0.1
|
231 |
+
2024-07-10 11:58:46 | INFO | gradio_web_server | monitor error: Extra data: line 1 column 5 (char 4)
|
232 |
+
2024-07-10 11:58:46 | INFO | gradio_web_server | model_name: llava-original;model_api_dict: None
|
233 |
+
2024-07-10 11:58:46 | INFO | gradio_web_server | hello
|
234 |
+
2024-07-10 11:58:46 | INFO | gradio_web_server | hello
|
235 |
+
2024-07-10 12:01:16 | INFO | stdout | Keyboard interruption in main thread... closing server.
|
236 |
+
2024-07-10 12:01:17 | ERROR | stderr | Traceback (most recent call last):
|
237 |
+
2024-07-10 12:01:17 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 2553, in block_thread
|
238 |
+
2024-07-10 12:01:17 | ERROR | stderr | time.sleep(0.1)
|
239 |
+
2024-07-10 12:01:17 | ERROR | stderr | KeyboardInterrupt
|
240 |
+
2024-07-10 12:01:17 | ERROR | stderr |
|
241 |
+
2024-07-10 12:01:17 | ERROR | stderr | During handling of the above exception, another exception occurred:
|
242 |
+
2024-07-10 12:01:17 | ERROR | stderr |
|
243 |
+
2024-07-10 12:01:17 | ERROR | stderr | Traceback (most recent call last):
|
244 |
+
2024-07-10 12:01:17 | ERROR | stderr | File "/home/bofei-zhang/Documents/Project/Projects/Multimodal-CL/nips_0601/FIRE/app.py", line 16, in <module>
|
245 |
+
2024-07-10 12:01:17 | ERROR | stderr | )
|
246 |
+
2024-07-10 12:01:17 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 2458, in launch
|
247 |
+
2024-07-10 12:01:17 | ERROR | stderr | self.block_thread()
|
248 |
+
2024-07-10 12:01:17 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/blocks.py", line 2557, in block_thread
|
249 |
+
2024-07-10 12:01:17 | ERROR | stderr | self.server.close()
|
250 |
+
2024-07-10 12:01:17 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/site-packages/gradio/http_server.py", line 68, in close
|
251 |
+
2024-07-10 12:01:17 | ERROR | stderr | self.thread.join(timeout=5)
|
252 |
+
2024-07-10 12:01:17 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/threading.py", line 1100, in join
|
253 |
+
2024-07-10 12:01:17 | ERROR | stderr | self._wait_for_tstate_lock(timeout=max(timeout, 0))
|
254 |
+
2024-07-10 12:01:17 | ERROR | stderr | File "/home/bofei-zhang/miniconda3/envs/fire_demo/lib/python3.10/threading.py", line 1116, in _wait_for_tstate_lock
|
255 |
+
2024-07-10 12:01:17 | ERROR | stderr | if lock.acquire(block, timeout):
|
256 |
+
2024-07-10 12:01:17 | ERROR | stderr | KeyboardInterrupt
|
gradio_web_server_multi.log
ADDED
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
2024-07-10 11:54:17 | INFO | gradio_web_server_multi | add_text (named). ip: 127.0.0.1. len: 5
|
2 |
+
2024-07-10 11:54:17 | INFO | gradio_web_server_multi | bot_response_multi (named). ip: 127.0.0.1
|
3 |
+
2024-07-10 11:56:37 | INFO | gradio_web_server_multi | add_text (named). ip: 127.0.0.1. len: 5
|
4 |
+
2024-07-10 11:56:38 | INFO | gradio_web_server_multi | bot_response_multi (named). ip: 127.0.0.1
|
5 |
+
2024-07-10 11:57:22 | INFO | gradio_web_server_multi | add_text (named). ip: 127.0.0.1. len: 6
|
6 |
+
2024-07-10 11:57:23 | INFO | gradio_web_server_multi | bot_response_multi (named). ip: 127.0.0.1
|
7 |
+
2024-07-10 11:58:24 | INFO | gradio_web_server_multi | add_text (named). ip: 127.0.0.1. len: 5
|
8 |
+
2024-07-10 11:58:24 | INFO | gradio_web_server_multi | bot_response_multi (named). ip: 127.0.0.1
|
9 |
+
2024-07-10 11:58:46 | INFO | gradio_web_server_multi | add_text (named). ip: 127.0.0.1. len: 5
|
10 |
+
2024-07-10 11:58:46 | INFO | gradio_web_server_multi | bot_response_multi (named). ip: 127.0.0.1
|
src/__pycache__/conversation.cpython-310.pyc
CHANGED
Binary files a/src/__pycache__/conversation.cpython-310.pyc and b/src/__pycache__/conversation.cpython-310.pyc differ
|
|
src/conversation.py
CHANGED
@@ -605,8 +605,8 @@ class Conversation:
|
|
605 |
|
606 |
def save_new_images(self, has_csam_images=False, use_remote_storage=False):
|
607 |
import hashlib
|
608 |
-
from
|
609 |
-
from
|
610 |
|
611 |
_, last_user_message = self.messages[-2]
|
612 |
|
@@ -638,7 +638,7 @@ class Conversation:
|
|
638 |
|
639 |
def extract_text_and_image_hashes_from_messages(self):
|
640 |
import hashlib
|
641 |
-
from
|
642 |
|
643 |
messages = []
|
644 |
|
|
|
605 |
|
606 |
def save_new_images(self, has_csam_images=False, use_remote_storage=False):
|
607 |
import hashlib
|
608 |
+
from src.constants import LOGDIR
|
609 |
+
from src.utils import load_image, upload_image_file_to_gcs
|
610 |
|
611 |
_, last_user_message = self.messages[-2]
|
612 |
|
|
|
638 |
|
639 |
def extract_text_and_image_hashes_from_messages(self):
|
640 |
import hashlib
|
641 |
+
from src.utils import load_image
|
642 |
|
643 |
messages = []
|
644 |
|
src/model/__pycache__/__init__.cpython-310.pyc
CHANGED
Binary files a/src/model/__pycache__/__init__.cpython-310.pyc and b/src/model/__pycache__/__init__.cpython-310.pyc differ
|
|
src/model/__pycache__/model_falcon.cpython-310.pyc
CHANGED
Binary files a/src/model/__pycache__/model_falcon.cpython-310.pyc and b/src/model/__pycache__/model_falcon.cpython-310.pyc differ
|
|
src/model/__pycache__/model_yuan2.cpython-310.pyc
CHANGED
Binary files a/src/model/__pycache__/model_yuan2.cpython-310.pyc and b/src/model/__pycache__/model_yuan2.cpython-310.pyc differ
|
|
src/serve/__pycache__/api_provider.cpython-310.pyc
CHANGED
Binary files a/src/serve/__pycache__/api_provider.cpython-310.pyc and b/src/serve/__pycache__/api_provider.cpython-310.pyc differ
|
|
src/serve/__pycache__/gradio_block_arena_named.cpython-310.pyc
CHANGED
Binary files a/src/serve/__pycache__/gradio_block_arena_named.cpython-310.pyc and b/src/serve/__pycache__/gradio_block_arena_named.cpython-310.pyc differ
|
|
src/serve/__pycache__/gradio_block_arena_vision_named.cpython-310.pyc
CHANGED
Binary files a/src/serve/__pycache__/gradio_block_arena_vision_named.cpython-310.pyc and b/src/serve/__pycache__/gradio_block_arena_vision_named.cpython-310.pyc differ
|
|
src/serve/__pycache__/gradio_web_server.cpython-310.pyc
CHANGED
Binary files a/src/serve/__pycache__/gradio_web_server.cpython-310.pyc and b/src/serve/__pycache__/gradio_web_server.cpython-310.pyc differ
|
|
src/serve/gradio_web_server.py
CHANGED
@@ -449,49 +449,54 @@ def bot_response(
|
|
449 |
api_endpoint_info[model_name] if model_name in api_endpoint_info else None
|
450 |
)
|
451 |
images = conv.get_images()
|
452 |
-
|
453 |
if model_api_dict is None:
|
|
|
|
|
|
|
|
|
|
|
454 |
# Query worker address
|
455 |
-
ret = requests.post(
|
456 |
-
|
457 |
-
)
|
458 |
-
worker_addr = ret.json()["address"]
|
459 |
-
logger.info(f"model_name: {model_name}, worker_addr: {worker_addr}")
|
460 |
-
|
461 |
-
# No available worker
|
462 |
-
if worker_addr == "":
|
463 |
-
|
464 |
-
|
465 |
-
|
466 |
-
|
467 |
-
|
468 |
-
|
469 |
-
|
470 |
-
|
471 |
-
|
472 |
-
|
473 |
-
|
474 |
-
|
475 |
-
# Construct prompt.
|
476 |
-
# We need to call it here, so it will not be affected by "▌".
|
477 |
-
prompt = conv.get_prompt()
|
478 |
-
# Set repetition_penalty
|
479 |
-
if "t5" in model_name:
|
480 |
-
|
481 |
-
else:
|
482 |
-
|
483 |
-
|
484 |
-
stream_iter = model_worker_stream_iter(
|
485 |
-
|
486 |
-
|
487 |
-
|
488 |
-
|
489 |
-
|
490 |
-
|
491 |
-
|
492 |
-
|
493 |
-
|
494 |
-
)
|
495 |
else:
|
496 |
if use_recommended_config:
|
497 |
recommended_config = model_api_dict.get("recommended_config", None)
|
@@ -502,15 +507,19 @@ def bot_response(
|
|
502 |
"max_new_tokens", max_new_tokens
|
503 |
)
|
504 |
|
505 |
-
stream_iter =
|
506 |
-
|
507 |
-
|
508 |
-
|
509 |
-
|
510 |
-
|
511 |
-
|
512 |
-
|
513 |
-
|
|
|
|
|
|
|
|
|
514 |
|
515 |
html_code = ' <span class="cursor"></span> '
|
516 |
|
|
|
449 |
api_endpoint_info[model_name] if model_name in api_endpoint_info else None
|
450 |
)
|
451 |
images = conv.get_images()
|
452 |
+
logger.info(f"model_name: {model_name};model_api_dict: {model_api_dict}")
|
453 |
if model_api_dict is None:
|
454 |
+
|
455 |
+
stream_iter = [{
|
456 |
+
"error_code": 0,
|
457 |
+
"text": "hello"
|
458 |
+
}]
|
459 |
# Query worker address
|
460 |
+
# ret = requests.post(
|
461 |
+
# controller_url + "/get_worker_address", json={"model": model_name}
|
462 |
+
# )
|
463 |
+
# worker_addr = ret.json()["address"]
|
464 |
+
# logger.info(f"model_name: {model_name}, worker_addr: {worker_addr}")
|
465 |
+
|
466 |
+
# # No available worker
|
467 |
+
# if worker_addr == "":
|
468 |
+
# conv.update_last_message(SERVER_ERROR_MSG)
|
469 |
+
# yield (
|
470 |
+
# state,
|
471 |
+
# state.to_gradio_chatbot(),
|
472 |
+
# disable_btn,
|
473 |
+
# disable_btn,
|
474 |
+
# disable_btn,
|
475 |
+
# enable_btn,
|
476 |
+
# enable_btn,
|
477 |
+
# )
|
478 |
+
# return
|
479 |
+
|
480 |
+
# # Construct prompt.
|
481 |
+
# # We need to call it here, so it will not be affected by "▌".
|
482 |
+
# prompt = conv.get_prompt()
|
483 |
+
# # Set repetition_penalty
|
484 |
+
# if "t5" in model_name:
|
485 |
+
# repetition_penalty = 1.2
|
486 |
+
# else:
|
487 |
+
# repetition_penalty = 1.0
|
488 |
+
|
489 |
+
# stream_iter = model_worker_stream_iter(
|
490 |
+
# conv,
|
491 |
+
# model_name,
|
492 |
+
# worker_addr,
|
493 |
+
# prompt,
|
494 |
+
# temperature,
|
495 |
+
# repetition_penalty,
|
496 |
+
# top_p,
|
497 |
+
# max_new_tokens,
|
498 |
+
# images,
|
499 |
+
# )
|
500 |
else:
|
501 |
if use_recommended_config:
|
502 |
recommended_config = model_api_dict.get("recommended_config", None)
|
|
|
507 |
"max_new_tokens", max_new_tokens
|
508 |
)
|
509 |
|
510 |
+
stream_iter = [{
|
511 |
+
"error_code": 0,
|
512 |
+
"text": "hello"
|
513 |
+
}]
|
514 |
+
# stream_iter = get_api_provider_stream_iter(
|
515 |
+
# conv,
|
516 |
+
# model_name,
|
517 |
+
# model_api_dict,
|
518 |
+
# temperature,
|
519 |
+
# top_p,
|
520 |
+
# max_new_tokens,
|
521 |
+
# state,
|
522 |
+
# )
|
523 |
|
524 |
html_code = ' <span class="cursor"></span> '
|
525 |
|
vision-tmp-2024-07-10-conv.json
ADDED
@@ -0,0 +1,2 @@
|
|
|
|
|
|
|
1 |
+
{"tstamp": 1720583926.6994, "type": "chat", "model": "llava-fire", "gen_params": {"temperature": 0.7, "top_p": 1.0, "max_new_tokens": 1024}, "start": 1720583926.678, "finish": 1720583926.6994, "state": {"template_name": "vicuna_v1.1", "system_message": "A chat between a curious user and an artificial intelligence assistant. The assistant gives helpful, detailed, and polite answers to the user's questions.", "roles": ["USER", "ASSISTANT"], "messages": [["USER", "Hello"], ["ASSISTANT", "hello"]], "offset": 0, "conv_id": "a48164214dce453a9ad276401b7d095c", "model_name": "llava-fire", "has_csam_image": false}, "ip": "127.0.0.1"}
|
2 |
+
{"tstamp": 1720583926.6998, "type": "chat", "model": "llava-original", "gen_params": {"temperature": 0.7, "top_p": 1.0, "max_new_tokens": 1024}, "start": 1720583926.6815, "finish": 1720583926.6998, "state": {"template_name": "vicuna_v1.1", "system_message": "A chat between a curious user and an artificial intelligence assistant. The assistant gives helpful, detailed, and polite answers to the user's questions.", "roles": ["USER", "ASSISTANT"], "messages": [["USER", "Hello"], ["ASSISTANT", "hello"]], "offset": 0, "conv_id": "8bed262a5728409284a7a56a0fe66a75", "model_name": "llava-original", "has_csam_image": false}, "ip": "127.0.0.1"}
|