yinboc / liif

Learning Continuous Image Representation with Local Implicit Image Function, in CVPR 2021 (Oral)
https://yinboc.github.io/liif/
BSD 3-Clause "New" or "Revised" License
1.26k stars 145 forks source link

stack expects each tensor to be equal size, but got [3, 256, 256] at entry 0 and [3, 144, 144] at entry 1 #11

Closed ArcobalenoX closed 3 years ago

ArcobalenoX commented 3 years ago

when I "python test.py --config ./configs/test/test-set5-2.yaml --model edsr-baseline-liif.pth --gpu 0" it errors that—— stack expects each tensor to be equal size, but got [3, 256, 256] at entry 0 and [3, 144, 144] at entry 1

it means all image should have same shape?

yinboc commented 3 years ago

The config test-set5-2.yaml has the batch size of 1 and the code above should work, did you follow the setting in the instructions or did you modifiy anything? Also note that the evaluation batch size should be 1 for correct PSNR computation.

ArcobalenoX commented 3 years ago

oh,my wrong. that works,very thanks!

yinboc commented 3 years ago

You're welcome.