Skip to content

Commit

Permalink
Merge pull request PaddlePaddle#35 from lijianshe02/master
Browse files Browse the repository at this point in the history
add adaptive frames interpolation after deduplicate frames
  • Loading branch information
lijianshe02 authored Oct 14, 2020
2 parents 9ce257c + b3118d7 commit 5500675
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions applications/DAIN/predict.py
Original file line number Diff line number Diff line change
Expand Up @@ -139,8 +139,14 @@ def run(self):
end = time.time()

frames = sorted(glob.glob(os.path.join(out_path, '*.png')))
orig_frames = len(frames)
need_frames = orig_frames * times_interp

if remove_duplicates:
frames = remove_duplicates(out_path)
left_frames = len(frames)
timestep = left_frames / need_frames
num_frames = int(1.0 / timestep) - 1

img = imread(frames[0])

Expand Down

0 comments on commit 5500675

Please sign in to comment.