Data compression device for ship data

By designing a data compression device for ship data, using multi-module collaborative operation and Swin Transformer model for target segmentation and HEVC encoding format for compression encoding, the problem of inability to transmit large-scale ship data in real time and lossless in the prior art is solved, and efficient data transmission is achieved.

CN120075306APending Publication Date: 2025-05-30TAIHU LAB OF DEEPSEA TECH SCI +1
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202510224753.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-27
Publication Date
2025-05-30

AI Technical Summary

Technical Problem

The prior art is difficult to transmit large volumes of ship data from the ship to the shore-based center in real time and losslessly.

Method used

A data compression device is designed, including a data processor and a communication switch. The ship data is compressed through the coordinated operation of multiple modules in the data processor (such as data reception module, control module, hardware parallel acceleration module, target segmentation module, data encoding module, etc.), and the target segmentation and HEVC encoding format are used for compression coding.

Benefits of technology

It realizes real-time and lossless transmission of large-scale ship data from the ship to the shore-based center, improving data transmission efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120075306A_ABST
    Figure CN120075306A_ABST
Patent Text Reader

Abstract

The invention discloses a data compression device for ship data, and relates to the technical field of ship data processing, and the device comprises a data processor and a communication switch. The data processor comprises a data receiving module, a control module, a hardware parallel acceleration module, a data processing module, a target segmentation module, a data decoding module, a data compression module, a data coding module and a data output module. And compressing the ship data transmitted by the plurality of pieces of ship equipment based on the video stream, and sending the compressed ship data to a shore-based center. The method is used for solving the problem that in the prior art, large-volume ship data cannot be transmitted to the shore-based center from the ship in a real-time and lossless mode, and the large-volume ship data can be transmitted to the shore-based center from the ship in a real-time and lossless mode.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of ship data processing, and in particular to a data compression device for ship data. Background Art

[0002] With the improvement of intelligence level, marine equipment has also undergone corresponding technological innovation and performance upgrades, which means that more types of data need to be collected and the amount of data is larger. Due to the particularity of the marine geographical environment, it is difficult for the existing ship-to-shore communication technology to transmit such a large amount of ship data to the shore-based center in real time and losslessly.

[0003] Therefore, how to transmit large amounts of ship data to shore-based centers in real time and without loss is an important issue that the industry needs to solve urgently. Summary of the invention

[0004] In response to the above-mentioned problems and technical needs, the applicant has proposed a data compression device for ship data to solve the problem in the prior art that large amounts of ship data cannot be transmitted from the ship to the shore-based center in real time and losslessly, and to achieve real-time and lossless transmission of large amounts of ship data from the ship to the shore-based center.

[0005] The embodiment of the present application provides a data compression device for ship data, the device comprising: a data processor and a communication switch;

[0006] The data processor is communicatively connected with the ship equipment installed on the ship through the communication switch, and is communicatively connected with the shore-based center through the communication switch;

[0007] The data processor comprises: a data receiving module, a control module, a hardware parallel acceleration module, a data processing module, a target segmentation module, a data decoding module, a data compression module, a data encoding module and a data output module;

[0008] The data receiving module is used to receive the ship data transmitted by multiple ship equipment based on the video stream and the control instructions sent by the shore-based center, and send the ship data and the control instructions to the control module;

[0009] The control module is used to respond to the control instruction, start the data compression function, and send the start identifier to the hardware parallel acceleration module and the data decoding module respectively;

[0010] The hardware parallel acceleration module is used to allocate a process to each ship data corresponding to the ship equipment based on the startup identifier, and process multiple processes in parallel through hardware;

[0011] The data decoding module is used to perform video decoding and frame splitting operations on the ship data corresponding to each process based on the start flag, and obtain multiple frames of images;

[0012] The target segmentation module is used to input multiple images into a pre-trained target segmentation model, and obtain a target probability map and a classification result output by the target segmentation model, where the target segmentation model is trained based on image samples, target probability map samples, and classification result samples representing ship data;

[0013] The data processing module is used to distinguish the background area and the target area in the image according to the target probability map and the classification result output by the target segmentation module, set a QP value for the distinguished image, and generate a QP offset map including the QP value, where the QP value of the background area is greater than the QP value of the target area;

[0014] The data encoding module is used to compress the image based on the QP offset map;

[0015] The data output module is used to send the compressed image to the shore-based center.

