pragnakalp commited on
Commit
94a264c
·
1 Parent(s): 8c20411

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -141,7 +141,7 @@ def one_shot_talking(image_in,audio_in):
141
  crop_src_image(image_in)
142
 
143
  #Improve quality of input image
144
- os.system(python /content/GFPGAN/inference_gfpgan.py --upscale 2 -i /content/image_pre.png -o /content/results --bg_upsampler realesrgan)
145
 
146
  image_in_one_shot='/content/results/restored_imgs/image_pre.png'
147
 
@@ -151,10 +151,10 @@ def one_shot_talking(image_in,audio_in):
151
  #Video Quality Improvement
152
 
153
  #1. Extract the frames from the video file using PyVideoFramesExtractor
154
- os.system(python /content/PyVideoFramesExtractor/extract.py --video=/content/train/image_pre_audio.mp4)
155
 
156
  #2. Improve image quality using GFPGAN on each frames
157
- os.system(python /content/GFPGAN/inference_gfpgan.py --upscale 2 -i /content/extracted_frames/image_pre_audio_frames -o /content/video_results --bg_upsampler realesrgan)
158
 
159
  #3. Merge all the frames to a one video using imageio
160
  merge_frames()
 
141
  crop_src_image(image_in)
142
 
143
  #Improve quality of input image
144
+ os.system(f"python /content/GFPGAN/inference_gfpgan.py --upscale 2 -i /content/image_pre.png -o /content/results --bg_upsampler realesrgan")
145
 
146
  image_in_one_shot='/content/results/restored_imgs/image_pre.png'
147
 
 
151
  #Video Quality Improvement
152
 
153
  #1. Extract the frames from the video file using PyVideoFramesExtractor
154
+ os.system(f"python /content/PyVideoFramesExtractor/extract.py --video=/content/train/image_pre_audio.mp4")
155
 
156
  #2. Improve image quality using GFPGAN on each frames
157
+ os.system(f"python /content/GFPGAN/inference_gfpgan.py --upscale 2 -i /content/extracted_frames/image_pre_audio_frames -o /content/video_results --bg_upsampler realesrgan")
158
 
159
  #3. Merge all the frames to a one video using imageio
160
  merge_frames()