Instrument digital wheel automatic initialization system and method based on RFID tag
By using an RFID tag-based automatic initialization system for meter digital wheels, multi-dimensional data is collected and analyzed in real time. The LightGBM model is used for anomaly prediction, which solves the problem of anomaly detection during the initialization process of meter digital wheels, ensuring the stability of the system and the accuracy of readings, and realizing efficient automated meter reading.
Patent Information
- Application Number
- CN202511713848.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-21
- Publication Date
- 2026-02-17
AI Technical Summary
Existing automated meter reading systems fail to effectively handle abnormal situations during the initialization of the meter's digital wheel, which may lead to reading errors and system failures, making it difficult to meet the demand for high-efficiency meter reading.
An automatic initialization system for instrument digital wheels based on RFID tags is adopted. Multidimensional data is collected in real time through a cloud server, a LightGBM model is built and optimized, a coding anomaly prediction model is trained, the initialization process is monitored in real time and the operation is paused when an anomaly is detected. Combined with high-precision sensors and data encryption storage technology, data security and the accuracy of anomaly prediction are ensured.
It enables real-time anomaly detection and early warning during the initialization process of the instrument's digital wheel, improving the system's stability and reliability, avoiding reading errors and system failures, and enhancing the accuracy and efficiency of automated meter reading.
Smart Images