[0016] According to the data compression device for ship data provided by an embodiment of the present application, the target segmentation module includes: a model of Swin Transformer;

[0017] The model of Swin Transformer is used to extract features of each pixel in each frame of image through a self-attention mechanism; compare the extracted features with preset target features; determine the target category corresponding to the pixel based on the comparison result to obtain the classification result corresponding to the image; perform softmax processing on the image along the target category to obtain a target probability map in which the target category of each pixel is normalized.

[0018] According to the data compression device for ship data provided by an embodiment of the present application, the QP value includes: a first QP value and a second QP value, and the first QP value is greater than the second QP value;

[0019] The data processing module is used to set the first QP value for the background area and the second QP value for the target area; process the background area by combining downsampling and upsampling to obtain a processed background area.

[0020] According to the data compression device for ship data provided by an embodiment of the present application, the data encoding module is configured to perform compression encoding on the background area with a first compression ratio and on the target area with a second compression ratio based on the QP offset map by using the HEVC encoding format, where the first compression ratio is greater than the second compression ratio.

[0021] According to the data compression device for ship data provided by an embodiment of the present application, the data processor further includes: a data preprocessing module;

[0022] The data preprocessing module is configured to perform a denoising operation on each frame of image of each process;

[0023] Wherein, the denoising operation includes:

[0024] For each pixel of the image, calculate the weighted value within the preset range of the pixel through a Gaussian function, and obtain a Gaussian kernel with a dimension of 5*5 based on the weighted value;

[0025] Perform a convolution operation on the Gaussian kernel and the image to obtain a denoised image;

[0026] Wherein, the Gaussian function includes:

[0027]

[0028] Wherein, G(x,y) represents the Gaussian kernel, σ represents the standard deviation of the Gaussian distribution, which is a constant, and x and y represent the positions of the pixels in the image;

[0029] Wherein, the convolution operation includes:

[0030]

[0031] Wherein, I′(x,y) represents the pixel value at the position (x,y) after denoising, k represents the Gaussian kernel radius, which is a constant, G(i,j) represents the weighted value corresponding to the position (i,j) in the Gaussian kernel, and I(x+i,y+j) represents the pixel value at the position (x+i,y+j) before denoising.

[0032] According to the data compression device for ship data provided by an embodiment of the present application, the data processor further includes: a data preprocessing module;

[0033] The data preprocessing module is configured to convert the RGB color space of multiple frames of images corresponding to each process into the YUV color space, and make multiple pixels in the RGB color space share one U value and one V value by using a preset chrominance downsampling standard.

[0034] According to the data compression device for ship data provided by an embodiment of the present application, the data processing module is configured to perform average pooling operation on each pixel in the background area to obtain the pooled background area; and perform upsampling operation based on the bilinear interpolation method to restore the image resolution of the pooled background area to obtain the final background area.

[0035] Among them, the average pooling operation includes:

[0036]

[0037] Among them, average(i, j) represents the pixel after average pooling, n represents the size of the pooling area, which is a constant, O(i, j) represents the pixel value at the position (x, y), s represents the offset of the pooling area in the vertical direction, and d represents the offset of the pooling area in the horizontal direction.

[0038] Among them, the bilinear interpolation method includes:

[0039] O(x′, y′) = O(x 1 , y 1 )·(1 - α)·(1 - β) + O(x 2 , y 1 )·α·(1 - β)

[0040] + O(x 1 , y 2 )·(1 - α)·β + O(x 2 , y 2 )·α·β;

[0041] Among them, O(x′, y′) represents the target position in the background area after average pooling, (x 1 , y 1 ), (x 1 , y 2 ), (x 2 , y 1 ), (x 2 , y 2 ) are the coordinates of four adjacent points corresponding to the target position.

[0042] According to the data compression device for ship data provided by an embodiment of the present application, the device further includes: a terminal block;

[0043] The terminal block is used to connect the data processor and the communication switch, as well as each module in the data processor.

[0044] According to the data compression device for ship data provided by an embodiment of the present application, the device further includes: a power distributor;

[0045] The power distributor is connected to an external power supply and is used to convert the external power supply into a standard power supply corresponding to the data processor and the communication switch.

[0046] According to the data compression device for ship data provided by an embodiment of the present application, the communication switch includes a communication module;

[0047] The communication module is powered by two 60W dual redundant power supplies, the interface follows the IEEE802.3af / at standard, the output power of a single interface can reach 30W, and the total output power can reach 120W.

