open-mmlab / mmagic

OpenMMLab Multimodal Advanced, Generative, and Intelligent Creation Toolbox. Unlock the magic 🪄: Generative-AI (AIGC), easy-to-use APIs, awsome model zoo, diffusion models, for text-to-image generation, image/video restoration/enhancement, etc.
https://mmagic.readthedocs.io/en/latest/
Apache License 2.0
6.85k stars 1.05k forks source link

test error #947

Closed Winnie202 closed 1 year ago

Winnie202 commented 2 years ago

Please see why this error occur 2022-07-06 15-56-20屏幕截图 s

wangruohui commented 2 years ago

It indicates the error at line 224 of real_esrgan.py. So please print lq_path there to check, and also please check the lq_path in your config file.

Winnie202 commented 2 years ago

I got this kind of result after changing it according to similar code 2022-07-06 16-07-16屏幕截图 2022-07-06 16-08-47屏幕截图 I would like to know why it is not saved as separate sheets

Winnie202 commented 2 years ago

my obtained lq_path is a list,like this:['data/test/test_lq/001/0000.jpg', 'data/test/test_lq/001/0001.jpg', 'data/test/test_lq/001/0002.jpg', 'data/test/test_lq/001/0003.jpg', 'data/test/test_lq/001/0004.jpg']

wangruohui commented 2 years ago

This logic is written in tensor2img functon. If you want to save different frames as different image files, you can modify the part you paste here, i.e. the save image logic.

Winnie202 commented 2 years ago

是tensor2img函数和real_esrgan.py中的forward_test函数都需要修改对吗?另外我还想请问一下,训练时如下警告会不会对精度有影响 2022-07-06 17-32-26屏幕截图

wangruohui commented 2 years ago

第一个问题: if save_image 这个下面的就是存图的逻辑,你可以根据你的需求自由发挥,目前的代码大体来讲就是根据data里面的path确定存图的路径,再把4维数组拼成拼图的样子保存,你可以自己根据自己的需求改一下。

第二个问题: meshgrid是没什么影响的,我们近期也会做一个更新加入这个参数。 upsample应该不会影响因为realbasicvsr里面的upsample是2整倍,所以应该是不影响。

Winnie202 commented 2 years ago

感谢您的及时回复,给了我很大帮助

zengyh1900 commented 1 year ago

Closing due to inactivity, please reopen if there are any further problems.