CN114070901B - Data transmitting and receiving method, device and equipment based on multi-data alignment - Google Patents

Data transmitting and receiving method, device and equipment based on multi-data alignment Download PDF

Info

Publication number
CN114070901B
CN114070901B CN202111169005.3A CN202111169005A CN114070901B CN 114070901 B CN114070901 B CN 114070901B CN 202111169005 A CN202111169005 A CN 202111169005A CN 114070901 B CN114070901 B CN 114070901B
Authority
CN
China
Prior art keywords
data
matrix
character
binary data
strings
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202111169005.3A
Other languages
Chinese (zh)
Other versions
CN114070901A (en
Inventor
白志得
哈米德
白智德
黄坤
殷燕
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Zhihuilin Network Technology Co ltd
Original Assignee
Shenzhen Zhihuilin Network Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Zhihuilin Network Technology Co ltd filed Critical Shenzhen Zhihuilin Network Technology Co ltd
Priority to CN202111169005.3A priority Critical patent/CN114070901B/en
Publication of CN114070901A publication Critical patent/CN114070901A/en
Priority to PCT/CN2022/119921 priority patent/WO2023051319A1/en
Application granted granted Critical
Publication of CN114070901B publication Critical patent/CN114070901B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/22Parsing or analysis of headers

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Abstract

The application discloses a data sending and receiving method, device and equipment based on multi-data alignment, wherein the data sending method comprises the following steps: t data to be sent are obtained; binary conversion is carried out on each data to be transmitted in t data to be transmitted, and t first binary data strings are obtained; vertically stacking t first binary data strings to obtain a first matrix; performing multiple line displacement processing on the first matrix to obtain a second matrix; splitting the second matrix by columns to obtain r second binary data strings; performing multiple character scanning processing on each second binary data string in the r second binary data strings respectively to obtain r simplified data strings, wherein the r simplified data strings are obtained to correspond to the r second binary data strings one by one; longitudinally splicing r simplified data strings according to the arrangement position of each second binary data string in the second matrix to obtain a target data string; and sending the target data string to a data receiving end.

Description

Data transmitting and receiving method, device and equipment based on multi-data alignment
Technical Field
The present invention relates to the field of data transmission technologies, and in particular, to a method, an apparatus, and a device for transmitting and receiving data based on multiple data alignment.
Background
Currently, in order to obtain higher transmission efficiency when transmitting data, the data is generally compressed or split into a plurality of sub-data with the same size for transmission. However, compression techniques compress data by consuming a large amount of computer resources for a large amount of computation, while, due to the increased bandwidth of modern routers, directly transmitting data without compression typically takes less time than transmitting the data after compression. The existing data splitting method generally splits data into a plurality of sub-data with equal size according to specific transmission requirements, and then sends the sub-data respectively, and then combines the sub-data at a receiving end. However, in practice, due to the problems of disk writing, indexing and the like of the split sub-data in the disk clusters, the split sub-data not only has no help to data transmission on the network, but also reduces the data transmission speed on the network. Therefore, the current data transmission method based on compression and splitting generally cannot increase the data transmission speed on the network, but rather can cause the data transmission speed to be slow.
Disclosure of Invention
In order to solve the above-mentioned problems in the prior art, the embodiments of the present application provide a method, an apparatus, and a device for transmitting and receiving data based on multi-data alignment, which can increase the data transmission speed on a network.
In a first aspect, embodiments of the present application provide a data transmission method based on multiple data alignment, including:
t pieces of data to be sent are obtained, wherein t is a positive integer greater than 1;
binary conversion is carried out on each data to be transmitted in t data to be transmitted, t first binary data strings are obtained, and the t first binary data strings are in one-to-one correspondence with the t data to be transmitted;
vertically stacking t first binary data strings to obtain a first matrix;
performing multiple line displacement processing on the first matrix to obtain a second matrix;
splitting the second matrix according to columns to obtain r second binary data strings, wherein r is a positive integer greater than 0;
performing multiple character scanning processing on each second binary data string in the r second binary data strings respectively to obtain r simplified data strings, wherein the r simplified data strings are obtained to correspond to the r second binary data strings one by one;
longitudinally splicing r simplified data strings according to the arrangement position of each second binary data string in the second matrix to obtain a target data string;
and sending the target data string to a data receiving end.
In a second aspect, embodiments of the present application provide a data receiving method based on multiple data alignment, including:
Receiving data to be restored from a data sending terminal, wherein the data to be restored comprises: a target data string and a description file;
carrying out data splitting on the target data string according to the description file to obtain x simplified data strings;
according to the description file and a preset conversion table, carrying out data conversion on each simplified data string in the x simplified data strings to obtain x third binary data strings, wherein the x third binary data strings are in one-to-one correspondence with the x simplified data strings;
sequentially arranging elements in each third binary data string in the x third binary data strings from top to bottom according to arrangement positions in each third binary data string to obtain x vertical data strings, wherein the x vertical data strings are in one-to-one correspondence with the x third binary data strings;
transversely splicing the x vertical data strings according to the label of each third binary data string to obtain a third matrix;
performing repeated line displacement reduction on the third matrix according to the description file to obtain a fourth matrix;
splitting the fourth matrix according to rows from top to bottom to obtain y fourth binary data strings;
and carrying out data reduction on each fourth binary data string in the y fourth binary data strings to obtain y original data, wherein the y original data are in one-to-one correspondence with the y binary data.
In a third aspect, embodiments of the present application provide a data transmission apparatus based on multiple data alignment, including:
the device comprises a first receiving module, a first processing module and a sending module; wherein,
the first receiving module is used for acquiring t data to be transmitted, wherein t is a positive integer greater than 1;
the first processing module is used for binary conversion of each data to be transmitted in t data to be transmitted to obtain t first binary data strings, wherein the t first binary data strings are in one-to-one correspondence with the t data to be transmitted; vertically stacking t first binary data strings to obtain a first matrix; performing multiple line displacement processing on the first matrix to obtain a second matrix; splitting the second matrix according to columns to obtain r second binary data strings, wherein r is a positive integer greater than 0; performing multiple character scanning processing on each second binary data string in the r second binary data strings respectively to obtain r simplified data strings, wherein the r simplified data strings are obtained to correspond to the r second binary data strings one by one; longitudinally splicing r simplified data strings according to the arrangement position of each second binary data string in the second matrix to obtain a target data string;
And the sending module is used for sending the target data string to the data receiving end.
In a fourth aspect, embodiments of the present application provide a data receiving apparatus based on multiple data alignment, including:
the device comprises a second receiving module, a second processing module and a restoring module; wherein,
the second receiving module is configured to receive data to be restored from the data sending end, where the data to be restored includes: a target data string and a description file;
the second processing module is used for carrying out data splitting on the target data string according to the description file to obtain x simplified data strings; according to the description file and a preset conversion table, carrying out data conversion on each simplified data string in the x simplified data strings to obtain x third binary data strings, wherein the x third binary data strings are in one-to-one correspondence with the x simplified data strings; sequentially arranging elements in each third binary data string in the x third binary data strings from top to bottom according to arrangement positions in each third binary data string to obtain x vertical data strings, wherein the x vertical data strings are in one-to-one correspondence with the x third binary data strings; transversely splicing the x vertical data strings according to the label of each third binary data string to obtain a third matrix; performing repeated line displacement reduction on the third matrix according to the description file to obtain a fourth matrix; splitting the fourth matrix according to rows from top to bottom to obtain y fourth binary data strings;
And the restoring module is used for carrying out data restoration on each fourth binary data string in the y fourth binary data strings to obtain y original data, wherein the y original data are in one-to-one correspondence with the y binary data.
In a fifth aspect, embodiments of the present application provide a data transmission apparatus based on multi-data alignment, including: and a processor coupled to the memory, the memory for storing a computer program, the processor for executing the computer program stored in the memory to cause the electronic device to perform the method as in the first aspect.
In a sixth aspect, embodiments of the present application provide a data receiving apparatus based on multi-data alignment, including: and a processor coupled to the memory, the memory for storing a computer program, the processor for executing the computer program stored in the memory to cause the electronic device to perform the method as in the second aspect.
In a seventh aspect, embodiments of the present application provide a computer-readable storage medium storing a computer program that causes a computer to perform the method as in the first and/or second aspects.
In an eighth aspect, embodiments of the present application provide a computer program product comprising a non-transitory computer readable storage medium storing a computer program, the computer being operable to cause a computer to perform a method as in the first and/or second aspects.
The implementation of the embodiment of the application has the following beneficial effects:
in the embodiment of the application, the t data to be sent are binarized and then vertically stacked to obtain a first matrix. And performing multiple line displacement processing on the first matrix to obtain a second matrix with the number of columns with identical elements being greater than or equal to a first threshold value. And splitting the second matrix according to columns to obtain r second binary data strings, and finally transmitting the r second binary data strings to a data receiving end. Therefore, a large number of similar redundant bits exist in the obtained second matrix through multiple displacement processing, and meanwhile, columns with identical elements also exist. Based on the method, after the second matrix is split according to columns, the obtained r data structures of the second binary data strings are simpler, the regularity is strong, the processing efficiency of data in the sending process can be effectively improved, and then the network transmission speed is improved. In addition, since a memory unit, such as a memory unit (RAM), can process bits in an original size during data transmission, it is generally accomplished through memory units at a transmitting end and a receiving end. In the method, the data to be sent are converted into binary data, so that the data alignment operation is realized, extra memory is not occupied at a sending end and a receiving end, the problems of disk writing, indexing and the like of data segmentation in a disk cluster are avoided, and the network transmission speed is further improved.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings that are needed in the description of the embodiments will be briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present application, and other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 is a schematic hardware structure diagram of a data transmitting device based on multi-data alignment or a data receiving device based on multi-data alignment according to an embodiment of the present application;
fig. 2 is a flow chart of a data transmission method based on multi-data alignment according to an embodiment of the present application;
fig. 3 is a flow chart of a method for performing multiple line displacement processing on a first matrix to obtain a second matrix according to an embodiment of the present application;
fig. 4 is a flow chart of another method for performing multiple line displacement processing on a first matrix to obtain a second matrix according to an embodiment of the present application;
FIG. 5 is a schematic flow chart of a method for performing multiple character scanning processing on each of r second binary data strings to obtain r simplified data strings according to the embodiment of the present application;
Fig. 6 is a flowchart of a method for transmitting a target data string to a data receiving end according to an embodiment of the present application;
fig. 7 is a flow chart of a data receiving method based on multi-data alignment according to an embodiment of the present application;
fig. 8 is a functional block diagram of a data transmitting device based on multiple data alignment according to an embodiment of the present application;
fig. 9 is a functional block diagram of a data receiving device based on multiple data alignment according to an embodiment of the present application;
fig. 10 is a schematic structural diagram of a data transmission device based on multiple data alignment according to an embodiment of the present application;
fig. 11 is a schematic structural diagram of a data receiving device based on multi-data alignment according to an embodiment of the present application.
Detailed Description
The following description of the embodiments of the present application will be made clearly and fully with reference to the accompanying drawings, in which it is evident that the embodiments described are some, but not all, of the embodiments of the present application. All other embodiments, based on the embodiments herein, which would be apparent to one of ordinary skill in the art without undue burden are within the scope of the present application.
The terms "first," "second," "third," and "fourth" and the like in the description and in the claims of this application and in the drawings, are used for distinguishing between different objects and not for describing a particular sequential order. Furthermore, the terms "comprise" and "have," as well as any variations thereof, are intended to cover a non-exclusive inclusion. For example, a process, method, system, article, or apparatus that comprises a list of steps or elements is not limited to only those listed steps or elements but may include other steps or elements not listed or inherent to such process, method, article, or apparatus.
Reference herein to "an embodiment" means that a particular feature, result, or characteristic described in connection with the embodiment may be included in at least one embodiment of the application. The appearances of such phrases in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. Those skilled in the art will explicitly and implicitly understand that the embodiments described herein may be combined with other embodiments.
First, referring to fig. 1, fig. 1 is a schematic hardware structure diagram of a data transmitting device based on multi-data alignment or a data receiving device based on multi-data alignment according to an embodiment of the present application. The data transmitting device based on multi-data alignment or the data receiving device based on multi-data alignment comprises at least one processor 101, a communication line 102, a memory 103 and at least one communication interface 104.
In this embodiment, the processor 101 may be a general purpose central processing unit (central processing unit, CPU), microprocessor, application-specific integrated circuit (ASIC), or one or more integrated circuits for controlling the execution of programs in the present application.
Communication line 102 may include a pathway to transfer information between the above-described components.
The communication interface 104, which may be any transceiver-like device (e.g., antenna, etc.), is used to communicate with other devices or communication networks, such as ethernet, RAN, wireless local area network (wireless local area networks, WLAN), etc.
The memory 103 may be, but is not limited to, a read-only memory (ROM) or other type of static storage device that can store static information and instructions, a random access memory (random access memory, RAM) or other type of dynamic storage device that can store information and instructions, or an electrically erasable programmable read-only memory (electrically erasable programmable read-only memory, EEPROM), a compact disc (compact disc read-only memory) or other optical disc storage, optical disc storage (including compact disc, laser disc, optical disc, digital versatile disc, blu-ray disc, etc.), magnetic disk storage media or other magnetic storage devices, or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a computer.
In this embodiment, the memory 103 may be independently provided and connected to the processor 101 via the communication line 102. Memory 103 may also be integrated with processor 101. The memory 103 provided by embodiments of the present application may generally have non-volatility. The memory 103 is used for storing computer-executable instructions for executing the embodiments of the present application, and is controlled by the processor 101 to execute the instructions. The processor 101 is configured to execute computer-executable instructions stored in the memory 103, thereby implementing the methods provided in the embodiments of the present application described below.
In alternative embodiments, computer-executable instructions may also be referred to as application code, which is not specifically limited in this application.
In alternative embodiments, processor 101 may include one or more CPUs, such as CPU0 and CPU1 in fig. 1.
In alternative embodiments, the data transmitting device based on multi-data alignment or the data receiving device based on multi-data alignment may also include multiple processors, such as processor 101 and processor 107 in fig. 1. Each of these processors may be a single-core (single-CPU) processor or may be a multi-core (multi-CPU) processor. A processor herein may refer to one or more devices, circuits, and/or processing cores for processing data (e.g., computer program instructions).
In an alternative embodiment, if the data transmitting apparatus based on the multi-data alignment or the data receiving apparatus based on the multi-data alignment is a server, the data transmitting apparatus based on the multi-data alignment or the data receiving apparatus based on the multi-data alignment may further include an output device 105 and an input device 106. The output device 105 communicates with the processor 101 and may display information in a variety of ways. For example, the output device 105 may be a liquid crystal display (liquid crystal display, LCD), a light emitting diode (light emitting diode, LED) display device, a Cathode Ray Tube (CRT) display device, or a projector (projector), or the like. The input device 106 is in communication with the processor 101 and may receive user input in a variety of ways. For example, the input device 106 may be a mouse, a keyboard, a touch screen device, a sensing device, or the like.
The data transmitting apparatus based on multi-data alignment or the data receiving apparatus based on multi-data alignment may be a general-purpose device or a special-purpose device. The present embodiment is not limited to the type of device of the data transmitting device based on the multi-data alignment or the data receiving device based on the multi-data alignment.
Hereinafter, a data transmission method based on multi-data alignment disclosed in the present application will be described:
referring to fig. 2, fig. 2 is a flow chart of a data transmission method based on multiple data alignment according to an embodiment of the present application. The data transmission method based on multi-data alignment comprises the following steps:
201: t data to be transmitted are acquired.
In this embodiment, t is a positive integer greater than 0. In short, in this embodiment, there is no requirement for the t data to be transmitted, that is, any data may be transmitted by the data transmission method based on multi-data alignment provided in this application.
202: and performing binary conversion on each data to be transmitted in the t data to be transmitted to obtain t first binary data strings.
In this embodiment, the t first binary data strings are in one-to-one correspondence with t data to be transmitted.
203: vertically stacking t first binary data strings to obtain a first matrix.
In this embodiment, a case where t is equal to 3 will be taken as an example, and a data transmission method based on multi-data alignment provided in the present application will be described. For example, there are 3 data to be transmitted DCM, MP4 and PDF, and after binarizing them, respectively, 3 first binary data strings are obtained as follows:
DCM=>01010011;
MP4=>10110011;
PDF=>00101001;
After vertically stacking the 3 first binary data strings, a first matrix can be obtained as follows:
204: and performing multiple line displacement processing on the first matrix to obtain a second matrix.
In this embodiment, a method for performing multiple line displacement processing on a first matrix to obtain a second matrix is provided, as shown in fig. 3, where the method includes:
301: and determining an initial matrix A of the ith row displacement processing, and displacing any row in the initial matrix A leftwards or rightwards by one bit to obtain a displacement matrix B.
In this embodiment, the number of columns with identical elements in the initial matrix a is smaller than the first threshold, i is an integer greater than or equal to 1, and when i=1, the initial matrix a is the first matrix.
302: the number of columns of exactly the same elements in the displacement matrix B is determined.
303: and when the number of columns with identical elements in the displacement matrix B is greater than or equal to a first threshold value, taking the displacement matrix B as a second matrix.
304: and when the number of columns with identical elements in the displacement matrix B is smaller than a first threshold value, performing i+1th row displacement processing by taking the displacement matrix B as a starting matrix of the i+1th row displacement processing until a second matrix is obtained after performing multiple row displacement processing.
Illustratively, assuming a first threshold of 4, following displacement of each row in the first matrix using the above example, the following matrix may be obtained:
wherein R represents one shift to the right.
It can be seen that the columns in which the elements are identical are 4 columns in total of the third column "111", the fourth column "000", the fifth column "111" and the seventh column "000".
In an alternative embodiment, there is further provided a method for performing multiple row displacement processing on a first matrix to obtain a second matrix, as shown in fig. 4, where the method includes:
401: and determining an initial matrix C of the j-th line displacement processing, and displacing any line in the initial matrix C to the left or right by one bit to obtain a displacement matrix D.
In this embodiment, the number of columns with identical elements in the initial matrix C is smaller than the first threshold, j is an integer greater than or equal to 1, and when j=1, the initial matrix C is the first matrix.
402: the number of target columns is determined in the displacement matrix D.
In this embodiment, the target column is a matrix column in which the number of consecutive identical elements in the matrix column is greater than the second threshold in the displacement matrix D.
Illustratively, for column "0011101100000110101", the largest consecutive identical elements thereof are respectively: the corresponding numbers of [ 00, 111,0, 11, 00000, 11,0,1,0,1 ] are respectively as follows: [ 2,3,1,2,5,2,1,1,1,1 ]. Therefore, when the second threshold value is 4, since the column "0011101100000110101" contains the consecutive identical elements "00000" whose number is 5 greater than the second threshold value, the column can be regarded as a satisfactory target column.
403: when the number of target columns in the displacement matrix D is greater than or equal to the first threshold, the displacement matrix D is taken as a second matrix.
404: and when the number of the target columns in the displacement matrix D is smaller than a first threshold value, the displacement matrix D is used as a starting matrix of j+1th row displacement processing to carry out j+1th row displacement processing until a plurality of row displacement processing are carried out, and a second matrix is obtained.
205: the second matrix is split column by column to obtain r second binary data strings.
In this embodiment, r is a positive integer greater than 0. Illustratively, following the above example, the second matrix may be split column by column to obtain 10 second binary data strings, as follows: [ 0, 00, 111, 000, 111, 010, 000, 101, 11,1 ].
206: and respectively carrying out multiple character scanning processing on each second binary data string in the r second binary data strings to obtain r simplified data strings corresponding to the r second binary data strings one by one.
In this embodiment, due to the displacement operation, a large number of similar redundancy bits exist in each of the r split second binary data strings, and at the same time, there are second binary data strings composed of the same elements, for example: 111 or 000. Based on the data structure of the r second binary data strings is simpler and the regularity is strong. Therefore, the original t data to be transmitted are converted into r second binary data strings, so that the processing efficiency of the data in the transmission process can be effectively improved, and the network transmission speed is further improved.
Based on this, in this embodiment, a large number of similar redundant bits may exist in each second binary data string, and at the same time, the characteristics of the second binary data strings composed of the same elements may also exist, so that simplification processing may be performed on each second binary data string to further improve the network transmission speed.
Specifically, the present embodiment provides a method for performing multiple character scanning processing on each of r second binary data strings to obtain r simplified data strings, as shown in fig. 5, where the method includes:
501: and traversing each second binary data string from the beginning character E of the kth character scanning process to the right in turn until an ending character F is determined.
In this embodiment, the end character F is a character having a first value different from the start character E in the process of scanning the kth character, or the end character F is a last character of each second binary data string, k is an integer greater than or equal to 1, and when k=1, the start character E is a first character of each second binary data string;
502: when the ending character F is the character with the first value different from the initial character E in the kth character scanning process, setting the scanning result of the kth character scanning process to be that the number of characters between the initial character E and the ending character F is increased by one, and taking the ending character F as the starting character of the kth+1st character scanning process to carry out the kth+1st character scanning process until the simplified data string corresponding to each second binary data string is obtained after carrying out the character scanning process for a plurality of times.
503: when the initial character E is the last character of each second binary data string, setting the scanning result of the kth character scanning process as 1, and sequencing the processing results of the multiple character scanning processes according to the processing sequence of the multiple character scanning processes to obtain a simplified data string corresponding to each second binary data string.
504: when the end character F is the last character of each second binary data string, setting the scanning result of the kth character scanning process to be the number of characters between the start character E and the end character F plus two, and sequencing the processing results of the multiple character scanning processes according to the processing sequence of the multiple character scanning processes to obtain a simplified data string corresponding to each second binary data string.
Illustratively, along the example with n equal to 3 above, the resulting 10 second binary data strings are: [ 0, 00, 111, 000, 111, 010, 000, 101, 11,1 ]. For the first and second binary data strings "0", the first character E of the 1 st character scanning process is the first character "0", and at the same time, the first character "0" is the last character, so that the simplified data string corresponding to the first and second binary data strings "0" is recorded as "1".
For the second binary data string "00", the initial character E of the 1 st character scanning process is the first character "0", and after traversing right in turn, the first character different from the initial character E is not found until the last character, the second character "0" is used as the final character F, and meanwhile, the simplified data string corresponding to the second binary data string "00" is recorded as "2" (the number of characters between the first character and the second character is increased by two, namely 0+2).
For the third second binary data string "111", the initial character E of the 1 st character scanning process is the first character "1", and after traversing right in turn, until the last character does not find the first character different from the initial character E, the third character "1" is taken as the final character F, and meanwhile, the simplified data string corresponding to the first second binary data string "111" is recorded as "3" (the number of characters between the first character and the third character is increased by two, i.e. 1+2).
By the method, the 10 second binary data strings can be sequentially simplified to obtain 10 simplified data strings: [ 1,2,3, 111,3, 111,2,1 ].
207: and longitudinally splicing the r simplified data strings according to the arrangement position of each second binary data string in the second matrix to obtain a target data string.
Illustratively, following the example above, 10 simplified data strings are provided: and (3) longitudinally splicing (1, 2,3, 111,3, 111,2,1) to obtain a target data string '12333111311121'.
Therefore, when t is hundreds or even thousands, namely hundreds or thousands of data meeting the requirements are simultaneously transmitted, the data can be greatly compressed through the splitting conversion, and the compression does not need complex compression calculation, so that the consumption of computing resources and the compression time are greatly reduced. And the corresponding data content cannot be directly restored through each compressed fragment, so that the safety of the data is improved.
In an alternative embodiment, each 256 data may be set to be sent as a group, so when a second binary data string composed of the same elements, that is, a second binary data string composed of 0 or 1, appears, the simplified result is 256, and the simplified result only occupies 1 byte in the network, which greatly reduces the bandwidth requirement on the network and further improves the network transmission speed.
208: and sending the target data string to a data receiving end.
In this embodiment, a method for transmitting a target data string to a data receiving end is provided, as shown in fig. 6, the method includes:
601: and carrying out data segmentation on the target data string to obtain at least one data fragment.
In the present embodiment, first, the number of division bits q may be determined, and then the target data string may be divided into at least one data piece having the same number of bits according to the number of division bits q. For example, q may be any integer greater than 1, and in this embodiment, a method for transmitting a target data string to a data receiving end provided in the present application will be described by taking a case where q is equal to 2 as an example.
Specifically, when q is equal to 2, it is explained that the number of division bits is set to 2, and at this time, the target data string may be divided into one group every 2 bits, and data splitting may be performed. For example, with the above example, the target data string is "12333111311121", and in the case where the division bit number is 2, it can be divided into [ 12, 33, 31, 11, 31, 11, 21 ].
In alternative embodiments, the number of split bits may also be a dynamic, cyclic number. For example, the number of division bits may be regarded as a division sequence [ m, x, y ], and then when data division is performed on binary data, m bits may be divided first, x bits may be divided again, y bits may be divided again, and then m bits may be divided again, and the binary data may be always circularly divided. Specifically, when the sequence [ 1,2,3 ] is split, the target data string is "321332133312", the split result [ 3, 21, 332,1, 33, 312 ] can be obtained.
602: at least one transmit frequency is determined based on the number of bits per data slice in the data slices.
In this embodiment, the number of required transmission frequencies, that is, the first number, may be determined first based on the number of bits per data slice. The first number may be, for example, the same number of bits as each data slice, i.e., the first number is q. Of course, other functional relationships are possible between the first number and the number of bits per data slice, for example, in one possible implementation, the relationship between the first number l and the number of bits q per data slice can be represented by equation (1):
l=2 q .........①
in this embodiment, a case where the first number is q will be taken as an example, and a multi-frequency-based data transmission method provided in the present application will be described. Based on this, along with the above example where q is equal to 2, it can be determined that the first number is also 2, and therefore, 2 transmission frequencies can be randomly selected from a preset transmission frequency library as the at least one transmission frequency.
603: and determining a first transmission frequency corresponding to each data fragment in at least one transmission frequency according to the arrangement position of each data fragment in the target data string.
In this embodiment, at least one transmission frequency obtained in step 602 may be randomly ordered, so that each data slice may sequentially and circularly select one of the ordered at least one transmission frequency as its own corresponding transmission frequency according to the arrangement position in the target data string.
Specifically, the above example where q is equal to 2 is followed, in which 2 transmission frequencies are selected and named as transmission frequency a and transmission frequency B, respectively, and the sequences [ transmission frequency a, transmission frequency B ] are obtained by sorting them. The target data string "12333111311121" corresponds to the data slicing sequence [ 12, 33, 31, 11, 31, 11, 21 ]. Based on this, it is determined that the first data burst "12" corresponds to the transmission frequency a, the second data burst "33" corresponds to the transmission frequency B, the third data burst "31" corresponds to the transmission frequency a, the fourth data burst "11" corresponds to the transmission frequency B, the fifth data burst "31" corresponds to the transmission frequency a, the sixth data burst "11" corresponds to the transmission frequency B, and the fifth data burst "21" corresponds to the transmission frequency a.
604: and respectively carrying out data conversion on each data fragment according to a preset conversion table and a first transmission frequency corresponding to each data fragment to obtain at least one conversion result.
In this embodiment, the conversion table records conversion results corresponding to different data fragments at different transmission frequencies, and at least one conversion result corresponds to at least one data fragment one by one.
605: and sequentially transmitting each conversion result in the at least one conversion result to the data receiving end according to the first transmission frequency corresponding to each conversion result.
In an alternative embodiment, r second binary data strings may be directly spliced according to the arrangement position of each second binary data string in the first matrix without simplifying the r second binary data strings, so as to obtain the target data string. The target data string is transmitted to the data receiving end in the method according to steps 601-605 described above.
In addition, referring to fig. 7, fig. 7 is a flow chart of a data receiving method based on multi-data alignment according to an embodiment of the present application. The data receiving method based on multi-data alignment comprises the following steps:
701: and receiving the data to be restored from the data sending end.
In this embodiment, the data to be restored may include: a target data string and a description file.
702: and carrying out data splitting on the target data string according to the description file to obtain x simplified data strings.
703: and according to the description file and a preset conversion table, carrying out data conversion on each simplified data string in the x simplified data strings to obtain x third binary data strings.
In the present embodiment, x third binary data strings are in one-to-one correspondence with x simplified data strings.
704: and arranging the elements in each third binary data string in the x third binary data strings in sequence from top to bottom according to the arrangement positions in each third binary data string to obtain x vertical data strings.
In the present embodiment, x vertical data strings are in one-to-one correspondence with x third binary data strings.
705: and transversely splicing the x vertical data strings according to the label of each third binary data string to obtain a third matrix.
706: and carrying out repeated line displacement reduction on the third matrix according to the description file to obtain a fourth matrix.
707: and splitting the fourth matrix according to rows from top to bottom to obtain y fourth binary data strings.
708: and carrying out data reduction on each fourth binary data string in the y fourth binary data strings to obtain y original data.
In this embodiment, y pieces of original data are in one-to-one correspondence with y pieces of binary data.
In summary, in the data transmission method based on multi-data alignment provided by the invention, the t data to be transmitted are binarized and then vertically stacked to obtain the first matrix. And performing multiple line displacement processing on the first matrix to obtain a second matrix with the number of columns with identical elements being greater than or equal to a first threshold value. And splitting the second matrix according to columns to obtain r second binary data strings, and finally transmitting the r second binary data strings to a data receiving end. Therefore, a large number of similar redundant bits exist in the obtained second matrix through multiple displacement processing, and meanwhile, columns with identical elements also exist. Based on the method, after the second matrix is split according to columns, the obtained r data structures of the second binary data strings are simpler, the regularity is strong, the processing efficiency of data in the sending process can be effectively improved, and then the network transmission speed is improved. In addition, since a memory unit, such as a memory unit (RAM), can process bits in an original size during data transmission, it is generally accomplished through memory units at a transmitting end and a receiving end. In the method, the data to be sent are converted into binary data, so that the data alignment operation is realized, extra memory is not occupied at a sending end and a receiving end, the problems of disk writing, indexing and the like of data segmentation in a disk cluster are avoided, and the network transmission speed is further improved.
Referring to fig. 8, fig. 8 is a functional block diagram of a data transmitting device based on multiple data alignment according to an embodiment of the present application. As shown in fig. 8, the data transmission apparatus 800 based on multi-data alignment includes: a first receiving module 801, a first processing module 802, and a transmitting module 803; wherein:
a first receiving module 801, configured to obtain t data to be sent, where t is a positive integer greater than 1;
the first processing module 802 is configured to binary-convert each data to be sent in t pieces of data to be sent to obtain t pieces of first binary data strings, where the t pieces of first binary data strings are in one-to-one correspondence with the t pieces of data to be sent; vertically stacking t first binary data strings to obtain a first matrix; performing multiple line displacement processing on the first matrix to obtain a second matrix; splitting the second matrix according to columns to obtain r second binary data strings, wherein r is a positive integer greater than 0; performing multiple character scanning processing on each second binary data string in the r second binary data strings respectively to obtain r simplified data strings, wherein the r simplified data strings are obtained to correspond to the r second binary data strings one by one; longitudinally splicing r simplified data strings according to the arrangement position of each second binary data string in the second matrix to obtain a target data string;
A sending module 803, configured to send the target data string to a data receiving end.
In the embodiment of the present invention, in performing the line displacement processing on the first matrix for multiple times to obtain the second matrix, the first processing module 802 is specifically configured to:
determining an initial matrix A of the ith row displacement processing, and shifting any row in the initial matrix A leftwards or rightwards by one bit to obtain a displacement matrix B, wherein the number of columns with identical elements in the initial matrix A is smaller than a first threshold value, i is an integer greater than or equal to 1, and when i=1, the initial matrix A is a first matrix;
determining the number of columns with identical elements in the displacement matrix B;
when the number of columns with identical elements in the displacement matrix B is greater than or equal to a first threshold value, taking the displacement matrix B as a second matrix;
and when the number of columns with identical elements in the displacement matrix B is smaller than a first threshold value, performing i+1th row displacement processing by taking the displacement matrix B as a starting matrix of the i+1th row displacement processing until a second matrix is obtained after performing multiple row displacement processing.
In the embodiment of the present invention, in performing the line displacement processing on the first matrix for multiple times to obtain the second matrix, the first processing module 802 is specifically configured to:
Determining an initial matrix C of the j-th line displacement processing, and shifting any line in the initial matrix C to the left or right by one bit to obtain a displacement matrix D, wherein the number of columns with identical elements in the initial matrix C is smaller than a first threshold value, j is an integer greater than or equal to 1, and when j=1, the initial matrix C is a first matrix;
determining the number of target columns in the displacement matrix D, wherein the target columns are matrix columns with the number of continuous identical elements in the matrix columns being larger than a second threshold in the displacement matrix D;
when the number of the target columns in the displacement matrix D is greater than or equal to a first threshold value, taking the displacement matrix D as a second matrix;
and when the number of the target columns in the displacement matrix D is smaller than a first threshold value, the displacement matrix D is used as a starting matrix of j+1th row displacement processing to carry out j+1th row displacement processing until a plurality of row displacement processing are carried out, and a second matrix is obtained.
In an embodiment of the present invention, in performing multiple character scanning processing on each of r second binary data strings to obtain r simplified data strings, the first processing module 802 is specifically configured to:
traversing each second binary data string from the initial character E of the kth character scanning process to the right in turn until an end character F is determined, wherein the end character F is a character with a first value different from the initial character E in the kth character scanning process, or the end character F is the last character of each second binary data string, k is an integer greater than or equal to 1, and when k=1, the initial character E is the first character of each second binary data string;
Setting the scanning result of the kth character scanning process to be that the number of characters between the initial character E and the ending character F is increased by one when the ending character F is the character with the first value different from the initial character E in the kth character scanning process, and carrying out the kth+1st character scanning process by taking the ending character F as the starting character of the kth+1st character scanning process until the simplified data string corresponding to each second binary data string is obtained after carrying out the character scanning process for a plurality of times;
when the initial character E is the last character of each second binary data string, setting the scanning result of the kth character scanning process as 1, and sequencing the processing results of the multiple character scanning processes according to the processing sequence of the multiple character scanning processes to obtain a simplified data string corresponding to each second binary data string;
when the end character F is the last character of each second binary data string, setting the scanning result of the kth character scanning process to be the number of characters between the start character E and the end character F plus two, and sequencing the processing results of the multiple character scanning processes according to the processing sequence of the multiple character scanning processes to obtain a simplified data string corresponding to each second binary data string.
Meanwhile, referring to fig. 9, fig. 9 is a block diagram of functional modules of a data receiving device based on multi-data alignment according to an embodiment of the present application. As shown in fig. 9, the data receiving apparatus 900 based on multi-data alignment includes: a second receiving module 901, a second processing module 902 and a restoring module 903; wherein:
the second receiving module 901 is configured to receive data to be restored from a data sending end, where the data to be restored includes: a target data string and a description file;
the second processing module 902 is configured to split data of the target data string according to the description file, so as to obtain x simplified data strings; according to the description file and a preset conversion table, carrying out data conversion on each simplified data string in the x simplified data strings to obtain x third binary data strings, wherein the x third binary data strings are in one-to-one correspondence with the x simplified data strings; sequentially arranging elements in each third binary data string in the x third binary data strings from top to bottom according to arrangement positions in each third binary data string to obtain x vertical data strings, wherein the x vertical data strings are in one-to-one correspondence with the x third binary data strings; transversely splicing the x vertical data strings according to the label of each third binary data string to obtain a third matrix; performing repeated line displacement reduction on the third matrix according to the description file to obtain a fourth matrix; splitting the fourth matrix according to rows from top to bottom to obtain y fourth binary data strings;
The restoring module 903 is configured to restore data of each fourth binary data string in the y fourth binary data strings to obtain y original data, where the y original data corresponds to the y binary data one by one.
Referring to fig. 10, fig. 10 is a schematic structural diagram of a data transmitting device based on multiple data alignment according to an embodiment of the present application. As shown in fig. 10, the data transmission apparatus 1000 based on multi-data alignment includes a transceiver 1001, a processor 1002, and a memory 1003. Which are connected by a bus 1004. The memory 1003 is used to store computer programs and data, and the data stored in the memory 1003 can be transferred to the processor 1002.
The processor 1002 is configured to read a computer program in the memory 1003 to:
t pieces of data to be sent are obtained, wherein t is a positive integer greater than 1;
binary conversion is carried out on each data to be transmitted in t data to be transmitted, t first binary data strings are obtained, and the t first binary data strings are in one-to-one correspondence with the t data to be transmitted;
vertically stacking t first binary data strings to obtain a first matrix;
performing multiple line displacement processing on the first matrix to obtain a second matrix;
Splitting the second matrix according to columns to obtain r second binary data strings, wherein r is a positive integer greater than 0;
performing multiple character scanning processing on each second binary data string in the r second binary data strings respectively to obtain r simplified data strings, wherein the r simplified data strings are obtained to correspond to the r second binary data strings one by one;
longitudinally splicing r simplified data strings according to the arrangement position of each second binary data string in the second matrix to obtain a target data string;
and sending the target data string to a data receiving end.
In an embodiment of the present invention, in performing the row displacement processing on the first matrix for a plurality of times to obtain the second matrix, the processor 1002 is specifically configured to perform the following operations:
determining an initial matrix A of the ith row displacement processing, and shifting any row in the initial matrix A leftwards or rightwards by one bit to obtain a displacement matrix B, wherein the number of columns with identical elements in the initial matrix A is smaller than a first threshold value, i is an integer greater than or equal to 1, and when i=1, the initial matrix A is a first matrix;
determining the number of columns with identical elements in the displacement matrix B;
when the number of columns with identical elements in the displacement matrix B is greater than or equal to a first threshold value, taking the displacement matrix B as a second matrix;
And when the number of columns with identical elements in the displacement matrix B is smaller than a first threshold value, performing i+1th row displacement processing by taking the displacement matrix B as a starting matrix of the i+1th row displacement processing until a second matrix is obtained after performing multiple row displacement processing.
In an embodiment of the present invention, in performing the row displacement processing on the first matrix for a plurality of times to obtain the second matrix, the processor 1002 is specifically configured to perform the following operations:
determining an initial matrix C of the j-th line displacement processing, and shifting any line in the initial matrix C to the left or right by one bit to obtain a displacement matrix D, wherein the number of columns with identical elements in the initial matrix C is smaller than a first threshold value, j is an integer greater than or equal to 1, and when j=1, the initial matrix C is a first matrix;
determining the number of target columns in the displacement matrix D, wherein the target columns are matrix columns with the number of continuous identical elements in the matrix columns being larger than a second threshold in the displacement matrix D;
when the number of the target columns in the displacement matrix D is greater than or equal to a first threshold value, taking the displacement matrix D as a second matrix;
and when the number of the target columns in the displacement matrix D is smaller than a first threshold value, the displacement matrix D is used as a starting matrix of j+1th row displacement processing to carry out j+1th row displacement processing until a plurality of row displacement processing are carried out, and a second matrix is obtained.
In an embodiment of the present invention, the processor 1002 is specifically configured to perform the following operations in terms of performing multiple character scanning processing on each of r second binary data strings to obtain r simplified data strings:
traversing each second binary data string from the initial character E of the kth character scanning process to the right in turn until an end character F is determined, wherein the end character F is a character with a first value different from the initial character E in the kth character scanning process, or the end character F is the last character of each second binary data string, k is an integer greater than or equal to 1, and when k=1, the initial character E is the first character of each second binary data string;
setting the scanning result of the kth character scanning process to be that the number of characters between the initial character E and the ending character F is increased by one when the ending character F is the character with the first value different from the initial character E in the kth character scanning process, and carrying out the kth+1st character scanning process by taking the ending character F as the starting character of the kth+1st character scanning process until the simplified data string corresponding to each second binary data string is obtained after carrying out the character scanning process for a plurality of times;
When the initial character E is the last character of each second binary data string, setting the scanning result of the kth character scanning process as 1, and sequencing the processing results of the multiple character scanning processes according to the processing sequence of the multiple character scanning processes to obtain a simplified data string corresponding to each second binary data string;
when the end character F is the last character of each second binary data string, setting the scanning result of the kth character scanning process to be the number of characters between the start character E and the end character F plus two, and sequencing the processing results of the multiple character scanning processes according to the processing sequence of the multiple character scanning processes to obtain a simplified data string corresponding to each second binary data string.
Meanwhile, referring to fig. 11, fig. 11 is a schematic structural diagram of a data receiving device based on multi-data alignment according to an embodiment of the present application. As shown in fig. 11, the data receiving apparatus 1100 based on multi-data alignment includes a transceiver 1101, a processor 1102, and a memory 1103. Which are connected by a bus 1104. The memory 1103 is used for storing computer programs and data, and the data stored in the memory 1103 can be transferred to the processor 1102.
The processor 1102 is configured to read a computer program in the memory 1103 to perform the following operations:
receiving data to be restored from a data sending terminal, wherein the data to be restored comprises: a target data string and a description file;
carrying out data splitting on the target data string according to the description file to obtain x simplified data strings;
according to the description file and a preset conversion table, carrying out data conversion on each simplified data string in the x simplified data strings to obtain x third binary data strings, wherein the x third binary data strings are in one-to-one correspondence with the x simplified data strings;
sequentially arranging elements in each third binary data string in the x third binary data strings from top to bottom according to arrangement positions in each third binary data string to obtain x vertical data strings, wherein the x vertical data strings are in one-to-one correspondence with the x third binary data strings;
transversely splicing the x vertical data strings according to the label of each third binary data string to obtain a third matrix;
performing repeated line displacement reduction on the third matrix according to the description file to obtain a fourth matrix;
splitting the fourth matrix according to rows from top to bottom to obtain y fourth binary data strings;
And carrying out data reduction on each fourth binary data string in the y fourth binary data strings to obtain y original data, wherein the y original data are in one-to-one correspondence with the y binary data.
It should be understood that the data transmitting device based on multi-data alignment and the data receiving device based on multi-data alignment in the present application may include a smart Phone (such as an Android Phone, an iOS Phone, a Windows Phone, etc.), a tablet computer, a palm computer, a notebook computer, a mobile internet device MID (Mobile Internet Devices, abbreviated as MID), a robot, a wearable device, etc. The above-described data transmission apparatus based on multi-data alignment and data reception apparatus based on multi-data alignment are merely examples, and include, but are not limited to, the above-described data transmission apparatus based on multi-data alignment and data reception apparatus based on multi-data alignment. In practical applications, the data transmitting apparatus based on the multi-data alignment and the data receiving apparatus based on the multi-data alignment may further include: intelligent vehicle terminals, computer devices, etc.
From the above description of embodiments, it will be apparent to those skilled in the art that the present invention may be implemented in software in combination with a hardware platform. With such understanding, all or part of the technical solution of the present invention contributing to the background art may be embodied in the form of a software product, which may be stored in a storage medium, such as ROM/RAM, a magnetic disk, an optical disk, etc., including several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to perform the methods described in the various embodiments or parts of the embodiments of the present invention.
Accordingly, the present application also provides a computer-readable storage medium storing a computer program that is executed by a processor to implement some or all of the steps of any one of the data transmission method based on multi-data alignment and the data reception method based on multi-data alignment described in the above method embodiments. For example, the storage medium may include a hard disk, a floppy disk, an optical disk, a magnetic tape, a magnetic disk, a flash memory, etc.
The present application also provides a computer program product comprising a non-transitory computer readable storage medium storing a computer program operable to cause a computer to perform part or all of the steps of any of the data transmission method based on multi-data alignment and the data reception method based on multi-data alignment as set forth in the method embodiments described above.
It should be noted that, for simplicity of description, the foregoing method embodiments are all expressed as a series of action combinations, but it should be understood by those skilled in the art that the present application is not limited by the order of actions described, as some steps may be performed in other order or simultaneously according to the present application. Further, those skilled in the art will also appreciate that the embodiments described in the specification are all alternative embodiments, and that the acts and modules referred to are not necessarily required in the present application.
In the foregoing embodiments, the descriptions of the embodiments are focused on, and for those portions of one embodiment that are not described in detail, reference may be made to the related descriptions of other embodiments.
In the several embodiments provided in this application, it should be understood that the disclosed apparatus may be implemented in other manners. For example, the apparatus embodiments described above are merely illustrative, such as the division of the units, merely a logical function division, and there may be additional divisions when actually implemented, such as multiple units or components may be combined or integrated into another system, or some features may be omitted or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed with each other may be an indirect coupling or communication connection via some interfaces, devices or units, or may be in electrical or other forms.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the embodiment.
In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, each unit may exist alone physically, or two or more units may be integrated into one unit. The integrated units described above may be implemented either in hardware or in software program modules.
The integrated units, if implemented in the form of software program modules, may be stored in a computer-readable memory for sale or use as a stand-alone product. Based on such understanding, the technical solution of the present application may be embodied in essence or a part contributing to the prior art or all or part of the technical solution in the form of a software product stored in a memory, including several instructions for causing a computer device (which may be a personal computer, a server or a network device, etc.) to perform all or part of the steps of the method described in the embodiments of the present application. And the aforementioned memory includes: a U-disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a removable hard disk, a magnetic disk, or an optical disk, or other various media capable of storing program codes.
Those of ordinary skill in the art will appreciate that all or a portion of the steps in the various methods of the above embodiments may be implemented by a program that instructs associated hardware, and the program may be stored in a computer readable memory, and the memory may include: flash disk, read-Only Memory (ROM), random access Memory (Random Access Memory, RAM), magnetic disk or optical disk.
The foregoing has outlined rather broadly the more detailed description of the embodiments herein, and the detailed description of the principles and embodiments herein has been presented in terms of specific examples only to assist in the understanding of the methods and concepts of the present application; meanwhile, as those skilled in the art will have modifications in the specific embodiments and application scope in accordance with the ideas of the present application, the present description should not be construed as limiting the present application in view of the above.

Claims (9)

1. A data transmission method based on multiple data alignment, wherein the method is applied to a data transmission end, the method comprising:
t pieces of data to be sent are obtained, wherein t is a positive integer greater than 1;
Performing binary conversion on each data to be transmitted in the t data to be transmitted to obtain t first binary data strings, wherein the t first binary data strings are in one-to-one correspondence with the t data to be transmitted;
vertically stacking the t first binary data strings to obtain a first matrix;
determining an initial matrix C of the j-th line displacement processing, and displacing any line in the initial matrix C to the left or right by one bit to obtain a displacement matrix D, wherein the number of columns with identical elements in the initial matrix C is smaller than a first threshold value, j is an integer greater than or equal to 1, and when j=1, the initial matrix C is the first matrix;
determining the number of target columns in the displacement matrix D, wherein the target columns are matrix columns with the number of continuous identical elements in the matrix columns being larger than a second threshold in the displacement matrix D;
when the number of target columns in the displacement matrix D is greater than or equal to the first threshold value, taking the displacement matrix D as a second matrix;
when the number of target columns in the displacement matrix D is smaller than the first threshold, the displacement matrix D is used as a starting matrix of j+1th row displacement processing to carry out j+1th row displacement processing until the second matrix is obtained after a plurality of row displacement processing;
Splitting the second matrix according to columns to obtain r second binary data strings, wherein r is a positive integer greater than 0;
performing multiple character scanning processing on each second binary data string in the r second binary data strings respectively to obtain r simplified data strings, wherein the obtained r simplified data strings are in one-to-one correspondence with the r second binary data strings;
longitudinally splicing the r simplified data strings according to the arrangement position of each second binary data string in the second matrix to obtain a target data string;
and sending the target data string to the data receiving end.
2. The method of claim 1, wherein performing a plurality of line displacement processes on the first matrix to obtain a second matrix comprises:
determining an initial matrix A of the ith row displacement processing, and shifting any row in the initial matrix A to the left or right by one bit to obtain a displacement matrix B, wherein the number of columns with identical elements in the initial matrix A is smaller than a first threshold value, i is an integer greater than or equal to 1, and when i=1, the initial matrix A is the first matrix;
determining the number of columns with identical elements in the displacement matrix B;
When the number of columns with identical elements in the displacement matrix B is greater than or equal to the first threshold value, taking the displacement matrix B as the second matrix;
and when the number of columns with identical elements in the displacement matrix B is smaller than the first threshold, taking the displacement matrix B as an initial matrix of the (i+1) th row displacement processing to perform the (i+1) th row displacement processing until the second matrix is obtained after the multiple row displacement processing.
3. The method according to claim 1 or 2, wherein performing character scanning processing on each of the r second binary data strings for a plurality of times to obtain r simplified data strings includes:
traversing each second binary data string from a starting character E of the kth character scanning process to the right in turn until an ending character F is determined, wherein the ending character F is a character with a first value different from the starting character E in the kth character scanning process, or the ending character F is a last character of each second binary data string, k is an integer greater than or equal to 1, and when k=1, the starting character E is a first character of each second binary data string;
When the end character F is a character with a first value different from the initial character E in the kth character scanning process, setting a scanning result of the kth character scanning process to be that the number of characters between the initial character E and the end character F is increased by one, and taking the end character F as a starting character of the kth+1th character scanning process to carry out the kth+1th character scanning process until a plurality of times of character scanning processes are carried out, so as to obtain a simplified data string corresponding to each second binary data string;
when the initial character E is the last character of each second binary data string, setting the scanning result of the kth character scanning process as 1, and sequencing the processing results of the multiple character scanning processes according to the processing sequence of the multiple character scanning processes to obtain a simplified data string corresponding to each second binary data string;
when the end character F is the last character of each second binary data string, setting the scanning result of the kth character scanning process to be that the number of characters between the initial character E and the end character F is increased by two, and sequencing the processing results of the multiple character scanning processes according to the processing sequence of the multiple character scanning processes to obtain a simplified data string corresponding to each second binary data string.
4. A data receiving method based on multiple data alignment, wherein the method is applied to a data receiving end, and the method comprises:
receiving data to be restored from a data sending terminal, wherein the data to be restored comprises: a target data string and a description file;
according to the description file, carrying out data splitting on the target data string to obtain x simplified data strings;
according to the description file and a preset conversion table, carrying out data conversion on each simplified data string in the x simplified data strings to obtain x third binary data strings, wherein the x third binary data strings are in one-to-one correspondence with the x simplified data strings;
sequentially arranging elements in each third binary data string in the x third binary data strings from top to bottom according to arrangement positions in each third binary data string to obtain x vertical data strings, wherein the x vertical data strings are in one-to-one correspondence with the x third binary data strings;
transversely splicing the x vertical data strings according to the label of each third binary data string to obtain a third matrix;
performing repeated line displacement reduction on the third matrix according to the description file to obtain a fourth matrix;
Splitting the fourth matrix according to rows from top to bottom to obtain y fourth binary data strings;
and carrying out data reduction on each fourth binary data string in the y fourth binary data strings to obtain y original data, wherein the y original data are in one-to-one correspondence with the y binary data.
5. A data transmitting device based on multi-data alignment is characterized in that,
the device comprises: the device comprises a first receiving module, a first processing module and a sending module; wherein the method comprises the steps of
The first receiving module is configured to obtain t data to be sent, where t is a positive integer greater than 1;
the first processing module is configured to binary convert each data to be sent in the t data to be sent to obtain t first binary data strings, where the t first binary data strings are in one-to-one correspondence with the t data to be sent; vertically stacking the t first binary data strings to obtain a first matrix; determining an initial matrix C of the j-th line displacement processing, and displacing any line in the initial matrix C to the left or right by one bit to obtain a displacement matrix D, wherein the number of columns with identical elements in the initial matrix C is smaller than a first threshold value, j is an integer greater than or equal to 1, and when j=1, the initial matrix C is the first matrix; determining the number of target columns in the displacement matrix D, wherein the target columns are matrix columns with the number of continuous identical elements in the matrix columns being larger than a second threshold in the displacement matrix D; when the number of target columns in the displacement matrix D is greater than or equal to the first threshold value, taking the displacement matrix D as a second matrix; when the number of target columns in the displacement matrix D is smaller than the first threshold, the displacement matrix D is used as a starting matrix of j+1th row displacement processing to carry out j+1th row displacement processing until the second matrix is obtained after a plurality of row displacement processing; splitting the second matrix according to columns to obtain r second binary data strings, wherein r is a positive integer greater than 0; performing multiple character scanning processing on each second binary data string in the r second binary data strings respectively to obtain r simplified data strings, wherein the obtained r simplified data strings are in one-to-one correspondence with the r second binary data strings; longitudinally splicing the r simplified data strings according to the arrangement position of each second binary data string in the second matrix to obtain a target data string;
The sending module is used for sending the target data string to the data receiving end.
6. A data receiving device based on multiple data alignment is characterized in that,
the device comprises: the device comprises a second receiving module, a second processing module and a restoring module; wherein the method comprises the steps of
The second receiving module is configured to receive data to be restored from a data sending end, where the data to be restored includes: a target data string and a description file;
the second processing module is used for splitting the data of the target data string according to the description file to obtain x simplified data strings; according to the description file and a preset conversion table, carrying out data conversion on each simplified data string in the x simplified data strings to obtain x third binary data strings, wherein the x third binary data strings are in one-to-one correspondence with the x simplified data strings; sequentially arranging elements in each third binary data string in the x third binary data strings from top to bottom according to arrangement positions in each third binary data string to obtain x vertical data strings, wherein the x vertical data strings are in one-to-one correspondence with the x third binary data strings; transversely splicing the x vertical data strings according to the label of each third binary data string to obtain a third matrix; performing repeated line displacement reduction on the third matrix according to the description file to obtain a fourth matrix; splitting the fourth matrix according to rows from top to bottom to obtain y fourth binary data strings;
The restoring module is configured to restore data of each fourth binary data string in the y fourth binary data strings to obtain y original data, where the y original data corresponds to the y binary data one by one.
7. A data transmission device based on multiple data alignment, comprising a processor, a memory, a communication interface, and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the processor, the one or more programs comprising instructions for performing the steps in the method of any of claims 1-3.
8. A data receiving device based on multiple data alignment, comprising a processor, a memory, a communication interface, and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the processor, the one or more programs comprising instructions for performing the steps of claim 4.
9. A computer readable storage medium, characterized in that the computer readable storage medium stores a computer program, which is executed by a processor to implement the method of any of claims 1-4.
CN202111169005.3A 2021-09-30 2021-09-30 Data transmitting and receiving method, device and equipment based on multi-data alignment Active CN114070901B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN202111169005.3A CN114070901B (en) 2021-09-30 2021-09-30 Data transmitting and receiving method, device and equipment based on multi-data alignment
PCT/CN2022/119921 WO2023051319A1 (en) 2021-09-30 2022-09-20 Data sending method, apparatus and device based on multi-data alignment, data receiving method, apparatus and device based on multi-data alignment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111169005.3A CN114070901B (en) 2021-09-30 2021-09-30 Data transmitting and receiving method, device and equipment based on multi-data alignment

Publications (2)

Publication Number Publication Date
CN114070901A CN114070901A (en) 2022-02-18
CN114070901B true CN114070901B (en) 2024-01-02

Family

ID=80234146

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111169005.3A Active CN114070901B (en) 2021-09-30 2021-09-30 Data transmitting and receiving method, device and equipment based on multi-data alignment

Country Status (2)

Country Link
CN (1) CN114070901B (en)
WO (1) WO2023051319A1 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114070901B (en) * 2021-09-30 2024-01-02 深圳智慧林网络科技有限公司 Data transmitting and receiving method, device and equipment based on multi-data alignment

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103365814A (en) * 2013-06-27 2013-10-23 深圳市汇顶科技股份有限公司 Serial data transmission method and system
CN105703782A (en) * 2016-03-11 2016-06-22 深圳大学 Incremental shift matrix construction method, network coding method and system
CN110233626A (en) * 2019-07-05 2019-09-13 重庆邮电大学 Mechanical oscillation signal edge data lossless compression method based on two-dimensional adaptive quantization
CN111881115A (en) * 2020-08-01 2020-11-03 江苏哩咕信息科技有限公司 Database coordination optimization method based on big data dynamic planning
CN112364294A (en) * 2020-10-27 2021-02-12 中国核动力研究设计院 Automatic conversion method, device, equipment and medium for reactor core numerical calculation matrix

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP6740912B2 (en) * 2017-01-17 2020-08-19 富士通株式会社 Data compression device, data compression program, data compression method and program
US11120101B2 (en) * 2019-09-27 2021-09-14 Arm Limited Matrix multiplication system and method
CN111222306A (en) * 2020-01-06 2020-06-02 广州虎牙科技有限公司 Data processing method and device, electronic equipment and storage medium
CN112861475A (en) * 2020-11-03 2021-05-28 深圳市和讯华谷信息技术有限公司 Encoding and decoding processing method, device, equipment and storage medium
CN112506880B (en) * 2020-12-18 2022-03-08 深圳智慧林网络科技有限公司 Data processing method and related equipment
CN114070901B (en) * 2021-09-30 2024-01-02 深圳智慧林网络科技有限公司 Data transmitting and receiving method, device and equipment based on multi-data alignment

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103365814A (en) * 2013-06-27 2013-10-23 深圳市汇顶科技股份有限公司 Serial data transmission method and system
CN105703782A (en) * 2016-03-11 2016-06-22 深圳大学 Incremental shift matrix construction method, network coding method and system
CN110233626A (en) * 2019-07-05 2019-09-13 重庆邮电大学 Mechanical oscillation signal edge data lossless compression method based on two-dimensional adaptive quantization
CN111881115A (en) * 2020-08-01 2020-11-03 江苏哩咕信息科技有限公司 Database coordination optimization method based on big data dynamic planning
CN112364294A (en) * 2020-10-27 2021-02-12 中国核动力研究设计院 Automatic conversion method, device, equipment and medium for reactor core numerical calculation matrix

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
"面向健康智能家居的数据压缩与加密技术研究";陈思伟;《中国优秀硕士学位论文全文数据库》;全文 *

Also Published As

Publication number Publication date
WO2023051319A1 (en) 2023-04-06
CN114070901A (en) 2022-02-18

Similar Documents

Publication Publication Date Title
US10505671B2 (en) Polar code encoding method and device
US10116325B2 (en) Data compression/decompression device
US10896171B2 (en) Big data blockchains with Merkle trees
CN106852185A (en) Parallelly compressed encoder based on dictionary
WO2023061177A1 (en) Multi-data sending method, apparatus and device based on columnar data scanning, and multi-data receiving method, apparatus and device based on columnar data scanning
CN108628898B (en) Method, device and equipment for data storage
CN108197324B (en) Method and apparatus for storing data
CN112506880B (en) Data processing method and related equipment
CN114070901B (en) Data transmitting and receiving method, device and equipment based on multi-data alignment
WO2018177386A1 (en) Polar code encoding and decoding method, sending device and receiving device
CN114138231B (en) Method, circuit and SOC for executing matrix multiplication operation
CN111353289B (en) Document comparison method and device, storage medium and electronic equipment
WO2023061180A1 (en) Multi frequency-based data sending method and apparatus, multi frequency-based data receiving method and apparatus, and device
CN111290714B (en) Data reading method and device
CN103036642B (en) A kind of transmission method of data and transmitting terminal and receiving terminal
CN111694692A (en) Data storage erasure method, device and equipment and readable storage medium
CN110598068A (en) Global identification generation method and device
CN112054805A (en) Model data compression method, system and related equipment
CN116662063B (en) Error correction configuration method, error correction method, system, equipment and medium for flash memory
WO2017186049A1 (en) Method and device for information processing
CN115454356B (en) Data file processing method, device and equipment based on recognition and aggregation algorithm
CN116708480B (en) Data synchronization method based on Datax frame
CN117235078B (en) Method, system, device and storage medium for processing mass data at high speed
CN117375629A (en) Data compression method and device, electronic equipment and storage medium
CN105068949A (en) Data transmission method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant