Picture compression transmission method based on 5G transmission

By compressing and decompressing images in the 5G transmission system in the silk making workshop, the problem of limited 5G bandwidth in the silk making workshop is solved, the accuracy and real-time performance of image recognition is achieved, pixel loss is reduced, and the production line is improved. feedback efficiency.

CN118540417APending Publication Date: 2024-08-23CHINA TOBACCO ZHEJIANG IND CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410579771.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-11
Publication Date
2024-08-23

AI Technical Summary

Technical Problem

In the silk-making workshop, due to the limited 5G bandwidth, image recognition of debris based on deep learning requires image compression and transmission, resulting in loss of image recognition results, and multiple images need to be taken to cover each point, which increases bandwidth usage and recognition delay. .

Method used

A camera is used to compress the image through a micro-processing unit, and a 5G industrial router is used to transmit it to the server. The server performs decompression and recognition. The specific steps include color space conversion, sampling, discrete cosine transform, quantization and Huffman coding to reduce bandwidth usage and Reduce pixel loss.

Benefits of technology

While ensuring the compression rate, the pixel loss of the picture is reduced, the accuracy and real-time performance of image recognition are achieved, the location and type of debris on the production line are quickly located, and the real-time feedback efficiency of the production line is improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118540417A
    Figure CN118540417A
Patent Text Reader

Abstract

The invention discloses a picture compression transmission method based on 5G transmission. The method comprises the following steps: S1, shooting a picture; a camera erected on a production line is used for carrying out full-coverage shooting on a position needing to be recognized, and shot pictures are cached and transmitted to a micro-processing unit of an accessory; s2, compressing the micro-processing unit; s3, compressing the picture; s4, transmission is carried out; transmitting the compressed picture through a medium channel of the 5G industrial router; s5, carrying out decompression processing; after the server receives the compressed picture, decompression processing is carried out according to the reverse process of the compression process in the step S3, image recognition is carried out on the decompressed picture, and non-tobacco sundries in the image are recognized and classified; and S6, transmitting the calculation structure to a front end. According to the method, a 5G transmission framework of the camera and the server is established, the bandwidth occupation is reduced, the pixel loss after image compression is reduced while the compression rate is ensured, and the accuracy of a subsequent image recognition algorithm is ensured.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of industrial control technology, and in particular relates to a picture compression and transmission method based on 5G transmission for use in a silk-making workshop. Background Art

[0002] In the silk-making workshop, due to the maintenance of the site and equipment, the deep learning-based debris image recognition cannot be performed on a server near the camera for image calculation and recognition. It needs to be transmitted to the server in the computer room through 5G for recognition. However, the currently available 5G bandwidth is limited, and bandwidth needs to be reserved for transmission of other networks. In addition, silk production is continuous and uninterrupted, and new pictures are generated every second. Therefore, the image upload needs to be compressed to reduce bandwidth usage. After receiving the compressed photos, the server decompresses them and then recognizes the image. Therefore, the size of the loss after compression and decompression of the image is particularly critical to the image recognition result.

[0003] In order to make image recognition more accurate and ensure that every point in the captured image can be covered, three to four pictures need to be taken every second for transmission, and each picture is 30-40M. When the available bandwidth for transmission is small and uplink and downlink are required, the size of the transmitted photos needs to be compressed a lot to meet the bandwidth and transmission requirements. However, after the image is compressed and decompressed, there will be a certain amount of loss in the image, so it is necessary to reduce the loss to a level that cannot be distinguished by the human eye while ensuring the compression rate. Summary of the invention

[0004] In order to solve the above technical problems existing in the prior art, the present invention provides a method for image compression and transmission based on 5G transmission for use in a silk-making workshop. The present invention uses a camera to compress the image to be identified through a microprocessor unit installed nearby, and then uploads it to the server side of the computer room through a 5G industrial router. After receiving the image, the server decodes the image and performs image debris recognition, and then transmits the result to the front end for display.

