Sequence processing method, device, equipment, and computer-readable storage medium
By shifting and exorbitant operations on binary window sequences, the problem of inefficiency in handling large-scale binary sequences in the prior art is solved, and efficient sequence processing and precise run feature extraction are achieved.
Patent Information
- Application Number
- CN202411496683.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-25
- Publication Date
- 2025-03-18
- Estimated Expiration
- 2044-10-25
AI Technical Summary
When processing large-scale binary sequences, the prior art has high time complexity and high computing resources consumption, resulting in low efficiency.
By obtaining the binary window sequence to be processed, performing a shift operation to obtain a binary window shift sequence, and performing an XOR operation with the binary window sequence to obtain the XOR result of the window. Determine the evaluation result based on the number of 1 in the window XOR result and the preset label range.
Synchronous processing of multiple elements in the sequence is realized, which significantly improves the efficiency of sequence processing, and accurately recognizes the starting position of the run through XOR operation, improving the accuracy of the run feature extraction.
Smart Images

Figure CN119026536B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to but is not limited to the field of data analysis technology, and in particular to a sequence processing method, device, equipment, and computer-readable storage medium. Background Art
[0002] Run-length distribution is an important indicator for evaluating data distribution characteristics. The existing method of processing binary sequences to obtain data run-length distribution is limited to traversing each element one by one. This method not only has a high time complexity, but also requires frequent access to data elements and execution of conditional judgments, which is often accompanied by high computing resource consumption and memory usage, thus limiting the efficiency of calculating run-length characteristics when processing large-scale data sets. Therefore, exploring more efficient sequence processing methods has become the key to improving processing performance. Summary of the invention
[0003] In view of this, embodiments of the present application at least provide a sequence processing method, apparatus, device, and computer-readable storage medium.
[0004] The technical solution of the embodiment of the present application is implemented as follows:
[0005] In a first aspect, an embodiment of the present application provides a sequence processing method, including: obtaining a binary window sequence to be processed; shifting the binary window sequence to obtain a binary window shift sequence; performing an XOR operation on the binary window sequence and a corresponding binary window shift sequence to obtain a window XOR result corresponding to the binary window sequence; wherein the window XOR result is a binary sequence; determining an evaluation result based on the number of 1s in the window XOR result and a preset marking range; wherein the evaluation result is used to characterize whether the binary window sequence meets the requirements.
[0006] In the embodiment of the present application, a binary window sequence to be processed is obtained, and the binary window sequence is shifted to obtain a binary window shift sequence, and the binary window sequence is XORed with each bit of the binary window shift sequence to obtain a window XOR result represented in binary form, and the evaluation result is determined according to the number of 1s in the window XOR result and a preset annotation range. In this way, since the shift operation and the XOR operation are both bit-level operations that can be efficiently executed in parallel at the hardware level, when they are jointly applied to the binary window sequence, it is possible to achieve synchronous processing of multiple elements in the sequence, thereby significantly improving the efficiency of sequence processing. In addition, by utilizing the characteristics of the XOR operation (i.e., when the two compared elements are the same, the result is 0, and when they are different, the result is 1), the starting position information of all runs in the binary window sequence can be accurately identified from the window XOR result, and the accuracy of extracting the run characteristics is improved without changing the original structure of the binary window sequence.
[0007] In a second aspect, an embodiment of the present application provides a sequence processing device, comprising: a first acquisition module, used to acquire a binary window sequence to be processed; a shift module, used to shift the binary window sequence to obtain a binary window shift sequence; a first XOR operation module, used to perform an XOR operation on the binary window sequence and the corresponding binary window shift sequence to obtain a window XOR result corresponding to the binary window sequence; wherein the window XOR result is a binary sequence; a first determination module, used to determine an evaluation result based on the number of 1s in the window XOR result and a preset marking range; wherein the evaluation result is used to characterize whether the binary window sequence meets the requirements.
[0008] In a third aspect, an embodiment of the present application provides a sequence processing device, including a memory and a processor, wherein the memory stores a computer program that can be run on the processor, and when the processor executes the program, some or all of the steps in the above method are implemented.
[0009] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium having a computer program stored thereon, which implements some or all of the steps in the above method when executed by a processor.
[0010] It should be understood that the above general description and the following detailed description are merely exemplary and explanatory, and are not intended to limit the technical solutions of the present application. BRIEF DESCRIPTION OF THE DRAWINGS
[0011] The drawings herein are incorporated into the specification and constitute a part of the specification. These drawings illustrate embodiments consistent with the present application and are used together with the specification to illustrate the technical solution of the present application.
[0012] Figure 1 A schematic diagram of an implementation process of a sequence processing method provided in an embodiment of the present application Figure 1 ;
[0013] Figure 2 A schematic diagram of an implementation process of a sequence processing method provided in an embodiment of the present application Figure 2 ;
[0014] Figure 3 A schematic diagram of an implementation process of a sequence processing method provided in an embodiment of the present application Figure 3 ;
[0015] Figure 4 A schematic diagram of an implementation process of a sequence processing method provided in an embodiment of the present application Figure 4 ;
[0016] Figure 5 A schematic diagram of an implementation process of a sequence processing method provided in an embodiment of the present application Figure 5 ;
[0017] Figure 6 A schematic diagram of an implementation process of a sequence processing method provided in an embodiment of the present application Figure 6 ;
[0018] Figure 7 A schematic diagram of an implementation process of a sequence processing method provided in an embodiment of the present application Figure 7 ;
[0019] Figure 8 A schematic diagram of an implementation process of a sequence processing method provided in an embodiment of the present application Figure 8 ;
[0020] Fig. 9 A schematic diagram of an implementation process of a sequence processing method provided in an embodiment of the present application Figure 9 ;
[0021] Fig.10 A schematic diagram of an implementation process of a sequence processing method provided in an embodiment of the present application Figure 10 ;
[0022] Fig.11 A schematic diagram of an implementation process of a sequence processing method provided in an embodiment of the present application Figure 10 one;
[0023] Fig.12 A schematic diagram of an implementation process of a sequence processing method provided in an embodiment of the present application Figure 10 two;
[0024] Fig.13 A schematic diagram of a sequence processing method provided in an embodiment of the present application Figure 1 ;
[0025] Fig.14 A schematic diagram of a sequence processing method provided in an embodiment of the present application Figure 2 ;
[0026] Fig.15 A schematic diagram of an implementation process of a sequence processing method provided in an embodiment of the present application Figure 10 three;
[0027] Fig.16 A schematic diagram of the structure of a sequence processing device provided in an embodiment of the present application;
[0028] Fig.17 A hardware entity diagram of a sequence processing device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0029] In order to make the purpose, technical solutions and advantages of the present application clearer, the technical solutions of the present application are further elaborated in detail below in conjunction with the drawings and embodiments. The described embodiments should not be regarded as limiting the present application. All other embodiments obtained by ordinary technicians in the field without making creative work are within the scope of protection of the present application.
[0030] In the following description, reference is made to “some embodiments”, which describe a subset of all possible embodiments, but it will be understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.
[0031] The terms "first / second / third" involved are merely used to distinguish similar objects and do not represent a specific ordering of the objects. It is understandable that "first / second / third" can be interchanged with a specific order or sequence where permitted so that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein.
[0032] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used herein are only for the purpose of describing this application and are not intended to limit this application.
[0033] Before describing the sequence processing method in the embodiment of the present application, the professional terms involved in the embodiment of the present application are first explained:
[0034] Binary sequence: A bit sequence consisting of "0" and "1".
[0035] Run: In a sequence, a subsequence consisting of consecutive "0" or "1", and the subsequence contains at least one element, and the previous element (if any) and the next element (if any) of the subsequence are different from its own elements.
[0036] In the field of chip security design technology, in the prior art, for a given binary sequence, the total number of runs in the sequence can be detected using data analysis methods such as traversal counting method, improved traversal method, iterator, state machine, and regular expression method.
[0037] The traversal counting method performs the same operation on each element in the sequence to achieve a complete traversal of the data set, and uses a counter to record the number of elements that meet the conditions or the number of times the loop is executed. Exemplarily, the traversal counting method can perform conditional judgment operations on each element in the sequence to achieve a complete traversal of the data set. The time complexity of the traversal counting method is usually O(n), where n is the size of the data set (that is, the number of elements in the sequence), that is, the total number of loop executions during traversal. When the processed data set is large, the time complexity of the traversal counting method is high, which will lead to reduced efficiency in program execution. In addition, during the traversal process, it is necessary to access the elements in the data set one by one and perform conditional judgment operations, which may take up more computing resources and memory resources, resulting in reduced efficiency.
[0038] The Improved Traversal Method makes improvements based on the traversal counting method, and takes a series of optimization measures by deeply analyzing the performance bottlenecks and shortcomings of traditional traversal algorithms. For example, the optimization measures may include improving the efficiency and accuracy of traversal by introducing new data structures (such as stacks, queues, hash tables, etc.), optimizing the traversal order, reducing repeated calculations, or using parallel computing. The improved traversal method requires more complex logic and algorithm design, which increases the difficulty of implementation and the possibility of errors, and reduces the readability and maintainability of the code. For example, the increased difficulty of implementation and the possibility of errors can be reflected in the fact that the improved traversal method may be incompatible with existing systems or frameworks, requiring additional adaptation work, occupying more computing resources and memory resources, and resulting in reduced efficiency. The reduced readability and maintainability of the code can be reflected in the fact that the implementation of the improved traversal method may involve complex logic and algorithms, resulting in reduced code readability. For complex traversal methods, maintenance and updates may be more difficult.
[0039] Through the method of iterator or state machine, two states can be set up to manage the stroke: one is the "stroke start" state, and the other is the "stroke continuation" state. When traversing the sequence, whenever an element different from the previous element is encountered, it is considered to jump to the "stroke start" state. At this time, the counter is increased by 1 to record the new stroke start and the value of the current stroke is updated. Subsequently, as long as the traversed element has the same value as the current stroke, it remains in the "stroke continuation" state and the counter is no longer increased until a different element is encountered, and it jumps to the "stroke start" state again. Traverse the elements in the sequence, access each element in the sequence through the state machine and use the final counter value as the result of the total number of strokes in the sequence. Using iterators and state machines to detect the total number of strokes in a sequence In some implementations, especially when the sequence is very large or the element type is complex, iterators and their related states (such as state information in the state machine) may occupy a certain amount of memory space, resulting in reduced efficiency. In addition, the sequence contains a large number of short strokes, and frequent state switching will introduce additional performance overhead.
[0040] Regular expressions cannot be used directly to detect the total number of runs in a sequence. Since the definition of a run is based on the continuous appearance of the same character, regular expressions are mainly used for string pattern matching. The segmentation and matching functions of regular expressions can be used to assist in detecting runs, rather than directly performing numerical calculations or processing non-string data structures. Although regular expressions can assist in detecting runs in a sequence, their syntax is relatively complex and requires high writing and understanding skills. At the same time, when processing large data or complex patterns, regular expressions may execute slowly, affecting the performance of the application. Therefore, the method of using regular expressions to assist in detecting runs in a sequence is only a theoretically feasible method and has poor practicality.
[0041] The above data analysis methods such as traversal counting method, improved traversal method, iterator or state machine, regular expression method, etc. all traverse all elements of the sequence and rely on complex algorithm design to a certain extent, resulting in low efficiency in obtaining the total number of runs. In addition, although the total number of runs can be counted by the counter, the distribution of runs in the sequence cannot be obtained.
[0042] In order to solve the problems of the related art, the present application embodiment provides a sequence processing method, such as Figure 1 As shown, the sequence processing method can be implemented through steps S101 to S104:
[0043] Step S101, obtaining a binary window sequence to be processed.
[0044] In the embodiment of the present application, the binary window sequence is a binary sequence. The binary sequence is a sequence of finite length consisting of 0 and 1. Exemplarily, the binary sequence may be "00011010".
[0045] Step S102, shifting the binary window sequence to obtain a binary window shifted sequence.
[0046] Among them, shifting means moving each element in a sequence to a certain position according to the specified position, thereby forming a new sequence. For example, when a sequence is shifted to the left, it is equivalent to moving each element position in the original sequence forward, and the vacant position can be filled with 0 or other specific values, and the filling value depends on the specific shift rule.
[0047] Step S103, performing an XOR operation on the binary window sequence and the corresponding binary window shift sequence to obtain a window XOR result corresponding to the binary window sequence.
[0048] In the embodiment of the present application, the window XOR result is a binary sequence. Among them, the XOR operation is a basic logical operation, also known as logical XOR, which is commonly used in computer science and electronic engineering, and has unique properties and wide applications. When the XOR operation is performed on two unequal values, the XOR result obtained is 1; when the XOR operation is performed on two equal values, the XOR result obtained is 0. Exemplarily, the XOR operation result of "1" and "0" is 1, and the XOR operation result of "1" and "1" is 0.
[0049] Step S104, determining the evaluation result according to the number of 1s in the window XOR result and a preset marking range.
[0050] The evaluation result is used to characterize whether the binary window sequence meets the requirements.
[0051] It can be understood that in a binary sequence, consecutive identical elements (0 or 1) constitute a run. After the binary sequence is shifted to obtain the shifted binary sequence, the binary sequence and the shifted binary sequence are subjected to a bit-by-bit XOR operation to obtain a new sequence A for characterizing the XOR operation result. Each 1 in sequence A represents the beginning or end of a run, and the information of the run can be obtained by counting the number of 1s. Exemplarily, the binary window sequence and the shifted XOR operation result include three 1s, which means that the binary window sequence involves the beginning or end of three runs, that is, the number of runs obtained is 3.
[0052] In some embodiments, the preset annotation range can be set by the user who uses the sequence processing product for the purpose of predicting the annotation results, so as to determine whether the input data can meet the randomness expected by the user. The randomness of the input data is indirectly reflected by the total number of runs.
[0053] Exemplarily, a user may input a 1000-bit binary sequence into a sequence processing device, and set the annotation range of the predicted total number of runs to (50±2). When it is detected that the total number of runs in the input binary sequence is 50, it indicates that the input data can meet the randomness expected by the user. When the total number of runs is 45, it indicates that the input data cannot meet the randomness expected by the user.
[0054] In other embodiments, the sequence processing method further includes: displaying evaluation results.
[0055] In the embodiment of the present application, a binary window sequence to be processed is obtained, and the binary window sequence is shifted to obtain a binary window shift sequence. Then, the binary window sequence is subjected to an XOR operation with each bit of the binary window shift sequence to obtain a window XOR result represented in binary form. The evaluation result is determined according to the number of 1s in the window XOR result and a preset annotation range. In this way, since the shift operation and the XOR operation are both bit-level operations that can be efficiently executed in parallel at the hardware level, when they are jointly applied to the binary window sequence, the synchronous processing of multiple elements in the sequence can be achieved, thereby significantly improving the efficiency of sequence processing. In addition, by utilizing the characteristics of the XOR operation (i.e., when the two compared elements are the same, the result is 0, and when they are different, the result is 1), the starting position information of all runs in the binary window sequence can be accurately identified from the window XOR result, and the accuracy of extracting the run characteristics is improved without changing the original structure of the binary window sequence.
[0056] In some embodiments, Figure 2 As shown, before executing step S101 "obtaining a binary window sequence to be processed", the method may include steps S201 to S205. Figure 2 The steps shown are explained.
[0057] Step S201, obtaining a sequence to be processed.
[0058] The sequence to be processed is a sequence composed of multiple data elements of the same type.
[0059] In some embodiments, the sequence to be processed may include a sequence of data structures such as an array, a list, a linked list or a queue. Exemplarily, when the sequence to be processed is an array, the sequence to be processed may be an integer array int[] numbers={1,2,3,4,5}, where int is an integer type, that is, the sequence number represents a string number containing 5 integer type elements (1, 2, 3, 4 and 5). When the sequence to be processed is a list, the sequence to be processed may be list_str=["apple","banana","cherry"], where the sequence list_str represents a string list containing three string elements (apple, banana and cherry).
[0060] Step S202, determining whether the data elements in the sequence to be processed are represented in binary form.
[0061] It is understandable that there are cases where the sequence to be processed does not conform to the expected binary format. If the sequence to be processed is directly processed without judgment, it may cause program crash, data corruption or wrong output due to data type mismatch or format error. By judging whether the data elements in the sequence to be processed are represented in binary form, it can be ensured that the subsequent processing flow is carried out on the correct data format, thereby avoiding potential errors.
[0062] In some embodiments, the method for determining whether the data elements in the sequence to be processed are represented in binary form may include checking and encoding checking. Exemplarily, checking whether there are characters other than 0 and 1 in the sequence to be processed, judging whether the data elements in the sequence are represented in binary form, and in the case where there are characters other than 0 and 1 in the sequence to be processed, determining that the data elements in the sequence are not represented in binary form, otherwise, determining that the data elements in the sequence are represented in binary form. It is also possible to determine whether the data elements in the sequence are represented in binary form by encoding checking whether the data type of the data to be processed is bytes or bytearray, and if the data type of the sequence to be processed is bytes or bytearray, determining that the data elements in the sequence are represented in binary form, otherwise, determining that the data elements in the sequence are not represented in binary form. Among them, bytes is an immutable byte sequence used to represent binary data; bytearray is a mutable byte sequence, also used to represent binary data.
[0063] Step S203: when the data elements in the sequence to be processed are represented in binary form, the sequence to be processed is determined as a binary sequence to be processed.
[0064] Step S204: when the data elements in the sequence to be processed are not represented in binary form, preprocess the sequence to be processed to obtain a binary sequence to be processed.
[0065] It is understandable that, since computer hardware and sequence processing algorithms are designed based on binary sequences, ensuring that the data to be processed is a binary sequence can make the computer more efficient in processing the data.
[0066] Step S205: divide the binary sequence into multiple binary window sequences according to a preset window length.
[0067] In some embodiments, the preset window length is a natural number set by the user that is greater than 2. For example, when the window length set by the user is 100 bits, the 1000-bit binary sequence will be divided into 10 binary window sequences, each of which includes 100 bits of binary bits.
[0068] In some embodiments, dividing the binary sequence into binary window sequences may further include dividing the binary sequence into multiple binary window sequences according to a preset number of windows. For example, when the number of windows set by the user is 20, 1000 bits of data will be grouped into 20 binary window sequences, each of which includes 50 bits of binary bits.
[0069] In some embodiments, after the binary sequence is divided into binary window sequences according to a preset window length, if the end of the binary sequence is a separate run (and the run length is less than the preset window length), it is necessary to perform additional processing on the separate run according to the specific situation. Exemplarily, the additional processing may include filling the separate run, filling multiple 0s when the run is a 0 run, and filling multiple 1s when the run is a 1 run, until its length reaches the preset window length. The additional processing may also include treating the run as a special mark or identifier, not performing shift and XOR operations, and recording the XOR operation result as 1.
[0070] In the embodiment of the present application, the sequence to be processed is converted into a binary sequence to be processed, and then the binary sequence to be processed is divided into multiple binary window sequences according to a preset window length. In this way, since the binary sequence consists of only two states (0 and 1) and does not involve complex value or state changes, the memory resources required are relatively small. Converting all sequences to be processed into binary sequences before processing can greatly simplify the complexity of analyzing binary sequences, thereby effectively improving the efficiency of sequence processing.
[0071] In some embodiments, after executing step S205 "dividing the binary sequence into multiple binary window sequences according to the preset window length", steps S2051 and S2052 may be included. Figure 3 The steps shown are explained.
[0072] Step S2051 : dividing a plurality of binary window sequences into a plurality of groups of binary window sequences according to a preset number of division groups.
[0073] Step S2052, allocating each set of binary window sequences to a parallel total run length detection module.
[0074] Among them, the total number of runs detection module is used to process binary window sequences in parallel.
[0075] It can be understood that different total run length detection modules can process binary sequences of multiple windows in parallel, efficiently and independently. This parallel processing method can significantly improve the efficiency of sequence processing.
[0076] In some embodiments, different total run detection modules can be used to detect different sequence data. For example, total run detection module 1 is used to detect sequence data A, and total run detection module 2 is used to detect sequence data B.
[0077] In an embodiment of the present application, after multiple binary window sequences are divided into multiple groups of binary window sequences according to a preset number of division groups, the multiple groups of binary window sequences are assigned to parallel total run detection modules for sequence processing, and each total run detection module can independently process a group of binary window sequences, thereby significantly improving the processing speed and efficiency of sequence processing.
[0078] In some embodiments, Figure 4 As shown, the step S204 of "preprocessing the sequence to be processed to obtain the binary sequence to be processed" may include steps S301 and S302. Figure 4 The steps shown are explained.
[0079] Step S301, querying preset conversion rules based on the data type information of the sequence to be processed, and determining a conversion method corresponding to the sequence to be processed.
[0080] The data type information represents the data type of the data element in the sequence to be processed. For example, the data type of the data element may include integer, floating point, Boolean, string, list, etc.
[0081] The preset conversion rules are used to characterize the conversion relationship between the data elements corresponding to the data type and the binary sequence.
[0082] It is understandable that the types of data elements in the sequence to be processed require different conversion strategies. Therefore, when the sequence to be processed needs to be pre-processed and converted into a binary sequence, it is necessary to first find the corresponding conversion method in the preset conversion rules.
[0083] In some embodiments, a preset conversion rule is queried based on the data type information of the sequence to be processed to determine the conversion method corresponding to the sequence to be processed. If there are multiple matching conversion rules, the most appropriate rule needs to be selected according to the specific business scenario and requirements.
[0084] Step S302: using a conversion method corresponding to the sequence to be processed, convert each data element in the sequence to be processed into a binary sequence to obtain a binary sequence.
[0085] In some embodiments, the input data is ensured to be a binary sequence (a sequence of 0s and 1s), and if not, it needs to be converted. This process usually involves converting each value to 0 or 1. For example, if there is an array of integers, treating these integers as components of a binary sequence requires setting a threshold, converting integers greater than the threshold to 1, and converting integers less than or equal to the threshold to 0.
[0086] In the embodiment of the present application, based on the conversion method corresponding to the data type information of the sequence to be processed, each data element in the sequence to be processed is converted into a binary number to obtain a binary sequence to be processed. In this way, the sequence to be processed is converted into a binary sequence using the conversion rule corresponding to the data type of the sequence to be processed, which can simplify the operation rules and improve the efficiency of sequence processing.
[0087] In some embodiments, Figure 5 As shown, the step S102 of “shifting the binary window sequence to obtain a binary window shift sequence” may include step S401 and step S402. Figure 5 The steps shown are explained.
[0088] Step S401, when the binary window sequence is right-shifted, a binary first element is added to the left of the first element of the binary window sequence data to obtain a binary window shift sequence corresponding to the binary window sequence.
[0089] It can be understood that in computer language, the right shift of a binary sequence corresponds to a division operation, that is, shifting the binary sequence right by n bits is equivalent to dividing the binary sequence by 2. n By adding 0 or 1 to the first bit, operations can be performed at the binary level, avoiding the conversion from binary to decimal and then from decimal to binary, further improving the speed and efficiency of data processing.
[0090] In some embodiments, a method for adding a binary first element to the left of the first element of the binary window sequence data may include using a built-in function of Python to add 0 or 1 to the first position of the binary window sequence. Python is a computer program programming language, and the built-in function of Python includes an insert function, which can insert a value at a specified position in a list. Exemplarily, insert(0, element) is used to add an element parameter representing 0 or 1 to the 0th position (before the first position) of the sequence.
[0091] In some embodiments, the method of adding a binary first element to the left of the first element of the binary window sequence data may also include using an addition operator to add 0 or 1 to the first position of the binary window sequence. Exemplarily, an empty binary window shift sequence without any data is defined, and an element parameter used to represent 0 or 1 is first added to the binary window shift sequence, and then the binary sequence in the binary window sequence is added to the binary window shift sequence, thereby realizing the binary window shift sequence obtained after the binary window sequence is shifted right by one position.
[0092] Step S402, when the binary window sequence is shifted left, a binary last element is added to the right of the last element of the binary window sequence data to obtain a binary window shift sequence corresponding to the binary window sequence.
[0093] It is understandable that in computer language, the left shift of a binary sequence corresponds to a multiplication operation, that is, shifting the binary sequence left by n bits is equivalent to multiplying the binary sequence by 2. n By adding 0 or 1 to the last bit, operations can be performed at the binary level, avoiding the conversion from binary to decimal and then from decimal to binary, further improving the speed and efficiency of data processing.
[0094] In some embodiments, the method of adding a binary last element to the right of the last element of the binary window sequence data may include using Python's insert function to add 0 or 1 to the last position of the binary window sequence. Exemplarily, insert(n, element) is used to add an element parameter for representing 0 or 1 to the nth position (last position) of a sequence of length n.
[0095] In some embodiments, the method of adding a binary last element to the right of the last element of the binary window sequence data may further include using an addition operator to add 0 or 1 to the last bit of the binary window sequence.
[0096] In the embodiment of the present application, in the case of left shift and right shift, an element with a value of 0 or 1 is added to the first or last bit of the binary window sequence data, respectively, to obtain the shifted binary window sequence. In this way, the shift operation of the binary sequence is realized by adding data elements in the binary sequence. This method does not need to consider the complex characteristics of the sequence, thereby simplifying the design and implementation of the algorithm and improving the efficiency of sequence processing.
[0097] In some embodiments, Figure 6 As shown, in step S401, "when the binary window sequence is right-shifted, a binary first element is added to the left of the first element of the binary window sequence data to obtain a binary window shift sequence corresponding to the binary window sequence" may include steps S501 and S502. Figure 6 The steps shown are explained.
[0098] Step S501, when the first element of the binary window sequence is 0, add 1 to the left of the first element of the binary window sequence data to obtain a binary window shift sequence corresponding to the binary window sequence whose first element is 0.
[0099] It can be understood that a binary sequence contains only two elements, 0 and 1. When a run ends, the element representing the same bit position changes. Therefore, a 1 can be obtained through the XOR operation result. This 1 represents the start of the run. Therefore, when the first element of the sequence to be processed is 0, 1 is added to the left of the first element to obtain the shifted sequence to be processed, so as to ensure that the XOR result between the first element of the first run and the sequence to be processed obtained after the shift is 1, that is, the length of the first run is recorded in the XOR operation result.
[0100] Step S502: when the first element of the binary window sequence is 1, add 0 to the left of the first element of the binary window sequence to obtain a binary window shift sequence corresponding to the binary window sequence whose first element is 1.
[0101] In an embodiment of the present application, a numerical value different from the first element is added before the first element of the binary window sequence to obtain a shifted sequence to be processed, which can ensure that after the first element of the first run is XORed with the sequence to be processed obtained after the shift, the XOR result obtained is 1, which effectively avoids the situation where the first run is ignored, and at the same time ensures that the integrity of each element in the sequence is retained during the processing process.
[0102] In some embodiments, Figure 7As shown, in step S402, "when the binary window sequence is shifted to the left, a binary last element is added to the right of the last element of the binary window sequence data to obtain a binary window shift sequence corresponding to the binary window sequence" may include steps S601 and S602. Figure 7 The steps shown are explained.
[0103] Step S601, when the last element of the binary window sequence is 0, add 1 to the right of the last element of the binary window sequence data to obtain a first binary window shift sequence corresponding to the binary window sequence whose last element is 0.
[0104] Step S602: when the last element of the binary window sequence is 1, add 0 to the right of the last element of the binary window sequence to obtain a first binary window shift sequence corresponding to the binary window sequence whose last element is 1.
[0105] In the embodiment of the present application, the addition rule is based only on adding the last element of the binary window sequence, which makes the processing logic very simple and effectively improves the efficiency of sequence processing. At the same time, it ensures that the integrity of each element in the sequence is preserved during the processing.
[0106] In some embodiments, Figure 8 As shown, the step S103 of "performing an XOR operation on the binary window sequence and the corresponding binary window shift sequence to obtain a window XOR result corresponding to the binary window sequence" may include steps S701 and S702. Figure 8 The steps shown are explained.
[0107] Step S701 , when the binary window sequence is right-shifted, an XOR operation is performed on the Nth bit of the binary window sequence and the Nth bit of the corresponding first binary window shift sequence to obtain a first window XOR result of the binary window sequence.
[0108] Wherein, N is a natural number greater than 0 and less than or equal to a preset window length.
[0109] Exemplarily, when the binary window sequence "001100" is right shifted, the binary window shift sequence "1001100" is obtained, and the Nth bit of the binary window sequence is XORed with the Nth bit of the binary window shift sequence, and the first window XOR result of the binary window sequence is "1010101".
[0110] Step S702, when the binary window sequence is shifted left, an XOR operation is performed on the Nth bit of the binary window sequence and the N+1th bit of the corresponding first binary window shift sequence to obtain a first window XOR result of the binary window sequence.
[0111] Exemplarily, when the binary window sequence "001100" is left-shifted, a binary window shift sequence "0011001" is obtained, and the Nth bit of the binary window sequence is XORed with the N+1th bit of the binary window shift sequence, and the first window XOR result of the binary window sequence is "1010101".
[0112] In the embodiment of the present application, each bit of the binary window sequence is compared with each bit of the corresponding position in the first binary window shift sequence, and the bit-level elements are processed in a consistent and efficient manner, which simplifies the processing logic and improves the efficiency of sequence processing.
[0113] In some embodiments, Fig. 9 As shown, in step S401, "when the binary window sequence is right-shifted, a binary first element is added to the left of the first element of the binary window sequence data to obtain a binary window shift sequence corresponding to the binary window sequence" may also include steps S801 and S802. Fig. 9 The steps shown are explained.
[0114] Step S801, when the binary window sequence is right-shifted, a binary first element is added to the left of the first element of the binary window sequence data to obtain a binary window shift sequence corresponding to the binary window sequence, and a binary last element is added to the right of the last element of the binary window sequence to obtain a binary XOR window sequence corresponding to the binary window sequence.
[0115] In some embodiments, when the binary window sequence is right-shifted, a binary first element is added to the left of the first element of the binary window sequence data to obtain a binary window shift sequence corresponding to the binary window sequence, and a binary last element is added to the right of the last element of the binary window sequence to obtain a binary XOR window sequence corresponding to the binary window sequence, which may include: when the binary window sequence is right-shifted, 0 or 1 is added to the left of the first element of the binary window sequence data to obtain a binary window shift sequence corresponding to the binary window sequence, and 0 or 1 is added to the right of the last element of the binary window sequence to obtain a binary XOR window sequence corresponding to the binary window sequence.
[0116] Step S802, when the binary window sequence is shifted left, a binary last element is added to the right of the last element of the binary window sequence data to obtain a binary window shift sequence corresponding to the binary window sequence, and a binary first element is added to the left of the first element of the binary window sequence to obtain a binary XOR window sequence corresponding to the binary window sequence.
[0117] In some embodiments, when the binary window sequence is shifted left, a binary last element is added to the right of the last element of the binary window sequence data to obtain a binary window shift sequence corresponding to the binary window sequence, and a binary first element is added to the left of the first element of the binary window sequence to obtain a binary XOR window sequence corresponding to the binary window sequence, which may include: when the binary window sequence is shifted left, 0 or 1 is added to the right of the last element of the binary window sequence data to obtain a binary window shift sequence corresponding to the binary window sequence, and 0 or 1 is added to the left of the first element of the binary window sequence to obtain a binary XOR window sequence corresponding to the binary window sequence.
[0118] In the embodiment of the present application, in the case of left shift and right shift, different transformation operations are performed on the binary window sequence, that is, the element on the left side of the first element is added to obtain the binary window shift sequence, and the last element is added to obtain the binary XOR window sequence. In this way, the number of bits of the binary window shift sequence and the binary XOR window sequence is equal, avoiding the XOR operation error caused by the number of bits.
[0119] In some embodiments, Fig.10 As shown, the step S103 of "performing an XOR operation on the binary window sequence and the corresponding binary window shift sequence to obtain a window XOR result corresponding to the binary window sequence" may also include steps S901 and S902. Fig.10 The steps shown are explained.
[0120] Step S901, when the binary window sequence is right-shifted, an XOR operation is performed on the Mth bit of the binary window sequence and the Mth bit of the corresponding binary window shift sequence to obtain a second window XOR result of the binary window sequence.
[0121] Wherein, M is a natural number greater than 0 and less than or equal to the preset window length plus 1; the first element of the second window XOR result is 1 by default, and the last element of the second window XOR result is not a valid component of the second window XOR result.
[0122] Exemplarily, when the binary window sequence "001100" is shifted to the left, 0 or 1 can be added to the last bit of the binary window sequence to obtain a binary window shift sequence "0011001" or "0011000", and 0 or 1 can be added to the left side of the first element of the binary window sequence data to obtain a binary XOR window sequence "0001100" or "1001100". The binary window shift sequence and the binary XOR window sequence are XORed, and multiple window XOR results can be obtained according to the binary window shift sequence, such as XORing the binary window sequence "0011001" and the binary XOR window sequence "0001100", wherein the first bit of the XOR operation result is 1 by default, and the last bit element is not used as a valid element of the XOR operation, that is, the last bit of the XOR operation result is ignored, and the XOR operation result obtained is "101010".
[0123] Step S902, when the binary window sequence is left-shifted, an XOR operation is performed on the Mth bit of the binary window sequence and the Mth bit of the corresponding binary window shift sequence to obtain a second window XOR result of the binary window sequence.
[0124] In the embodiment of the present application, the first bit of the XOR operation result is set to 1 by default, and the last bit element is not used as a valid element of the XOR operation, which can ensure that the first bit of the first run is XORed with the sequence to be processed after the shift, and the XOR result obtained is 1, which effectively avoids the situation where the first run is ignored. In addition, since the last bit of the window XOR result is caused by padding the original sequence during the operation after the shift, it cannot be used to determine the number of runs in the current binary sequence. The last bit of the window XOR result is ignored, which ensures that the integrity of each element in the binary sequence is retained during the processing.
[0125] In some embodiments, Fig.11 As shown, the step S104 of "determining the evaluation result according to the number of 1s in the window XOR result and the preset annotation range" may include steps S1001 to S1004. Fig.11 The steps shown are explained.
[0126] Step S1001, counting the number of 1s in the XOR results of all windows.
[0127] It can be understood that the position of 1 in the window XOR result represents the first position of a run, and by counting the number of 1s in the window XOR result, the number of runs of the corresponding binary window sequence can be obtained.
[0128] In some embodiments, the method for counting the number of 1s in all window XOR results may include traversing the string. Exemplarily, traversing each character in the window XOR result to check whether it is equal to "1". If it is equal, the counter is incremented by one until all window XOR results are traversed.
[0129] In some embodiments, the method for counting the number of 1s in all window XOR results may also include using a count function in a programming language. The count function is used to count the number of values in a statistical data set. Exemplarily, the code count('1') is used to quickly count the number of 1s in all window XOR results.
[0130] Step S1002, determine the number of 1s in the XOR results of all windows as the total number of runs.
[0131] The total number of runs represents the sum of the number of 0 runs and 1 runs in the binary sequence.
[0132] It is understandable that after the binary sequence is split, the arrangement of the elements in the sequence is not changed. Therefore, by adding the run lengths of each subsequence, the number of runs in the original sequence can be obtained.
[0133] Step S1003, determining whether the total number of runs is within a preset marked range.
[0134] In some embodiments, the preset annotation range may represent a range of total runs of the binary sequence that is expected to be used.
[0135] In some embodiments, the preset annotation range may also represent the range of the total number of runs of each binary window sequence that is expected to be used.
[0136] Step S1004: When the total number of runs is within a preset marked range, the evaluation result is determined to be successful.
[0137] In some embodiments, when the total number of runs is not within a preset marked range, the evaluation result may be determined to be a failure.
[0138] For example, the preset standard range is (30±2), and the binary sequence Q is divided into binary window sequences Q 1 and Q 2 , and the binary window sequence Q 1 and Q 2 The total number of runs is 20 and 30 respectively. 1 and Q 2 By comparing the total number of runs with the preset standard range, it can be found that the binary sequence Q 1 If it is not within the preset annotation range and does not meet the user's expectations of randomness and regularity, the evaluation result is a failure.
[0139] In the embodiment of the present application, the total number of runs is determined by counting the number of 1s in the XOR results of all windows, and it is determined whether the total number of runs is within a preset marked range, and the evaluation result is determined according to the judgment result. In this way, the evaluation method is relatively simple to implement, and only needs to calculate the total number of runs and compare it with the preset range. It can be quickly and effectively applied in various application scenarios to improve the efficiency of sequence processing.
[0140] In some embodiments, Fig.12 As shown, the step "displaying evaluation results" may include step S1101 and step S1202. Fig.12 The steps shown are explained.
[0141] Step S1101: When the evaluation result is successful, display the evaluation result.
[0142] Step S1102: when the evaluation result is a failure, display the evaluation result, the first prompt information and / or the second prompt information.
[0143] The first prompt information represents information for prompting to re-enter the sequence to be processed; the second prompt information represents information for prompting to modify the preset marking range.
[0144] In some embodiments, the first prompt information includes an interface that can be directly called by the user for re-inputting the sequence to be processed.
[0145] In some embodiments, the second prompt information includes an interface that can be directly called by the user to prompt the user to modify the preset annotation range.
[0146] In the embodiment of the present application, when the evaluation result is successful, only the evaluation result is displayed to avoid unnecessary interference to the user and improve the user experience. When the evaluation result is a failure, not only the evaluation result is displayed, but also the first or second prompt information is provided according to the specific situation to help the user quickly understand the problem and know how to take the next step. This instant feedback and specific guidance can effectively improve the efficiency of problem solving.
[0147] The present application embodiment provides a sequence processing method architecture. Fig.13 As shown, the core components of the product interface 1200 for sequence processing in the embodiment of the present application may include a data input module 1201, a data evaluation module 1202, and a result feedback module 1203. Fig.13 The components shown illustrate the sequence processing method.
[0148] Fig.13The product interface 1200 shown can be regarded as an entrance for users to interact with the sequence processing product, and users can upload or input random binary sequence data through the product interface 1200.
[0149] In some embodiments, the data input module 1201 is responsible for receiving sequences to be processed uploaded by users or randomly input.
[0150] In some embodiments, the data form of the sequence to be processed uploaded by the user may include text messages, binary messages, etc. Exemplarily, the user may upload the sequence to be processed to the data input module 1201 by sending a binary message. After the sequence to be processed is uploaded in the user interface, it will be converted into the American Standard Code for Information Interchange (ASCII) code. After the data input module 1201 receives the ASCII code, the ASCII code is restored to the original sequence to be processed through a decoding algorithm. Among them, the ASCII code uses 7-bit binary numbers to represent all uppercase and lowercase letters, numbers 0 to 9, punctuation marks, and special control characters used in American English, a total of 128 characters. The user can also upload the sequence to be processed to the data input module 1201 by sending a binary message. Binary messages are different from text messages and do not need to be converted in format and are directly transmitted in binary form.
[0151] In some embodiments, the data input module 1201 may perform format verification and preprocessing on the sequence to be processed to ensure that the data meets the evaluation requirements.
[0152] In some embodiments, the data input module 1201 may perform format verification on the sequence to be processed by using ASCII code values. In programming languages, binary data is usually represented by ASCII encoding, and whether it is binary data can be determined by comparing the encoding method of the string. Exemplarily, each character in the string can be traversed to check whether its ASCII code value is in the range of 0-31 or greater than 126. If the ASCII code values of all characters meet this condition, the string is considered to be binary data; otherwise, it is not binary data.
[0153] The data evaluation module 1202 includes at least one pre-integrated shift XOR processing unit (shift XOR processing unit 12021 , optional shift XOR processing unit 12022 , etc.), a run analysis unit 12024 , and a result integration unit 12025 .
[0154] In some embodiments, the shift XOR processing unit 12021, the optional shift XOR processing unit 12022, and the optional shift XOR processing unit 12022 can be used to perform a shift operation on the sequence to be processed to obtain a shift sequence.
[0155] In some embodiments, after performing a shift operation on the sequence to be processed to obtain a shifted sequence, the shift XOR processing unit 12021 and the optional shift XOR processing unit 12022 may perform a bitwise XOR operation on the shifted sequence and the sequence to be processed.
[0156] In some embodiments, when the sequence data to be processed is too large, the sequence to be processed can be grouped to obtain multiple binary window sequences, and the shift and XOR operations are repeatedly performed until each binary window sequence is processed. Exemplarily, after the sequence to be processed is divided into three binary window sequences, the shift XOR processing unit 12021 performs shift and XOR operations on each binary window sequence until each binary window sequence is processed.
[0157] In some embodiments, when there are two different sequences to be processed, the two sequences to be processed can be respectively transmitted to the shift XOR processing unit 12021 and the optional shift XOR processing unit 12022 to implement the processing of the two sequences to be processed.
[0158] In some embodiments, after the shift XOR processing unit obtains the XOR operation result, the run analysis unit 12024 can calculate the number of 1s in the XOR operation result, and then infer the total number of runs and the run characteristics. Among them, the run characteristics can include the randomness and regularity of the run. Exemplarily, when the lengths of two groups of binary sequences are the same, the binary sequence with a total number of runs of 20 is more random than the binary sequence with a total number of runs of 10. When binary sequences of the same length are divided into the same group of binary window sequences, when the total number of runs of each group of binary window sequences is equal, it is more regular than the binary sequence with unequal total number of runs of each group of binary window sequences.
[0159] In some embodiments, the run characteristics can be inferred by determining whether the total number of runs is within a preset marked range. For example, when the total number of runs 20 of the binary sequence is less than the preset marked range 22, it can be inferred that the run characteristics do not meet the standard of randomness expected by the user.
[0160] In some embodiments, the result integration unit 12025 is used to output the evaluation results.
[0161] In some embodiments, the value of the evaluation result may be customized by the user. For example, the value of the evaluation result may include success and failure.
[0162] In some embodiments, the evaluation result may be changed by changing the preset annotation range.
[0163] The result feedback module 1203 includes a visualization display unit 12031 and a user interaction unit 12032 .
[0164] In some embodiments, the visualization display unit 12031 displays the evaluation results to the user in a visualized form. For example, an evaluation report or chart for indicating the number of runs or the total number of runs can be displayed in the product interface.
[0165] In some embodiments, the user interaction unit 12032 provides a user interaction interface so that the user can operate or adjust according to the evaluation result. For example, if the evaluation result is a failure, the product returns the interaction interface to the user, allowing the user to choose to regenerate the sequence to be processed, adjust the preset annotation range according to the failure result, or use the current sequence to be processed.
[0166] In the embodiment of the present application, shift and XOR operations are efficiently executed on a computer, and the algorithm for run counting is relatively simple, so the entire sequence processing process has high efficiency.
[0167] The present application embodiment provides another architecture of a sequence processing method. Fig.14 As shown, in the data path and data bypass deployed in the sequence to be processed in the embodiment of the present application, the core components may include a data input module 1201, a data output module 1301, a total number of runs detection module 1302, an optional total number of runs detection module 1303 and a result integration unit 12025. Fig.14 The components shown illustrate the sequence processing method.
[0168] In some embodiments, the data input module 1201 outputs the received sequence to be processed uploaded by the user or randomly input to the data input module 1301 through a data path. The data path is an important concept in the computer composition principle, which is used to define the path for data information to be transmitted between functional components.
[0169] In some embodiments, the total number of runs detection module 1302 and the optional total number of runs detection module 1303 are parallel in the data bypass, and are used to efficiently monitor the number of sequences (i.e., runs) of consecutive identical data elements in the sequence to be processed, which can significantly improve the speed and efficiency of data processing. Exemplarily, the data bypass is based on a parallel strategy, and the binary sequence is divided into multiple binary window sequences, and each binary window sequence is run-detected by an independent total number of runs detection module. The total number of runs detection modules work in parallel to obtain the run detection result.
[0170] In some embodiments, the result integration unit 12025 summarizes the run detection results obtained by the total run detection module to obtain the total number of runs.
[0171] In some embodiments, the result integration unit 12025 outputs the total number of runs.
[0172] In some embodiments, the result integration unit 12025 outputs the total number of runs including outputting the evaluation result and outputting prompt information. Exemplarily, the result integration unit 12025 compares the total number of runs with a preset marked range, and if the total number of runs is not within the preset marked range, the prompt information is fed back to the user interface through the data bypass.
[0173] In some embodiments, the way in which the result integration unit 12025 outputs the total number of runs can be customized by the user.
[0174] In some embodiments, the prompt information output by the result integration unit 12025 includes information for prompting to re-enter the sequence to be processed, information for prompting to modify the preset annotation range, and information for using the sequence to be processed.
[0175] In some embodiments, the result integration unit 12025 may output an interface for implementing the prompt information function. Exemplarily, the interface for calling the prompt information includes an interface for re-inputting the sequence to be processed, an interface for modifying the preset annotation range, and an interface for using the sequence to be processed.
[0176] In the embodiments of the present application, the architecture combining data path and data bypass is particularly important in the application scenarios of high-speed and large-scale data processing, and helps to achieve real-time and accurate data analysis and decision support. The combination mechanism of data path and data bypass is a hardware mechanism. During the execution of instructions, the execution results of the previous instructions can be "forwarded" as input to the arithmetic logic unit (Arithmetic Logic Unit, ALU) or other functional components of the subsequent instructions that rely on these results, without having to write the results to the register first and then read them from the register. This method can significantly improve the execution efficiency of the central processing unit (CPU) and reduce the time delay caused by waiting for data to be written and read from the register.
[0177] The present application embodiment provides an implementation flow of a sequence processing method, such as Fig.15 As shown, the sequence processing method of the present application may include steps S1401 to S1404. Fig.15 The steps shown are explained.
[0178] Step S1401, obtaining an input sequence to be processed.
[0179] In some embodiments, before obtaining an input sequence to be processed, a data source of the sequence to be processed may be determined.
[0180] In some embodiments, the data source of the sequence to be processed can be obtained by randomly generating a binary sequence.
[0181] Step S1402: pre-process the sequence to be processed to obtain a binary sequence.
[0182] Step S1403, shifting the binary sequence to obtain a binary shifted sequence, and performing an XOR operation on the binary one-bit sequence and the sequence to be processed to obtain an XOR operation result.
[0183] In some embodiments, shifting the binary sequence to obtain the binary shift sequence may include performing a left shift or a right shift operation on the binary sequence to obtain the binary shift sequence. For example, taking a right shift by one bit as an example, an n-bit binary shift sequence S' having the same length as the binary sequence S is obtained, and the process can be represented by S'=S>>1.
[0184] It can be understood that the XOR operation result is used as a new sequence that can reflect the run characteristics and is used to mark the boundaries of the runs in the original sequence. For example, the XOR operation result A can be obtained by performing a bitwise XOR operation on the binary shift sequence S' and the binary sequence S, and the process can be represented by A=S^(S>>1).
[0185] In some embodiments, the binary sequence may be divided into multiple binary window sequences according to a preset window length or format requirement, and the above shift and XOR operations need to be repeated until all binary window sequences are processed.
[0186] Step S1404: perform run analysis on the binary sequence based on the XOR operation result.
[0187] It can be understood that in a binary sequence, consecutive identical elements (0 or 1) constitute a run. For example, the sequence "01100" contains three runs: a 1 run "11" and two 0 runs "0" and "00". After obtaining the binary sequence XOR operation result A through shifting and XOR operation, each 1 in the XOR operation result A represents the beginning or end of a run.
[0188] In some embodiments, the first bit in the XOR result sequence A is 1 by default, which indicates the starting position of the first run. The last 1 in the XOR result sequence A is caused by the original sequence being padded with 0 during the post-shift operation, and cannot be used to determine the number of runs in the current binary sequence. Therefore, whether the last bit in A is 1 or 0, it should be ignored.
[0189] In some embodiments, the run information can be indirectly obtained by reading the number of 1s or the position information of 1s in the XOR operation result.
[0190] In some embodiments, indirectly obtaining information about the run by reading the number of 1s in the XOR operation result includes obtaining the total number of runs by reading the number of 1s in the XOR operation result.
[0191] In some embodiments, indirectly obtaining the information of the run by reading the position information of 1 in the XOR operation result includes obtaining the length distribution of the run, the interval between the runs and other characteristics by reading the position information of 1 in the XOR operation result, thereby more comprehensively evaluating the randomness and regularity of the sequence.
[0192] Illustratively, Table 1 is an embodiment of obtaining an XOR operation result between a binary sequence S and a binary sequence S′, wherein the binary sequence S′ is obtained by shifting the binary sequence S right by one bit, as shown in Table 1.
[0193] Table 1
[0194]
[0195] After performing a preprocessing operation on the input sequence to be processed, a binary sequence S is obtained, where S=11001101, and the length of S is n, where n=8. Obtaining the XOR operation result of S may include step 1 and step 2.
[0196] Step 1, shift operation.
[0197] Shift the sequence S one position to the right, and fill the first position with 0 (or 1, which does not affect the result). The resulting shifted sequence S'=011001101 has a length of n=9.
[0198] Step 2, XOR operation.
[0199] Calculate the XOR operation result A=S^S'=101010111, length n=9.
[0200] Step 3: Run analysis.
[0201] Analyze the XOR result sequence A, where the number of 1s is 5 (the last 1 is ignored), that is, the total number of runs of the binary sequence S is 5. Observe the position of 1 in sequence A, and you can see that the number of runs of the first 4 bits of the original sequence S is 2, and the number of runs of the last 4 bits of the original sequence is 3. In this example, the amount of data is small, so the run characteristics reflected by the run distribution are not obvious. In the sequence analysis of large amounts of data, the run distribution differences of sequences at different stages can be obtained through the run distribution, and the distribution differences of randomness can be simply obtained.
[0202] Illustratively, Table 2 is an embodiment of obtaining an XOR operation result between a binary sequence S and a binary sequence T', wherein the binary sequence T' is obtained by shifting the binary sequence S left by one bit, as shown in Table 2.
[0203] Table 2
[0204]
[0205] After performing a preprocessing operation on the input sequence to be processed, a binary sequence S is obtained, where S=11001101, and the length of S is n, where n=8. Obtaining the XOR operation result of S may include step 1 and step 2.
[0206] Step 1, shift operation.
[0207] Shift the sequence S one position to the right, and fill the first position with 0 (or 1, which does not affect the result). The resulting shifted sequence S'=011001101 has a length of n=9.
[0208] Step 2, XOR operation.
[0209] Calculate the XOR operation result A=S^S'=101010111, length n=9.
[0210] Step 3: Run analysis.
[0211] Analyze the XOR result sequence T, where the number of 1s is 5 (the last 1 is ignored), that is, the total number of runs of the binary sequence T is 5. Observe the position of 1 in sequence A, and you can see that the number of runs of the first 4 bits of the original sequence T is 2, and the number of runs of the last 4 bits of the original sequence is 3. In this example, the amount of data is small, so the run characteristics reflected by the run distribution are not obvious. In the sequence analysis of large amounts of data, the run distribution differences of sequences at different stages can be obtained through the run distribution, and the distribution differences of randomness can be simply obtained.
[0212] In some embodiments, the present application proposes an underlying logic scheme based on shift and XOR operation. By adjusting the number of bits of data shift and the rules of XOR operation, it is possible to accurately detect and count runs of different lengths and characteristics. In some specific scenarios, the total number of runs of the sequence can be calculated by XORing adjacent bits of the sequence and then outputting the number of 1s in the result sequence. However, the scheme of the present application provides more flexibility and higher efficiency.
[0213] In some embodiments, the application of the results of this application on the product side can be a data evaluation tool or module integrated into the product. This sequence processing and analysis tool or module is intended to help users verify the run characteristics of their data sources or generated binary sequences, and ensure the safety and reliability of the product when using these sequences.
[0214] In some embodiments, the application solutions of the results of this application on the product side can also be used to quickly calculate the total number of runs in products that need to efficiently process and detect binary random sequence data streams, improve the efficiency and accuracy of data quality assessment, and provide strong support for various application scenarios that need to verify run characteristics.
[0215] In the embodiment of the present application, a method for calculating the total number of runs of a sequence is used by shifting and XORing the data and calculating the number of 1s in the shifted result. The core idea of this calculation method is to mark the end position of the run in the sequence through a series of bit operations (mainly shifting and XORing operations), and then count the number of these marks to obtain the total number of runs. This method can be used to process binary sequences or data that can be converted into binary sequences, because each bit in the binary sequence is either 0 or 1, which is convenient for processing through bit operations. This method is based on the following technical principles: 1) Shift: Shift the original sequence to the right (or left) by one bit to form a new sequence. 2) XOR: Perform a bitwise XOR operation on the original sequence and the shifted sequence. The characteristic of the XOR operation is that the two values are the same as 0, and the different values are 1. 3) Count the number of 1s in the XOR result sequence: In the XOR result sequence, the beginning and end of each run will generate a 1 in the XOR result because it is different from the adjacent elements. Therefore, there is a direct correlation between the number of 1s in the XOR result and the total number of runs.
[0216] In the embodiment of the present application, a data sample integration and analysis method is proposed. The total number of runs contained in the binary sequence and the distribution of runs in the sequence are detected by the method of "shifting and XORing the elements" on the sample sequence, and whether the number of consecutive occurrences of the same element in the sequence (i.e., the run) meets the expectations of the data distribution characteristics can be further evaluated. The core idea of the method is to mark the end position of the run in the sequence through a series of bit operations (mainly shifting and XOR operations), and then count the number of these marks to obtain the total number of runs. Specifically, it includes: 1) Shifting and XORing the sequence to be detected so that the end position (or starting position, depending on the specific implementation) of each run will generate a 1 in the result due to different adjacent elements. 2) Counting the number of 1s in the XOR result is the total number of runs in the sequence to be detected. 3) Observing the position of 1 in the result reflects the distribution of runs in the sequence to be detected. 4) The present application can be deployed in parallel in the data path bypass, processing multiple parts of the data stream at the same time, and improving the analysis and processing efficiency.
[0217] In the embodiment of the present application, compared with the sequence processing method in the prior art, the improvements include: 1) detection efficiency. Data shift (such as right shift or left shift) and XOR (XOR) operations are basic and efficient operations in computers. These operations can be performed quickly at the hardware level, so using them to detect the total number of runs can significantly improve the processing speed. Modern computer architectures have highly optimized bit operations, and these operations can usually be completed within a single CPU cycle. Therefore, using bit operations such as shift and XOR can more effectively utilize hardware resources and improve computing speed. In addition, through one or a few shift and XOR operations, multiple elements can be processed at one time, reducing the number of direct traversals and comparisons of each element in the sequence. 2) Detection accuracy. The total number of runs for binary sequences is essentially a bit-level operation, and data shift and XOR operations just meet this requirement. They can accurately operate and judge each bit of the data without changing the overall structure of the original data. And because these operations are all based on binary bits, errors caused by errors in data representation or processing can be minimized. 3) Parallelism potential. Since bit operations are performed in parallel at the hardware level, this method can naturally take advantage of the parallel processing capabilities of modern processors. This parallelism can significantly improve computational efficiency when processing large-scale data. The method can also be further parallelized, such as using multithreading or multiprocessors to process different parts of the sequence simultaneously. 4) Simplicity. The code used to implement the method of the present application is relatively compact and easy to understand, and the number of lines of code is usually small, and the logic is intuitive and clear. 5) Higher flexibility. Data shifting and XOR operations are not only suitable for run detection of random numbers, but can also be widely used in other scenarios that require bit-level operations. This makes these data processing techniques highly flexible in the field of data processing and analysis. In addition, by adjusting the number of bits of data shifting and the rules of XOR operations, accurate detection and statistics of runs of different lengths and characteristics can be achieved.
[0218] The advantages of adopting the technical solution provided by the embodiment of the present application are: 1) Shift and XOR operations can be efficiently performed on a computer, so the entire evaluation process has a high efficiency. It is particularly efficient when processing large data sets because it avoids explicit sequence traversal and counting. 2) Through a concise data processing process, the present application can not only count the total number of runs in the sequence to be tested, but also obtain the distribution of runs in the sequence to be tested, providing options for further processing data and analyzing run characteristics. 3) The processing process of the sequence adopts bit-level operations, and the use of shifts and XOR does not change the overall structure of the data, which can minimize errors caused by errors in data representation or processing, and accurately operate and judge each bit of the data. 4) The code implementation may be relatively concise, and the logic of the algorithm becomes very clear, so the design is highly readable and maintainable. 5) Since bit operations are inherently parallel (at the hardware level), this method may make it easier to utilize the parallel processing capabilities of modern processors. Especially when processing large-scale data, this parallelism can significantly improve computing efficiency. At the same time, it can be displayed in parallel with the data path during deployment, and multiple threads can be used to process different parts of the sequence simultaneously. 6) When processing binary sequences or data that can be converted into binary sequences, the method of calculating the total number of runs of the sequence by shifting and XORing the data and counting the number of 1s in the shifted result is a concise, efficient and accurate method based on bit operations.
[0219] The present application embodiment provides a schematic diagram of the composition structure of a sequence processing device, such as Fig.16 As shown, the sequence processing device 1500 includes: a first acquisition module 1501, a shift module 1502, a first XOR operation module 1503, and a first determination module 1504, wherein: the first acquisition module 1501 is used to obtain a binary window sequence to be processed; wherein the binary window sequence is a binary sequence; the shift module 1502 is used to shift the binary window sequence to obtain a binary window shift sequence; the first XOR operation module 1503 is used to perform an XOR operation on the binary window sequence and the corresponding binary window shift sequence to obtain a window XOR result corresponding to the binary window sequence; wherein the window XOR result is a binary sequence; the first determination module 1504 is used to determine an evaluation result according to the number of 1s in the window XOR result and a preset annotation range; wherein the evaluation result is used to characterize whether the binary window sequence meets the requirements.
[0220] In other embodiments, the sequence processing device 1500 further includes: a first display module, configured to display the evaluation result.
[0221] In some embodiments, the sequence processing device 1500 also includes: a second acquisition module, used to acquire a sequence to be processed; wherein the sequence to be processed is a sequence composed of multiple data elements of the same type; a first judgment module, used to judge whether the data elements in the sequence to be processed are represented in binary form; a second judgment module, used to determine the sequence to be processed as a binary sequence to be processed when it is judged that the data elements in the sequence to be processed are represented in binary form; a preprocessing module, used to preprocess the sequence to be processed to obtain a binary sequence to be processed when it is determined that the data elements in the sequence to be processed are not represented in binary form; a division module, used to divide the binary sequence into multiple binary window sequences according to a preset window length.
[0222] In some embodiments, the sequence processing device 1500 also includes: a division module, used to divide multiple binary window sequences into multiple groups of binary window sequences according to a preset number of division groups; an allocation module, used to allocate each group of binary window sequences to a parallel total run detection module; wherein the total run detection module is used to process binary window sequences in parallel.
[0223] In some embodiments, the preprocessing module includes: a third determination module, which is used to query the preset conversion rules based on the data type information of the sequence to be processed, and determine the conversion method corresponding to the sequence to be processed; wherein the data type information represents the data type of the data element in the sequence to be processed; the preset conversion rules are used to represent the conversion relationship between the data elements corresponding to the data type and the binary sequence; the conversion module is used to adopt the conversion method corresponding to the sequence to be processed to convert each data element in the sequence to be processed into a binary sequence to obtain a binary sequence.
[0224] In some embodiments, the shift module 1502 includes: a first adding module, which is used to add a binary first element to the left of the first element of the binary window sequence data when the binary window sequence is right-shifted, so as to obtain a binary window shift sequence corresponding to the binary window sequence; and a second adding module, which is used to add a binary last element to the right of the last element of the binary window sequence data when the binary window sequence is left-shifted, so as to obtain a binary window shift sequence corresponding to the binary window sequence.
[0225] In some embodiments, the first adding module includes: a third adding module, which is used to add 1 to the left of the first element of the binary window sequence data when the first element of the binary window sequence is 0, so as to obtain the first binary window shift sequence corresponding to the binary window sequence whose first element is 0; and a fourth adding module, which is used to add 0 to the left of the first element of the binary window sequence element when the first element of the binary window sequence is 1, so as to obtain the first binary window shift sequence corresponding to the binary window sequence whose first element is 1.
[0226] In some embodiments, the second adding module includes: a fifth adding module, which is used to add 1 to the right of the last element of the binary window sequence data when the last element of the binary window sequence is 0, so as to obtain the first binary window shift sequence corresponding to the binary window sequence whose last element is 0; and a sixth adding module, which is used to add 0 to the right of the last element of the binary window sequence element when the last element of the binary window sequence is 1, so as to obtain the first binary window shift sequence corresponding to the binary window sequence whose last element is 1.
[0227] In some embodiments, the first XOR operation module 1503 includes: a second XOR operation module, which is used to perform an XOR operation on the Nth bit of the binary window sequence and the Nth bit of the corresponding first binary window shift sequence when the binary window sequence is right-shifted to obtain a window XOR result of the binary window sequence; wherein N is a natural number greater than 0 and less than or equal to a preset window length; and a third XOR operation module, which is used to perform an XOR operation on the Nth bit of the binary window sequence and the N+1th bit of the corresponding first binary window shift sequence when the binary window sequence is left-shifted to obtain a window XOR result of the binary window sequence.
[0228] In some embodiments, the second adding module also includes: a seventh adding module, which is used to add a binary first element to the left of the first element of the binary window sequence data when the binary window sequence is right-shifted, so as to obtain a binary window shift sequence corresponding to the binary window sequence, and add a binary last element to the right of the last element of the binary window sequence to obtain a binary XOR window sequence corresponding to the binary window sequence; an eighth adding module, which is used to add a binary last element to the right of the last element of the binary window sequence data when the binary window sequence is left-shifted, so as to obtain a binary window shift sequence corresponding to the binary window sequence, and add a binary first element to the left of the first element of the binary window sequence to obtain a binary XOR window sequence corresponding to the binary window sequence.
[0229] In some embodiments, the seventh adding module includes: a ninth adding module, which is used to add 0 or 1 to the left side of the first element of the binary window sequence data when the binary window sequence is right shifted to obtain a binary window shift sequence corresponding to the binary window sequence, and add 0 or 1 to the right side of the last element of the binary window sequence to obtain a binary XOR window sequence corresponding to the binary window sequence.
[0230] In some embodiments, the eighth adding module includes: a tenth adding module, which is used to add 0 or 1 to the right side of the first element of the binary window sequence data when the binary window sequence is left-shifted to obtain a binary window shift sequence corresponding to the binary window sequence, and add 0 or 1 to the left side of the first element of the binary window sequence to obtain a binary XOR window sequence corresponding to the binary window sequence.
[0231] In some embodiments, the first XOR operation module 1503 also includes: a fourth XOR operation module, which, when the binary window sequence is right-shifted, performs an XOR operation on the Mth bit of the binary window sequence and the Mth bit of the corresponding binary window shift sequence to obtain a second window XOR result of the binary window sequence; and a fifth XOR operation module, which, when the binary window sequence is left-shifted, performs an XOR operation on the Mth bit of the binary window sequence and the Mth bit of the corresponding binary window shift sequence to obtain a second window XOR result of the binary window sequence.
[0232] In some embodiments, the first determination module 1504 includes: a statistical module, used to count the number of 1s in all window XOR results; a fourth determination module, used to determine the number of 1s in all window XOR results as the total number of runs; wherein the total number of runs represents the sum of the number of 0 runs and the number of 1 runs in the binary sequence; a third judgment module, used to judge whether the total number of runs is within a preset marking range; wherein the preset marking range represents the range of the total number of runs of the binary sequence expected to be used; and a fifth determination module, used to determine that the evaluation result is successful when the total number of runs is within the preset marking range.
[0233] The description of the above device embodiment is similar to the description of the above method embodiment, and has similar beneficial effects as the method embodiment. In some embodiments, the functions or modules included in the device provided by the embodiments of the present disclosure can be used to execute the method described in the above method embodiment. For technical details not disclosed in the device embodiment of the present application, please refer to the description of the method embodiment of the present application for understanding.
[0234] The embodiment of the present application provides a computer-readable storage medium on which a computer program is stored, and when the computer program is executed by a processor, some or all of the steps in the above method are implemented. The computer-readable storage medium can be transient or non-transient.
[0235] An embodiment of the present application provides a computer program, including a computer-readable code. When the computer-readable code is run in a computer device, a processor in the computer device executes some or all of the steps for implementing the above method.
[0236] The embodiment of the present application provides a computer program product, which includes a non-transitory computer-readable storage medium storing a computer program, and when the computer program is read and executed by a computer, some or all of the steps in the above method are implemented. The computer program product can be implemented in hardware, software, or a combination thereof. In some embodiments, the computer program product is specifically embodied as a computer storage medium, and in other embodiments, the computer program product is specifically embodied as a software product, such as a software development kit (SDK), etc.
[0237] The present application embodiment provides a hardware entity of a sequence processing device, such as Fig.17 As shown, the hardware entity of the sequence processing device 1600 includes: a processor 1601, a communication interface 1602 and a memory 1603, wherein: the processor 1601 generally controls the overall operation of the sequence processing device 1600, and the overall operation can be to implement the sequence processing method provided in the embodiment of the present application. The communication interface 1602 can enable the sequence processing device 1600 to communicate with other terminals or servers through a network. The memory 1603 is configured to store instructions and applications executable by the processor 1601, and can also cache data to be processed or processed by each module in the processor 1601 and the sequence processing device 1600 (for example, image data, audio data, voice communication data and video communication data), which can be implemented by flash memory (FLASH) or random access memory (Random Access Memory, RAM). Data transmission can be carried out between the processor 1601, the communication interface 1602 and the memory 1603 through the bus 1604.
[0238] It should be understood that "one embodiment" or "an embodiment" mentioned throughout the specification means that specific features, structures or characteristics related to the embodiment are included in at least one embodiment of the present application. Therefore, "in one embodiment" or "in an embodiment" appearing throughout the specification does not necessarily refer to the same embodiment. In addition, these specific features, structures or characteristics can be combined in one or more embodiments in any suitable manner. It should be understood that in various embodiments of the present application, the size of the serial number of each step / process mentioned above does not mean the order of execution, and the execution order of each step / process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiment of the present application. The serial numbers of the embodiments of the present application mentioned above are for description only and do not represent the advantages and disadvantages of the embodiments.
[0239] It should be noted that, in this article, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the existence of other identical elements in the process, method, article or device including the element.
[0240] The above is only an implementation method of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application.
Claims
1. A sequence processing method, characterized in that: The method comprises: Acquire a binary window sequence to be processed; wherein the binary window sequence is a binary sequence; Shifting the binary window sequence to obtain a binary window shifted sequence; Performing an XOR operation on the binary window sequence and the corresponding binary window shift sequence to obtain a window XOR result corresponding to the binary window sequence; wherein the window XOR result is a binary sequence; Determine an evaluation result according to the number of 1s in the window XOR result and a preset annotation range; wherein the evaluation result is used to characterize whether the binary window sequence meets the requirements; The step of determining the evaluation result according to the number of 1s in the window XOR result and a preset marking range includes: Count the number of 1s in all XOR results of the window; Determine the number of 1s in all the window XOR results as the total number of runs; wherein the total number of runs represents the sum of the number of 0 runs and 1 runs in all the binary window sequences; When the total number of runs is within the preset marked range, the evaluation result is determined to be successful.
2. The method according to claim 1, characterized in that Before obtaining the binary window sequence to be processed, the method includes: Obtaining a sequence to be processed; wherein the sequence to be processed is a sequence composed of multiple data elements of the same type; In the case where the data elements in the sequence to be processed are represented in binary form, determining the sequence to be processed as the binary sequence to be processed; In the case where the data elements in the sequence to be processed are not represented in binary form, preprocessing the sequence to be processed to obtain the binary sequence to be processed; The binary sequence is divided into a plurality of binary window sequences according to a preset window length.
3. The method according to claim 2, characterized in that After dividing the binary sequence into a plurality of binary window sequences according to a preset window length, the method comprises: Dividing the plurality of binary window sequences into a plurality of groups of binary window sequences according to a preset number of division groups; Each group of the binary window sequences is allocated to a parallel total run length detection module; wherein the total run length detection module is used for processing the binary window sequences in parallel.
4. The method according to claim 2, characterized in that The preprocessing of the sequence to be processed to obtain the binary sequence to be processed includes: Based on the data type information of the sequence to be processed, a preset conversion rule is queried to determine a conversion method corresponding to the sequence to be processed; wherein the data type information represents the data type of the data element in the sequence to be processed; and the preset conversion rule is used to represent the conversion relationship between the data element corresponding to the data type and the binary sequence; The conversion method corresponding to the sequence to be processed is adopted to convert each of the data elements in the sequence to be processed into a binary sequence to obtain the binary sequence.
5. The method according to claim 2, characterized in that: The step of shifting the binary window sequence to obtain a binary window shift sequence includes: When the binary window sequence is right-shifted, a binary first element is added to the left of the first element of the binary window sequence to obtain a binary window shift sequence corresponding to the binary window sequence; In the case of left shifting the binary window sequence, a binary last element is added to the right of the last element of the binary window sequence to obtain a binary window shift sequence corresponding to the binary window sequence.
6. The method according to claim 5, characterized in that In the case of right shifting the binary window sequence, adding a binary first element to the left of the first element of the binary window sequence to obtain a binary window shift sequence corresponding to the binary window sequence, including: when the first element of the binary window sequence is 0, adding 1 to the left of the first element of the binary window sequence to obtain a first binary window shift sequence corresponding to the binary window sequence whose first element is 0; when the first element of the binary window sequence is 1, adding 0 to the left of the first element of the binary window sequence to obtain a first binary window shift sequence corresponding to the binary window sequence whose first element is 1; In the case of left shifting the binary window sequence, a binary last element is added to the right of the last element of the binary window sequence to obtain a binary window shift sequence corresponding to the binary window sequence, including: when the last element of the binary window sequence is 0, 1 is added to the right of the last element of the binary window sequence to obtain a first binary window shift sequence corresponding to the binary window sequence whose last element is 0; when the last element of the binary window sequence is 1, 0 is added to the right of the last element of the binary window sequence to obtain a first binary window shift sequence corresponding to the binary window sequence whose last element is 1.
7. The method according to claim 6, characterized in that The performing an XOR operation on the binary window sequence and the corresponding binary window shift sequence to obtain a window XOR result corresponding to the binary window sequence includes: When the binary window sequence is right-shifted, an XOR operation is performed on the Nth bit of the binary window sequence and the Nth bit of the corresponding first binary window shift sequence to obtain a first window XOR result of the binary window sequence; wherein N is a natural number greater than 0 and less than or equal to the preset window length; When the binary window sequence is shifted left, an XOR operation is performed on the Nth bit of the binary window sequence and the N+1th bit of the corresponding first binary window shift sequence to obtain a first window XOR result of the binary window sequence.
8. The method according to claim 5, characterized in that The method further comprises: when the binary window sequence is right-shifted, adding the binary first element to the left of the first element of the binary window sequence to obtain a binary window shift sequence corresponding to the binary window sequence, and adding the binary last element to the right of the last element of the binary window sequence to obtain a binary XOR window sequence corresponding to the binary window sequence; The method further comprises: when the binary window sequence is shifted left, adding the binary last element to the right of the last element of the binary window sequence to obtain a binary window shift sequence corresponding to the binary window sequence, and adding the binary first element to the left of the first element of the binary window sequence to obtain a binary XOR window sequence corresponding to the binary window sequence.
9. The method according to claim 8, characterized in that The performing an XOR operation on the binary window sequence and the corresponding binary window shift sequence to obtain a window XOR result corresponding to the binary window sequence further includes: In the case of right shifting the binary window sequence, an XOR operation is performed on the Mth bit of the binary window sequence and the Mth bit of the corresponding binary window shift sequence to obtain a second window XOR result of the binary window sequence; wherein M is a natural number greater than 0 and less than or equal to the preset window length plus 1; the first element of the second window XOR result is 1 by default, and the last element of the second window XOR result is not used as a valid component of the second window XOR result; When the binary window sequence is shifted left, an XOR operation is performed on the Mth bit of the binary window sequence and the Mth bit of the corresponding binary window shift sequence to obtain a second window XOR result of the binary window sequence.
10. A sequence processing device, characterized in that: The sequence processing device is applied to a safety bus, and the sequence processing device comprises: A first acquisition module is used to acquire a binary window sequence to be processed; wherein the binary window sequence is a binary sequence; A shift module, used for shifting the binary window sequence to obtain a binary window shift sequence; A first XOR operation module is used to perform an XOR operation on the binary window sequence and the corresponding binary window shift sequence to obtain a window XOR result corresponding to the binary window sequence; wherein the window XOR result is a binary sequence; A first determination module is used to determine an evaluation result according to the number of 1s in the window XOR result and a preset annotation range; wherein the evaluation result is used to indicate whether the binary window sequence meets the requirements; The first determination module is also used to count the number of 1s in all the window XOR results; determine the number of 1s in all the window XOR results as the total number of runs; wherein the total number of runs represents the sum of the number of 0 runs and 1 runs in all the binary window sequences; and determine that the evaluation result is successful when the total number of runs is within the preset marking range.
11. A sequence processing device, characterized in that: include: A memory for storing executable instructions; A processor, configured to implement the method according to any one of claims 1 to 9 when executing the executable instructions stored in the memory.
12. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores executable instructions, which, when executed by a processor, implement the method according to any one of claims 1 to 9.
Citation Information
Patent Citations
Random number verification method and device, storage medium and electronic equipment
CN117093983A