The restored image after dc-ae encoding and decoding is unreasonable

#1
by elegy111 - opened

I did some encoding and decoding experiments on images with a resolution other than 512x512, but the results were very poor. Is it because the resolution is not 512?

MIT HAN Lab org

Hi elegy111,

Can you clarify which resolution you are using?

Thank you,
Han

I started by testing on a 960×720 image. But since 720 is not a multiple of 32, I cropped it to 960×704, but the result after encoding and decoding was terrible.

MIT HAN Lab org

Hi elegy111,

Could you please share the image you are using?

Thanks,
Junyu

test.jpg

I think maybe my data input or output parsing method is wrong. Do you have a script that can use DC-AE to directly perform encoding and decoding tests on images? Thanks.

MIT HAN Lab org

Hi elegy111,

The script is provided here. https://github.com/mit-han-lab/efficientvit/blob/5dd097d341a9cb2649733285d57e1efe6f35c0bd/applications/dc_ae/README.md?plain=1#L49

Note that the input to be passed to dc_ae.encode(x) should be within the range [-1, 1].

Best,
Junyu

MIT HAN Lab org

Here is my reconstruction result.
demo_dc_ae.jpg

I solved it, I found out that I was too stupid to forget to add the batch dimension. Thanks very much!

MIT HAN Lab org

You are welcome.

elegy111 changed discussion status to closed

Sign up or log in to comment