[0005] The technical solution adopted by the present invention is:

[0006] A method for image compression transmission based on 5G transmission, characterized in that it includes the following specific steps:

[0007] S1. Take pictures;

[0008] The camera installed on the production line takes full coverage photos of the locations that need to be identified, and the captured images are cached and transmitted to the attached microprocessor unit;

[0009] S2, compression microprocessing unit;

[0010] Compress the captured images according to the compression algorithm to reduce bandwidth usage;

[0011] S3, compressed image;

[0012] S4, transmission;

[0013] The compressed images are transmitted through the 5G industrial router media channel;

[0014] S5, decompression processing;

[0015] After receiving the compressed image, the server performs decompression processing according to the reverse process of the compression process in step S3, performs image recognition on the decompressed image, and identifies and classifies non-tobacco debris in the image;

[0016] S6, transmitting the calculation structure to the front end;

[0017] According to the processing result of step S5, the result of whether there is debris in the image and its category are transmitted to the front end for display.

[0018] Furthermore, in step S3, the specific steps of compressing the image are as follows:

[0019] S31, converting the image into a color space;

[0020] Since the data volume of YUV mode is greatly reduced compared with RGB mode, the image is converted from RGB color space to YUV color space according to the following formula. The specific formula is as follows:

[0021] Y=0.299R+0.587G+0.114R (1)

[0022] U=-0.169R-0.331G_0.500B+128 (2)

[0023] V=0.500R-0.419G-0.081B-128 (3)

[0024] S32, sampling;

[0025] The 411 sampling method is adopted, that is, every four Ys share one UV, and the stored stream code is Y0 U0Y1 Y2 V2 Y3;

[0026] S33. Split;

[0027] Divide the image into 8*8 sub-blocks for processing;

[0028] S34, discrete cosine transform;

[0029] According to the following formula, DCT transformation is performed on YUV respectively. Since the two-dimensional DCT transformation does not depend on any DCT coefficient, in order to improve the DCT transformation rate, the two-dimensional DCT transformation method is selected, and the GPU processor is selected;

[0030] F(u,v)=Af(x,y)A T (4)

[0031] Where F(u, v) is the result after DCT, f(x, y) is the original image, A is the matrix coefficient, A T is the transposed matrix of the matrix coefficients;

[0032] S35, quantification;

[0033] Quantization is the root cause of the loss of image precision in the JPEG algorithm and the source of the compression effect. Quantization is performed according to the following quantization algorithm and quantization table.

[0034] B i,j =round(G i,j / Q i,j )jj=0,1,2,3,…7 (5)

[0035] Among them, B is the quantized image, G is the image matrix we need to process, Q is called the quantization coefficient matrix, the round function is the integer function; j is a positive integer;

[0036] S36, coding;

[0037] The encoding method is Huffman coding, that is, variable word length coding, which uses short codes to represent objects with a high probability of appearing in the signal source, and uses long codes to represent objects with a low probability of appearing;.

[0038] Furthermore, in step S36, the specific steps of encoding are as follows:

[0039] S361, sorting the signal sources according to the probability of occurrence;

[0040] S362, find two minimum probabilities in the original data. If they are not equal, their sizes are 1 and 0 respectively. If they are equal, 0 and 1 are randomly assigned.

[0041] S363, repeat the previous step with the added new probability point and the remaining probability points until the new probability point is 1;

[0042] S364, finally, the digital numbers of each object are combined according to the structural order.

[0043] Compared with the prior art, the beneficial effects of the present invention are as follows:

[0044] 1. The present invention reduces bandwidth occupancy by building a 5G transmission architecture between the camera and the server, and reduces pixel loss after image compression while ensuring the compression rate, thereby ensuring the accuracy of the subsequent image recognition algorithm.

