An asymmetric lossy data compression method and system with stable compression rate
Patent Information
- Application Number
- CN202611272884.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-21
- Publication Date
- 2026-09-22
AI Technical Summary
[0003]现有技术难以同时满足上述要求
1、压缩率固定可控:通过设定聚类数量K,可精确控制最终压缩率,输出体积稳定可预测。
Smart Images

Figure CN122802676A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of image processing and relates to a method and system for asymmetric lossy data compression with stable compression ratio. Background Technology
[0002] In many real-time data transmission and embedded storage scenarios, such as temporary storage of intermediate results in high-performance computing, game streaming, ultra-large-scale sensor networks, and communication between hardware accelerators and hosts, the system places drastically different demands on data compression algorithms compared to traditional applications. First, the stability and predictability of the compression ratio are crucial, directly affecting the allocation of channel bandwidth, the design of buffer size, and the guarantee of system real-time performance. Second, since the decompression end is usually limited by computing resources (such as embedded processors, FPGAs, or dedicated hardware), the decompression process must have extremely low overhead, extremely high speed, and constant speed, without involving complex computational processes. Finally, a certain degree of precision loss is acceptable within an acceptable range in exchange for the aforementioned performance improvements, i.e., lossy compression schemes are adopted.
[0003] Existing technologies struggle to simultaneously meet these requirements. Traditional lossless compression algorithms (such as the LZ series and Zstandard) heavily rely on the redundancy of the data itself for their compression ratio. They perform poorly on data with high randomness, and the output size fluctuates greatly, failing to provide a stable compression ratio guarantee. Furthermore, their decompression process typically involves variable-length decoding and backtracking matching, resulting in unstable computational overhead that is difficult to implement efficiently using pure hardware pipelines. While existing lossy compression standards (such as JPEG and H.264) offer high compression ratios, their decompression algorithms remain relatively complex, involving computationally intensive operations such as inverse quantization and inverse discrete cosine transform. Their power consumption and latency are insufficient to meet the stringent requirements of ultra-low-power embedded devices.
[0004] Therefore, there is an urgent need in this field for a novel asymmetric compression architecture. Summary of the Invention
[0005] This invention discloses an asymmetric lossy data compression method and system with a stable compression ratio, aiming to provide a fast decompression scheme with constant overhead, minimal overhead and easy hardware implementation for resource-constrained decompression ends, while the compression end is responsible for calculation to achieve precise compression ratio control.
[0006] This invention provides an asymmetric lossy data compression method with stable compression ratio. It employs an asymmetric "analysis-compression-reconstruction" architecture that utilizes recalculation at the compression end and a simplified lookup table at the decompression end. This method is suitable for hardware decompression of RGB images and includes the following steps: On the compression end, it includes: Step 1: Segmentation and Quantization. The input data stream is divided into data blocks. Based on the importance of the data or preset rules, some data blocks are quantized, while other important data blocks retain their original precision. The degree of quantization for each type of data is preset. Finally, several quantized data blocks of the same length are obtained. Step 2: Vector clustering. Based on the feature vectors, perform cluster analysis on the data blocks to generate a predetermined number of clusters, which is K. Step 3: Template generation and encoding. An optimal template block is generated for each cluster in the clustering results. Each original data block is encoded using the index of its cluster. The final compressed result is the index data and the template block lookup table. On the decompression end, it includes: Step 4: Find the template. Based on the received index value, find the corresponding template block from the local pre-loaded or transmitted template block library. Step 5: Data reconstruction. The found template blocks are reconstructed to restore the approximate value of the original data blocks. Step 6: Output the reconstructed data blocks in sequence.
[0007] Furthermore, in step one, the original pixel data is first subjected to channel separation and spatial dimensionality reduction quantization, and then the processed data stream is divided into blocks of fixed size: S1.1 Channel Separation and Dimensionality Reduction Quantization: The 2400×1080 RGB image data is separated into three independent channel planes: R, G, and B. Each channel plane has a size of 2400 in height and 1080 in width. S1.2 For the green G channel: retain its full resolution, do not perform any downsampling processing, and the processed G channel data is still 2400×1080 pixel values; S1.3 For the red R and blue B channels: Perform 2:1 mean dimensionality reduction quantization in the horizontal direction.
[0008] Furthermore, step one also includes data reorganization and segmentation: The new data stream is divided into blocks. To match raster scanning and simplify hardware design, the data is divided into blocks with a height of 1 row, each block containing 4 consecutive logical pixels: The data size of each block is: 4 points × 1 byte = 4 bytes; The number of blocks that can be divided per scan line is: 1080 logical pixels / 4 = 270 blocks for the G channel, and 540 logical pixels / 4 = 135 blocks for the RB channel; The entire screen contains a total of (135 blocks / row + 270 blocks / row + 135 blocks / row) × 2400 rows = 1,296,000 blocks.
[0009] Furthermore, step two includes: Data representation: Each 4-byte data block is directly treated as a vector; Clustering process: On the compression side, the Mini Batch K-Means clustering algorithm is used to cluster all 1,296,000 vectors. The index numbers of the clustering results need to be recorded. The number of index numbers is equal to the number of clusters K. Assuming that the number of K is less than or equal to 2 to the power of N, N bits are needed to store them. The space required to store these index numbers is N times the number of data blocks to be stored. At the same time, space is also needed to store the data of the cluster centers corresponding to the K index numbers. This step is completed on the host side in order to discover the recurring pattern blocks in the data.
[0010] Furthermore, step three includes: Template generation: Calculate a centroid for each cluster, which is a 4-byte template block; all template blocks form a template lookup table; Encoding: For each block in the original data, find the most similar template block in the template lookup table and replace the block with its index number; Index size: K=256, the index number is represented by 1 byte (8 bits); Data packet composition: The compressed data stream consists of a template lookup table of K×4 bytes and an index sequence of 1296000 ×1 bytes concatenated together; the lengths of the RGB index sequences are not equal due to RB quantization, so they are arranged such that each group of index units contains 1 R-mean index, 2 G-mean indices, and 1 B-mean index. [R_avg1_index, G1_index, G2_index, B_avg1_index], [R_avg2_index, G3_index, G4_index, B_avg2_index], ... .
[0011] Furthermore, step four includes: The decompression hardware preloads the entire template lookup table into the internal SRAM; During decompression, each byte in the index sequence is read sequentially and used as an address to directly read the corresponding 4-byte template block from SRAM.
[0012] Furthermore, step five includes reading a 4-byte template block from SRAM, which is the reconstructed data.
[0013] Furthermore, step S1.3 includes: (1) For each scan line, calculate the arithmetic mean of the values of two adjacent R or B pixels, and use the average value to represent the two original pixels; (2) Quantization results: Each row of data in the R and B channels was compressed from 1080 pixels to 540 pixel values; the size of the entire channel was changed from 2400×1080 to 2400×540; (3) The data volume of the two channels was reduced from 2×2400×1080 bytes to 2×2400×540 bytes, which means that the data volume of the R and B channels was compressed by 50%.
[0014] Furthermore, step six includes: The reconstructed data stream will be output in the order of [R_avg1_index, G1_index, G2_index, B_avg1_index], [R_avg2_index, G3_index, G4_index, B_avg2_index], ... Before final display, the following post-processing is performed: For each average value of the R and B channels, a copy is made and used to fill two consecutive pixel locations to restore the horizontal resolution of the image to 1080; the copying process is as follows: The decompressed sequence is [R_avg1, G1, B_avg1], [R_avg2, G2, B_avg2], [R_avg3, G3, B_avg3], [R_avg4, G4, B_avg4], which is then reconstructed after copying. Pixel 1: (R_avg1, G1, B_avg1) Pixel 2: (R_avg1, G2, B_avg1) reuses the same R_avg1 and B_avg1; Pixel 3: (R_avg2, G3, B_avg2) Pixel 4: (R_avg2, G4, B_avg2) reuses R_avg2 and B_avg2.
[0015] Furthermore, the present invention also provides an asymmetric lossy data compression system with stable compression ratio for implementing the aforementioned asymmetric lossy data compression method with stable compression ratio. The system employs an asymmetric architecture with a high-computation-power compression end and a low-computation-power hardware decompression end, and includes a data block quantization unit, a clustering encoding unit, a data storage unit, and a decompression and reconstruction unit. The data block quantization unit is used to receive the original RGB image data and preset compression parameters, quantize the RGB channels differently according to the human eye's visual sensitivity, and uniformly cut them into data blocks of equal length and fixed size and output them. The clustering encoding unit, connected to the data block quantization unit, is used to receive the quantized data block vector, obtain K clusters by Mini Batch K-Means clustering, generate a template block lookup table based on the cluster centroids, encode each data block using a fixed-length index, and output the index sequence and template block lookup table. A data storage unit, connected to the clustering encoding unit, is used to store a compressed data stream consisting of an index sequence and a template block lookup table; The decompression and reconstruction unit receives externally input compression parameters and reads the compressed data stream from the data storage unit. It is internally configured with an SRAM cache for preloading a template block lookup table. After reading the index, the decompression and reconstruction unit directly addresses the SRAM to obtain the template block and completes the data reconstruction. It also copies and fills the R and B channel mean chromaticity data to restore the original image resolution and finally outputs complete RGB pixel data in raster scan order.
[0016] The system is applied to the display driver of handheld mobile devices, storing the physical pixel data corresponding to the three RGB channels of the display device. It quantifies the degree of importance of each channel to the final display effect. Then, it performs compression and decompression after mixing the data from the three channels according to the raster scan order.
[0017] The technical effects of this invention are as follows: 1. Fixed and controllable compression ratio: By setting the number of clusters K, the final compression ratio can be precisely controlled, and the output volume is stable and predictable.
[0018] 2. Extremely efficient decompression performance: The decompression process involves only two table lookups and one addition operation, with constant and minimal overhead. There are no branch predictions or complex calculations, making it ideal for implementing ultra-low latency and ultra-high throughput decompression pipelines using hardware such as FPGAs or ASICs.
[0019] 3. Asymmetric architecture: All computational complexity is placed on the compression end, perfectly adapting to the application model of "strong compression end - weak decompression end" (such as server-client, PC-embedded device).
[0020] 4. Clear application objectives: It is especially suitable for real-time data transmission and embedded storage scenarios that are sensitive to latency and power consumption and can accept lossy compression. Attached Figure Description
[0021] Figure 1 The diagram shown is a flowchart of the method of the present invention; Figure 2 The diagram shown is a system structure diagram of the present invention. Detailed Implementation
[0022] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0023] Please see Figure 1-2 This invention provides an asymmetric lossy data compression method with stable compression ratio. It employs an asymmetric "analysis-compression-reconstruction" architecture that involves recalculation at the compression end and a simplified lookup table at the decompression end. This method is suitable for hardware decompression of RGB images and includes the following steps: On the compression end, it includes: Step 1: Segmentation and Quantization. The input data stream is divided into data blocks. Based on the importance of the data or preset rules, some data blocks are quantized, while other important data blocks retain their original precision. The degree of quantization for each type of data is preset. Finally, several quantized data blocks of the same length are obtained. Step 2: Vector clustering. Based on the feature vectors, perform cluster analysis on the data blocks to generate a predetermined number of clusters, which is K. Step 3: Template generation and encoding. An optimal template block is generated for each cluster in the clustering results. Each original data block is encoded using the index of its cluster. The final compressed result is the index data and the template block lookup table. At the decompression end, the process is extremely efficient and constant, including: Step 4: Find the template. Based on the received index value, find the corresponding template block from the local pre-loaded or transmitted template block library. Step 5: Data reconstruction. Perform simple, deterministic reconstruction operations on the found template blocks to restore an approximate value of the original data blocks. Step 6: Output the reconstructed data blocks in sequence.
[0024] Step one first performs channel separation and spatial dimensionality reduction quantization on the original pixel data, and then divides the processed data stream into blocks of fixed size: S1.1 Channel Separation and Dimensionality Reduction Quantization: The 2400×1080 RGB image data is separated into three independent channel planes: R, G, and B. Each channel plane has a size of 2400 in height and 1080 in width. S1.2 For the green G channel: Since the human eye is most sensitive to vision, its full resolution is preserved, and no downsampling is performed. The processed G channel data is still 2400×1080 pixel values. S1.3 For the red R and blue B channels: Since the human eye has low sensitivity, a 2:1 mean dimensionality reduction quantization is performed in the horizontal direction.
[0025] Specific operation: For each scan line, calculate the arithmetic mean of the values of two adjacent R (or B) pixels, and use this average value to represent these two original pixels; for example, R1, R2, R3, R4 (4 real pixels): R_avg1 = (R1+R2) / 2, replacing R1 and R2; R_avg2 = (R3+R4) / 2, replacing R3 and R4; After processing, the number of pixels in a single row of the R channel is halved: [R_avg1, R_avg2] (from 4 points to 2 points, 50% data compression); the B channel undergoes the same operation.
[0026] The G channel is sensitive to human vision, so it is not downsampled in any way, and the original pixels G1, G2, G3, and G4 are fully preserved.
[0027] Quantization result: Each row of data in the R and B channels was compressed from 1080 pixels to 540 pixel values, and the size of the entire channel changed from 2400×1080 to 2400×540; This process significantly reduced the amount of data: the amount of data in the two channels was reduced from 2×2400×1080 bytes to 2×2400×540 bytes, which means that the data volume of the R and B channels was compressed by 50%.
[0028] Data restructuring and segmentation: The new data stream is divided into blocks. To match raster scanning and simplify hardware design, the data is divided into blocks with a height of 1 row. The number of consecutive pixels in each block is the most influential factor on the compression ratio. Here, each block contains 4 consecutive logical pixels: The data size of each block is: 4 points × 1 byte = 4 bytes; The number of blocks that can be divided per scan line is: 1080 logical pixels / 4 = 270 blocks for the G channel, and 540 logical pixels / 4 = 135 blocks for the RB channel; The entire screen contains a total of (135 blocks / row + 270 blocks / row + 135 blocks / row) × 2400 rows = 1,296,000 blocks.
[0029] Step two includes: Data representation: Each 4-byte data block is directly treated as a vector; Clustering process: On the compression side, the Mini Batch K-Means clustering algorithm is used to cluster all 1,296,000 vectors. For this scale of data, clustering can be completed in less than 5 seconds on a PC. The number of clusters K will affect the data compression ratio and effect. The impact on the ratio is reflected in the fact that the index numbers of the clustering results need to be recorded. The number of index numbers is equal to the number of clusters K. Assuming that the number of K is less than or equal to 2 to the power of N, N bits are needed to store them. The space required to store these index numbers is N times the number of data blocks to be stored. At the same time, space is also needed to store the data of the cluster centers corresponding to the K index numbers. This step is completed on a powerful host to discover recurring pattern blocks in the data.
[0030] Furthermore, step three includes: Template generation: Calculate a centroid for each cluster, which is a 4-byte template block; all template blocks form a template lookup table; Encoding: For each block in the original data, find the most similar template block in the template lookup table and replace the block with its index number; Index number size rules: if K=256, the index number can be represented by 1 byte 8 bits; if K=512, the index number can be represented by 9 bits, and so on; in the example, K=256 is used.
[0031] Data packet composition: The compressed data stream consists of a template lookup table of K×4 bytes and an index sequence of 1296000×1 bytes concatenated together. The lengths of the RGB index sequences are unequal due to RB quantization. To adapt to raster scanning for display, no additional buffering is needed for decompression. Fixed groups are used, with each group's average R / B value corresponding to two consecutive G pixels, exactly corresponding to the original... Figure 2 Each actual screen pixel.
[0032] Therefore, the arrangement uses two Gs paired with RBs to ensure that the RGB data can be synchronously restored according to the raster scan order without the need for additional caching. [R_avg1_index, G1_index, G2_index, B_avg1_index], [R_avg2_index, G3_index, G4_index, B_avg2_index], ... .
[0033] Step four includes: The decompression hardware preloads the entire template lookup table into the internal SRAM; During decompression, each byte in the index sequence is read sequentially and used as an address to directly read the corresponding 4-byte template block from SRAM.
[0034] Step five includes reading a 4-byte template block from SRAM, which is the reconstructed data. This process requires no computation and is solely a memory read operation.
[0035] Step six includes: The reconstructed data stream will be output in the order of [R_avg1_index, G1_index, G2_index, B_avg1_index], [R_avg2_index, G3_index, G4_index, B_avg2_index], ... After decompression and table lookup, only the compressed low-resolution chroma averages (R_avg, B_avg) are obtained, losing the original separate R1 / R2 and B1 / B2. Since the screen hardware output must restore the original 1080 full horizontal resolution, and the number of R / B pixels per row must be restored to 1080, a simple upsampling restoration is performed before final display: For each average value of the R and B channels, a copy is made and used to fill two consecutive pixel locations to restore the horizontal resolution of the image to 1080; the copying process is as follows: The decompressed sequence is [R_avg1, G1, B_avg1], [R_avg2, G2, B_avg2], [R_avg3, G3, B_avg3], [R_avg4, G4, B_avg4], which is then reconstructed after copying. Pixel 1: (R_avg1, G1, B_avg1) Pixel 2: (R_avg1, G2, B_avg1) reuses the same R_avg1 and B_avg1; Pixel 3: (R_avg2, G3, B_avg2) Pixel 4: (R_avg2, G4, B_avg2) reuses R_avg2 and B_avg2.
[0036] This copying operation is very simple and can be implemented in hardware with a simple buffer and repeat output logic, resulting in very low overhead.
[0037] This invention also provides an asymmetric lossy data compression system with stable compression ratio, used to implement the aforementioned asymmetric lossy data compression method with stable compression ratio. The system employs an asymmetric architecture with a high-computation-power compression end and a low-computation-power hardware decompression end, and includes a data block quantization unit, a clustering encoding unit, a data storage unit, and a decompression and reconstruction unit. The data block quantization unit is used to receive the original RGB image data and preset compression parameters, quantize the RGB channels differently according to the human eye's visual sensitivity, and uniformly cut them into data blocks of equal length and fixed size and output them. The clustering encoding unit, connected to the data block quantization unit, is used to receive the quantized data block vector, obtain K clusters by Mini Batch K-Means clustering, generate a template block lookup table based on the cluster centroids, encode each data block using a fixed-length index, and output the index sequence and template block lookup table. A data storage unit, connected to the clustering encoding unit, is used to store a compressed data stream consisting of an index sequence and a template block lookup table; The decompression and reconstruction unit receives externally input compression parameters and reads the compressed data stream from the data storage unit. It is internally configured with an SRAM cache for preloading a template block lookup table. After reading the index, the decompression and reconstruction unit directly addresses the SRAM to obtain the template block and completes the data reconstruction. It also copies and fills the R and B channel mean chromaticity data to restore the original image resolution and finally outputs complete RGB pixel data in raster scan order.
[0038] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is limited by the appended claims and their equivalents.
Claims
1. A method for stable asymmetric lossy data compression, characterized in that, It adopts an asymmetric "analysis-compression-reconstruction" architecture with computation at the compression end and table lookup at the decompression end, adapting to RGB image hardware decompression scenarios, including compression and decompression processing steps. The compression end processing steps include: Step 1: Blocking and Differential Quantization. The input data stream is divided into data blocks. Based on the importance of the data or preset rules, some data blocks are quantized, while other important data blocks retain their original precision. The degree of quantization for each type of data is preset. Finally, several quantized data blocks of the same length are obtained. Step 2: Vector clustering. Based on the feature vectors, perform cluster analysis on the data blocks to generate a predetermined number of clusters, which is K. Step 3: Template generation and encoding. An optimal template block is generated for each cluster in the clustering results. Each original data block is encoded using the index of its cluster. The final compressed result is the index data and the template block lookup table. On the decompression end, it includes: Step 4: Find the template. Based on the received index value, find the corresponding template block from the local pre-loaded or transmitted template block library. Step 5: Data reconstruction. The found template blocks are reconstructed to restore the approximate value of the original data blocks. Step 6: Output the reconstructed data blocks in sequence.
2. The asymmetric lossy data compression method with stable compression ratio according to claim 1, characterized in that, Step one first performs channel separation and spatial dimensionality reduction quantization on the original pixel data, and then divides the processed data stream into blocks of fixed size: S1.1 Channel Separation and Dimensionality Reduction Quantization: The 2400×1080 RGB image data is separated into three independent channel planes: R, G, and B. Each channel plane has a size of 2400 in height and 1080 in width. S1.2 For the green G channel: retain its full resolution, do not perform any downsampling processing, and the processed G channel data is still 2400×1080 pixel values; S1.3 For the red R and blue B channels: Perform 2:1 mean dimensionality reduction quantization in the horizontal direction.
3. The asymmetric lossy data compression method with stable compression ratio according to claim 1, characterized in that, Step one also includes data reorganization and segmentation: The new data stream is divided into blocks. To match raster scanning and simplify hardware design, the data is divided into blocks with a height of 1 row, each block containing 4 consecutive logical pixels: The data size of each block is: 4 points × 1 byte = 4 bytes; The number of blocks that can be divided per scan line is: 1080 logical pixels / 4 = 270 blocks for the G channel, and 540 logical pixels / 4 = 135 blocks for the RB channel; The entire screen contains a total of (135 blocks / row + 270 blocks / row + 135 blocks / row) × 2400 rows = 1,296,000 blocks.
4. The asymmetric lossy data compression method with stable compression ratio according to claim 3, characterized in that, Step two includes: Data representation: Each 4-byte data block is directly treated as a vector; Clustering process: On the compression side, the Mini Batch K-Means clustering algorithm is used to cluster all 1,296,000 vectors. The index numbers of the clustering results need to be recorded. The number of index numbers is equal to the number of clusters K. Assuming that the number of K is less than or equal to 2 to the power of N, N bits are needed to store them. The space required to store these index numbers is N times the number of data blocks to be stored. At the same time, space is also needed to store the data of the cluster centers corresponding to the K index numbers. This step is completed on the host side in order to discover the recurring pattern blocks in the data.
5. The asymmetric lossy data compression method with stable compression ratio according to claim 4, characterized in that, Step three includes: Template generation: Calculate a centroid for each cluster, which is a 4-byte template block; all template blocks form a template lookup table; Encoding: For each block in the original data, find the most similar template block in the template lookup table and replace the block with its index number; Index size: K=256, the index number is represented by 1 byte (8 bits); Data packet composition: The compressed data stream consists of a template lookup table of K×4 bytes and an index sequence of 1296000 ×1 bytes concatenated together; the lengths of the RGB index sequences are not equal due to RB quantization, so they are arranged such that each group of index units contains 1 R-mean index, 2 G-mean indices, and 1 B-mean index. [R_avg1_index, G1_index, G2_index, B_avg1_index], [R_avg2_index, G3_index, G4_index, B_avg2_index], ... .
6. The asymmetric lossy data compression method with stable compression ratio according to claim 1, characterized in that, Step four includes: The decompression hardware preloads the entire template lookup table into the internal SRAM; During decompression, each byte in the index sequence is read sequentially and used as an address to directly read the corresponding 4-byte template block from SRAM.
7. The asymmetric lossy data compression method with stable compression ratio according to claim 1, characterized in that, Step five includes reading a 4-byte template block from SRAM, which is the reconstructed data.
8. The asymmetric lossy data compression method with stable compression ratio according to claim 2, characterized in that, Step S1.3 includes: (1) For each scan line, calculate the arithmetic mean of the values of two adjacent R or B pixels, and use the average value to represent the two original pixels; (2) Quantization results: Each row of data in the R and B channels was compressed from 1080 pixels to 540 pixel values; the size of the entire channel was changed from 2400×1080 to 2400×540; (3) The data volume of the two channels was reduced from 2×2400×1080 bytes to 2×2400×540 bytes, which means that the data volume of the R and B channels was compressed by 50%.
9. The asymmetric lossy data compression method with stable compression ratio according to claim 1, characterized in that, Step six includes: The reconstructed data stream is output in the order of [R_avg1_index, G1_index, G2_index, B_avg1_index], [R_avg2_index, G3_index, G4_index, B_avg2_index], ... Before final display, the following post-processing is performed: For each average value of the R and B channels, a copy is made and used to fill two consecutive pixel locations to restore the horizontal resolution of the image to 1080; the copying process is as follows: The decompressed sequence is [R_avg1, G1, B_avg1], [R_avg2, G2, B_avg2], [R_avg3, G3, B_avg3], [R_avg4, G4, B_avg4], which is then reconstructed after copying. Pixel 1: (R_avg1, G1, B_avg1) Pixel 2: (R_avg1, G2, B_avg1) reuses the same R_avg1 and B_avg1; Pixel 3: (R_avg2, G3, B_avg2) Pixel 4: (R_avg2, G4, B_avg2) reuses R_avg2 and B_avg2.
10. A stable compression ratio asymmetric lossy data compression system, characterized in that... To implement the asymmetric lossy data compression method with stable compression ratio as described in any of claims 1-9, the system adopts an asymmetric architecture with a high-computation-power compression end and a low-computation-power hardware decompression end, including a data block quantization unit, a clustering encoding unit, a data storage unit, and a decompression and reconstruction unit: The data block quantization unit is used to receive the original RGB image data and preset compression parameters, quantize the RGB channels differently according to the human eye's visual sensitivity, and uniformly cut them into data blocks of equal length and fixed size and output them. The clustering encoding unit, connected to the data block quantization unit, is used to receive the quantized data block vector, obtain K clusters by Mini Batch K-Means clustering, generate a template block lookup table based on the cluster centroids, encode each data block using a fixed-length index, and output the index sequence and template block lookup table. A data storage unit, connected to the clustering encoding unit, is used to store a compressed data stream consisting of an index sequence and a template block lookup table; The decompression and reconstruction unit receives externally input compression parameters and reads the compressed data stream from the data storage unit. It is internally configured with an SRAM cache for preloading a template block lookup table. The decompression and reconstruction unit reads the index, directly addresses the SRAM to obtain the template block, completes the data reconstruction, copies and fills the mean chromaticity data of the R and B channels to restore the original image resolution, and finally outputs the complete RGB pixel data in the raster scan order.