Cheeun / AdaBM

[CVPR2024] Official Code for the "AdaBM: On-the-Fly Adaptive Bit Mapping for Image Super-Resolution"
29 stars 1 forks source link

SSIM calculate error #1

Open stefenmax opened 3 months ago

stefenmax commented 3 months ago

Hi, thanks for your work. When I want to reproduce the result using the DIV2K dataset. When calculate the ssim it raises the error File "/mnt/new_ssd/stefen/code/AdaBM/src/utility.py", line 265, in ssimmatlab (, _, height, width) = img1.size() ValueError: too many values to unpack (expected 4) When I check the dimension of imag1, it has 5. Should I remove the first dimension? Thanks (Pdb) img1.size() torch.Size([1, 1, 3, 1336, 2020])

stefenmax commented 3 months ago

Plus, when I comment the ssim and continue to train 100 epochs use the following line sh run.sh edsr 0 6 8 The average PSNR remain around 11.679, and the SR image looks not good. 0808_x4_10 21dB_5 31bit

Cheeun commented 3 months ago

Hi, thanks for your interest in our work! Could you check which type of data you are using for training? When I directly ran sh run.sh edsr 0 6 8, the data dimension was 4 instead of 5.

stefenmax commented 3 months ago

I used the DIV2K link you provided. It's PNG file

Cheeun commented 3 months ago

@stefenmax, sorry but I failed to reproduce your error. Could you post the command that you used?