[0045] 2. Under a certain bandwidth, the present invention can realize the uploading and downloading of a large number of pictures, and maximize the real-time and accuracy of image recognition, so as to locate the position and type of debris on the production line as quickly as possible and quickly feed back to the production line. BRIEF DESCRIPTION OF THE DRAWINGS

[0046] Figure 1 It is a transmission flow chart based on 5G communication of the present invention;

[0047] Figure 2 The present invention is based on Figure 1 The design structure is a flow chart for image transmission. DETAILED DESCRIPTION

[0048] The specific implementation of the embodiment of the present invention is described in detail below in conjunction with the accompanying drawings. It should be understood that the specific implementation described here is only used to illustrate and explain the embodiment of the present invention, and is not used to limit the embodiment of the present invention.

[0049] It should be noted that, in the absence of conflict, the embodiments of the present invention and the features in the embodiments may be combined with each other.

[0050] The present invention will be described in detail below in conjunction with exemplary embodiments with reference to the accompanying drawings.

[0051] A method for image compression transmission based on 5G transmission, characterized in that it includes the following specific steps:

[0052] S1. Take pictures;

[0053] The camera installed on the production line takes full coverage photos of the locations that need to be identified, and the captured images are cached and transmitted to the attached microprocessor unit;

[0054] S2, compression microprocessing unit;

[0055] Compress the captured images according to the compression algorithm to reduce bandwidth usage;

[0056] S3, compressed image;

[0057] Specifically, in step S3, the specific steps of compressing the picture are as follows:

[0058] S31, converting the image into a color space;

[0059] Since the data volume of YUV mode is greatly reduced compared with RGB mode, the image is converted from RGB color space to YUV color space according to the following formula. The specific formula is as follows:

[0060] Y=0.299R+0.587G+0.114R (1)

[0061] U=-0.169R-0.331G_0.500B+128 (2)

[0062] V=0.500R-0.419G-0.081B-128 (3)

[0063] S32, sampling;

[0064] Since the human eye is more sensitive to brightness changes, in order to reduce the accuracy of loss, the present invention preferably selects the 411 sampling method, that is, every four Ys share one UV, and the stored stream code is Y0 U0 Y1 Y2 V2 Y3, which reduces the amount of data and reduces the loss to a level that is invisible to the human eye;

[0065] S33. Split;

[0066] Divide the image into 8*8 sub-blocks for processing;

[0067] S34, discrete cosine transform;

[0068] According to the following formula, DCT transformation is performed on YUV respectively. Since the two-dimensional DCT transformation does not depend on any DCT coefficient, in order to improve the DCT transformation rate, the two-dimensional DCT transformation method is selected, and the GPU processor is selected;

[0069] F(u,v)=Af(x,y)A T (4)

[0070] Where F(u, v) is the result after DCT, f(x, y) is the original image, A is the matrix coefficient, A T is the transposed matrix of the matrix coefficients;

[0071] S35, quantification;

[0072] Quantization is the root cause of the loss of image precision in the JPEG algorithm and the source of the compression effect. Quantization is performed according to the following quantization algorithm and quantization table.

[0073] B i,j =round(G i,j / Q i,j )jj=0,1,2,3,…7 (5)

[0074] Among them, B is the quantized image, G is the image matrix we need to process, Q is called the quantization coefficient matrix, the round function is the integer function; j is a positive integer;

[0075] S36, coding;

[0076] The encoding method is Huffman coding, that is, variable word length coding, which uses short codes to represent objects with a high probability of appearing in the signal source, and uses long codes to represent objects with a low probability of appearing.

[0077] Specifically, in step S36, the specific steps of encoding are as follows:

[0078] S361, sorting the signal sources according to the probability of occurrence;

[0079] S362, find two minimum probabilities in the original data. If they are not equal, their sizes are 1 and 0 respectively. If they are equal, 0 and 1 are randomly assigned.

[0080] S363, repeat the previous step with the added new probability point and the remaining probability points until the new probability point is 1;

[0081] S364, finally, the digital numbers of each object are combined according to the structural order.