[0048] The data compression device for ship data provided by an embodiment of the present application includes: a data processor and a communication switch. The data processor includes: a data receiving module, a control module, a hardware parallel acceleration module, a data processing module, a target segmentation module, a data decoding module, a data compression module, a data encoding module, and a data output module. Through the collaborative operation of each module in the data processor, the ship data based on video stream transmission from multiple marine equipment is compressed, and the compressed ship data is sent to the shore-based center. Through the data processor and the communication switch, the present application realizes stable communication connection and data transmission with multiple marine equipment, improves the data transmission efficiency through compression, and realizes the purpose of real-time and lossless transmission of a large amount of ship data from the ship to the shore-based center. Description of the Drawings

[0049] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the drawings required for use in the description of the embodiments or the prior art. Obviously, the following drawings are some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other drawings can also be obtained based on these drawings.

[0050] Figure 1 is one of the structural schematic diagrams of the data compression device for ship data provided by an embodiment of the present application;

[0051] Figure 2 is the second structural schematic diagram of the data compression device for ship data provided by an embodiment of the present application;

[0052] Figure 3 is the data processing flow schematic diagram of the data compression device for ship data provided by an embodiment of the present application. Detailed Embodiments

[0053] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the following will clearly and completely describe the technical solutions in the embodiments of this application with reference to the accompanying drawings in the embodiments of the present invention. Apparently, the described embodiments are some, but not all, of the embodiments of this application. All other embodiments obtained by those of ordinary skill in the art based on the embodiments in this application without creative efforts belong to the scope of protection of the present invention.

[0054] An embodiment of this application provides a data compression device for ship data. As Figure 1 shown, the device includes: a data processor 1 and a communication switch 2.

[0055] The data processor 1 is communicatively connected to marine equipment installed on the ship through the communication switch 2, and is communicatively connected to the shore-based center through the communication switch 2.

[0056] The data processor 1 includes: a data receiving module 11, a control module 12, a hardware parallel acceleration module 13, a data processing module 14, a target segmentation module 15, a data decoding module 16, a data compression module 17, a data encoding module 18, and a data output module 19.

[0057] The data receiving module 11 is configured to receive ship data transmitted by multiple marine equipment based on video streams and control instructions sent by the shore-based center, and send the ship data and control instructions to the control module 12.

[0058] The control module 12 is configured to respond to the control instructions, start the data compression function, and send start flags to the hardware parallel acceleration module 13 and the data decoding module 16 respectively.

[0059] The hardware parallel acceleration module 13 is configured to allocate a process for the ship data corresponding to each marine equipment based on the start flag, and process multiple processes in parallel through hardware.

[0060] The data decoding module 16 is configured to perform video decoding and frame splitting operations on the ship data corresponding to each process based on the start flag, obtain multiple frames of images, and send the multiple frames of images to the target segmentation module 15.

[0061] The target segmentation module 15 is configured to input multiple images into a pre-trained target segmentation model, obtain a target probability map and a classification result output by the target segmentation model, and send the images, the target probability map, and the classification result to the data processing module 14.

[0062] Wherein, the target segmentation model is trained based on image samples, target probability map samples, and classification result samples representing ship data.

[0063] The data processing module 14 is configured to distinguish the background region and the target region in the image according to the target probability map and the classification result output by the target segmentation module, set a QP value for the distinguished image, generate a QP offset map including the QP value, and send the QP offset map and the image to the data encoding module 16.

[0064] Among them, the QP value of the background region is greater than the QP value of the target region.

[0065] The data encoding module 16 is configured to compress the image based on the QP offset map and send the compressed image to the data output module 18.

[0066] The data output module 18 is configured to send the compressed image to the shore-based center.

[0067] The data compression device for ship data provided by the embodiment of the present application includes: a data processor 1 and a communication switch 2. The data processor 1 includes: a data receiving module 11, a control module 12, a hardware parallel acceleration module 13, a data processing module 14, a target segmentation module 15, a data decoding module 16, a data compression module 17, a data encoding module 18, and a data output module 19. Through the collaborative operation of each module in the data processor 1, the ship data transmitted based on the video stream by multiple marine equipment is compressed, and the compressed ship data is sent to the shore-based center. Through the data processor 1 and the communication switch 2, the present application realizes stable communication connection and data transmission with multiple marine equipment, improves the data transmission efficiency by means of compression, and realizes the purpose of transmitting a large amount of ship data from the ship to the shore-based center in real time and losslessly.

