Justin-Tan / high-fidelity-generative-compression

Pytorch implementation of High-Fidelity Generative Image Compression + Routines for neural image compression
Apache License 2.0
411 stars 77 forks source link

compression problem #43

Open XDongiang opened 2 years ago

XDongiang commented 2 years ago

The hfc file I get by compressing a large image is 21kib. But cut this picture into many small pictures, and then compress all the pictures with hific, the total size of hfc obtained exceeds 190kib

yifeipet commented 1 year ago

This compression saves the compressed probability table and dimensionality information for each image. So it's reasonable to see what you have mentioned.

GimmeSomeJazz commented 1 year ago

hey, great job @Justin-Tan! Thank you for this amazing job :) How do we activate ans compression in the code? I see that the hfc file contains only numerical data (see compression_utils.save_compressed_format), and I would have expected String data. Furthermore, reading the code, I think that we never come into the ans_index_buffered_encoder function for example. Maybe some mistake on my side, but maybe you could confirm that? And explain us how to activate ans encoding at the end of the process if I am not wrong? That could greatly improve compression rate :) Thank you again!!! Regards,