Git Product home page Git Product logo

Comments (10)

xinntao avatar xinntao commented on July 28, 2024 2

It is an interesting problem. It is probably raised from the different distributions of the training data and testing data.

from edvr.

yinnhao avatar yinnhao commented on July 28, 2024 1

@xinntao I solved this problem by finetuning your pretrained model using 'train_EDVR_M.yml'. But what surprised me was that I only used one video during the finetune process, monitoring the artifacts slowly disappearing. Then the new model work well on 99% video in my dataset without artifacts( too large offset mean is basically not present), although these video content vary greatly. So I have two questions:

Do you think this is because the model learned how to understand unnatural scene in the the finetune process with only one video? (I found out that noise is mostly in unnatural areas.)
The TSA module is behind the DCN module, so finutuning TSA influence DCN by back propagation? I can't understand why is the TSA module so powerful?

from edvr.

xinntao avatar xinntao commented on July 28, 2024 1

@hahahaprince

  1. I think so. Before the finetuning process, the pre-trained EDVR network has not seen these data and thus produces artifacts. Although with only one video during finetuning, the model learns to deal with these scenes.
  2. Did you perform the fine-tuning on all the parameters? If you use the train_EDVR_M.yml, it will fine tune all the parameters.

@Mukosame
You can finetune the pre-trained model using your own data, as @hahahaprince does.

from edvr.

xinntao avatar xinntao commented on July 28, 2024

Oh, it is a severe artifact. Do these artifacts appear when testing with Vid4 or REDS dataset?

It may raise from the different distributions of the datasets. But they are usually related to BN layers. However, there is no BN layer in the EDVR model.

from edvr.

yinnhao avatar yinnhao commented on July 28, 2024

Oh, it is a severe artifact. Do these artifacts appear when testing with Vid4 or REDS dataset?

It may raise from the different distributions of the datasets. But they are usually related to BN layers. However, there is no BN layer in the EDVR model.

Artifacts doesn't appear in Vid4 or REDS dataset, and it mostly appears in unnatural scenes.

from edvr.

yinnhao avatar yinnhao commented on July 28, 2024

It is an interesting problem. It is probably raised from the different distributions of the training data and testing data.

Hi, xinntao. I found that this artifacts become more severe when the offset mean is larger than 100. Can you give me some advice about how to guarantee the value of the offset when training? I found increasing input image size (deblur task) can alleviate this situation to some extent.

from edvr.

xinntao avatar xinntao commented on July 28, 2024

If the offset mean is large than 100, the offsets must be meaningless. This is an issue of DCN for alignment - unstable training. Usually, we can finetune a pre-trained model with a smaller learning rate for those conv layers that predicts the offsets.

Sometimes, the too large offset mean occurs occasionally. In this case, we just stop it and resume it from a model whose offset prediction is normal.

from edvr.

Mukosame avatar Mukosame commented on July 28, 2024

+1, same artifacts too.

from edvr.

sjscotti avatar sjscotti commented on July 28, 2024

@hahahaprince I am using the EDVR_REDS_deblurcomp_L.pth model and I am getting similar artifacts in some of the videos I am processing with EDVR. Are you doing blur_comp processing too, and if so, would you be willing to share your modified model?

from edvr.

vlee-harmonicinc avatar vlee-harmonicinc commented on July 28, 2024

I also encounter this artifact without offset mean > 100.
How to visualize Ablation on the PCD or TSA like figure 8 and figure 9 in the paper?

I visualized the offset by displaying the max offset of all channels (8 groups x3x3 kernel size) in ModulatedDeformConvPack relative to the width and height of current layer
edit: My previous code of parsing offset xy coordinates was incorrect. I checked the cuda code and guessed the offset format should be deformable group, kernel 3, 3, x,y, H, W (please correct me if I misunderstand the offset)

        if VISUALIZE_OFFSET:
            offset_x = torch.max(torch.abs(offset_view[:,:,:,0,:,:]).view([-1, H, W]), dim=0)[0]/H
            offset_y = torch.max(torch.abs(offset_view[:,:,:,1,:,:]).view([-1, H, W]), dim=0)[0]/W
            padding = torch.zeros([H,W], dtype=offset.dtype).to(offset.get_device())
            offset_tensor_img = torch.stack([offset_x, padding, offset_y])
            next_index = len(glob.glob(os.path.join(self.offset_output_folder, '*.png')))
            torchvision.utils.save_image(offset_tensor_img, os.path.join(self.offset_output_folder, f'{next_index:05d}.png'))

image
image
image
It seems that it is introduce by offset (even thought the mean of offset is below 1, the offset of specific pixel region or one deformable group is high.
According to NTIRE 2019 Challenge on Video Deblurring and Super-Resolution: Dataset and Study, REDS datasets synthesize motion blur via increasing the frame rate to virtual 1920 fps by recursively interpolating the frames with CNN. It seems quite complex, and I haven't high-quality version of target video for training. Is it possible to fine-tune / transfer pre-trained model from general unpaired datasets?
----------update--------
I'm fine-tuning EDVR_REDS_deblurcomp_L model. I cannot stop and resume reply on the offset warning since it keep showing from the begining. I saved val_images, it show something like below after 55000 iter (still epoch 1).
image
Is it possible that the problem happen when CosineAnnealingLR_Restart restart?

from edvr.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.