Data compression by using cognitive created dictionaries
A compression method, system, and computer program product include creating compressed data via a first system from input data, sending information to a second system detailing a compression strategy for the compressed data, and learning, via the second system, from the information how to recreate the input to the first system using the compressed data.
1. A computer-implemented compression method, the method comprising:
creating compressed data via a first system from input data;
sending a decoding hint detailing a compression strategy for the compressed data and the compressed data from the first system to a second system,
wherein the first system teaches the second system how to recreate the input using the decoding hint while the second system teaches the first system a result of recreating the input data using the teaching that the first system provides to the second system;
wherein the compressed data is created with a minimum size with an effort level of decoding, the effort level of decoding is dependent on a number of computing steps of the second system, and
wherein feedback is sent to the first system if the recreated input and the input do not match;
the method further comprising:
in response to receiving the feedback by the first system,
modifying the compression strategy for the input data;
updating the decoding hint to detail the modified compression strategy;
repeating the creating and the sending to confirm that the modified compression strategy creates compressed data including a minimum size by comparing a new size to the measured size; and
in response to determining that a quality of the recreated input is greater than a predetermined threshold value, sending the compressed data and stopping sending the decoding hint to the second system, the quality of the recreated input is a difference between the input and the recreated input.
2. The computer-implemented method of claim 1 , further comprising:
decompressing, via the second system, the compressed data to a recreated input; and
comparing the input data to the first system with the recreated input in an iterative loop.
3. The computer-implemented method of claim 2 , further comprising:
based on a result of the comparing and the iterative loop of the comparing, modifying the decoding hint at each iterative loop how to recreate the input such that the input data to the first system matches the recreated input.
4. A computer program product for compression, the computer program product comprising a computer-readable storage medium having program instructions embodied therewith, the program instructions executable by a computer to cause the computer to perform:
creating compressed data via a first system from input data;
sending a decoding hint detailing a compression strategy for the compressed data and the compressed data from the first system to a second system,
wherein the first system teaches the second system how to recreate the input using the decoding hint while the second system teaches the first system a result of recreating the input data using the teaching that the first system provides to the second system;
wherein the compressed data is created with a minimum size with an effort level of decoding, the effort level of decoding is dependent on a number of computing steps of the second system, and
wherein feedback is sent to the first system if the recreated input and the input do not match;
the program instructions executable by a computer to cause the computer to further perform:
in response to receiving the feedback by the first system,
modifying the compression strategy for the input data;
updating the decoding hint to detail the modified compression strategy;
repeating the creating and the sending to confirm that the modified compression strategy creates compressed data including a minimum size by comparing a new size to the measured size; and
in response to determining that a quality of the recreated input is greater than a predetermined threshold value, sending the compressed data and stopping sending the decoding hint to the second system, the quality of the recreated input is a difference between the input and the recreated input.
5. A compression system, said system comprising:
a processor; and
a memory, the memory storing instructions to cause the processor to perform:
creating compressed data via a first system from input data;
sending a decoding hint detailing a compression strategy for the compressed data and the compressed data from the first system a second system,
wherein the first system teaches the second system how to recreate the input using the decoding hint while the second system teaches the first system a result of recreating the input data using the teaching that the first system provides to the second system;
wherein the compressed data is created with a minimum size with an effort level of decoding, the effort level of decoding is dependent on a number of computing steps of the second system, and
wherein feedback is sent to the first system if the recreated input and the input do not match;
the instructions further causing the processor to perform:
in response to receiving the feedback by the first system,
modifying the compression strategy for the input data;
updating the decoding hint to detail the modified compression strategy;
repeating the creating and the sending to confirm that the modified compression strategy creates compressed data including a minimum size by comparing a new size to the measured size; and
in response to determining that a quality of the recreated input is greater than a predetermined threshold value, sending the compressed data and stopping sending the decoding hint to the second system, the quality of the recreated input is a difference between the input and the recreated input.