JPEG Inspired Deep Learning

Ahmed H. Salamah, Kaixiang Zheng, Yiwen Liu, En-Hui Yang
2/12/2026

No official code found. Best implementation: JpegInspiredDl/JPEG-Inspired-DL (3 stars, MIT, last commit 2024-10-17).

Abstract

Although it is traditionally believed that lossy image compression, such as JPEG compression, has a negative impact on the performance of deep neural networks (DNNs), it is shown by recent works that well-crafted JPEG compression can actually improve the performance of deep learning (DL). Inspired by this, we propose JPEG-DL, a novel DL framework that prepends any underlying DNN architecture with a trainable JPEG compression layer. To make the quantization operation in JPEG compression trainable, a new differentiable soft quantizer is employed at the JPEG layer, and then the quantization operation and underlying DNN are jointly trained. Extensive experiments show that in comparison with the standard DL, JPEG-DL delivers significant accuracy improvements across various datasets and model architectures while enhancing robustness against adversarial attacks. Particularly, on some fine-grained image classification datasets, JPEG-DL can increase prediction accuracy by as much as 20.9%. Our code is available on https://github.com/AhmedHussKhalifa/JPEG-Inspired-DL.git.

View on arXivView PDF

Code Implementations(1)

MIT
30Shell, PythonSep 25, 20242 years agoMIT

Similar Papers

Cite this paper

@article{salamah2026jpeg,
  title  = {JPEG Inspired Deep Learning},
  author = {Ahmed H. Salamah and Kaixiang Zheng and Yiwen Liu and En-Hui Yang},
  year   = {2026},
  eprint = {2410.07081},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2410.07081},
  journal = {ICLR 2024 2024}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2410.07081.svg)](https://codeofpaper.com/paper/2410.07081)

Discussion