[0068] In a specific embodiment, the device further includes: a terminal block, and the terminal block is waterproof and dustproof.

[0069] The terminal block is used to connect the data processor 1 and the communication switch 2, as well as each module in the data processor 1.

[0070] In a specific embodiment, the device further includes: a power distributor.

[0071] The power distributor is connected to an external power supply and is configured to convert the external power supply into a standard power supply corresponding to the data processor 1 and the communication switch 20.

[0072] Specifically, a 220V input power supply is converted into two independent 60W 48V power supplies and one 15W 12V power supply through a transformer and a voltage regulator. The two independent 60W 48V power supplies are used to supply power to the communication switch 2, and one 15W 12V power supply is used to supply power to the data processor 1.

[0073] In a specific embodiment, the communication switch 2 includes a communication module, which is powered by two 60W dual redundant power supplies. The interface complies with the IEEE802.3af / at standard. The output power of a single interface can reach 30W, and the total output power can reach 120W.

[0074] The communication switch 2 has protection mechanisms such as overcurrent, overvoltage, surge, and short circuit that comply with PSE standards. Each port has its own independent circuit and independent fuse. Even if a single circuit fails, it will not affect the normal operation of other ports.

[0075] Specifically, the data processor 1 is used for forwarding and compressing the video stream, and is embedded in a backend server for device function control, as well as a local database for storing and backing up the streaming data.

[0076] The data processor 1 can use a professional industrial control computer card, configured with an octa-core 64-bit CPU (4*Cortex-A76+4*Cortex-A55), an ARM Mali-G610 MP4 quad-core GPU, 32G memory, 257G eMMC onboard storage, 1T NVMe SSD extended hard disk storage, a Gigabit Ethernet interface, and can run Android / Linux systems.

[0077] The data processor 1 is connected to the communication switch 2 via USB to Ethernet to realize the input and output of data of 8-way RJ45 Ethernet interface. All data can be read and processed in the data processor 1 through software.

[0078] Specifically, an open source MySQL local database is deployed in the data receiving module 11 for storing and backing up the flow data. Embedded device function control software is deployed in the control module 12, which can control the marine equipment according to the remote control instructions in the same local area network.

[0079] The embedded device function control software deployed in the control module 12 is developed in accordance with the native HTML / CSS / JavaScript development model, based on the Layui open source free Web UI front-end framework and the Flask lightweight web application back-end framework. Users in the same local area network communicate with the back-end through the front-end web interface, thereby sending control instructions to the control module.

[0080] Specifically, the hardware parallel acceleration module 13 assigns processes to the input ship data, and processes each process in parallel through hardware. Each CPU main core corresponds to a process, and each process can be divided into multiple threads to perform different operations on the ship data. The data processing speed is improved through multi-process and multi-thread operations.

[0081] Specifically, the overall operating temperature of the device is -20°C to 80°C, the dust and waterproof rating is IP65, and all components pass the vibration test (amplitude 5 mm, frequency 50 Hz, time 1 hour), the aging screening test (85°C, 8 hours), and the high-temperature operating test (80°C, 20 minutes, 60°C, 1 hour).

[0082] In a specific embodiment, the device further includes: a data preprocessing module.

[0083] The data preprocessing module is used to perform denoising processing operations on each frame of images of each process.

[0084] Among them, the denoising processing operations include:

[0085] For each pixel of the image, calculate the weighted value within the preset range of the pixel through the Gaussian function, and obtain a Gaussian kernel with a dimension of 5*5 based on the weighted value; perform a convolution operation on the Gaussian kernel and the image to obtain the denoised image.

[0086] Specifically, the noise in the data is removed by Gaussian filtering, and the width of the filter is controlled by the standard deviation of the Gaussian distribution, which determines the smoothness of the filtering and can take a value of 1.

[0087] Among them, the 5*5 dimension is obtained based on the marine environment.

[0088] Among them, the Gaussian function is shown in formula (1):

[0089]

[0090] Among them, G(x, y) represents the Gaussian kernel, σ represents the standard deviation of the Gaussian distribution, which is a constant, and x and y represent the positions of the pixels in the image.

[0091] Among them, the convolution operation is shown in formula (2):

[0092]