[0082] S4, transmission;

[0083] The compressed images are transmitted through the 5G industrial router media channel;

[0084] S5, decompression processing;

[0085] After receiving the compressed image, the server performs decompression processing according to the reverse process of the compression process in step S3, performs image recognition on the decompressed image, and identifies and classifies non-tobacco debris in the image;

[0086] S6, transmitting the calculation structure to the front end;

[0087] According to the processing result of step S5, the result of whether there is debris in the image and its category are transmitted to the front end for display.

[0088] In the present invention, the decompression process is merely the reverse process of the compression process and will not be described in detail in this description.

[0089] Although the embodiments of the present invention have been shown and described above, it is to be understood that the above embodiments are exemplary and are not to be construed as limitations of the present invention. A person skilled in the art may change, modify, replace and vary the above embodiments within the scope of the present invention.

Claims

1. A method for image compression transmission based on 5G transmission, characterized in that: The specific steps include: S1. Take pictures; The camera installed on the production line takes full coverage photos of the locations that need to be identified, and the captured images are cached and transmitted to the attached microprocessor unit; S2, compression microprocessing unit; Compress the captured images according to the compression algorithm to reduce bandwidth usage; S3, compressed image; S4, transmission; The compressed images are transmitted through the 5G industrial router media channel; S5, decompression processing; After receiving the compressed image, the server performs decompression processing according to the reverse process of the compression process in step S3, performs image recognition on the decompressed image, and identifies and classifies non-tobacco debris in the image; S6, transmitting the calculation structure to the front end; According to the processing result of step S5, the result of whether there is debris in the image and its category are transmitted to the front end for display.

2. The method for image compression transmission based on 5G transmission as claimed in claim 1, characterized in that: In step S3, the specific steps of compressing the picture are as follows: S31, converting the image into a color space; Since the data volume of YUV mode is greatly reduced compared with RGB mode, the image is converted from RGB color space to YUV color space according to the following formula. The specific formula is as follows: Y=0.299R+0.587G+0.114R (1) U=-0.169R-0.331G_0.500B+128 (2) V=0.500R-0.419G-0.081B-128 (3) S32, sampling; The 411 sampling method is adopted, that is, every four Ys share one UV, and the stored stream code is Y0 U0Y1 Y2 V2 Y3; S33. Split; Divide the image into 8*8 sub-blocks for processing; S34, discrete cosine transform; According to the following formula, DCT transformation is performed on YUV respectively. Since the two-dimensional DCT transformation does not depend on any DCT coefficient, in order to improve the DCT transformation rate, the two-dimensional DCT transformation method is selected, and the GPU processor is selected; F(u,v)=Af(x,y)A T (4) Where F(u, v) is the result after DCT, f(x, y) is the original image, A is the matrix coefficient, A T is the transposed matrix of the matrix coefficients; S35, quantification; Quantization is the root cause of the loss of image precision in the JPEG algorithm and the source of the compression effect. Quantization is performed according to the following quantization algorithm and quantization table. B i,j =round(G i,j / Q i,j )j j=0,1,2,3,…7 (5) Among them, B is the quantized image, G is the image matrix we need to process, Q is called the quantization coefficient matrix, the round function is the integer function; j is a positive integer; S36, coding; The encoding method is Huffman coding, that is, variable word length coding, which uses short codes to represent objects with a high probability of appearing in the signal source, and uses long codes to represent objects with a low probability of appearing.

3. The method for image compression transmission based on 5G transmission as claimed in claim 1, characterized in that: In step S36, the specific steps of encoding are as follows: S361, sorting the signal sources according to the probability of occurrence; S362, find two minimum probabilities in the original data. If they are not equal, their sizes are 1 and 0 respectively. If they are equal, 0 and 1 are randomly assigned. S363, repeat the previous step with the added new probability point and the remaining probability points until the new probability point is 1; S364, finally, the digital numbers of each object are combined according to the structural order.