mcahny / Deep-Video-Inpainting

Official pytorch implementation for "Deep Video Inpainting" (CVPR 2019)
508 stars 95 forks source link

Multiplication factor of 5 in the loss function of train_git.py #32

Open VjayalakshmiK opened 3 years ago

VjayalakshmiK commented 3 years ago

I need a clarification regarding the following: In line 96 of train_git.py, which calculates HOLE_loss, the L1 loss is multiplied by 5 before accumulating in HOLE_loss variable. Is this because there are 5 input frames?

Line 96, for reference

HOLE_loss += 5*criterion_L1(
            frame_o1*frame_m[0][:,:,midx,:,:].expand_as(frame_o1), 
            frame_i[0]*frame_m[0][:,:,midx,:,:].expand_as(frame_o1))

If yes, if I were to use just 1 past and 1 future frame (3 input frames), can I change that factor to 3?