alex commited on
Commit
eceec4c
·
1 Parent(s): e067264

progress bar removed

Browse files
Files changed (1) hide show
  1. app.py +6 -6
app.py CHANGED
@@ -114,7 +114,7 @@ def restore_inductor_cache_from_hub(repo_id: str, filename: str = "torch_compile
114
  # restore_inductor_cache_from_hub("alexnasa/humo-compiled")
115
 
116
 
117
- def get_duration(prompt_text, steps, image_file, audio_file_path, tea_cache_l1_thresh, max_duration, session_id, progress):
118
 
119
  return calculate_required_time(steps, max_duration)
120
 
@@ -147,7 +147,7 @@ def update_required_time(steps, max_duration):
147
  return get_required_time_string(steps, max_duration)
148
 
149
 
150
- def generate_scene(prompt_text, steps, image_paths, audio_file_path, tea_cache_l1_thresh, max_duration = 2, session_id = None, progress=gr.Progress(track_tqdm=True)):
151
 
152
  print(image_paths)
153
  prompt_text_check = (prompt_text or "").strip()
@@ -157,12 +157,12 @@ def generate_scene(prompt_text, steps, image_paths, audio_file_path, tea_cache_l
157
  if not audio_file_path and not image_paths:
158
  raise gr.Error("Please provide a reference image or a lipsync audio.")
159
 
160
- return run_pipeline(prompt_text, steps, image_paths, audio_file_path, tea_cache_l1_thresh, max_duration, session_id, progress)
161
 
162
 
163
- def generate_example(prompt_text, steps, image_paths, audio_file_path, tea_cache_l1_thresh = 0.0, max_duration = 4, session_id = None, progress=gr.Progress(track_tqdm=True)):
164
 
165
- return run_pipeline(prompt_text, steps, image_paths, audio_file_path, tea_cache_l1_thresh, max_duration, session_id, progress)
166
 
167
  def upload_inductor_cache_to_hub(
168
  repo_id: str,
@@ -216,7 +216,7 @@ def upload_inductor_cache_to_hub(
216
 
217
 
218
  @spaces.GPU(duration=get_duration)
219
- def run_pipeline(prompt_text, steps, image_paths, audio_file_path, tea_cache_l1_thresh = 0.0, max_duration = 2, session_id = None, progress=gr.Progress(track_tqdm=True)):
220
 
221
  if session_id is None:
222
  session_id = uuid.uuid4().hex
 
114
  # restore_inductor_cache_from_hub("alexnasa/humo-compiled")
115
 
116
 
117
+ def get_duration(prompt_text, steps, image_file, audio_file_path, tea_cache_l1_thresh, max_duration, session_id):
118
 
119
  return calculate_required_time(steps, max_duration)
120
 
 
147
  return get_required_time_string(steps, max_duration)
148
 
149
 
150
+ def generate_scene(prompt_text, steps, image_paths, audio_file_path, tea_cache_l1_thresh, max_duration = 2, session_id = None):
151
 
152
  print(image_paths)
153
  prompt_text_check = (prompt_text or "").strip()
 
157
  if not audio_file_path and not image_paths:
158
  raise gr.Error("Please provide a reference image or a lipsync audio.")
159
 
160
+ return run_pipeline(prompt_text, steps, image_paths, audio_file_path, tea_cache_l1_thresh, max_duration, session_id)
161
 
162
 
163
+ def generate_example(prompt_text, steps, image_paths, audio_file_path, tea_cache_l1_thresh = 0.0, max_duration = 4, session_id = None):
164
 
165
+ return run_pipeline(prompt_text, steps, image_paths, audio_file_path, tea_cache_l1_thresh, max_duration, session_id)
166
 
167
  def upload_inductor_cache_to_hub(
168
  repo_id: str,
 
216
 
217
 
218
  @spaces.GPU(duration=get_duration)
219
+ def run_pipeline(prompt_text, steps, image_paths, audio_file_path, tea_cache_l1_thresh = 0.0, max_duration = 2, session_id = None):
220
 
221
  if session_id is None:
222
  session_id = uuid.uuid4().hex