tianleliphoebe commited on
Commit
340b8c3
1 Parent(s): 73eb3ef
Files changed (1) hide show
  1. serve/vote_utils.py +6 -6
serve/vote_utils.py CHANGED
@@ -926,7 +926,7 @@ def generate_vgm(gen_func, state0, state1, text, model_name0, model_name1, reque
926
  state0.model_name = model_name0
927
  state1.model_name = model_name1
928
 
929
- yield state0, state1, generated_video0, generated_video1
930
  print("====== model name =========")
931
  print(state0.model_name)
932
  print(state1.model_name)
@@ -976,7 +976,7 @@ def generate_vgm(gen_func, state0, state1, text, model_name0, model_name1, reque
976
  print(state.output.shape)
977
  imageio.mimwrite(output_file, state.output, fps=8, quality=9)
978
  save_video_file_on_log_server(output_file)
979
- # yield state0, state1, f'{VIDEO_DIR}/generation/{state0.conv_id}.mp4', f'{VIDEO_DIR}/generation/{state1.conv_id}.mp4'
980
 
981
 
982
  def generate_vgm_annoy(gen_func, state0, state1, text, model_name0, model_name1, request: gr.Request):
@@ -999,8 +999,8 @@ def generate_vgm_annoy(gen_func, state0, state1, text, model_name0, model_name1,
999
  state0.model_name = model_name0
1000
  state1.model_name = model_name1
1001
 
1002
- yield state0, state1, generated_video0, generated_video1, \
1003
- gr.Markdown(f"### Model A: {model_name0}"), gr.Markdown(f"### Model B: {model_name1}")
1004
 
1005
  finish_tstamp = time.time()
1006
  # logger.info(f"===output===: {output}")
@@ -1044,5 +1044,5 @@ def generate_vgm_annoy(gen_func, state0, state1, text, model_name0, model_name1,
1044
  imageio.mimwrite(output_file, state.output, fps=8, quality=9)
1045
  save_video_file_on_log_server(output_file)
1046
 
1047
- # yield state0, state1, f'{VIDEO_DIR}/generation/{state0.conv_id}.mp4', f'{VIDEO_DIR}/generation/{state1.conv_id}.mp4', \
1048
- # gr.Markdown(f"### Model A: {model_name0}"), gr.Markdown(f"### Model B: {model_name1}")
 
926
  state0.model_name = model_name0
927
  state1.model_name = model_name1
928
 
929
+ # yield state0, state1, generated_video0, generated_video1
930
  print("====== model name =========")
931
  print(state0.model_name)
932
  print(state1.model_name)
 
976
  print(state.output.shape)
977
  imageio.mimwrite(output_file, state.output, fps=8, quality=9)
978
  save_video_file_on_log_server(output_file)
979
+ yield state0, state1, f'{VIDEO_DIR}/generation/{state0.conv_id}.mp4', f'{VIDEO_DIR}/generation/{state1.conv_id}.mp4'
980
 
981
 
982
  def generate_vgm_annoy(gen_func, state0, state1, text, model_name0, model_name1, request: gr.Request):
 
999
  state0.model_name = model_name0
1000
  state1.model_name = model_name1
1001
 
1002
+ # yield state0, state1, generated_video0, generated_video1, \
1003
+ # gr.Markdown(f"### Model A: {model_name0}"), gr.Markdown(f"### Model B: {model_name1}")
1004
 
1005
  finish_tstamp = time.time()
1006
  # logger.info(f"===output===: {output}")
 
1044
  imageio.mimwrite(output_file, state.output, fps=8, quality=9)
1045
  save_video_file_on_log_server(output_file)
1046
 
1047
+ yield state0, state1, f'{VIDEO_DIR}/generation/{state0.conv_id}.mp4', f'{VIDEO_DIR}/generation/{state1.conv_id}.mp4', \
1048
+ gr.Markdown(f"### Model A: {model_name0}"), gr.Markdown(f"### Model B: {model_name1}")