/ANNImageCompression

Artificial Neural Networks (ANN) Image Compression

Primary LanguageC++

Artificial Neural Networks (ANN) Image Compression

Bottleneck-type Neural Net Architecture for Image Compression for laboratory work.

Library

Armadillo C++ linear algebra library

The CImg Library for image processing

for Ubuntu:

sudo apt-get install libarmadillo-dev libarmadillo6
sudo apt-get install cimg-dev

Before installing Armadillo, it's recommended to install LAPACK, BLAS and ATLAS

Input:

n – height of rectangle;

m – width of rectangle;

p – number of neuron for second layer;

e – error degree;

α – learning step;

argv[1] - path to image

Output:

Z – compression ratio;

Iteration – number of iterations;

E – total error for the training sample;

Example

Input Image

Input

Output Image(n:8; m:8; p:48; e:256; a:0.001; Iteration = 515; Z = 3.36831)

Output

Output Image(n:8; m:8; p:32; e:450; a:0.001; Iteration = 561; Z = 5.05237)

Output

Output Image(n:8; m:8; p:16; e:973; a:0.001; Iteration = 490; Z = 10.1042)

Output