[0093] Among them, I′(x, y) represents the pixel value at the position (x, y) after denoising, k represents the Gaussian kernel radius, which is a constant (for example, 2), G(i, j) represents the weighted value corresponding to the position (i, j) in the Gaussian kernel, and I(x + i, y + j) represents the pixel value at the position (x + i, y + j) before denoising.

[0094] In a specific embodiment, the data preprocessing module is used to convert the RGB color space of multiple frames of images corresponding to each process into the YUV color space, and make multiple pixels in the RGB color space share one U value and one V value by using the preset chrominance downsampling standard.

[0095] For example, the chrominance downsampling standard of 4:2:0 allows four pixels (a 2×2 block) to share one U value and one V value, that is, the U values and V values of four pixels in the image corresponding to the RGB color space (original image) are averaged to obtain the shared U value and V value. For details, see formulas (3) and (4):

[0096]

[0097]

[0098] wherein, U x,y , U x+1,y , U x,y+1 , U x+1,y+1 represent the U values corresponding to four pixels respectively, and U x′,y′ represents the shared U value. V x,y , V x+1,y , V x,y+1 , V x+1,y+1 represent the V values corresponding to four pixels respectively, and V x′,y′ represents the shared V value.

[0099] Specifically, the data preprocessing module is connected to the data decoding module 16. The data decoding module 16 sends multiple frames of images to the data preprocessing module. The data preprocessing module performs denoising processing on each image, performs color space conversion on the denoised image, and sends the converted image to the target segmentation module 15.

[0100] In a specific embodiment, the data processing module 14 is configured to perform average pooling on each pixel in the background region to obtain the pooled background region; perform upsampling based on the bilinear interpolation method to restore the image resolution of the pooled background region to obtain the final background region. Then, the QP offset map and the final image are sent to the data encoding module 16.

[0101] Among them, the average pooling operation is shown in formula (5):

[0102]

[0103] wherein, average(i,j) represents the pixel after average pooling, n represents the size of the pooling region, which is a constant, O(i,j) represents the pixel value at the position (x,y), s represents the offset of the pooling region in the vertical direction, and d represents the offset of the pooling region in the horizontal direction.

[0104] Among them, the bilinear interpolation method is shown in formula (6):

[0105] O(x′,y′) = O(x 1 ,y 1)·(1-α)·(1-β)+O(x 2 ,y 1 )·α·(1-β)+O(x 1 ,y 2 )·(1-α)·β+O(x 2 ,y 2 )·α·β………(6)

[0106] Among them, O(x′, y′) represents the target position in the background area after average pooling, and (x 1 ,y 1 ),(x 1 ,y 2 ),(x 2 ,y 1 ),(x 2 ,y 2 ) are the coordinates of four adjacent points corresponding to the target position.

[0107] Specifically, by first reducing the image resolution and then restoring the image resolution, the complexity of the background area is reduced, unnecessary details are weakened, and the data volume is reduced.

[0108] In a specific embodiment, the target segmentation module 15 includes: a model of Swin Transformer.

[0109] The model of Swin Transformer is used to extract features for each pixel in each frame of image through the self-attention mechanism; compare the extracted features with the preset target features; determine the target category corresponding to the pixel based on the comparison result to obtain the classification result corresponding to the image; perform softmax processing on the image along the target category to obtain the target probability map after normalizing the target category of each pixel.

[0110] Among them, the extracted features include: shape, color, and position, etc.

[0111] Among them, the classification result is a multi-channel tensor including the target category.

[0112] Among them, the softmax processing is shown in formula (7):

[0113]

[0114] Among them, m represents the number of target categories, c represents the target category, and softmax(c) i represents the target probability.

[0115] Specifically, the target probability is compared with the preset probability. The pixels with a target probability greater than the preset probability are determined to belong to the target region, and the pixels with a target probability less than or equal to the preset probability are determined to belong to the background region.

[0116] In a specific embodiment, the QP value includes: a first QP value and a second QP value, and the first QP value is greater than the second QP value.

[0117] The data processing module 14 is configured to set the first QP value for the background region and the second QP value for the target region; process the background region by using a combination of downsampling and upsampling to obtain a processed background region.

[0118] Specifically, the complexity of the background region is reduced by using a combination of downsampling and upsampling for the background region, and unnecessary details are weakened. The target region is not processed and remains unchanged.

[0119] In a specific embodiment, the data encoding module 18 is configured to perform compression encoding on the background region with a first compression ratio and on the target region with a second compression ratio based on the QP offset map by using the HEVC encoding format.

