All Projects → mmSir → GainedVAE

mmSir / GainedVAE

Licence: other
A Pytorch Implementation of a continuously rate adjustable learned image compression framework.

Programming Languages

python
139335 projects - #7 most used programming language
C++
36643 projects - #6 most used programming language

Projects that are alternatives of or similar to GainedVAE

Zipson
JSON parse and stringify with compression
Stars: ✭ 229 (+432.56%)
Mutual labels:  compression
ConvectionKernels
Fast, high-quality texture compression library for many formats
Stars: ✭ 40 (-6.98%)
Mutual labels:  compression
php-closure-compiler
A PHP Library to use Google Closure Compiler compress Javascript
Stars: ✭ 20 (-53.49%)
Mutual labels:  compression
Minlzma
The Minimal LZMA (minlzma) project aims to provide a minimalistic, cross-platform, highly commented, standards-compliant C library (minlzlib) for decompressing LZMA2-encapsulated compressed data in LZMA format within an XZ container, as can be generated with Python 3.6, 7-zip, and xzutils
Stars: ✭ 236 (+448.84%)
Mutual labels:  compression
em inflate
Fast, small, in-memory inflate (zlib, deflate and gzip decompression)
Stars: ✭ 59 (+37.21%)
Mutual labels:  compression
pybashutils
Collection of Bash and Python scripts I've made that may be generally useful
Stars: ✭ 26 (-39.53%)
Mutual labels:  compression
Cineform Sdk
The GoPro® CineForm video codec SDK.
Stars: ✭ 219 (+409.3%)
Mutual labels:  compression
levi-db
levi-db is a fast database engine
Stars: ✭ 37 (-13.95%)
Mutual labels:  compression
Huffman-Coding
A C++ compression program based on Huffman's lossless compression algorithm and decoder.
Stars: ✭ 81 (+88.37%)
Mutual labels:  compression
Guetzling
Guetzling is a simple script for macOS and Linux written in Bash, to automate (recursively finding files) the compression of jpegs using the Guetzli algorithm.
Stars: ✭ 20 (-53.49%)
Mutual labels:  compression
Gdcm
Grassroots DICOM read-only mirror. Only for Pull Request. Please report bug at http://sf.net/p/gdcm
Stars: ✭ 240 (+458.14%)
Mutual labels:  compression
Precomp Cpp
Precomp, C++ version - further compress already compressed files
Stars: ✭ 250 (+481.4%)
Mutual labels:  compression
roadroller
Roadroller: Flattens Your JavaScript Demo
Stars: ✭ 253 (+488.37%)
Mutual labels:  compression
Smol V
SMOL-V: like Vulkan/Khronos SPIR-V, but smaller.
Stars: ✭ 230 (+434.88%)
Mutual labels:  compression
wordpress-plugin
Speed up your WordPress website. Optimize your JPEG and PNG images automatically with TinyPNG.
Stars: ✭ 78 (+81.4%)
Mutual labels:  compression
Qs
Quick serialization of R objects
Stars: ✭ 225 (+423.26%)
Mutual labels:  compression
GenuineChannels
Collection of custom .NET Remoting channels
Stars: ✭ 29 (-32.56%)
Mutual labels:  compression
Compressor
An android image compression library.
Stars: ✭ 6,745 (+15586.05%)
Mutual labels:  compression
snappy
Fastest Snappy compression library in Node.js
Stars: ✭ 110 (+155.81%)
Mutual labels:  compression
FrameOfReference
C++ library to pack and unpack vectors of integers having a small range of values using a technique called Frame of Reference
Stars: ✭ 36 (-16.28%)
Mutual labels:  compression

GainedVAE

A Pytorch Implementation of the continuously rate adjustable learned image compression framework, Gained Variational Autoencoder(GainedVAE).

Note that This Is Not An Official Implementation Code.

More details can be found in the following paper:

Asymmetric Gained Deep Image Compression With Continuous Rate Adaptation.
Huawei Technologies, CVPR 2021
Ze Cui, Jing Wang, Shangyin Gao, Tiansheng Guo, Yihui Feng, Bo Bai

Todo: Reproduce Implementation of the following paper:

INTERPOLATION VARIABLE RATE IMAGE COMPRESSION
Alibaba Group, ACM Multimedia 2021 Zhenhong Sun, Zhiyu Tan, Xiuyu Sun, Fangyi Zhang, Yichen Qian, Dongyang Li, Hao Li

Environment

  • Python == 3.7.10
  • Pytorch == 1.7.1
  • CompressAI

Dataset

Training set

I use a part of the OpenImages Dataset to train the models (train06, train07, train08, about 54w images). You can download from here. Download OpenImages Maybe train08 (14w images) is enough.

Test set

Download Kodak dataset

The dataset fold structure is as follows:

.dataset/
│  
├─test
│      kodim01.png
│      kodim02.png
│      kodim03.png
...
├─train
│      000002b66c9c498e.jpg
│      000002b97e5471a0.jpg
│      000002c707c9895e.jpg
...

Train Your Own Model

python3 trainGain.py -d /path/to/your/image/dataset/ --epochs 200 -lr 1e-4 --batch-size 16 --model-save /path/to/your/model/save/dir --cuda

Result

I try to train the Gained Mean-Scale Hyperprior model/Gained Scale Hyperprior model. See details in ./results I retrained the single rate baseline but can not achieve the official performance. Results from Google tensorflow/compression library is very strong probably because of their large and diverse training data set and long training time.

results1

results2

Pretrained Model

You can download the checkpoint trained by me from Pretrained Model.

Acknowledgement

The framework is based on CompressAI, I add the model in compressai.models.gain, compressai.models.gain_utils.
And trainGain/trainGain.py is modified with reference to compressai_examples/train.py.

More Variable Rate Image Compression Repositories

"Variable-Rate Deep Image Compression through Spatially-Adaptive Feature Transform" (ICCV 2021).
code

"Variable Bitrate Image Compression with Quality Scaling Factors" (ICASSP 2020).
code

"Variable Rate Deep Image Compression with Modulated Autoencoders" (IEEE SPL 2020)
code

"Slimmable Compressive Autoencoders for Practical Neural Image Compression" (CVPR 2021)
code

Contact

Feel free to contact me if there is any question about the code or to discuss any problems with image and video compression. ([email protected])

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].