Adaptive data compression method, sending method and system based on Beidou short message
By using an adaptive data compression method in the Beidou short message system and selecting an appropriate compression algorithm (LZW or Huffman) to process timing and natural language information, the problem of limited transmission capacity and frequency of the Beidou short message system is solved, and efficient data compression and real-time transmission are achieved.
Patent Information
- Application Number
- CN202411728935.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-28
- Publication Date
- 2025-02-28
AI Technical Summary
Due to the limited transmission capacity and frequency of Beidou short message system, the data transmission volume and timeliness are limited, making it difficult to meet the needs of maritime services.
Adaptive data compression method based on Beidou short message is adopted. By judging the data type and selecting the appropriate compression algorithm (LZW or Huffman) for compression, ensuring that the data remains complete and real-time during transmission.
Efficient data compression is achieved within a limited short message capacity, reducing the amount of data transmitted, saving Beidou satellite resources, improving transmission efficiency, and ensuring real-time and integrity of data.
Smart Images

Figure CN119545427A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data compression, and more specifically, to an adaptive data compression method, a sending method and a system based on Beidou short messages. Background Art
[0002] The BeiDou Navigation Satellite System (BDS) can provide global users with high-precision and high-reliability navigation positioning, timing and short message services. BDS short message communication is one of the unique services that distinguishes the BDS from other global satellite navigation systems. At present, BDS short message technology is becoming more and more mature and has begun to be applied to various industries, such as electricity, ocean communications, ecological monitoring, flight tracking, landslide monitoring, emergency rescue and satellite positioning data broadcasting.
[0003] The BeiDou short message system provides two types of short message communication services: regional short message and global short message. BeiDou regional short message can transmit up to 1,000 Chinese characters in a single communication, and BeiDou-3 global short message can transmit up to 40 Chinese characters in a single communication.
[0004] Beidou short messages can realize point-to-point and multi-point-to-multi-point two-way data transmission, with a wide coverage range and no blind spots in communication. Their application in various important fields is gradually increasing, and they have been widely used in maritime distress alarms, maritime safety information broadcasting, ship-shore information interaction, etc. However, due to the shortage of satellite communication resources, the Beidou short message system has problems such as limited message length and communication frequency, and the application of short message functions is subject to certain restrictions.
[0005] An efficient data compression algorithm can effectively improve the application efficiency of the Beidou short message system, make more rational use of Beidou satellite resources, and enhance the maritime service capabilities of the short message system. Therefore, how to achieve efficient data compression within the limited short message capacity while ensuring the integrity and real-time nature of the data is an important topic that needs to be studied in the Beidou short message communication process of the maritime system.
[0006] Through the above analysis, the problems faced by the existing Beidou short message communication are:
[0007] (1) The limited data capacity of BeiDou short message transmission limits the amount of data transmission;
[0008] (2) The Beidou short message communication frequency limits the timeliness of data. Summary of the invention
[0009] The present invention aims to overcome at least one defect (shortcoming) of the above-mentioned prior art and provide an adaptive data compression method, a sending method and a system based on Beidou short messages, so as to solve the problem of how to ensure the integrity and real-time performance of data under the condition that the transmission capacity and transmission frequency of Beidou short message communication are limited.
[0010] The technical solution adopted by the present invention is:
[0011] In a first aspect, an adaptive data compression method based on Beidou short message is provided, which is used to compress data sent through Beidou short message, including:
[0012] Determine whether the data is time series information and whether it is natural language information;
[0013] If the data is time series information, the LZW compression algorithm is used to compress the data;
[0014] If the data is natural language information, the Huffman compression algorithm is used to compress the data;
[0015] If the data is a mixture of time series information and natural language information, or the data is neither time series information nor natural language information, or the data is not clearly time series information or natural language information, the compression ratios of the data compressed by the LZW and Huffman compression algorithms are compared, and a compression algorithm with a smaller compression ratio is selected to compress the data.
[0016] Preferably, the data is non-distress information, which has a higher priority than distress information.
[0017] Preferably, the time series information includes one or more of ship position information, ship status information, and historical track information; the natural language information includes one or more of ship-to-shore communication information and ship-to-ship communication information.
[0018] In a second aspect, a method for sending data based on Beidou short messages is provided, comprising:
[0019] Determine whether the data is distress information or non-distress information;
[0020] If the data is a distress message, the data is placed in a transmission queue;
[0021] If the data is non-distress information, the adaptive data compression method based on Beidou short message as described in the first aspect is used to compress the data, and the compressed data is placed in a transmission queue;
[0022] The priority of distress information in the transmission queue is higher than that of non-distress information in the transmission queue, and the data in the transmission queue is sent according to the priority.
[0023] Preferably, the data is sampled according to a sampling frequency, and the data sending method further includes: determining whether the population variance of the data collected in a number of sampling periods is stable, if it is stable, reducing the sampling frequency of the data, if it is unstable, increasing the sampling frequency of the data; the population variance is calculated according to the following formula:
[0024]
[0025]
[0026]
[0027] Where Q is the data, and P is the total amount of data Q; is the population variance of the entire dataset, p q is the amount of data in the qth data set; is the population variance of the qth data point.
[0028] Preferably, judging whether the population variance of the data collected in several sampling periods is stable, if it is stable, reducing the sampling frequency of the data, if it is unstable, increasing the sampling frequency of the data, specifically includes:
[0029] Determine the chi-square distribution x of several sampling periods 2 Are they all less than the threshold? a is a significant parameter, Q-1 is the degree of freedom;
[0030] If so, reduce the sampling frequency of the data;
[0031] If not, increase the sampling frequency of the data;
[0032] Chi-square distribution 2 Calculated using the following formula:
[0033]
[0034] Preferably, the sampling frequency of the data is reduced, specifically by reducing the sampling frequency of the data by 5%-15%; the sampling frequency of the data is increased, specifically by increasing the sampling frequency of the data by 5%-15%; several sampling cycles, specifically 3-8 sampling cycles.
[0035] In a third aspect, an adaptive data compression system based on Beidou short message is provided, which is used to compress data sent through Beidou short message, including:
[0036] A type judgment module is used to judge whether the data is time series information and whether it is natural language information;
[0037] The adaptive compression module is used to compress the data using the LZW compression algorithm if the type judgment module determines that the data is time series information; if the type judgment module determines that the data is natural language information, then the Huffman compression algorithm is used to compress the data; if the type judgment module determines that the data is a mixture of time series information and natural language information, or the data is neither time series information nor natural language information, or the data is not clear whether it is time series information or natural language information, then the compression ratios of the LZW and Huffman compression algorithms for compressing the data are compared, and a compression algorithm with a smaller compression ratio is selected to compress the data.
[0038] Preferably, the data is non-distress information, which has a higher priority than distress information.
[0039] Preferably, the time series information includes one or more of ship position information, ship status information, and historical track information; the natural language information includes one or more of ship-to-shore communication information and ship-to-ship communication information.
[0040] In a fourth aspect, a ship maritime terminal system is provided, comprising:
[0041] A distress judgment module is used to judge whether the data is distress information or non-distress information;
[0042] The adaptive data compression system based on Beidou short message as described in the third aspect is used to compress the data when the distress judgment module determines that the data is non-distress information;
[0043] The transmission management module is used to place the data in the transmission queue when the distress judgment module determines that the data is distress information; when the distress judgment module determines that the data is non-distress information, the data compressed by the adaptive data compression system is placed in the transmission queue; the priority of distress information in the transmission queue is higher than the priority of non-distress information in the transmission queue;
[0044] The data sending module is used to send the data in the transmission queue according to the priority.
[0045] Preferably, the data is sampled according to a sampling frequency, and the adaptive data compression system further comprises:
[0046] The frequency adjustment module is used to determine whether the population variance of the data collected in several sampling periods is stable. If it is stable, the sampling frequency of the data is reduced; if it is unstable, the sampling frequency of the data is increased; the population variance is calculated according to the following formula:
[0047]
[0048]
[0049]
[0050] Where Q is the data, and P is the total amount of data Q; is the population variance of the entire dataset, p q is the amount of data in the qth data set; is the population variance of the qth data point.
[0051] Preferably, the frequency adjustment module is used to determine whether the population variance of the data collected in several sampling periods is stable, and if it is stable, the sampling frequency of the data is reduced; if it is unstable, the sampling frequency of the data is increased, and specifically includes:
[0052] Frequency adjustment module, used to determine the chi-square distribution of several sampling periods 2 Are they all less than the threshold? a is a significant parameter, Q-1 is the degree of freedom, if yes, then reduce the sampling frequency of the data, if no, increase the sampling frequency of the data;
[0053] Chi-square distribution 2 Calculated using the following formula:
[0054]
[0055] Preferably, the frequency adjustment module is used to determine the chi-square distribution x of several sampling periods 2 Are they all less than the threshold? If yes, then reduce the data sampling frequency, if no, increase the data sampling frequency, specifically including:
[0056] Frequency adjustment module, used to determine the chi-square distribution x of several sampling periods 2 Are they all less than the threshold? If yes, the sampling frequency of the data is reduced by 5%-15%; if no, the sampling frequency of the data is increased by 5%-15%;
[0057] Several sampling periods, specifically 3-8 sampling periods.
[0058] A fifth aspect provides a computer device, including:
[0059] Memory for storing computer programs;
[0060] A processor is used to implement the steps of the adaptive data compression method based on Beidou short message as described in the first aspect or the data sending method based on Beidou short message as described in the second aspect when executing a computer program.
[0061] In a sixth aspect, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps of the adaptive data compression method based on Beidou short messages as described in the first aspect or the data sending method based on Beidou short messages as described in the second aspect are implemented.
[0062] Compared with the prior art, the beneficial effects of the present invention are: when the message length of short message communication is limited, efficient data compression can be achieved through adaptive data compression, which greatly reduces the amount of transmitted data, saves Beidou satellite resources, and improves transmission efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0063] Figure 1 The present invention is a flowchart of an adaptive data compression method based on Beidou short message according to an embodiment of the present invention.
[0064] Figure 2 This is a schematic diagram of the LZW compression algorithm according to an embodiment of the present invention.
[0065] Figure 3 This is a schematic diagram of the Huffman compression algorithm according to an embodiment of the present invention.
[0066] Figure 4 The present invention is a flowchart of a method for sending data based on Beidou short messages according to an embodiment of the present invention.
[0067] Figure 5 The composition diagram of the adaptive data compression system based on Beidou short message in the embodiment of the present invention is as follows
[0068] Figure 6 This is a composition diagram of a ship maritime terminal system according to an embodiment of the present invention. DETAILED DESCRIPTION
[0069] In order to make the purpose, technical solution and advantages of the embodiments of the present invention more clear, the technical solution in the embodiments of the present invention will be clearly and completely described below in combination with the embodiments of the present invention.
[0070] Example 1
[0071] like Figure 1 As shown, this embodiment provides an adaptive data compression method based on Beidou short message, which is used to compress data sent through Beidou short message.
[0072] Before using the method provided in this embodiment to compress data, a feature extraction algorithm can be used to identify and retain valuable data features for the data and remove irrelevant or redundant information. For example, for maritime communications, the timing information at the same time can be transmitted only once; the ship position information within a period of communication frequency is integrated into track information to avoid information redundancy.
[0073] Among them, the data feature extraction algorithm can use the sliding window method and principal component analysis (PCA). The sliding window method extracts features from the ship's position information, ship status information, historical track information, etc. during the operation of the ship. It can effectively extract the characteristics of time series information and enhance the data's ability to reflect the ship's status. The principal component analysis method converts ship maritime data into a set of new unrelated variables. The use of PCA reduces the dimension of the data while trying to retain the key information in the data.
[0074] The method provided in this embodiment includes the following steps:
[0075] A1. Determine whether the data is time series information and whether it is natural language information.
[0076] Figure 1 It is shown that firstly determining whether the data is time series information, and then determining whether the data is natural language information. That is, step A1 specifically includes:
[0077] A11. Determine whether the data is time series information;
[0078] A12. Determine whether the data is natural language information.
[0079] It is understandable that in practice, we can first determine whether the data is time series information, and then determine whether the data is natural language information; we can also first determine whether the data is natural language information, and then determine whether the data is time series information; we can also determine whether the data is time series information and whether it is natural language information at the same time.
[0080] A2. If the data is time series information, the LZW compression algorithm is used to compress the data;
[0081] The principle and operation process of the LZW compression algorithm are as follows: The principle of LZW is dictionary encoding, that is, the "previous text" input first is converted into a dictionary to refer to the repeated "next text" input later, reducing repetitive output, thereby achieving the purpose of data compression. The advantage of LZW over traditional dictionary encoding is that only the dictionary index value is used to replace the input string sequence. During the compression and decompression process, the LZW algorithm dynamically establishes a dictionary, and there is no need to send the dictionary from the source to the destination.
[0082] The specific implementation process is as follows Figure 2 As shown, if the current dictionary index can be found in the dictionary, the prefix string and the first character of the string corresponding to the current dictionary index are added to the dictionary. If the current dictionary index cannot be found in the dictionary, the prefix string and the first character of the prefix string are added to the dictionary to obtain the dictionary entry corresponding to the current dictionary index. At the same time, the dictionary entry corresponding to the current dictionary index is output as a decompressed string.
[0083] Based on the above operation process, the LZW data compression algorithm can effectively process long repetitive patterns and frequently occurring character strings, conform to the data characteristics of time series information, and has a good compression effect. Specifically in the embodiment of marine communication, the time series information may include one or more of ship position information, ship status information, and historical track information.
[0084] A3. If the data is natural language information, the Huffman compression algorithm is used to compress the data;
[0085] The principle and operation process of the Huffman compression algorithm are as follows: The Huffman compression algorithm is a compression algorithm based on statistics. Its essence is to re-encode the characters that appear in the file. The basic principle is that characters that appear more times in the text are assigned shorter codes, and characters that appear less times are assigned longer codes. The average code length of all characters in the file is the shortest, so data compression can be achieved.
[0086] The specific implementation process is as follows Figure 3 As shown, the Huffman coding principle mainly uses the Huffman binary tree. The construction algorithm is to generate a binary tree from the leaves to the root. The steps are as follows:
[0087] (1) Traversing the compressed text, counting the occurrence probability of each character to be compressed, and sorting according to the occurrence probability of each character;
[0088] (2) Select the two characters with the lowest probability of occurrence as child nodes, add them together to get the sum of the probabilities of the two, and call the intermediate node obtained by the sum the parent node of the subtree. Then put the obtained parent node as a new node into the original sorting, and continue to cycle until there is only one node left, which is the root node;
[0089] (3) Mark one path of the two nodes as 0 and the other path as 1;
[0090] (4) Starting from the root node, all 0s and 1s on the path to each child node are counted in order. The resulting string of 0s and 1s is the Huffman code corresponding to each character.
[0091] (5) Re-encode the text content using the Huffman algorithm to obtain the compressed data text.
[0092] The coding compression method based on the above Huffman algorithm has a better compression effect for data samples with uneven symbol occurrence probability and large distribution gap, and is more suitable for natural language information of Chinese characters. Specifically in the embodiment of marine communication, the natural language information may include one or more of ship-to-shore communication information and ship-to-ship communication information.
[0093] A4. If the data is a mixture of time series information and natural language information, or the data is neither time series information nor natural language information, or the data is not clearly time series information or natural language information, then compare the compression ratios of the LZW and Huffman compression algorithms for compressing the data, and select the compression algorithm with a smaller compression ratio to compress the data.
[0094] The compression ratio can be calculated using the following formula:
[0095]
[0096] The smaller the compression ratio CR is, the smaller the compressed file is, which means the better the compression effect is. On the contrary, the larger the compression ratio is, the worse the compression effect is. For data that is a mixture of time series information and natural language information, or the data is neither time series information nor natural language information, or the data is not clear whether it is time series information or natural language information, if the compression effect of the LZW compression algorithm on the data is relatively small, then select the LZW compression algorithm to compress the data. If the compression effect of the Huffman compression algorithm on the data is relatively small, then select the Huffman compression algorithm to compress the data.
[0097] The method provided in this embodiment mainly adopts the LZW compression algorithm and the Huffman compression algorithm, based on the task requirements and data characteristics of Beidou short message maritime data transmission, and is particularly suitable for the compression of time series information such as ship status data and natural language information such as Chinese text.
[0098] In one embodiment, based on the adaptive data compression method of Beidou short message, the compressed data is non-distress information.
[0099] Non-distress information has a lower priority than distress information. Beidou short message communication has a 60s communication frequency limit. For the highest priority distress information, data compression can be completed without completing the information transmission, and it is not limited by the communication frequency, and the distress is completed as soon as possible. For non-distress information, the method provided in this embodiment can adaptively select the optimal compression algorithm, which can effectively ensure that important communication messages are sent in time and reasonably use Beidou resources.
[0100] Taking the International Telecommunication Union (ITU) as an example, maritime communications are divided into four priority levels: distress, emergency, safety and routine.
[0101] (1) Distress information: Distress information is the highest priority for ship communications at sea and has strict communication procedures.
[0102] (2) Emergency information: Emergency information means urgent information about the safety of ships or personnel that needs to be sent.
[0103] (3) Safety information: Safety information means that there is a piece of information related to route safety that needs to be sent.
[0104] (4) Routine information: Routine information is the information that ships send to the outside on a daily basis during navigation. This type of data occupies most of the content of short message communications, and the message content is relatively long and is sent frequently.
[0105] Distress information can correspond to the above-mentioned distress levels. To ensure the real-time and accuracy of distress information, data compression is not performed and the distress information is transmitted through a specific frequency, and is not limited by the communication frequency. It is transmitted first without being limited by the short message communication frequency, and the distress alarm situation report is completed as soon as possible. Non-distress information can correspond to the above-mentioned emergency, safety, and regular levels. Emergency, safety, and regular information are compressed in turn using the method provided in this embodiment, and a transmission queue is formed to complete the short message information communication.
[0106] The adaptive compression algorithm provided in this embodiment is used to compress data, and different compression algorithms are used for different data types to compress data. When the data type is uncertain or mixed, the better compression result is selected for Beidou short message information broadcasting, which achieves higher compression efficiency than the single use of traditional compression algorithm.
[0107] During the specific implementation process, the compressed data and compression results generated can provide support for the subsequent improvement of this embodiment. The accumulation of a large amount of maritime communication data is helpful to form a targeted coding dictionary, and further improve the data compression efficiency in the adaptive data compression method, thereby continuously optimizing and improving, and ultimately improving the efficiency of ship short message communications at sea and saving Beidou resources.
[0108] In one embodiment, the data to be compressed by the method provided in this embodiment can be sampled according to a certain sampling frequency. Introducing the Bartlett test algorithm, dynamically adjusting the sampling frequency according to the stability of the variance in the same population of sent data can focus on important information in the data, further reduce the amount of data, and improve the quality of sent data. Specifically, it can be: determine whether the population variance of the data collected in several sampling periods is stable, if it is stable, reduce the sampling frequency of the data, if it is unstable, increase the sampling frequency of the data; the population variance is calculated according to the following formula:
[0109]
[0110]
[0111]
[0112] Where Q is the data, and P is the total amount of data Q; is the population variance of the entire dataset, p q is the amount of data in the qth data set; is the population variance of the qth data point.
[0113] When judging whether the population variance is stable, we can make a judgment by comparing the threshold value. We can also compare the chi-square distribution χ 2 Is it less than the threshold? Make a judgment, where a is a significant parameter and Q-1 is the degree of freedom. Specifically: judge the chi-square distribution χ 2 Is it less than the threshold? If yes, then reduce the sampling frequency of the data; if no, then increase the sampling frequency of the data.
[0114] Chi-square distribution 2 Calculated using the following formula:
[0115]
[0116] if It means that at the significant level a, the population variance of the data has obvious differences; if It means that at the significance level a, the population variance of the data is significantly different.
[0117] Reduce the data sampling frequency, specifically reduce the data sampling frequency by 5%-15%; increase the data sampling frequency, specifically increase the data sampling frequency by 5%-15%; several sampling cycles, specifically 3-8 sampling cycles. For example, determine whether the sampling frequency is uniform within 5 sampling cycles. If so, increase the sending frequency by 10%, if not, decrease the sending frequency by 10%.
[0118] The effectiveness of the proposed adaptive compression algorithm is verified through simulation examples: According to the characteristics of data communication in the maritime service field, a verification data set that meets the actual application situation is independently designed to realize the simulation verification of the algorithm. The data set includes three parts: time series data containing time, position and status information, Chinese language and text data, and mixed data with unclear type. The accuracy and effectiveness of the adaptive compression algorithm are verified through MATLAB simulation calculation software to ensure the smooth implementation of the algorithm.
[0119] In order to better fit the actual usage scenario of this embodiment, ship behavior data and Chinese language text are used in the simulation verification to ensure the accuracy and effectiveness of the simulation verification.
[0120] An example of the simulation verification process is:
[0121] (a) Principal component analysis is used to extract features from a large amount of ship behavior data, and key feature data are selected to form the source data required for transmission.
[0122] (b) Input data into the simulation application of the adaptive compression algorithm to obtain the compression result.
[0123] (c) Compare the compressed data length with the source data length to obtain its compression ratio, compression time, etc.
[0124] (d) Check whether the compressed data length meets the short message communication requirements.
[0125] (e) Decompress the compressed data using the corresponding algorithm and verify the integrity and accuracy of the data.
[0126] Another example of the simulation verification process is:
[0127] (a) Aiming at the actual communication needs of ships during their maritime voyages, a Chinese natural language text that conforms to the actual situation is provided to form the source data.
[0128] (b) Input data into the simulation application of the adaptive compression algorithm to obtain the compression result.
[0129] (c) Compare the compressed data length with the source data length to obtain its compression ratio, compression time, etc.
[0130] (d) Check whether the compressed data length meets the short message communication requirements.
[0131] (e) Decompress the compressed data using the corresponding algorithm and verify the integrity and accuracy of the data.
[0132] The hardware configuration used in the experiment is CPU AMD Ryzen 75000H, RAM 16.0GB, GPU RTX1650, and the software environment used is Windows 10 64-bit, Matlab2021. The experimental results show that the standard ship positioning data compression example adaptively selects the LZW algorithm for data compression, with a CR of 19.93%, a compressed message length of 110, and a data accuracy of 100% after decompression; the Chinese language text data compression example adaptively selects the Huffman coding algorithm for data compression, with a CR of 31.19%, a compressed message length of 97, and a data accuracy of 100% after decompression.
[0133] The above simulation results show that the adaptive data compression algorithm based on Beidou short message communication proposed in this embodiment has many advanced features. On the one hand, it can effectively reduce the information length of ship maritime communications, improve information transmission efficiency, and save Beidou satellite resources; on the other hand, the data compression algorithms used are all lossless compression algorithms, and the process of compressing and decompressing data will not affect the integrity and accuracy of the data itself. The simulation verification results strongly prove the availability and effectiveness of the method proposed in this embodiment.
[0134] Example 2
[0135] like Figure 4 As shown, this embodiment provides a method for sending data based on Beidou short message, including:
[0136] B1. Determine whether the data is distress information or non-distress information.
[0137] Distress information is relative to non-distress information, and distress information is more urgent and important than non-distress information. The priority of distress information in the transmission queue is higher than that of non-distress information in the transmission queue. Specifically in the embodiment of maritime communication, the distress information can be standard maritime distress alarm communication data. Non-distress information can include two categories, one is ship navigation data, such as ship position, ship status, historical track and other time series information, the data involved are mostly time series data and have many repeated character strings; the other is ship-to-shore communication information and / or ship-to-ship communication information, involving data text files (natural language text) with uneven frequency distribution of characters.
[0138] Before sending data, you can preprocess the data to simplify and extract key information, including setting data format and data encoding to improve the quality of transmitted data.
[0139] B2. If the data is a distress message, place the data in the transmission queue.
[0140] For distress information, no data compression is performed to ensure its timeliness and accuracy.
[0141] B3. If the data is non-distress information, the adaptive data compression method based on Beidou short message as described in Example 1 is used to compress the data, and the compressed data is placed in the transmission queue;
[0142] Preferably, non-distress information can be further divided into critical information and non-critical information, and the priority of data in the transmission queue is set according to critical information and non-critical information. Critical information is relative to non-critical information. For critical information, such as distress alarm information, extreme weather warning and other data, priority is given to compression and transmission. For non-critical information, its sending frequency or priority can be appropriately reduced, and the scheduling function of Beidou short messages can be used to reasonably allocate message resources to ensure timely and accurate transmission of critical data.
[0143] Specifically in maritime communications, the priority of data in the transmission queue can also be dynamically adjusted according to the ship's own status and navigation conditions. Taking the International Telecommunication Union (ITU) as an example, emergency information has a higher priority than safety information and regular information, and is compressed and placed at the front of the transmission queue; safety information has a priority second only to emergency information, and is compressed and placed in the transmission queue after emergency information; regular information has a lower priority than safety information, and is compressed and placed in the transmission queue after safety information.
[0144] Different compression algorithms are used in the method provided in this embodiment. During the specific implementation process, after receiving the data sent by the method provided in this embodiment, the receiving end can identify the compression method by identifying the flag information of the sent data, and then restore the original data information through the corresponding decompression method. A verification bit can also be added to the sent data, and the verification information of the decompressed data is checked to ensure the correctness of the sent data. If the verification bit information fails the verification, the ship terminal can be requested to retransmit or request recompression. Since maritime services have high requirements for data integrity and accuracy, the data compression algorithms used in this embodiment are lossless compression, so there is no loss of accuracy in the data compression and decompression process.
[0145] B4. Send the data in the transmission queue according to priority.
[0146] Sending compressed data in the transmission queue according to the Beidou communication frequency, adjusting the order of data sending in the transmission queue according to the priority, and sending short message communications in this order can effectively ensure that important communication messages are sent in a timely manner and make rational use of Beidou resources.
[0147] This embodiment may not compress the distress information, and transmit the information with the highest priority to ensure the timeliness of data transmission, and may be transmitted first without being limited by the frequency of short message communication. The transmission frequency or priority of non-distress information may be appropriately reduced, and the scheduling function of Beidou short messages may be used to reasonably allocate message resources to ensure the timely and accurate transmission of key data.
[0148] Example 3
[0149] like Figure 5 As shown, based on the same inventive concept as that of Embodiment 1, this embodiment provides an adaptive data compression system based on Beidou short message, which is used to compress data sent through Beidou short message, including:
[0150] A type determination module 11 is used to determine whether the data is time series information and whether it is natural language information;
[0151] The adaptive compression module 12 is used to compress the data using the LZW compression algorithm if the type judgment module determines that the data is time series information; if the type judgment module determines that the data is natural language information, then the Huffman compression algorithm is used to compress the data; if the type judgment module determines that the data is a mixture of time series information and natural language information, or the data is neither time series information nor natural language information, or the data is not clear whether it is time series information or natural language information, then compare the compression ratios of the LZW and Huffman compression algorithms used to compress the data, and select a compression algorithm with a smaller compression ratio to compress the data.
[0152] The LZW compression algorithm effectively compresses data by dynamically building a dictionary. By finding repeated strings in the input data and representing these strings with short codes, it can effectively handle long repeated patterns and frequently occurring strings, thereby achieving compression. In maritime communications, the data reflecting the navigation status of ships is mainly time series information, in which the string contents such as ship position information, ship status information, and historical track information all have a large amount of information that is frequently repeated and changes little. The LZW compression algorithm can significantly reduce the demand for data transmission. At the same time, the LZW algorithm is simple and has a fast compression speed.
[0153] The Huffman compression algorithm is a compression algorithm based on character frequency. It uses the characteristics of character frequency to generate codes, and is particularly suitable for situations where character frequency distribution is uneven. By analyzing the frequency statistics of Chinese characters and the characteristics of character sets, Huffman coding can significantly improve compression efficiency. The ship-to-shore communication information or ship-to-ship communication information of maritime vessels, including weather forecasts, command and dispatch, daily communications, etc., are all natural language texts of Chinese characters. The character frequency distribution is uneven, and the Huffman compression algorithm can significantly reduce the data length.
[0154] In one embodiment, the data is non-distress information.
[0155] In an embodiment specifically applied in maritime communications, the timing information may include one or more of ship position information, ship status information, and historical track information; the natural language information may include one or more of ship-to-shore communication information and ship-to-ship communication information.
[0156] Based on the same inventive concept, the parts of this embodiment that are the same or similar to those of Embodiment 1 are not repeated here.
[0157] Example 4
[0158] like Figure 6 As shown, based on the same inventive concept as that of Embodiment 2, this embodiment provides a ship maritime terminal system, including:
[0159] A distress judgment module 20, used to judge whether the data is distress information or non-distress information;
[0160] The adaptive data compression system based on Beidou short message as described in Example 3 includes a type judgment module 11 and an adaptive compression module 12, which is used to compress the data when the distress judgment module judges that the data is non-distress information;
[0161] The transmission management module 30 is used to place the data in the transmission queue when the distress judgment module determines that the data is distress information; when the distress judgment module determines that the data is non-distress information, place the data compressed by the adaptive data compression system in the transmission queue; the priority of the distress information in the transmission queue is higher than the priority of the non-distress information in the transmission queue;
[0162] The data sending module 40 is used to send the data in the transmission queue according to priority.
[0163] The adaptive data compression method is integrated into a module and integrated into the ship maritime terminal system at a low cost, completing data compression at a low cost, and has wide applicability. The integrated ship maritime terminal system can adaptively select the optimal compression algorithm between the LZW compression algorithm and the Huffman compression algorithm to achieve targeted data compression. Compared with the single use of traditional compression algorithms, it achieves higher compression efficiency, thereby improving the efficiency of short message communication, providing strong support for data transmission between ships and ships, ships and shores, and improving the efficiency of ship maritime communications.
[0164] In one embodiment, the ship maritime terminal system further includes a frequency adjustment module, which is used to determine whether the population variance of the data collected in several sampling periods is stable, and if it is stable, the sending frequency of the data in the transmission queue is reduced, and if it is unstable, the sending frequency of the data in the transmission queue is increased; the population variance is calculated according to the following formula:
[0165]
[0166]
[0167]
[0168] Where Q is the data, and P is the total amount of data Q; is the population variance of the entire dataset, p q is the amount of data in the qth data set; is the population variance of the qth data point.
[0169] In one embodiment, the frequency adjustment module is used to determine whether the population variance of data collected in a number of sampling periods is stable, and if it is stable, reduce the sending frequency of data in the transmission queue; if it is unstable, increase the sending frequency of data in the transmission queue, and specifically includes:
[0170]
[0171] Chi-square distribution 2 Calculated using the following formula:
[0172]
[0173] In one embodiment, the frequency adjustment module is used to determine the chi-square distribution χ 2 Is it less than the threshold? If yes, then the frequency of sending data in the transmission queue is reduced; otherwise, the frequency of sending data in the transmission queue is increased, specifically including:
[0174]
[0175] Several sampling periods, specifically 3-8 sampling periods.
[0176] Based on the same inventive concept, the parts of this embodiment that are the same or similar to those of Embodiment 2 are not repeated here.
[0177] Example 5
[0178] In one embodiment, a computer device is provided, including: a memory for storing a computer program; and a processor for implementing the steps of the adaptive data compression method based on Beidou short message as described in Example 1 or the data sending method based on Beidou short message as described in Example 2 when executing the computer program.
[0179] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps of the adaptive data compression method based on Beidou short message as described in Example 1 or the data sending method based on Beidou short message as described in Example 2 are implemented.
[0180] Obviously, the above embodiments of the present invention are merely examples for clearly illustrating the technical solution of the present invention, and are not intended to limit the specific implementation methods of the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the claims of the present invention shall be included in the protection scope of the claims of the present invention.
Claims
1. An adaptive data compression method based on Beidou short message, used to compress data sent via Beidou short message, characterized in that: include: Determining whether the data is time series information and whether it is natural language information; If the data is time series information, the data is compressed using an LZW compression algorithm; If the data is natural language information, the data is compressed using the Huffman compression algorithm; If the data is a mixture of time series information and natural language information, or the data is neither time series information nor natural language information, or the data is not clearly time series information or natural language information, then the compression ratios of the data compressed by the LZW and Huffman compression algorithms are compared, and a compression algorithm with a smaller compression ratio is selected to compress the data.
2. The adaptive data compression method based on Beidou short message according to claim 1, characterized in that: The data is non-distress information, and the non-distress information has a higher priority than the distress information.
3. An adaptive data compression method based on Beidou short message according to claim 1 or 2, characterized in that: The time series information includes one or more of ship position information, ship status information, and historical track information; the natural language information includes one or more of ship-to-shore communication information and ship-to-ship communication information.
4. A method for sending data based on Beidou short message, used for sending data through Beidou short message, characterized in that: include: Determining whether the data is distress information or non-distress information; If the data is a distress message, placing the data in a transmission queue; If the data is non-distress information, the data is compressed by using an adaptive data compression method based on Beidou short message as described in any one of claims 1 to 3, and the compressed data is placed in a transmission queue; The priority of the distress information in the transmission queue is higher than the priority of the non-distress information in the transmission queue, and the data in the transmission queue is sent according to the priority.
5. A method for sending data based on Beidou short message according to claim 4, characterized in that: The data is sampled according to a sampling frequency, and the method further includes: determining whether the population variance of the data collected in a number of sampling periods is stable, if it is stable, reducing the sampling frequency of the data, and if it is unstable, increasing the sampling frequency of the data; the population variance is calculated according to the following formula: Where Q is the data, and P is the total amount of data Q; is the population variance of the entire dataset, p q is the data volume of the qth data set; is the population variance of the qth data point.
6. A method for sending data based on Beidou short message according to claim 5, characterized in that: Determine whether the population variance of the data collected in several sampling periods is stable. If it is stable, reduce the sampling frequency of the data; if it is unstable, increase the sampling frequency of the data. Specifically, it includes: Determine the chi-square distribution of several sampling periods 2 Are they all less than the threshold? a is a significant parameter, Q-1 is the degree of freedom; If so, reduce the sampling frequency of the data; If not, increase the sampling frequency of the data; Chi-square distribution 2 Calculated using the following formula:
7. A method for sending data based on Beidou short message according to claim 6, characterized in that: The reducing of the data sampling frequency specifically refers to reducing the data sampling frequency by 5%-15%; the increasing of the data sampling frequency specifically refers to increasing the data sampling frequency by 5%-15%; the several sampling cycles specifically refers to 3-8 sampling cycles.
8. An adaptive data compression system based on Beidou short message, used for compressing data sent via Beidou short message, characterized in that: include: A type determination module, used to determine whether the data is time series information and whether it is natural language information; The adaptive compression module is used to compress the data using the LZW compression algorithm if the type judgment module determines that the data is time series information; if the type judgment module determines that the data is natural language information, then the Huffman compression algorithm is used to compress the data; if the type judgment module determines that the data is a mixture of time series information and natural language information, or the data is neither time series information nor natural language information, or the data is not clear whether it is time series information or natural language information, then compare the compression ratios of the LZW and Huffman compression algorithms used to compress the data, and select a compression algorithm with a smaller compression ratio to compress the data.
9. The adaptive data compression system based on Beidou short message according to claim 8, characterized in that: The data is non-distress information, and the non-distress information has a higher priority than the distress information.
10. An adaptive data compression system based on Beidou short message according to claim 8 or 9, characterized in that: The time series information includes one or more of ship position information, ship status information, and historical track information; the natural language information includes one or more of ship-to-shore communication information and ship-to-ship communication information.
11. A ship maritime terminal system for sending data via Beidou short messages, characterized in that: include: A distress judgment module, used to judge whether the data is distress information or non-distress information; The adaptive data compression system based on Beidou short message according to any one of claims 8 to 10, used for compressing data when the distress judgment module judges that the data is non-distress information; a transmission management module, configured to place the data in a transmission queue when the distress judgment module determines that the data is distress information; and to place the data compressed by the adaptive data compression system in a transmission queue when the distress judgment module determines that the data is non-distress information; the priority of distress information in the transmission queue is higher than the priority of non-distress information in the transmission queue; The data sending module is used to send the data in the transmission queue according to the priority.
12. A ship maritime terminal system according to claim 11, characterized in that: The data is sampled according to a sampling frequency, and the system further comprises: The frequency adjustment module is used to determine whether the population variance of the data collected in several sampling periods is stable. If it is stable, the sampling frequency of the data is reduced; if it is unstable, the sampling frequency of the data is increased; the population variance is calculated according to the following formula: Where Q is the data, and P is the total amount of data Q; is the population variance of the entire dataset, p q is the data volume of the qth data set; is the population variance of the qth data point.
13. A ship maritime terminal system according to claim 12, characterized in that: The frequency adjustment module is used to determine whether the population variance of the data collected in several sampling periods is stable. If it is stable, the sampling frequency of the data is reduced; if it is unstable, the sampling frequency of the data is increased. Specifically, it includes: Chi-square distribution 2 Calculated using the following formula:
14. A ship maritime terminal system according to claim 13, characterized in that: Frequency adjustment module for Determine the chi-square distribution of several sampling periods 2 Are they all less than the threshold? If yes, then reduce the data sampling frequency, if no, increase the data sampling frequency, specifically including: Several sampling periods, specifically 3-8 sampling periods.
15. A computer device, characterized in that: include: Memory for storing computer programs; A processor, used to implement the steps of the adaptive data compression method based on Beidou short message as described in any one of claims 1 to 3 or the data sending method based on Beidou short message as described in any one of claims 4 to 7 when executing the computer program.
16. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by the processor, the steps of the adaptive data compression method based on Beidou short message as described in any one of claims 1 to 3 or the data sending method based on Beidou short message as described in any one of claims 4 to 7 are implemented.