CompressAI
CompressAI copied to clipboard
Ubuntu compressed images can't be decoded properly in Windows
I've configured Compressai on both Ubuntu and Windows. they both encode and decode fine on their respective systems. But the bin files compressed by Ubuntu are not decoded properly in Windows. How can I fix it?
This occurs due to non-determinism (particularly in the context model) across systems/hardware/etc. We do not currently provide methods to mitigate this. However, you can try the following to see if it helps:
torch.backends.cudnn.deterministic = True
torch.backends.cudnn.benchmark = False
See also:
- https://github.com/InterDigitalInc/CompressAI/issues/235#issuecomment-1740940306
- https://github.com/InterDigitalInc/CompressAI/issues/279#issuecomment-2019388285
- https://github.com/InterDigitalInc/CompressAI/issues/335#issuecomment-2771481279
- https://arxiv.org/pdf/2410.09872