Open antithing opened 1 year ago
Hi @antithing,
With the provided logs, there might be something wrong with your environment. More specifically, some packages are not correctly installed. You may refer to the Colab notebook for the installation.
Hope this can help you.
Hi, thanks! I have run the install.sh steps again, and i no longer see the warning Cannot inport EDVR modules!!!
. The result is:
[('00002.jpg',)] torch.Size([1, 3, 1080, 1920])
[('00003.jpg',)] torch.Size([1, 3, 1080, 1920])
But the frames are still black!
Is this line correct?
` cv2.imwrite(save_image_path, out[0].cpu().permute(1, 2, 0).numpy())``
Hi @antithing, I will check what happened and update the results here ASAP.
Hi @antithing, sorry for the late reply.
This problem can be attributed to the saving function cv2.imwrite
. You should scale the image range to [0, 255] for saving with cv2.imwrite
to avoid the black image. I also updated a video inference demo code https://github.com/ljzycmd/SimDeblur/blob/main/inference_video.py, and you can infer the sharp frames with:
python inference_video.py \
CONFIG_PATH \
CKPT_PATH \
--frames_folder_path FRAME_FOLDER_PATH \
--save_dir OUTPUT_ROOT
Note that the FRAME_FOLDER_PATH
should contain consecutive video frames, you may ffmepg
to split a blurry video into separate frames.
Hope this can help you.
Hi, and thank you for making this code available!
I am running:
python video_infer.py D:\\DeBlur\\SimDeblur-main\\SimDeblur-main\\configs\\dbn\\dbn_gopro.yaml D:\\DeBlur\\SimDeblur-main\\SimDeblur-main\\saves\\checkpoints\\DBN\\dbn_ckpt.pth --frames_folder_path=datasets/input --save_path=deblur
where video_infer.py is:
The code runs, and prints:
But all the resulting frames are just solid black. What might be happening here?
Thanks!