A system for lossy image or video compression, transmission and decoding, the system including a first computer system, a first trained neural network, a second computer system, a second trained neural network, a third trained neural network, a fourth trained neural network and a trained neural network identical to the fourth trained neural network, wherein:
- (i) the first computer system is configured to receive an input image;
- (ii) the first computer system is configured to encode the input image using a first trained neural network, to produce a y latent representation;
- (iii) the first computer system is configured to encode they latent using a second trained neural network, to produce a z latent representation;
- (iv) the first computer system is configured to encode the z latent using a third trained neural network, to produce a w latent representation;
- (v) the first computer system is configured to entropy encode the w latent into a first bitstream;
- (vi) the first computer system is configured to entropy encode the z latent into a second bitstream;
- (vii) the first computer system is configured to entropy encode the y latent into a third bitstream;
- (viii) the first computer system is configured to transmit the first bitstream, the second bitstream, and the third bitstream to the second computer system;
- (ix) the second computer system is configured to entropy decode the first bitstream to produce the w latent;
- (x) the second computer system is configured to process the w latent using a fourth trained neural network;
- (xi) the second computer system is configured to entropy decode the second bitstream using the processed w latent to produce the z latent;
- (xii) the second computer system is configured to process the z latent using a fifth trained neural network;
- (xiii) the second computer system is configured to entropy decode the third bitstream using the processed z latent to produce the y latent;
- and
- (xiv) the second computer system is configured to use a sixth trained neural network to produce an output image from the y latent, wherein the output image is an approximation of the input image.