[0120] Among them, the first compression ratio is greater than the second compression ratio.

[0121] Specifically, the present application adopts an adaptive encoding method, performs low-quality encoding on the background region, performs high-quality encoding on the target region, and combines the two to obtain a compressed video stream encoding.

[0122] Specifically, the following is a schematic illustration of the device: Figure 2

[0123] In Figure 2 it includes: a data processor 1, a communication switch 2, a terminal block 3, and a power distributor 4.

[0124] The power distributor 4 includes: a power module 41 and at least four terminal blocks 3. The four terminal blocks 3 include: a terminal block 3 connected to an external power supply, a terminal block 3 connected to the data processor 1, and two terminal blocks 3 connected to the communication switch 2.

[0125] The communication switch 2 includes: a communication module 21 and at least three terminal blocks 3. The three terminal blocks 3 include: two terminal blocks 3 connected to the power distributor 4 and a terminal block 3 connected to the data processor 1.

[0126] The data processor 1 further includes: a terminal block 3 connected to the power distributor 4 and a terminal block 3 connected to the communication switch 2.

[0127] ​In addition, the data processor 1, the communication switch 2, and the power distributor 4 each have at least one redundant terminal 3. For example, the data processor 1 is connected to the host computer using the redundant terminal 3 to achieve human-machine interaction.

[0128] Specifically, the following will Figure 3 specifically describe the processing flow of the device for ship data:

[0129] Step 301, receive ship data transmitted based on video streams from multiple marine devices and control instructions sent by the shore-based center through the data reception module, and store the ship data in the local database.

[0130] Step 302, respond to the control instructions through the control module to start the data compression function.

[0131] Step 303, automatically allocate processes and threads through the hardware parallel acceleration module to process data in parallel and accelerate it.

[0132] Step 304, perform preprocessing operations on the ship data through the data preprocessing module.

[0133] Step 305, perform video decoding and frame splitting operations on the ship data corresponding to each process through the data decoding module to obtain multiple frames of images.

[0134] Step 306, input multiple images into a pre-trained target segmentation model through the target segmentation module to obtain the target probability map and classification results output by the target segmentation model.

[0135] Step 307, based on the target probability map and classification results output by the target segmentation module, distinguish the background area and the target area in the image through the data processing module, set a QP value for the distinguished image, and generate a QP offset map including the QP value.

[0136] Step 308, compress the image based on the QP offset map through the data encoding module.

[0137] Step 309, output the compressed video stream through the data output module.

[0138] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed to multiple network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment. Those of ordinary skill in the art can understand and implement it without creative labor.

[0139] Finally, it should be noted that the above is only the preferred implementation of the present application, and the present application is not limited to the above embodiments. It is understood that other improvements and changes directly derived or associated by those skilled in the art without departing from the spirit and concept of the present application should be considered to be included in the scope of protection of the present application.

Claims

1. A data compression device for ship data, characterized in that: The device comprises: a data processor and a communication switch; The data processor is communicatively connected with the ship equipment installed on the ship through the communication switch, and is communicatively connected with the shore-based center through the communication switch; The data processor comprises: a data receiving module, a control module, a hardware parallel acceleration module, a data processing module, a target segmentation module, a data decoding module, a data compression module, a data encoding module and a data output module; The data receiving module is used to receive the ship data transmitted by multiple ship equipment based on the video stream and the control instructions sent by the shore-based center, and send the ship data and the control instructions to the control module; The control module is used to respond to the control instruction, start the data compression function, and send the start identifier to the hardware parallel acceleration module and the data decoding module respectively; The hardware parallel acceleration module is used to allocate a process to each ship data corresponding to the ship equipment based on the startup identifier, and process multiple processes in parallel through hardware; The data decoding module is used to perform video decoding and frame division operations on the ship data corresponding to each process based on the start identifier to obtain multiple frames of images; The target segmentation module is used to input the plurality of images into a pre-trained target segmentation model to obtain a target probability map and a classification result output by the target segmentation model, wherein the target segmentation model is trained based on image samples representing ship data, target probability map samples and classification result samples; The data processing module is used to distinguish the background area and the target area in the image according to the target probability map and the classification result output by the target segmentation module, set the QP value for the distinguished image, and generate a QP offset map including the QP value, wherein the QP value of the background area is greater than the QP value of the target area; The data encoding module is used to compress the image based on the QP offset map; The data output module is used to send the compressed image to the shore-based center.

