sindhuhegde commited on
Commit
7406842
1 Parent(s): 3257615

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -185,7 +185,7 @@ def crop_video(avi_dir, tmp_dir, track, cropfile, tight_scale=1):
185
 
186
  return {'track': track, 'proc_track': dets}
187
 
188
- @spaces.GPU(duration=140)
189
  def inference_video(avi_dir, work_dir, padding=0):
190
  videofile = os.path.join(avi_dir, 'video.avi')
191
  vidObj = cv2.VideoCapture(videofile)
@@ -357,7 +357,7 @@ def process_video_asd(file, sd_root, work_root, data_root, avi_dir, tmp_dir, wor
357
 
358
 
359
 
360
- @spaces.GPU(duration=140)
361
  def preprocess_video(path, result_folder, apply_preprocess, padding=20):
362
 
363
  '''
@@ -1066,7 +1066,7 @@ def extract_audio(video, result_folder):
1066
 
1067
  return wav_file, "success"
1068
 
1069
- @spaces.GPU(duration=140)
1070
  def get_embeddings(video_sequences, audio_sequences, model, calc_aud_emb=True):
1071
 
1072
  '''
@@ -1082,7 +1082,7 @@ def get_embeddings(video_sequences, audio_sequences, model, calc_aud_emb=True):
1082
  - audio_emb (array) : Audio embedding
1083
  '''
1084
 
1085
- batch_size = 12
1086
  video_emb = []
1087
  audio_emb = []
1088
 
 
185
 
186
  return {'track': track, 'proc_track': dets}
187
 
188
+ @spaces.GPU(duration=60)
189
  def inference_video(avi_dir, work_dir, padding=0):
190
  videofile = os.path.join(avi_dir, 'video.avi')
191
  vidObj = cv2.VideoCapture(videofile)
 
357
 
358
 
359
 
360
+ @spaces.GPU(duration=60)
361
  def preprocess_video(path, result_folder, apply_preprocess, padding=20):
362
 
363
  '''
 
1066
 
1067
  return wav_file, "success"
1068
 
1069
+ @spaces.GPU(duration=60)
1070
  def get_embeddings(video_sequences, audio_sequences, model, calc_aud_emb=True):
1071
 
1072
  '''
 
1082
  - audio_emb (array) : Audio embedding
1083
  '''
1084
 
1085
+ batch_size = 48
1086
  video_emb = []
1087
  audio_emb = []
1088