Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -139,9 +139,8 @@ def separation_content_motion(video_clip):
the second is motions based on base frame
"""
total_frames = video_clip.shape[1]
base_frame = video_clip[0]
motions = [video_clip[i] - base_frame for i in range(1, total_frames)]
motions = torch.cat(motions, dim=1)
base_frame = video_clip[:, 0:1] # [B, 1, C, H, W]
motions = video_clip[:, 1:] - video_clip[:, 0:1] # [B, F-1, C, H, W]
return base_frame, motions

def get_experiment_dir(root_dir, args):
Expand Down