{"id":32933325,"url":"https://github.com/liushuai1998/ijcn","last_synced_at":"2025-11-17T15:01:25.497Z","repository":{"id":323593248,"uuid":"1093895577","full_name":"liushuai1998/IJCN","owner":"liushuai1998","description":"Official implementation of the Paper \"Blind JPEG Artifacts Removal via Inverse JPEG Compression\"","archived":false,"fork":false,"pushed_at":"2025-11-11T02:20:08.000Z","size":22638,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-11-11T04:09:57.230Z","etag":null,"topics":["deep-learning","image-processing","jpeg-artifacts-removal","pytorch"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/liushuai1998.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-11-11T01:38:05.000Z","updated_at":"2025-11-11T03:00:02.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/liushuai1998/IJCN","commit_stats":null,"previous_names":["liushuai1998/ijcn"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/liushuai1998/IJCN","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liushuai1998%2FIJCN","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liushuai1998%2FIJCN/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liushuai1998%2FIJCN/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liushuai1998%2FIJCN/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/liushuai1998","download_url":"https://codeload.github.com/liushuai1998/IJCN/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liushuai1998%2FIJCN/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":284100246,"owners_count":26947309,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-11-12T02:00:06.336Z","response_time":59,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["deep-learning","image-processing","jpeg-artifacts-removal","pytorch"],"created_at":"2025-11-11T19:00:52.035Z","updated_at":"2025-11-13T21:00:51.579Z","avatar_url":"https://github.com/liushuai1998.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"## [Blind JPEG Artifacts Removal  via Inverse JPEG Compression]\nShuai Liu, Binqiang Liu, Qingyu Mao, Jiacong Chen, Fanyang Meng, Yonghong Tian\n________\n\n:fire::fire: This repository is the official PyTorch implementation of paper \"Blind JPEG Artifacts Removal  via Inverse JPEG Compression\".\nIJCN achieves **state-of-the-art performance** in **BLIND** JPEG artifacts removal on\n- Color Single JPEG images\n- Color Double JPEG images\n- Real-world JPEG images\n\n## Abstract\n\u003eQuantization and chroma downsampling are two primary operations that introduce distortions in the JPEG compression. However, most existing blind methods treat artifacts removal as a direct mapping from compressed images to clean ones. They fail to explicitly model the underlying degradation process or design targeted compensation mechanisms. As a result, these methods can only partially remove compression artifacts and struggle to generalize to diverse or unseen degradation scenarios. In this work, we present a novel perspective that formulates artifacts removal as an approximate inversion of the lossy steps in JPEG. Based on this view, we propose an Inverse JPEG Compression Network (IJCN), which aims to progressively compensate for quantization errors and color distortions. Specifically, we first design a Learnable Offset Guidance Module (LOGM) to approximate inverse quantization by modeling both intra-block and inter-block coefficient correlations for predicting rounding offsets. In addition, we propose a Quantization Table Guidance Module (QTGM) that leverages the quantization tables to guide the reconstruction network in mitigating color distortions. By modeling compensation mechanisms under the guidance of quantization tables, IJCN effectively eliminates artifacts across varying compression levels. Extensive experiments demonstrate that IJCN outperforms existing methods in both quantitative metrics and visual quality.\n________\n\n\n## Environment\nFirst you have to make sure that you have installed all dependencies. To do so, you can create an anaconda environment  using the following command:\n```bash\nconda env create -f environment.yml\nconda activate ijcn\n```\n\n\n## Dataset\nThe **LIVE1** dataset is already included in the `testsets` directory.  If you need additional datasets such as **Urban100**, **BSDS500**, or **ICB**, please use the download links below:\n\n- [Urban100](https://huggingface.co/datasets/eugenesiow/Urban100/resolve/main/data/Urban100_HR.tar.gz?download=true)\n- [BSDS500](http://web.archive.org/web/20160306133802/http://www.eecs.berkeley.edu/Research/Projects/CS/vision/grouping/BSR/BSR_bsds500.tgz)\n- [ICB](http://imagecompression.info/test_images/rgb8bit.zip)\n\nThese datasets are publicly available for research purposes. Please follow the original authors’ licenses and usage terms when using the data.\n\n## Checkpoints\nDownload the following pre-trained models of IJCN from [Github Release]() to `model_zoo`.\n- Color_IJCN.pth\n- Colordouble_IJCN.pth\n\n\n## Test\nAfter preparing the environment, datasets, and pretrained models, run the following commands to test the models. If you want to test your own real JPEG images, modify the `L_path` in `test_real_IJCN.py` to the path of your images.\n\n- Color Single JPEG images\n```bash\npython test_color_IJCN.py\n```\n\n- Color Double JPEG images\n```bash\npython test_colordouble_IJCN.py\n```\n\n- Real-World JPEG images\n```bash\npython test_real_IJCN.py\n```\n\n## Acknowledgement\nThis code is built on [FBCNN](https://github.com/jiaxi-jiang/FBCNN), [QGAC](https://gitlab.com/Queuecumber/quantization-guided-ac), and [SwinIR](https://github.com/JingyunLiang/SwinIR). We thank the authors for sharing their codes.\n\n## Contact\nFor any questions or inquiries, please contact us at liushuai981115@163.com or 2410044032@mails.szu.edu.cn.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fliushuai1998%2Fijcn","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fliushuai1998%2Fijcn","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fliushuai1998%2Fijcn/lists"}