chenjoya commited on
Commit
d181208
·
verified ·
1 Parent(s): 641455e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -1,6 +1,7 @@
1
  import spaces, os
2
  import gradio as gr
3
  from kokoro import KPipeline
 
4
 
5
  from demo.infer import LiveCCDemoInfer
6
 
@@ -57,11 +58,11 @@ with gr.Blocks() as demo:
57
  @spaces.GPU
58
  def gr_chatinterface_fn(message, history, state, video_path, mode):
59
  global infer
60
- yield 'initializing model, thanks for waiting...', state
61
  if infer is None:
62
  infer = _init_infer()
63
  state['video_path'] = video_path
64
- yield 'finished initialization, responding...', state
65
  if mode != 'Conversation':
66
  yield 'waiting video input...', state
67
  query = message
 
1
  import spaces, os
2
  import gradio as gr
3
  from kokoro import KPipeline
4
+ from qwen_vl_utils import process_vision_info
5
 
6
  from demo.infer import LiveCCDemoInfer
7
 
 
58
  @spaces.GPU
59
  def gr_chatinterface_fn(message, history, state, video_path, mode):
60
  global infer
61
+ yield '(initializing model, thanks for waiting...)', state
62
  if infer is None:
63
  infer = _init_infer()
64
  state['video_path'] = video_path
65
+ yield '(finished initialization, responding...)', state
66
  if mode != 'Conversation':
67
  yield 'waiting video input...', state
68
  query = message