Joint-Bilateral-Learning icon indicating copy to clipboard operation
Joint-Bilateral-Learning copied to clipboard

test error

Open mzprose opened this issue 4 years ago • 2 comments

Hello,there is a problem when I run test.py: Traceback (most recent call last): File "test.py", line 67, in test(params) File "test.py", line 42, in test cont_feat = net.encode_with_intermediate(low_cont) "RuntimeError: Expected 4-dimensional input for 4-dimensional weight 3 3 1 1, but got 3-dimensional input of size [3, 256, 256] instead"

input :single image

could you help me?

mzprose avatar Jul 10 '20 06:07 mzprose

modify the code like that: cont_feat = net.encode_with_intermediate(low_cont.unsqueeze(0)) style_feat = net.encode_with_intermediate(low_style.unsqueeze(0)) coeffs, output = model(cont_img.unsqueeze(0), cont_feat, style_feat)

mousecpn avatar Jul 12 '20 01:07 mousecpn

thank you,problem solved successfully.

mzprose avatar Jul 13 '20 02:07 mzprose