Figure CN121543613A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to an automatic initialization system and method for instrument digital wheels based on RFID tags, belonging to the field of digital processing technology. Background Technology
[0002] Traditionally, meter readings are primarily acquired manually. Manual meter reading is not only inefficient, consuming significant manpower and time, but also prone to human error and recording mistakes, making it difficult to meet the demands of large-scale, high-efficiency meter reading. While some attempts at automated meter reading have emerged with technological advancements, most still have shortcomings.
[0003] A Chinese patent application with publication number CN108052943A discloses a method and device for recognizing the dial wheel of an instrument. The method includes: acquiring the original dial image of the instrument; initializing and positioning the original dial image according to the dial wheel template; setting the image initialization parameters of the instrument; acquiring the current dial image of the instrument; obtaining a target image according to the image initialization parameters; performing binarization processing on the target image to obtain a binarized image; cropping the dial wheel image from the binarized image according to the initialization parameters to obtain the optimal matching position of each dial wheel on the dial wheel image; and recognizing the dial wheel digits at each optimal matching position using a recognition algorithm.
[0004] While existing technologies reduce the amount of uploaded meter images, automatically identify the digit wheel numbers and upload readings, achieving automated meter reading, saving manpower, and improving work efficiency, they do not consider potential anomalies during the automatic initialization of the meter digit wheel, nor their prediction and response mechanisms. During automatic initialization of the meter digit wheel, anomalies may occur due to various factors such as initialization time, meter operating status parameters, initial position of the digit wheel, historical initialization records, and surrounding environmental data. Therefore, this application provides an automatic initialization system and method for meter digit wheels based on RFID tags. Summary of the Invention
[0005] To address the shortcomings of existing technologies, the present invention aims to provide an automatic initialization system and method for instrument digital wheels based on RFID tags. This system collects multi-dimensional data in real time, builds and optimizes the LightGBM model, trains a code writing anomaly prediction model, acquires real-time data to predict anomalies during the automatic initialization of the instrument digital wheels, and pauses the automatic initialization operation of the instrument digital wheels once an anomaly is detected.
[0006] To achieve the above objectives, the present invention provides the following technical solution:
[0007] An automatic initialization system for instrument digital wheels based on RFID tags includes: a cloud server and a prediction module;
[0008] The cloud server is used to collect multi-dimensional data related to the automatic initialization of the instrument digital wheel in real time, generate an initial write code dataset containing various types of write code information, and encrypt and store the data.
[0009] The prediction module is used to preprocess the initial write-code dataset, build and optimize the LightGBM model; train a write-code anomaly prediction model based on the training dataset, acquire real-time multidimensional data during the automatic initialization of the instrument digital wheel, determine whether an anomaly will occur during the automatic initialization of the instrument digital wheel, and pause the automatic initialization operation of the instrument digital wheel once an anomaly is detected.
[0010] Furthermore, the specific steps for preprocessing the initial write-code dataset include:
[0011] The initial write-code dataset is preprocessed to generate a write-code matrix. , The number of samples in the code matrix. This represents the number of factors influencing the writing of codes in the writing matrix.
[0012] Calculate the write code matrix The covariance and variance are calculated, and a correlation coefficient matrix is generated. ;
[0013] Solve the correlation coefficient matrix The eigenvalues are used to calculate the contribution rate. and cumulative contribution rate ;
[0014] Select the first sorted 3 eigenvectors, forming an eigenvector matrix And generate principal component matrix .
[0015] Furthermore, the specific steps to optimize the LightGBM model include:
[0016] Build a LightGBM model and set the initial value range of the parameters to be optimized based on the dimension and features of the principal component matrix;
[0017] Iterative generation using Tent chaotic mapping Given a sequence of chaotic variables, map the sequence of chaotic variables to a parameter range to generate an initial population. ;in, The first in the initial population Individual;
[0018] For individuals Cross-validation was used to calculate the performance of the LightGBM model on the training dataset. average accuracy and will Defined as an individual fitness value The training dataset includes the principal component matrix and the corresponding label vector.
[0019] Compare the fitness values of all individuals to find the optimal individual. and suboptimal individuals ;
[0020] Calculate individuals Hunger rate And update the individual's location.
[0021] Furthermore, the specific steps for optimizing the LightGBM model also include:
[0022] Calculate dynamic threshold Optimize the suboptimal individuals; if The second-best individual is the one with the second-highest fitness value; if The second-best individual is the one with the third-best fitness score.
[0023] Calculate the optimal individual Inverse solution If the reverse solution Out of parameter range Then, the parameter range will be randomly reset. Otherwise, do not change. ;in, For individuals, For individuals, the lower limit;
[0024] Calculate the inverse solution fitness value and with the optimal individual fitness value Compare;
[0025] like Then let ;like Then let ;in, The updated optimal individual;
[0026] Determine if the current iteration count has reached the maximum iteration count. If it has, output the updated optimal individual. If the corresponding model parameters have not reached the maximum number of iterations, repeat the above steps.
[0027] Furthermore, the specific steps to determine whether there will be any abnormalities in the automatic initialization of the instrument's digital wheel include:
[0028] Using the optimized LightGBM model and on the training dataset The model is trained on the code writing anomaly prediction model to obtain the final model.
[0029] During the automatic initialization of the instrument's digital wheel, relevant real-time multidimensional data is collected and processed to generate real-time write code data. ;
[0030] Based on the output of the code writing anomaly prediction model, it is determined whether an anomaly will occur during the automatic initialization of the instrument digital wheel. Once an anomaly is detected, the automatic initialization operation of the instrument digital wheel is paused.
[0031] Furthermore, the specific steps for encrypted storage include:
[0032] Read the binary data sequence and preprocess it;
[0033] Based on data type and channel conditions, selection rules are defined, and candidate parity matrices are selected from the known set of parity-check matrices. In this process, a verification matrix is selected according to the selection rules. And calculate the generator matrix. ;in, For the candidate set of the verification matrix A test matrix, The number of test matrices in the candidate set of the verification matrix. For preprocessed data bits, The length of the encoded sequence;
[0034] Preprocessed data As information bits, and in conjunction with the generated matrix Perform matrix multiplication to obtain the encoded sequence. ;
[0035] In a finite field The S-box is constructed through a series of pre-defined mathematical operations, including affine transformation, multiplicative inverse, and addition.
[0036] The constructed S-boxes are screened based on multiple performance indicators. The performance indicator values of each S-box are compared with the predetermined performance indicator standards, and the S-boxes that meet all performance indicator standards are retained.
[0037] Random sequences are generated based on the Logistic chaotic system. The corresponding parameter array is retrieved from the stored parameter array through linear mapping, and the corresponding S-box is calculated, including affine transformation, multiplicative inverse, and addition operation.
[0038] Encoded sequence The plaintext input to the AES encryption algorithm is used to obfuscate and spread the plaintext using a selected dynamic S-box, ultimately yielding the encrypted ciphertext. .
[0039] Furthermore, it also includes: a control module and a communication module;
[0040] The control module is used to automatically initialize the instrument digital wheel according to the instructions of the prediction module;
[0041] The communication module is used to realize data transmission and communication with the cloud server, prediction module and control module using wireless communication technology.
[0042] An automatic initialization method for instrument digital wheels based on RFID tags, comprising:
[0043] Real-time acquisition of multi-dimensional data related to the automatic initialization of the instrument's digital wheel generates an initial write code dataset;
[0044] Preprocess the initial coding dataset, build and optimize the LightGBM model;
[0045] A code writing anomaly prediction model was trained; and during the automatic initialization of the instrument digital wheel, real-time multidimensional data was acquired to determine whether anomalies would occur during the automatic initialization of the instrument digital wheel.
[0046] The instrument's digital wheel is automatically initialized, and the data is stored in encrypted form.
[0047] Furthermore, the specific steps to optimize the LightGBM model include:
[0048] Build a LightGBM model and set the initial value range of the parameters to be optimized based on the dimension and features of the principal component matrix;
[0049] Iterative generation using Tent chaotic mapping Given a sequence of chaotic variables, map the sequence of chaotic variables to a parameter range to generate an initial population. ;in, The first in the initial population Individual;
[0050] For individuals Cross-validation was used to calculate the performance of the LightGBM model on the training dataset. average accuracy and will Defined as an individual fitness value The training dataset includes principal component matrices and corresponding label vectors.
[0051] Compare the fitness values of all individuals to find the optimal individual. and suboptimal individuals ;
[0052] Calculate individuals Hunger rate And update the individual's location.
[0053] Furthermore, the specific steps for optimizing the LightGBM model also include:
[0054] Calculate dynamic threshold Optimize the suboptimal individuals; if The second-best individual is the one with the second-highest fitness value; if The second-best individual is the one with the third-best fitness score.
[0055] Calculate the optimal individual Inverse solution If the reverse solution Out of parameter range Then, the parameter range will be randomly reset. Otherwise, do not change. ;
[0056] Calculate the inverse solution fitness value and with the optimal individual fitness value Comparison; among them, For individuals, For individuals, the lower limit;
[0057] like Then let ;like Then let ;in, The updated optimal individual;
[0058] Determine if the current iteration count has reached the maximum iteration count. If it has, output the updated optimal individual. If the corresponding model parameters have not reached the maximum number of iterations, repeat the above steps.
[0059] The beneficial effects of this invention are:
[0060] Real-time capture of multidimensional data using high-precision sensors and data acquisition cards ensures comprehensiveness and timeliness of information, while encrypted data storage enhances data security. Combining PCA dimensionality reduction with the LightGBM model effectively mines data features and improves anomaly prediction accuracy. Furthermore, the use of chaotic mapping and elite reverse learning strategies enhances the model's global search capability, avoids local optima, and makes predictions more reliable. Real-time data monitoring and anomaly early warning mechanisms can quickly identify and respond to potential problems during initialization, preventing malfunctions and ensuring the stable operation of the instrument's digital wheel. Attached Figure Description
[0061] Figure 1 This is a structural diagram of an automatic initialization system for an instrument digital wheel based on RFID tags.
[0062] Figure 2 A flowchart for preprocessing the initial write-code dataset;
[0063] Figure 3 Flowchart for optimizing the LightGBM model;
[0064] Figure 4 A flowchart for encrypted storage;
[0065] Figure 5 This is a flowchart of an automatic initialization method for the digital wheel of an instrument based on RFID tags. Detailed Implementation
[0066] The technical solution of the present invention will be described in detail below with reference to the accompanying drawings and specific embodiments. It should be understood that the embodiments of the present invention and the specific features in the embodiments are detailed descriptions of the technical solution of the present invention, rather than limitations thereof. In the absence of conflict, the embodiments of the present invention and the technical features in the embodiments can be combined with each other.
[0067] Example 1
[0068] refer to Figures 1 to 4 As shown in the figure, this embodiment introduces an automatic initialization system for instrument digital wheels based on RFID tags, including: a cloud server, a prediction module, a control module, and a communication module;
[0069] The cloud server utilizes the high-precision sensors and stable data acquisition card configured within the instrument's digital wheel to collect multi-dimensional data related to the automatic initialization of the instrument's digital wheel in real time. This includes initialization time, the instrument's digital wheel's operating status parameters during initialization (such as voltage, current, and temperature), the initial position information of the instrument's digital wheel, historical initialization records (successful or failed cases), and surrounding environmental data (such as ambient temperature, humidity, and electromagnetic interference intensity). The multi-dimensional data is then arranged in chronological order to generate an initial coding dataset containing various coding information. Each data record is accompanied by a timestamp for easy subsequent chronological processing and analysis. The server also receives and saves the prediction results from the prediction module, while simultaneously encrypting and storing the data.
[0070] The prediction module is used to preprocess the initial write-code dataset, such as obtaining the principal component matrix through PCA dimensionality reduction, building and optimizing the LightGBM model, generating the initial population using chaotic mapping, combining the principal component matrix and label vectors to generate the training dataset, selecting the best and second-best individuals, updating the position according to the hunger rate, dynamically selecting the second-best individuals, adopting an elite back-learning strategy to escape local optima, initializing the LightGBM model with optimal parameters, and training to obtain the write-code anomaly prediction model; and during the automatic initialization of the instrument digital wheel, real-time multidimensional data is acquired, and after PCA dimensionality reduction, it is determined whether the automatic initialization of the instrument digital wheel will cause anomalies, and the corresponding mechanism is triggered according to the prediction results. Once an anomaly is detected, the automatic initialization operation of the instrument digital wheel is paused.
[0071] The control module is used to perform a series of operations to automatically initialize the instrument digital wheel according to the instructions of the prediction module;
[0072] The communication module is used to realize data transmission and communication with the cloud server, prediction module and control module using wireless communication technology, so as to ensure the real-time and accuracy of information.
[0073] Furthermore, the control module includes a smart wheel loading and unloading unit, a coding unit, a verification unit, and a laser coding unit;
[0074] The intelligent wheel loading and unloading unit is used to classify and arrange uninitialized instrument digital wheels by ones, tens, hundreds, and thousands and transport them to the gripping position. According to the preset coordinate program, the four-axis robotic arm is controlled to accurately grip the instrument digital wheels and place them on the stepper motor driven rotary table. After laser marking is completed, the four-axis robotic arm is controlled to remove the instrument digital wheels that have completed data initialization and laser marking from the rotary table and place them into the corresponding guide slots for assembly. Then, the new instrument digital wheels to be written are gripped.
[0075] The coding unit is used to retrieve order data from the cloud server and uses multi-threading technology to group 40 RFID data into groups and send them to 4 high-precision RFID readers. As the digital wheel of the instrument rotates, the readers code the RFID tags on the digital wheel of the instrument from 0 to 9 in sequence.
[0076] The verification unit is activated after the coding is completed. The card reader reads the tag data again and compares it with the preset correct data. If the verification fails, the verification is paused and the staff is notified. If the verification passes, all RFID tags on the instrument's digital wheel are locked at once. The data of successful locking is uploaded to the cloud server through blockchain technology.
[0077] The laser marking unit is used to start after locking is completed, and sends marking instructions to the laser marking machine through the RS232 serial port to mark the ones, tens, hundreds and thousands place marks on the instrument digital wheel respectively.
[0078] Furthermore, the specific steps for preprocessing the initial write-code dataset include:
[0079] Obtain the initial write-code dataset stored on the cloud server, preprocess the initial write-code dataset, and generate the write-code matrix. , The number of samples in the code matrix. This represents the number of factors influencing the writing of the code in the writing matrix. Preprocessing includes: removing outliers and missing values, data standardization, using the Laida criterion to identify outliers, calculating the mean and standard deviation of the data, and discarding data points that deviate from the mean by more than three times the standard deviation. For missing values, if the data volume is sufficient, records containing missing values are directly deleted; if the data volume is small, the mean is used for imputation. Z-score standardization is used to eliminate the influence of different feature data magnitudes and units.
[0080] Calculate the write code matrix The covariance and variance are calculated, and a write code matrix is generated. Correlation coefficient matrix The expression is as follows:
[0081]
[0082] In the formula, , , For writing the code matrix The Middle The and the first The correlation coefficients between various factors influencing coding. , These are the code-writing matrices. The Middle The, the Factors affecting coding, For writing the code matrix The Middle The and the first Covariance among factors influencing coding , These are the code-writing matrices. The Middle The, the The variance of each factor influencing coding;
[0083] Solve the correlation coefficient matrix The eigenvalues are obtained by arranging them in descending order. The corresponding feature vectors are respectively , ... Calculate the contribution rate based on the eigenvalues and cumulative contribution rate The expression is as follows:
[0084]
[0085]
[0086] In the formula, , For the first 1 eigenvalue, For the first The eigenvectors corresponding to each eigenvalue. For the first Contribution rate corresponding to each feature value For the front Cumulative contribution rate of each feature value;
[0087] Principal components with eigenvalues greater than or close to 1 and a cumulative contribution rate of over 80% are selected as new features. The number of principal components is then [number missing]. Select the first sorted order 3 eigenvectors, forming an eigenvector matrix And generate principal component matrix The principal component matrix was obtained after PCA dimensionality reduction, which retained most of the important information of the original data while reducing the impact of data dimensionality and multicollinearity.
[0088] Furthermore, the specific steps to optimize the LightGBM model include:
[0089] In a Python environment, a LightGBM model is built using relevant deep learning libraries. The LightGBM model uses the principal component matrix as input features for subsequent training, and the dimensionality information of the principal component matrix is used as parameters for the model's input layer. In this case, the dimension of the LightGBM model's input layer is set to [value missing]. The LightGBM model is initialized, and the initial range of values for the parameters to be optimized is set according to the dimension and features of the principal component matrix, such as the maximum growth depth of the tree, the learning rate, the number of trees, the minimum loss function decrease value, the sum of the weights of all samples of the minimum child node, and the total number of leaves.
[0090] Iterative generation using Tent chaotic mapping Given a sequence of chaotic variables, map the sequence of chaotic variables to a parameter range to generate an initial population. To increase initial individual diversity; the expression is as follows:
[0091]
[0092]
[0093] In the formula, To determine the initial number of vulture individuals, for each initial vulture individual (corresponding to a set of parameters to be optimized), the corresponding value needs to be obtained from the chaotic variable sequence. This value is then calculated and mapped to the parameter range to determine the individual's parameters. Therefore, the number of chaotic variable sequences is consistent with the number of initial vulture individuals. The first in the initial population The individual, and the first The individuals contain the first A set of parameter combinations to be optimized. , For the first The chaotic variable values of the next iteration. initial value Random selection Within the interval, in this embodiment, we take , For the control parameters of the chaotic mapping, in this embodiment, we take... , For the model One parameter to be optimized. , Parameters The lower and upper limits;
[0094] Principal component matrix Combined with the corresponding label vectors, a training dataset is generated. For each individual The LightGBM model is constructed using the corresponding combination of parameters to be optimized. Cross-validation is used to compute the model on the training dataset. average accuracy and as an individual fitness value The fitness value is used to select the best and second-best individuals in the subsequent selection;
[0095] Compare the fitness values of all individuals and select the individual with the highest fitness value as the optimal individual. The individual with the second-highest fitness value is selected as the suboptimal individual. The best and second-best individuals will be the targets of the vulture swarm's search, guiding other individuals to evolve in a better direction;
[0096] Calculate individuals Hunger rate The hunger rate determines whether a vulture individual will engage in global exploration or local exploitation in subsequent steps, and its position is updated based on the hunger rate. The updated position will continue to be used for fitness evaluation and position updates in subsequent iterations; the expression is as follows:
[0097]
[0098]
[0099] In the formula, As an intermediate variable, This represents the current iteration number. The maximum number of iterations, , , The parameter is random, and , , By introducing random parameters, the randomness and diversity of the algorithm are increased, preventing the algorithm from getting trapped in local optima too early. To use fixed parameters, this embodiment takes... ;
[0100] Calculate dynamic threshold Optimize the suboptimal individuals; if The second-best individual is the one with the second-highest fitness value; if The second-best individual is the one with the third-highest fitness value. Dynamically selecting the second-best individual balances the algorithm's global exploration and local exploitation capabilities. The expression is shown below:
[0101]
[0102] In the formula, For the optimal individual fitness value, The average fitness value of the population, and ;
[0103] Calculate the optimal individual using an elite reverse learning strategy. Inverse solution If the reverse solution Out of parameter range Then, the parameter range will be randomly reset. Otherwise, do not change. The expression is as follows:
[0104]
[0105] In the formula, For individuals, For individuals, the lower limit The parameters are random and follow a normal distribution. ;
[0106] Calculate the inverse solution fitness value and with the optimal individual fitness value Comparisons are made to escape local optima and improve the algorithm's global search capability; if , indicating the inverse solution There is no better individual than the current best individual Better, the current best individual It is still the optimal solution. Keeping the current optimal individual unchanged, let ;like , indicating the inverse solution A better, closer solution to the global optimum, update the current best individual to the reverse solution, and let ;in, The updated optimal individual;
[0107] Determine if the current iteration count has reached the maximum iteration count. If the maximum number of iterations is reached, output the updated optimal individual. The corresponding model parameters are used as the optimal model parameters to construct the final write anomaly prediction model. If the maximum number of iterations is not reached, repeat the above steps.
[0108] Furthermore, the specific steps to determine whether there will be any abnormalities in the automatic initialization of the instrument's digital wheel include:
[0109] Initialize the LightGBM model with optimal model parameters and on the training dataset. The model is trained on the code writing anomaly prediction model to obtain the final model.
[0110] During the automatic initialization of the instrument's digital wheel, relevant real-time multidimensional data is collected and processed according to the steps of preprocessing the initial code writing dataset to generate real-time code writing data. ;
[0111] Based on the output of the write-code anomaly prediction model, it is determined whether an anomaly will occur during the automatic initialization of the instrument digital wheel. Once an anomaly is detected, the automatic initialization operation of the instrument digital wheel is paused to prevent the error from escalating further and to trigger the corresponding anomaly handling mechanism.
[0112] Furthermore, the specific steps for updating an individual's location include:
[0113] when At this time, the vulture enters the exploration phase, allowing individuals to search the potential solution space over a larger area in order to find a better region; when At that time, the optimal individual is selected through a roulette wheel strategy. and suboptimal individuals Choose one as the target individual and update the individual location to ;when At that time, to avoid the algorithm getting trapped in local optima too early, individual Perform a random search and update the individual's location. The expression for position update is as follows:
[0114]
[0115]
[0116] In the formula, , Each is an updated individual Location, , , , , For random parameters, To calculate the optimal individual for the target individual selected using the roulette wheel strategy. Selection probability Generate a Random numbers between ,like Then let ,like Then let ;
[0117] when At that time, the first part of the development phase begins; when ,individual A slow encirclement strategy is implemented, allowing individuals to approach the target individual based on their distance and hunger rate, conducting a local search, and updating their positions accordingly. ;when ,individual The system employs a rotational flight strategy, leveraging the periodicity and randomness of trigonometric functions to conduct more complex local searches near the target individual. This increases the diversity of the search, avoids getting trapped in local optima, and updates the individual's position accordingly. The expression is as follows:
[0118]
[0119]
[0120] In the formula, , , for Random numbers within the interval To increase search flexibility, , Used to introduce randomness, , By utilizing the periodicity and volatility of trigonometric functions, individuals can generate complex movement trajectories near the target individual, thereby achieving diversified local searches.
[0121] when At that time, we entered the second part of the development phase; when The individual combines information from the best and second-best individuals to perform a more refined local search and updates the individual's position. ;when Individuals employ a highly competitive strategy, occasionally escaping local optima through the Lévy flight function to conduct a broader search, thus avoiding the algorithm from getting trapped in local optima and updating the individual's position accordingly. The expression is as follows:
[0122]
[0123]
[0124]
[0125]
[0126]
[0127] In the formula, , These are the first and second intermediate variables used to calculate the individual's new location, respectively. This is the Lévy flight function, used to implement long-distance jump search. and It is a random variable that follows a normal distribution, introducing randomness into the Lévy flight. To control the parameters of Lévy's flight step size distribution, and In this embodiment, we take , It is a constant. This is the gamma function, used to calculate the value of the Lévy flight function.
[0128] Furthermore, the specific steps for encrypted storage include:
[0129] Read the binary data sequence that needs to be processed and encrypted from the data source, and perform preprocessing such as data padding and format conversion to ensure that the data length meets the requirements of subsequent LDPC encoding, and set the preprocessed data... Length is Bit;
[0130] Selection rules are defined based on data type (e.g., text, image, audio) and channel conditions (e.g., noise level, bit error rate), and candidate sets of parity-check matrices are selected. In the process, the check matrix is selected according to the defined selection rules. The generator matrix is calculated using the encoding principle of LDPC codes. , The length of the encoded sequence, and ;in, For the candidate set of the verification matrix A test matrix, This represents the number of test matrices in the candidate set of the verification matrix;
[0131] Preprocessed data As information bits, and in relation to the generator matrix Perform matrix multiplication to obtain the encoded sequence. ,in, The length is Bit;
[0132] In a finite field The S-box is constructed through a series of specific mathematical operations: first, an affine transformation is performed; then, the multiplicative inverse is calculated; and finally, addition is performed to obtain the nonlinear transformation expression of the S-box. Simultaneously, to ensure the reversibility of the encryption algorithm, the inverse S-box is calculated. The expression is shown below:
[0133]
[0134]
[0135] +
[0136]
[0137]
[0138] In the formula, The result of the affine transformation, For a finite field The elements in the array represent the input values of the affine transformation. Let be the coefficient polynomial of the affine transformation. The result of multiplication inverse. The result of the addition operation. For another finite field The elements in Output the S-box value. The coefficient matrix related to the affine transformation. The input values for the S-box are finite fields. The elements in For a finite field Constant elements in;
[0139] The constructed S-boxes are screened based on multiple performance indicators to ensure that they have good cryptographic properties. These performance indicators include affine transformation period, iterative output period, strict avalanche criterion distance (SACD), nonlinearity, and differential uniformity. The performance indicator values of each S-box are compared with the predetermined performance indicator standards, and the S-boxes that simultaneously meet all performance indicator standards are retained.
[0140] Random sequences are generated based on a Logistic chaotic system. The corresponding parameter array is retrieved from the stored parameter array through a linear mapping, and the corresponding S-box is calculated, including affine transformation, multiplicative inverse, and addition operations. This ensures that the server and client use the same dynamic S-box for encryption operations; the expression is shown below:
[0141]
[0142] In the formula, For the first Chaos value in the next iteration For the first The chaotic value of the next iteration, and , For branch parameters, This represents the number of iterations.
[0143] Using the AES-128 algorithm, the encoded sequence The plaintext input to the AES encryption algorithm is used to obfuscate and spread the plaintext using a selected dynamic S-box, ultimately yielding the encrypted ciphertext. .
[0144] Example 2
[0145] Please see Figure 5 Another embodiment of the present invention provides: an automatic initialization method for an instrument digital wheel based on RFID tags, comprising the following steps:
[0146] Real-time acquisition of multidimensional data related to the automatic initialization of the instrument digital wheel; arranging the acquired multidimensional data in chronological order to generate an initial write code dataset containing various types of write code information.
[0147] The initial coding dataset is preprocessed, such as by PCA dimensionality reduction to obtain the principal component matrix; the LightGBM model is built and optimized, the initial population is generated by using chaotic mapping, the principal component matrix and label vector are combined to generate the training dataset, the best and second-best individuals are selected, the position is updated according to the hunger rate, the second-best individuals are dynamically selected, and an elite back-learning strategy is adopted to escape local optima.
[0148] The LightGBM model is initialized with optimal parameters and trained to obtain a write-code anomaly prediction model. During the automatic initialization of the instrument digital wheel, real-time multidimensional data is acquired, and after PCA dimensionality reduction, it is input into the write-code anomaly prediction model to determine whether anomalies will occur during the automatic initialization of the instrument digital wheel.
[0149] A series of operations are performed to automatically initialize the instrument's digital wheel and to encrypt and store the data.
[0150] Furthermore, the specific steps for preprocessing the initial write-code dataset include:
[0151] The initial write code dataset is preprocessed to generate a write code matrix. , The number of samples in the code matrix. This represents the number of factors influencing the writing of codes in the writing matrix.
[0152] Calculate the write code matrix The covariance and variance are calculated, and a correlation coefficient matrix is generated. ;
[0153] Solve the correlation coefficient matrix The eigenvalues are used to calculate the contribution rate. and cumulative contribution rate ;
[0154] Select the first sorted 3 eigenvectors, forming an eigenvector matrix And generate principal component matrix .
[0155] Furthermore, the specific steps to optimize the LightGBM model include:
[0156] Build a LightGBM model and set the initial value range of the parameters to be optimized based on the dimension and features of the principal component matrix;
[0157] Iterative generation using Tent chaotic mapping Given a sequence of chaotic variables, map the sequence of chaotic variables to a parameter range to generate an initial population. ;in, The first in the initial population Individual;
[0158] For individuals Cross-validation was used to calculate the performance of the LightGBM model on the training dataset. average accuracy and will Defined as an individual fitness value ;
[0159] Compare the fitness values of all individuals to find the optimal individual. and suboptimal individuals ;
[0160] Calculate individuals Hunger rate and update individual locations;
[0161] Calculate dynamic threshold Optimize the suboptimal individuals; if The second-best individual is the one with the second-highest fitness value; if The second-best individual is the one with the third-best fitness score.
[0162] Calculate the optimal individual Inverse solution If the reverse solution Out of parameter range Then, the parameter range will be randomly reset. Otherwise, do not change. ;in, For individuals, For individuals, the lower limit;
[0163] Calculate the inverse solution fitness value and with the optimal individual fitness value Compare;
[0164] like Then let ;like Then let ;
[0165] Determine if the current iteration count has reached the maximum iteration count. If it has, output the updated optimal individual. If the corresponding model parameters have not reached the maximum number of iterations, repeat the above steps.
[0166] In summary, this invention uses high-precision sensors and data acquisition cards to collect multidimensional data in real time and arranges it chronologically to generate an initial write-code dataset. The dataset is then subjected to PCA dimensionality reduction to construct and optimize the LightGBM model. This includes generating an initial population using chaotic mapping, forming a training set by combining principal component matrices and label vectors, and training a write-code anomaly prediction model using strategies such as elite back-learning. During the automatic initialization of the instrument's digital wheel, data is collected in real time, reduced to PCA dimensionality, and then input into the write-code anomaly prediction model to predict anomalies. Once an anomaly prediction is detected, the initialization operation is immediately paused. Simultaneously, the data is encrypted during system operation.
[0167] The above description is merely a preferred embodiment of the present invention. The scope of protection of the present invention is not limited to the above embodiments. All technical solutions falling within the scope of the present invention's concept are within the scope of protection of the present invention. It should be noted that for those skilled in the art, any improvements and modifications made without departing from the principles of the present invention should also be considered within the scope of protection of the present invention.
Claims
1. An automatic initialization system for instrument digital wheels based on RFID tags, characterized in that, include: Cloud servers and prediction modules; The cloud server is used to collect multi-dimensional data related to the automatic initialization of the instrument digital wheel in real time, generate an initial write code dataset containing various types of write code information, and encrypt and store the data. The prediction module is used to preprocess the initial write-code dataset, build and optimize the LightGBM model; train a write-code anomaly prediction model based on the training dataset, acquire real-time multidimensional data during the automatic initialization of the instrument digital wheel, determine whether an anomaly will occur during the automatic initialization of the instrument digital wheel, and pause the automatic initialization operation of the instrument digital wheel once an anomaly is detected.
2. The automatic initialization system for instrument digital wheels based on RFID tags according to claim 1, characterized in that, The specific steps for preprocessing the initial write-code dataset include: The initial write-code dataset is preprocessed to generate a write-code matrix. , The number of samples in the code matrix. This represents the number of factors influencing the writing of codes in the writing matrix. Calculate the write code matrix The covariance and variance are calculated, and a correlation coefficient matrix is generated. ; Solve the correlation coefficient matrix The eigenvalues are used to calculate the contribution rate. and cumulative contribution rate ; Select the first sorted 3 eigenvectors, forming an eigenvector matrix And generate principal component matrix .
3. The automatic initialization system for instrument digital wheels based on RFID tags according to claim 2, characterized in that, The specific steps to optimize the LightGBM model include: Build a LightGBM model and set the initial value range of the parameters to be optimized based on the dimension and features of the principal component matrix; Iterative generation using Tent chaotic mapping Given a sequence of chaotic variables, map the sequence of chaotic variables to a parameter range to generate an initial population. ;in, The first in the initial population Individual; For individuals Cross-validation was used to calculate the performance of the LightGBM model on the training dataset. average accuracy and will Defined as an individual fitness value The training dataset includes the principal component matrix and the corresponding label vector. Compare the fitness values of all individuals to find the optimal individual. and suboptimal individuals ; Calculate individuals Hunger rate And update the individual's location.
4. The automatic initialization system for instrument digital wheels based on RFID tags according to claim 3, characterized in that, The specific steps for optimizing the LightGBM model also include: Calculate dynamic threshold Optimize the suboptimal individuals; if The second-best individual is the one with the second-highest fitness value; if The second-best individual is the one with the third-best fitness score. Calculate the optimal individual Inverse solution If the reverse solution Out of parameter range Then, the parameter range will be randomly reset. Otherwise, do not change. ;in, For individuals, For individuals, the lower limit; Calculate the inverse solution fitness value and with the optimal individual fitness value Compare; like Then let ;like Then let ;in, The updated optimal individual; Determine if the current iteration count has reached the maximum iteration count. If it has, output the updated optimal individual. If the corresponding model parameters have not reached the maximum number of iterations, repeat the above steps.
5. The automatic initialization system for instrument digital wheels based on RFID tags according to claim 4, characterized in that, The specific steps to determine whether there will be any abnormalities in the automatic initialization of the instrument digital wheel include: Using the optimized LightGBM model and on the training dataset The model is trained on the code writing anomaly prediction model to obtain the final model. During the automatic initialization of the instrument's digital wheel, relevant real-time multidimensional data is collected and processed to generate real-time write code data. ; Based on the output of the code writing anomaly prediction model, it is determined whether an anomaly will occur during the automatic initialization of the instrument digital wheel. Once an anomaly is detected, the automatic initialization operation of the instrument digital wheel is paused.
6. The automatic initialization system for instrument digital wheels based on RFID tags according to claim 5, characterized in that, The specific steps for encrypted storage include: Read the binary data sequence and preprocess it; Based on data type and channel conditions, selection rules are defined, and candidate parity matrices are selected from the known set of parity-check matrices. In this process, a verification matrix is selected according to the selection rules. And calculate the generator matrix. ;in, For the candidate set of the verification matrix A test matrix, The number of test matrices in the candidate set of the verification matrix. For preprocessed data bits, The length of the encoded sequence; Preprocessed data As information bits, and in conjunction with the generated matrix Perform matrix multiplication to obtain the encoded sequence. ; In a finite field The S-box is constructed through a series of pre-defined mathematical operations, including affine transformation, multiplicative inverse, and addition. The constructed S-boxes are screened based on multiple performance indicators. The performance indicator values of each S-box are compared with the predetermined performance indicator standards, and the S-boxes that meet all performance indicator standards are retained. Random sequences are generated based on the Logistic chaotic system. The corresponding parameter array is retrieved from the stored parameter array through linear mapping, and the corresponding S-box is calculated, including affine transformation, multiplicative inverse, and addition operation. Encoded sequence The plaintext input to the AES encryption algorithm is used to obfuscate and spread the plaintext using a selected dynamic S-box, ultimately yielding the encrypted ciphertext. .
7. The automatic initialization system for instrument digital wheels based on RFID tags according to claim 6, characterized in that, Also includes: Control module and communication module; The control module is used to automatically initialize the instrument digital wheel according to the instructions of the prediction module; The communication module is used to realize data transmission and communication with the cloud server, prediction module and control module using wireless communication technology.
8. An automatic initialization method for an instrument digital wheel based on RFID tags, implemented based on an automatic initialization system for an instrument digital wheel based on RFID tags as described in any one of claims 1-7, characterized in that, include: Real-time acquisition of multi-dimensional data related to the automatic initialization of the instrument's digital wheel generates an initial write code dataset; Preprocess the initial coding dataset, build and optimize the LightGBM model; A code writing anomaly prediction model was trained; and during the automatic initialization of the instrument digital wheel, real-time multidimensional data was acquired to determine whether anomalies would occur during the automatic initialization of the instrument digital wheel. The instrument's digital wheel is automatically initialized, and the data is stored in encrypted form.
9. The automatic initialization method for an instrument digital wheel based on an RFID tag according to claim 8, characterized in that, The specific steps to optimize the LightGBM model include: Build a LightGBM model and set the initial value range of the parameters to be optimized based on the dimension and features of the principal component matrix; Iterative generation using Tent chaotic mapping Given a sequence of chaotic variables, map the sequence of chaotic variables to a parameter range to generate an initial population. ;in, The first in the initial population Individual; For individuals Cross-validation was used to calculate the performance of the LightGBM model on the training dataset. average accuracy and will Defined as an individual fitness value The training dataset includes principal component matrices and corresponding label vectors. Compare the fitness values of all individuals to find the optimal individual. and suboptimal individuals ; Calculate individuals Hunger rate And update the individual's location.
10. The automatic initialization method for an instrument digital wheel based on an RFID tag according to claim 9, characterized in that, The specific steps for optimizing the LightGBM model also include: Calculate dynamic threshold Optimize the suboptimal individuals; if The second-best individual is the one with the second-highest fitness value; if The second-best individual is the one with the third-best fitness score. Calculate the optimal individual Inverse solution If the reverse solution Out of parameter range Then, the parameter range will be randomly reset. Otherwise, do not change. ;in, For individuals, For individuals, the lower limit; Calculate the inverse solution fitness value and with the optimal individual fitness value Compare; like Then let ;like Then let ;in, The updated optimal individual; Determine if the current iteration count has reached the maximum iteration count. If it has, output the updated optimal individual. If the corresponding model parameters have not reached the maximum number of iterations, repeat the above steps.
Citation Information
Patent Citations
Method and device for recognizing instrument character wheel
CN108052943A