2. The data compression device for ship data according to claim 1, characterized in that: The target segmentation module includes: a Swin Transformer model; The Swin Transformer model is used to extract features from each pixel in each frame of the image through a self-attention mechanism; compare the extracted features with preset target features; determine the target category corresponding to the pixel based on the comparison result to obtain a classification result corresponding to the image; perform softmax processing on the image along the target category to obtain a target probability map after normalization of the target category of each pixel.

3. The data compression device for ship data according to claim 1, characterized in that: The QP value includes: a first QP value and a second QP value, the first QP value being greater than the second QP value; The data processing module is used to set the first QP value for the background area and set the second QP value for the target area; and process the background area by combining downsampling and upsampling to obtain a processed background area.

4. The data compression device for ship data according to claim 1, characterized in that: The data encoding module is used to compress and encode the background area with a first compression ratio and compress and encode the target area with a second compression ratio based on the QP offset map using the HEVC encoding format, wherein the first compression ratio is greater than the second compression ratio.

5. The data compression device for ship data according to any one of claims 1 to 4, characterized in that: The data processor also includes: a data preprocessing module; The data preprocessing module is used to perform a denoising operation on each frame of image in each process; The denoising operation includes: For each pixel of the image, a weighted value within a preset range of the pixel is calculated using a Gaussian function, and a Gaussian kernel with a dimension of 5*5 is obtained based on the weighted value; Performing a convolution operation on the Gaussian kernel and the image to obtain a denoised image; Among them, Gaussian functions include: Among them, G(x,y) represents the Gaussian kernel, σ represents the standard deviation of the Gaussian distribution, which is a constant, and x and y represent the position of the pixel in the image; Among them, the convolution operation includes: Among them, I′(x,y) represents the pixel value at the position (x,y) after denoising, k represents the radius of the Gaussian kernel, which is a constant, G(i,j) represents the weighted value corresponding to the position (i,j) in the Gaussian kernel, and I(x+i,y+j) represents the pixel value at the position (x+i,y+j) before denoising.

6. The data compression device for ship data according to any one of claims 1 to 4, characterized in that: The data processor also includes: a data preprocessing module; The data preprocessing module is used to convert the RGB color space of multiple frames of images corresponding to each process into the YUV color space, and use a preset chroma downsampling standard to make multiple pixels in the RGB color space share a U value and a V value.

7. The data compression device for ship data according to any one of claims 1 to 4, characterized in that: The data processing module is used to perform an average pooling operation on each pixel in the background area to obtain a pooled background area; An upsampling operation is performed based on a two-line difference method to restore the image resolution of the background area after pooling, and the final background area is obtained; Among them, the average pooling operation includes: Where average(i,j) represents the pixel after average pooling, n represents the size of the pooling area, which is a constant, O(i,j) represents the pixel value at the (x,y) position, s represents the vertical offset of the pooling area, and d represents the horizontal offset of the pooling area; Among them, the two-line difference method includes: O(x′,y′)=O(x1,y1)·(1-α)·(1-β)+O(x2,y1)·α·(1-β)+O(x1,y2)·(1-α)·β+O(x2,y2)·α·β; Among them, O(x′,y′) represents the target position in the background area after average pooling, (x1,y1),(x1,y2),(x2,y1),(x2,y2) are the coordinates of the four neighboring points corresponding to the target position, 8. The data compression device for ship data according to any one of claims 1 to 4, characterized in that: The device further comprises: a connection terminal; The connection terminal is used to connect the data processor and the communication switch, as well as each module in the data processor.

9. The data compression device for ship data according to any one of claims 1 to 4, characterized in that: The device also includes: a power distributor; The power distributor is connected to an external power source and is used to convert the external power source into a standard power source corresponding to the data processor and the communication switch.

10. The data compression device for ship data according to any one of claims 1 to 4, characterized in that: The communication switch includes a communication module; The communication module is powered by two 60W dual redundant power supplies, the interface complies with the IEEE802.3af / at standard, the output power of a single interface can reach 30W, and the total output power can reach 120W.

Citation Information

Patent Citations

  • ROI-based video coding method and system and video transmission and coding system

    CN111447449A

  • Hierarchical compression method and device for regions of interest of vessel

    CN117058257A

  • Ship-shore data compression and transmission method

    CN118555094A