Point switch gap state detection method, system, equipment and medium

Through the multi-model integration strategy integrating BiLSTM, Dense model and random forest algorithm, intelligent classification detection of the gap state of the switch machine is solved, and the problem of difficulty in accurately distinguishing between static and vehicle-passing states in the existing technology under large noise or interference is significantly improved, and the accuracy and stability of the detection are significantly improved.

CN119830226APending Publication Date: 2025-04-15TAIYUAN JINGFENG RAILWAY EQUIP MANUFCTURING CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202510306793.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-15
Publication Date
2025-04-15

AI Technical Summary

Technical Problem

The prior art is difficult to accurately distinguish the static state of the switch machine from the vehicle-passing state under large signal noise or external interference, resulting in insufficient reliability of the detection results.

Method used

The bidirectional long and short-term memory network (BiLSTM) and fully connected network (Dense) model combined with a multi-model integration strategy of random forest algorithm is used to intelligently classify and detect the gap state data of the switch machine. Vibration spectrum characteristics are extracted through Fourier transform, statistical characteristics of gap quantity are calculated, and a joint feature vector set is constructed to perform classification prediction.

Benefits of technology

It significantly improves the accuracy and stability of the classification of gap state of the switch machine, enhances the fault tolerance and adaptability of the system, ensures the real-time and accuracy of the detection results, and provides strong technical support for the safe operation of railway transportation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119830226A_ABST
    Figure CN119830226A_ABST
Patent Text Reader

Abstract

The invention relates to a point switch gap state detection method, system and device and a medium, and the detection method comprises the steps: receiving gap state data of a to-be-detected point switch, and storing the gap state data as time sequence data; performing data preprocessing on the time sequence data to obtain a feature data set; performing feature extraction according to the feature data set to obtain a feature vector set; respectively inputting the feature vector set into a pre-constructed bidirectional long-short-term memory network model and a full-connection network structure model to obtain a first classification prediction result and a second classification prediction result; based on a random forest algorithm, performing weighted voting on the first classification prediction result and the second classification prediction result to obtain a gap state classification result of the to-be-detected switch machine; wherein the gap state classification result comprises a converted state, a static state and a vehicle passing state. The accuracy and the stability of a detection result can be ensured.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of switch gap state detection, and in particular to a switch gap state detection method, system, equipment and medium. Background Art

[0002] The switch machine is one of the key equipment in the railway system. Its main function is to realize the reliable conversion of railway turnouts and ensure that trains run according to the scheduled route. As an important guarantee for railway transportation safety, the switch machine needs to monitor its operating status in real time to avoid driving safety accidents caused by equipment failure. The operating status of the switch machine is mainly judged by monitoring its gap status, and the accurate judgment of the gap status is crucial to the safety and operation efficiency of railway transportation.

[0003] At present, the gap states of switch machines include post-conversion state, static state and passing state. Among them, the characteristic differences between the static state and the passing state are relatively weak, especially in the case of large signal noise or external interference, it is difficult for traditional methods to accurately distinguish the two, resulting in insufficient reliability of the detection results. Secondly, complex operating environments, such as train vibrations, weather changes or fluctuations in sensor performance, may cause the detection results to be affected by external interference, resulting in missed or misjudgment, reducing the accuracy and stability of the detection. Summary of the invention

[0004] In order to ensure the accuracy and stability of the detection results, the present application provides a switch machine gap status detection method, system, equipment and medium.

[0005] In the first aspect, the present application provides a method for detecting a notch state of a switch machine, which adopts the following technical solution: A method for detecting a switch machine notch state, the method comprising: Receiving the gap state data of the switch machine to be detected and storing it as time series data; the gap state data includes gap vibration data and gap quantity data; Performing data preprocessing on the time series data to obtain a feature data set; Perform feature extraction according to the feature data set to obtain a feature vector set; Inputting the feature vector set into a pre-built bidirectional long short-term memory network model and a fully connected network structure model respectively to obtain a first classification prediction result and a second classification prediction result; Based on the random forest algorithm, the first classification prediction result and the second classification prediction result are weighted voted to obtain the gap state classification result of the switch machine to be detected; wherein the gap state classification result includes a post-conversion state, a static state and a passing vehicle state.

[0006] By adopting the above technical solutions, integrating the bidirectional long short-term memory network (BiLSTM), fully connected network (Dense) classification model and the multi-model integration strategy of the random forest algorithm, the intelligent classification detection of the switch gap state is accurately realized. By using the deep learning model to capture the complex time dependency and nonlinear relationship, the post-conversion, static and passing states of the switch are accurately distinguished. The voting mechanism of the random forest further enhances the stability and robustness of the classification, making the system more fault-tolerant and adaptable, ensuring the real-time and accuracy of the detection results, and providing strong technical support for the safe operation of railway transportation.

[0007] Optionally, the step of performing feature extraction according to the feature data set to obtain a feature vector set includes: Performing Fourier transformation on the notch vibration data in the feature vector set to obtain vibration spectrum features; According to the gap quantity data in the feature vector set, the average amplitude and standard deviation of the gap quantity data are calculated to obtain the statistical characteristics of the gap quantity; Aligning the vibration spectrum feature and the notch quantity statistical feature at time points; The vibration spectrum characteristics and the notch quantity statistical characteristics at each time point are combined to construct a feature vector set.

[0008] By adopting the above technical solution, the dynamic and static characteristics of the switch machine are fully captured by using Fourier transform to extract vibration spectrum features, calculate gap quantity statistical features, align time points and construct a joint feature vector set. Fourier transform provides information on dynamic characteristics, gap quantity statistics reflect static characteristics, time alignment ensures data consistency, and the joint feature vector set provides a high-dimensional comprehensive representation for subsequent classification models. The technical solution of this application can significantly improve the integrity and discrimination ability of features, lay a solid foundation for the accuracy and robustness of the classification model, and ensure that the method has good adaptability and practicality.

[0009] Optionally, the method further includes a training step of the bidirectional long short-term memory network model and the fully connected network structure model, wherein the training step includes: Acquire a sample data set; the sample data set includes gap state sample data and pre-labeled gap state classification result labels; Performing time serialization and data preprocessing on the sample data set, and extracting a set of sample feature vectors in the sample data set; Dividing the sample feature vector set into a training set, a validation set and a test set; The training set is respectively input into the pre-built bidirectional long short-term memory network model and the fully connected network structure model for iterative training, and the model parameters are optimized until the loss function meets the preset conditions, so as to obtain the trained bidirectional long short-term memory network model and the fully connected network structure model; Verify the bidirectional long short-term memory network model and the fully connected network structure model based on the verification set, evaluate performance and adjust model hyperparameters; The prediction capabilities of the adjusted bidirectional long short-term memory network model and the fully connected network structure model are tested based on the test set.

[0010] By adopting the above technical solution, after training, verification and testing, this application can build and optimize an efficient switch gap state detection model. Through training, the BiLSTM model can learn time-dependent features, and the Dense model can further mine nonlinear features. Finally, the classification effect is enhanced through integrated learning strategies (such as random forests). The verification and testing stages ensure the accuracy, robustness and generalization ability of the model, providing reliable technical support for the real-time detection of the switch gap state.

[0011] Optionally, the pre-built bidirectional long short-term memory network model includes an input layer, a Masking layer, a BiLSTM layer, a fully connected layer and a Softmax output layer; wherein the BiLSTM layer includes three layers of bidirectional long short-term memory networks, each layer of the bidirectional long short-term memory network includes a forward LSTM unit and a reverse LSTM unit, and the time expansion length of each layer of the bidirectional long short-term memory network is 11, 5, and 11, respectively.

[0012] By adopting the above technical solution, the forward LSTM unit and the reverse LSTM unit work together in the BiLSTM model to process the time series information from the current moment to the future moment and from the future moment to the current moment respectively. Through this bidirectional structure, the BiLSTM model can simultaneously obtain the forward and backward information of the context, thereby improving the modeling ability of complex dependencies in time series data.

[0013] Optionally, based on a random forest algorithm, the first classification prediction result and the second classification prediction result are weighted voted to obtain the gap state classification result of the switch machine to be detected, including: Respectively configuring the preset weight values ​​of the bidirectional long short-term memory network model and the fully connected network structure model; Based on the preset weight value, calculating the weighted voting result of the first classification prediction result and the second classification prediction result; The category with the highest probability in the weighted voting results is used as the gap state classification result of the switch machine to be detected.

[0014] By adopting the above technical solution, the weighted voting strategy based on the random forest algorithm, combined with the prediction results of the BiLSTM model and the Dense model, and taking advantage of the complementarity of the two, the accuracy and stability of the switch machine gap state classification are significantly improved. Through the probability output of the weighted voting of the model, it is possible to flexibly combine different models according to their contribution to obtain more accurate classification results.

[0015] Optionally, the steps of respectively configuring the preset weight values ​​of the bidirectional long short-term memory network model and the fully connected network structure model include: Obtaining gap status sample data and gap status classification result labels in the validation set; Configuring initial weight values ​​of the trained bidirectional long short-term memory network model and the fully connected network structure model; Inputting the gap state sample data in the validation set into the bidirectional long short-term memory network model and the fully connected network structure model respectively, and generating a first label result and a second label result respectively; Based on the gap status classification result label in the validation set, the first label result and the second label result are compared to obtain a comparison result; The initial weight values ​​of the bidirectional long short-term memory network model and the fully connected network structure model are optimized according to the comparison result to obtain the preset weight values ​​of the bidirectional long short-term memory network model and the fully connected network structure model.

[0016] By adopting the above technical solution, configuring and optimizing the preset weight values ​​of the BiLSTM and Dense models, the classification results of the two models can play different degrees of influence in weighted voting. By comparing the model prediction results with the actual labels, the weights can be adjusted dynamically to gradually improve the classification accuracy of the model.

[0017] Optionally, the detection method further includes: When the switch machine to be detected receives a track switching command, a gap state classification result of the switch machine to be detected is obtained in real time; Determining whether the gap status classification result is a static state; If so, generating corresponding status alarm information according to the static status; The status alarm information is sent to the management terminal of the switch machine to be detected.

[0018] By adopting the above technical solutions, combined with the real-time monitoring of the switch machine, the classification of the gap status and the alarm generation mechanism, it is ensured that the system can quickly detect the abnormal state of the switch machine (such as the static state) and generate corresponding alarm information. By sending the alarm information to the management terminal or control center in a timely manner, the system can provide real-time response when there is a problem with the equipment, reduce potential safety risks, and ensure the normal operation and timely maintenance of the equipment.

[0019] In the second aspect, the present application provides a switch gap state detection system, which adopts the following technical solution: A switch machine gap state detection system, the detection system comprising: A data receiving module is used to receive the gap state data of the switch machine to be detected and store it as time series data; the gap state data includes gap vibration data and gap quantity data; A preprocessing module, used for performing data preprocessing on the time series data to obtain a feature data set; A feature extraction module, used to extract features according to the feature data set to obtain a feature vector set; A classification prediction module, used to input the feature vector set into a pre-built bidirectional long short-term memory network model and a fully connected network structure model, respectively, to obtain a first classification prediction result and a second classification prediction result; The classification result generation module is used to perform weighted voting on the first classification prediction result and the second classification prediction result based on the random forest algorithm to obtain the gap state classification result of the switch machine to be detected; wherein the gap state classification result includes a post-conversion state, a static state and a passing vehicle state.

[0020] In a third aspect, the present application provides a computer device, which adopts the following technical solution: A computer device comprises a memory, a processor and a computer program stored in the memory, wherein the processor executes the computer program to implement the steps of the method as described in the first aspect.

[0021] In a fourth aspect, the present application provides a computer-readable storage medium, which adopts the following technical solution: A computer-readable storage medium stores a computer program that can be loaded by a processor and execute any one of the methods in the first aspect.

[0022] In summary, the present application includes at least one of the following beneficial technical effects: The present application integrates BiLSTM and fully connected network structure (Dense) models, and combines random forest algorithm for weighted voting, which effectively improves the accuracy and robustness of gap state prediction. By real-time and accurate monitoring of the working status of the switch machine, potential faults or abnormalities can be discovered in time, which significantly improves the safety and reliability of railway transportation, and provides a scientific basis for fault warning and maintenance decision-making. BRIEF DESCRIPTION OF THE DRAWINGS

[0023] Figure 1 It is a first flow chart of a method for detecting a notch state of a switch machine according to one embodiment of the present application.

[0024] Figure 2 It is a second flow chart of the method for detecting the notch state of a switch machine according to one of the embodiments of the present application.

[0025] Figure 3 It is a third flow chart of a method for detecting a notch state of a switch machine according to one embodiment of the present application.

[0026] Figure 4 This is a schematic diagram of the internal connection structure of a bidirectional long short-term memory network model of one of the embodiments of the present application.

[0027] Figure 5 It is a schematic diagram of the forward propagation and reverse optimization process of a bidirectional long short-term memory network model according to one embodiment of the present application.

[0028] Figure 6 This is a schematic diagram of the connection relationship between the BiLSTM and the classifier in the bidirectional long short-term memory network model of one of the embodiments of the present application.

[0029] Figure 7 It is a schematic diagram of the overall process of a bidirectional long short-term memory network model of one of the embodiments of the present application.

[0030] Figure 8 It is a fourth flow chart of a method for detecting a notch state of a switch machine according to one embodiment of the present application.

[0031] Fig. 9 It is a fifth flow chart of a method for detecting a notch state of a switch machine according to one embodiment of the present application.

[0032] Fig.10 It is a sixth flow chart of a method for detecting a notch state of a switch machine according to one embodiment of the present application. DETAILED DESCRIPTION

[0033] In order to make the purpose, technical solutions and advantages of this application more clear, the following Figure 1-10It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0034] The embodiment of the present application discloses a method for detecting a notch state of a switch machine.

[0035] Reference Figure 1 , a method for detecting a switch gap state, the detection method comprising: Step S101, receiving the gap state data of the switch machine to be detected and storing it as time series data; Among them, the gap state data includes gap vibration data and gap quantity data; both gap vibration data and gap quantity data can be collected by the gap sensor. The gap vibration data is used to reflect the vibration characteristics of the switch machine during mechanical movement, such as the difference in vibration amplitude and frequency when the switch machine is stationary, after the action is completed, or when a train passes; the gap quantity data represents the displacement amplitude of the switch machine action or track switching, which is used to quantify whether the track is fully in place. By storing these data in chronological order as time series data, the dynamic evolution of the switch machine gap state over time can be fully reflected.

[0036] In some embodiments, the notch vibration data is arranged in time order, such as [0.12, 0.15, 0.10, ...]; the notch volume data is the opening amplitude recorded by the displacement sensor, such as [2.1, 2.3, 2.2, ...].

[0037] It should be noted that the gap sensor is a monitoring device installed on the switch machine, which is used to monitor whether the switch machine is in place in real time and record changes in the track status. For example, when the switch machine switches tracks, there will be an action stroke, and the gap sensor can record whether this stroke meets the preset standards. If the action is not in place or an abnormality occurs, the gap sensor can collect relevant data for subsequent judgment and processing.

[0038] Step S102, preprocessing the time series data to obtain a feature data set; Among them, time series data may be interfered by environmental noise (such as vibration superposition) and equipment failure (such as data loss) during the actual collection process, resulting in reduced data quality. The data preprocessing step can clean and standardize the data through filtering, interpolation and normalization techniques to ensure the high quality of the model input data.

[0039] Specifically, the denoising step can use a smoothing filter algorithm (such as Gaussian filtering) to remove random noise in the signal; the missing value interpolation step can use a mean or interpolation algorithm to fill the NaN value in [0.12, NaN, 0.10, ...]; the standardization step can normalize all data to the [0, 1] interval.

[0040] Step S103, extracting features based on the feature data set to obtain a feature vector set; Among them, feature extraction is to extract indicators that can effectively reflect state changes from time series data, such as vibration frequency characteristics, displacement amplitude, etc.; the feature vector set is a compressed and structured representation of data, which is convenient for inputting into the model for analysis.

[0041] Step S104, inputting the feature vector set into the pre-built bidirectional long short-term memory network model and the fully connected network structure model respectively, to obtain the first classification prediction result and the second classification prediction result; Among them, the Bidirectional Long Short-Term Memory Network (BiLSTM) model is an improved recurrent neural network (RNN) that can capture long-term and short-term dependencies by forward and backward processing of time series, and is very suitable for processing the time characteristics of the switch gap state. Forward processing is to analyze the time characteristics from the current moment to the future; backward processing is to reversely analyze the time characteristics from the current moment to the past; the first classification result is the model outputting the preliminary state classification probability based on the time characteristics. The BiLSTM model effectively captures the time correlation of the gap state and can provide a relatively accurate preliminary classification result.

[0042] Among them, the fully connected network (Dense) model focuses on extracting hidden patterns in high-dimensional space from feature vectors, and is suitable for nonlinear combination and classification of feature space. Compared with the BiLSTM model, it pays more attention to the combination of global features. The Dense model further enriches the representation of features through nonlinear mapping, which complements the classification prediction results output by the BiLSTM model.

[0043] Step S105, based on the random forest algorithm, weighted voting is performed on the first classification prediction result and the second classification prediction result to obtain the gap state classification result of the switch machine to be detected; wherein the gap state classification result includes a converted state, a static state and a passing vehicle state.

[0044] Specifically, the random forest uses an integrated learning strategy to perform weighted voting on the first classification prediction results and the second classification prediction results. The prediction results of each single model are combined as the basis for the overall voting, and the final classification result is determined by majority voting. Weighted voting means assigning different weights to the two groups of classification results, for example, the BiLSTM model weight is 0.6 and the Dense model weight is 0.4. The final classification is output based on the voting results.

[0045] It can be understood that through the complementarity of the two models, BiLSTM provides the classification ability of temporal features, and the fully connected network structure model supplements the classification ability of global features. The results of the two are fused through the random forest ensemble algorithm to improve the classification accuracy and robustness.

[0046] It should be noted that the post-conversion state indicates the normal state after the switch machine has completed its operation, the static state indicates that the switch machine has not operated or is stationary, and the passing state indicates the dynamic state when a train passes by.

[0047] In the above implementation, the application integrates the bidirectional long short-term memory network (BiLSTM), the fully connected network (Dense) classification model and the multi-model integration strategy of the random forest algorithm to accurately realize the intelligent classification detection of the switch gap state. By using the deep learning model to capture the complex time dependency and nonlinear relationship, the post-conversion, static and passing states of the switch can be accurately distinguished. The voting mechanism of the random forest further enhances the stability and robustness of the classification, making the system more fault-tolerant and adaptable, ensuring the real-time and accuracy of the detection results, and providing strong technical support for the safe operation of railway transportation.

[0048] Reference Figure 2 As an implementation of step S103, the step of extracting features according to the feature data set to obtain a feature vector set includes: Step S201, performing Fourier transform on the notch vibration data in the feature vector set to obtain vibration spectrum features; Among them, Fourier transform is a mathematical tool that converts time domain signals into frequency domain signals. Through Fourier transform, the spectrum information in the vibration data, such as the main frequency and its amplitude, can be extracted. These spectrum features can reflect the dynamic characteristics of the vibration state of the switch machine, such as high-frequency vibration in the passing state or low-frequency fluctuation in the static state.

[0049] Step S202, calculating the average amplitude and standard deviation of the gap quantity data according to the gap quantity data in the feature vector set to obtain the gap quantity statistical characteristics; Among them, the gap data reflects the displacement amplitude change of the switch machine. By calculating its mean value and standard deviation, the stability and variation range of the gap data can be evaluated, thereby judging whether the state of the switch machine is normal or stable.

[0050] It can be understood that by calculating the average amplitude and standard deviation, the global statistical characteristics of the gap volume data are extracted, providing a basis for distinguishing between the static state (small fluctuation) and the dynamic state (large fluctuation).

[0051] Step S203, aligning the vibration spectrum characteristics and the notch quantity statistical characteristics at time points; Among them, since vibration data and gap volume data are usually time series data collected by different sensors, in order to ensure that the two features can be correctly combined, they need to be aligned in time points. This can be done by interpolating or synchronizing the data so that the complete features can be matched at each time point.

[0052] Step S204: Combine the vibration spectrum features and the notch quantity statistical features at each time point to construct a feature vector set.

[0053] Among them, the vibration spectrum characteristics (such as main frequency and amplitude) at each time point are combined with the statistical characteristics of the gap quantity (such as mean and standard deviation) to form a multi-dimensional feature vector set. These feature vectors can be used as the input of the model to comprehensively reflect the dynamic and static characteristics of the switch machine.

[0054] For example, at time point t1, the vibration spectrum feature is [Freq: 10 Hz, Amp: 0.3], and the notch statistical feature is [Mean: 2.1, StdDev: 0.1], then the joint feature vector is F t1 =[10Hz,0.3,2.1,0.1]; for time point t2, F t2 =[15Hz,0.4,2.3,0.2], and finally the feature vector set is constructed as Fcombined={F t1 ,F t2 ,...,F tn}.

[0055] In the above implementation, Fourier transform is used to extract vibration spectrum features, calculate gap quantity statistical features, align time points and construct a joint feature vector set, which comprehensively captures the dynamic and static characteristics of the switch machine. Fourier transform provides information on dynamic characteristics, gap quantity statistics reflect static characteristics, time alignment ensures data consistency, and the joint feature vector set provides a high-dimensional comprehensive representation for subsequent classification models. The technical solution of the present application can significantly improve the integrity and discrimination ability of features, lay a solid foundation for the accuracy and robustness of the classification model, and ensure that the method has good adaptability and practicality.

[0056] Reference Figure 3 As an implementation of the bidirectional long short-term memory network model and the fully connected network structure model, the method further includes the training steps of the bidirectional long short-term memory network model and the fully connected network structure model, specifically including: Step S301, obtaining a sample data set; the sample data set includes gap state sample data and pre-labeled gap state classification result labels; Among them, the gap state sample data includes the gap vibration data and gap quantity data of the switch machine; the gap state label, that is, each sample data corresponds to a classification label (such as after conversion, static, passing vehicle state), which can be determined by sensors or manual labeling.

[0057] Exemplarily, the sample data set is {X, Y}, where X is the gap state sample data (feature data) and Y is the label data (gap state classification).

[0058] Step S302, time serializing and preprocessing the sample data set, and extracting a set of sample feature vectors in the sample data set; Specifically, before training, the sample data needs to be preprocessed and feature extracted. This step converts the original data into a set of feature vectors that conform to the model input format through serialization operations, and normalizes the data to ensure that it is consistent within the numerical range.

[0059] Among them, the serialization step includes segmenting the training data into time windows of fixed length, and the preprocessing step includes denoising, normalization, missing value processing and other steps.

[0060] Step S303, dividing the sample feature vector set into a training set, a validation set and a test set; Among them, in order to evaluate the generalization ability of the model, the dataset needs to be divided into three parts: training set, validation set and test set; the training set is used to train the model, the validation set is used to adjust hyperparameters and prevent overfitting, and the test set is used to evaluate the final performance of the model.

[0061] Step S304, inputting the training set into the pre-built bidirectional long short-term memory network model and the fully connected network structure model for iterative training, optimizing the model parameters until the loss function meets the preset conditions, and obtaining the trained bidirectional long short-term memory network model and the fully connected network structure model; Among them, the training process is the core of model learning, and its purpose is to optimize the weight of the model by minimizing the loss function. The bidirectional long short-term memory network (BiLSTM) and the fully connected network structure model (Dense) will be trained separately, and their parameters will be optimized through back propagation.

[0062] Specifically, during the training process, the cross entropy loss function (applicable to multi-classification problems) can be used to measure the difference between the model output and the actual label, and an optimizer (such as the Adam optimizer) can be used to perform gradient updates and adjust the model parameters until the loss function meets the preset conditions (such as the loss value no longer decreases significantly).

[0063] Step S305, verifying the bidirectional long short-term memory network model and the fully connected network structure model based on the verification set, evaluating the performance and adjusting the model hyperparameters; During the training process, the validation set can be used to adjust the model hyperparameters to ensure the stability of the model performance on different data sets and avoid overfitting. Specifically, the validation set is input into the BiLSTM and Dense models in training to evaluate the difference between their prediction results and the actual labels. Based on the performance on the validation set, the learning rate, batch size, number of training rounds and other hyperparameters can be adjusted, and then the model can be evaluated using evaluation indicators such as accuracy and F1 score.

[0064] Step S306, testing the prediction capabilities of the adjusted bidirectional long short-term memory network model and the fully connected network structure model based on the test set.

[0065] After training and verification, the final model can be evaluated using the test set to ensure that the model can work accurately in a real environment. Specifically, the prediction results are obtained by inputting the test set into the trained BiLSTM and Dense models, calculating the performance indicators such as the accuracy and F1 score of the model on the test set, and analyzing the error distribution of the model classification through methods such as the confusion matrix to further optimize the model.

[0066] In the above implementation, after training, verification and testing, the present application can build and optimize an efficient switch gap state detection model. Through training, the BiLSTM model can learn time-dependent features, and the Dense model can further mine nonlinear features. Finally, the classification effect is enhanced through an integrated learning strategy (such as random forest). The verification and testing stages ensure the accuracy, robustness and generalization ability of the model, providing reliable technical support for the real-time detection of the switch gap state.

[0067] As an implementation method of a bidirectional long short-term memory network model, a pre-built bidirectional long short-term memory network model includes an input layer, a Masking layer, a BiLSTM layer, a fully connected layer and a Softmax output layer; wherein the BiLSTM layer includes three layers of bidirectional long short-term memory networks, each layer of the bidirectional long short-term memory network includes a forward LSTM unit and a reverse LSTM unit, and the time expansion length of each layer of the bidirectional long short-term memory network is 11, 5, and 11, respectively.

[0068] In an embodiment of the present application, the input layer is used to receive a set of preprocessed time series feature vectors, and the Masking layer is used to filter invalid data points (such as missing values ​​or fill values) in the input data. Through the Masking layer, the model can automatically ignore irrelevant data and focus on valid information; the BiLSTM layer can capture time dependencies, including short-term and long-term features, by bidirectionally processing time series; the fully connected layer is used to further map the output features of the BiLSTM into classification probabilities, that is, it can compress the time step dimension to the final classification dimension; the Softmax output layer uses the Softmax function to generate the first classification prediction result of the model and provide the probability distribution of each state.

[0069] Each layer of the bidirectional long short-term memory network has forward and reverse LSTM units, and the output is Dropout to prevent overfitting. The time expansion length of the first layer of the bidirectional long short-term memory network can be configured to 11, which means that each LSTM unit processes the dependencies of 11 time steps; the time expansion length of the second layer of the bidirectional long short-term memory network can be configured to 5, focusing on short-term dependencies; the time expansion length of the third layer of the bidirectional long short-term memory network can be configured to 11 to capture the global dependencies over a longer period of time again.

[0070] Specifically, in the BiLSTM layer, the forward LSTM and reverse LSTM units work in parallel to jointly learn the temporal dependencies of sequence data. By combining the forward and reverse information, the BiLSTM layer can simultaneously capture contextual information from the past to the future and from the future to the past. This enables the BiLSTM model to obtain more comprehensive and accurate feature representations when dealing with tasks with complex temporal dependencies.

[0071] It should be noted that the forward LSTM unit processes data from the beginning of the sequence to the future moment and calculates the corresponding hidden state; the reverse LSTM unit processes data from the end of the sequence to the current moment in reverse and calculates the corresponding hidden state; the output of the BiLSTM layer is the concatenation or summation of the hidden states of the forward LSTM unit and the reverse LSTM unit. Since the outputs of the forward and reverse LSTM units are combined as the final feature representation of the model, this enables the BiLSTM model to provide more accurate classification results when processing tasks such as switch gap state detection.

[0072] In the above implementation, the forward LSTM unit and the reverse LSTM unit work together in the BiLSTM model to process the time series information from the current moment to the future moment and from the future moment to the current moment respectively. Through this bidirectional structure, the BiLSTM model can simultaneously obtain the forward and backward information of the context, thereby improving the modeling ability of complex dependencies in time series data.

[0073] Reference Figure 4 As shown, the neuron connection structure of the BiLSTM (Bidirectional Long Short-Term Memory Network) model of one embodiment of the present application is shown, and how the neurons in each layer interact with the previous and next layers through different time steps (expansion lengths). Among them, Layer (l-1), Layerl and Layer (l+1) respectively represent the multi-layer structure of BiLSTM, and each layer receives input data from the previous layer and outputs features to the next layer.

[0074] Reference Figure 5 As shown, the process of forward propagation and reverse optimization of the BiLSTM model in one embodiment of the present application is shown. Among them, CNN Neuron k represents a neuron in the network, which processes the input features of the convolution layer (CNN Layerl); in the forward propagation process, the input features generate the output of the neuron through the summation operation Σ and the activation function f(x), and the convolution operation maps the local features (time series fragments) to the high-dimensional feature space; in the reverse optimization process, the error is optimized through back propagation weights, and the arrows in the figure indicate the update flow direction of the gradient Δ.

[0075] Reference Figure 6 As shown, it shows how the BiLSTM output of one embodiment of the present application is connected to the multi-layer perceptron (MLP) classifier to achieve the final state prediction. The classifier maps the features extracted by the BiLSTM to specific output categories. CNN extracts local features of the sequence, BiLSTM captures time dependencies, and the final feature vector is input to the MLP layer. The prediction result is output through weighted summation and activation function f(x). Each layer of neurons is connected in a fully connected manner to ensure the comprehensive transmission of information.

[0076] Reference Figure 7 As shown, the complete processing flow of the BiLSTM model of one embodiment of the present application is shown, including input, feature extraction, sequence processing and output prediction, by processing missing values ​​in the input data (Masking Layer) and extracting time features using bidirectional dependencies. Among them, the input time series data processes missing values ​​through the Masking layer to ensure the integrity of the input data; the multi-layer BiLSTM extracts features of specific time scales respectively, gradually accumulates global and local information, and finally outputs the classification results for predicting the gap status.

[0077] As an implementation method of the fully connected network structure model, the fully connected network structure model includes an input layer, a first hidden layer, a second hidden layer, and an output layer. The input layer is used to receive the feature vector set obtained after the feature extraction step. The feature vector set contains the refined features of the time series data and is used for further processing by the classification model; the first hidden layer is used to perform nonlinear transformation on the input feature vector set and learn the complex relationship between the input features. This layer usually includes multiple neurons and nonlinear activation functions to increase the expressive power of the model; the second hidden layer is used to further perform in-depth processing on the output features of the previous layer, learn more advanced nonlinear features, and reduce the dimension; the output layer is used to map the feature vector of the previous layer (the second hidden layer) to the classification space and output the state classification result of the switch gap. The output layer maps the feature vector to the probability distribution of three categories (conversion state, static state, and passing state) through the Softmax activation function. By training the model, the cross entropy loss function and the Adam optimizer are used to optimize its weights and biases so that it can better predict the state of the switch gap.

[0078] Reference Figure 8 As an implementation method of step S105, based on the random forest algorithm, the first classification prediction result and the second classification prediction result are weighted voted to obtain the gap state classification result of the switch machine to be detected, including: Step S401, respectively configuring preset weight values ​​of a bidirectional long short-term memory network model and a fully connected network structure model; Among them, by setting weights for the prediction results of each model, different models can play different roles in the final classification results. This weight configuration usually reflects the reliability and importance of the model in the task.

[0079] Step S402, calculating the weighted voting result of the first classification prediction result and the second classification prediction result based on the preset weight value; Among them, the weighted voting step obtains the comprehensive classification result through weighted calculation according to the prediction results and weights of each model. This process improves the accuracy and stability of classification by integrating the advantages of BiLSTM and Dense models; the core of weighted voting is to use the probability predicted by each model, weighted by the weight value, and obtain a comprehensive probability distribution.

[0080] For example, the result after weighted voting is: R i =[0.66,0.24,0.1], that is, the classification probability of the converted state is 66%, the classification probability of the static state is 24%, and the classification probability of the passing state is 10%.

[0081] Step S403: taking the category with the highest probability in the weighted voting result as the gap state classification result of the switch machine to be detected.

[0082] Among them, the final classification result is determined according to the category with the highest probability in the weighted voting results. By selecting the category with the highest probability, it is ensured that the final classification result can reflect the main trend of the data.

[0083] For example, for the result R after weighted voting i =[0.66,0.24,0.1], the category corresponding to the maximum probability value can be selected as the final classification result, that is, the final classification result is the “converted state”.

[0084] In the above implementation, the weighted voting strategy based on the random forest algorithm is combined with the prediction results of the BiLSTM model and the Dense model, and the complementarity of the two is used to significantly improve the accuracy and stability of the switch gap state classification. By outputting the probability of weighted voting on the model, it is possible to flexibly combine different models according to their contribution to obtain more accurate classification results.

[0085] Reference Fig. 9 As an implementation of step S401, the steps of respectively configuring the preset weight values ​​of the bidirectional long short-term memory network model and the fully connected network structure model include: Step S501, obtaining gap status sample data and gap status classification result labels in the validation set; Among them, the validation set can obtain gap status sample data and actual label results, which are used to adjust the preset weights of the model and conduct a preliminary evaluation of the model.

[0086] Step S502, configuring the initial weight values ​​of the trained bidirectional long short-term memory network model and the fully connected network structure model; Before weighted voting, you need to configure initial weight values ​​for the BiLSTM and Dense models. These initial weight values ​​are set before model training and are gradually optimized during subsequent training.

[0087] For example, according to the model design and training requirements, the initial weight of the BiLSTM model is set to 0.5, which means that the BiLSTM model contributes 50% to the weighted voting in the initial stage. Similarly, the initial weight of the Dense model is also set to 0.5, so that its initial contribution to the weighted voting is also 50%.

[0088] Step S503, inputting the gap state sample data in the validation set into the bidirectional long short-term memory network model and the fully connected network structure model respectively, generating a first label result and a second label result respectively; Among them, the configured BiLSTM and Dense models are used to infer the validation set data and generate prediction results. The output results of these two models will be used as the first label results and the second label results respectively, and provide reference for subsequent comparisons and iterations.

[0089] Step S504, based on the gap status classification result label in the validation set, the first label result and the second label result are compared to obtain a comparison result; Among them, by comparing the prediction results of the BiLSTM and Dense models with the true labels (from the validation set), the performance of each model can be evaluated and a basis can be provided for subsequent weight adjustments. The comparison results reflect the accuracy of the model predictions.

[0090] Specifically, the prediction results of the BiLSTM and Dense models are compared one by one with the real labels in the validation set, and the degree of match between the prediction results of each model and the actual labels is compared. The classification accuracy or error metrics (such as cross entropy loss, accuracy) are used to quantify the comparison results to evaluate the prediction accuracy of each model, help determine the pros and cons of the model in prediction, and thus provide a basis for adjusting the weights.

[0091] Step S505, optimizing the initial weight values ​​of the bidirectional long short-term memory network model and the fully connected network structure model according to the comparison result, and obtaining the preset weight values ​​of the bidirectional long short-term memory network model and the fully connected network structure model.

[0092] Among them, the initial weights of the BiLSTM and Dense models are updated according to the comparison results (such as error or accuracy). Common adjustment methods include gradient descent or other optimization algorithms (such as Adam). Through multiple iterations, the weights of the BiLSTM and Dense models are gradually optimized until the error is minimized or the preset accuracy standard is met.

[0093] For example, assuming that the BiLSTM model has an accuracy of 80% in the first round of comparison and the Dense model has an accuracy of 75%, based on these comparison results, the weight of the BiLSTM may be increased to 0.65, while the weight of the Dense model may be reduced to 0.35.

[0094] In the above implementation, the preset weight values ​​of the BiLSTM and Dense models are configured and optimized so that the classification results of the two models can have different degrees of influence in the weighted voting. By comparing the model prediction results with the true labels, the weights can be dynamically adjusted to gradually improve the classification accuracy of the model.

[0095] Reference Fig.10 As a further embodiment of the detection method, the detection method further comprises: Step S601, when the switch machine to be detected receives a track switching command, the gap state classification result of the switch machine to be detected is obtained in real time; Specifically, the switch machine to be tested receives a track switching command from a train dispatching system or a control center. These commands are usually issued by a control system to instruct the switch machine to complete a track switching operation. The gap status of the switch machine is detected in real time, and a gap status classification result is generated through a classification algorithm.

[0096] It should be noted that real-time performance is the core requirement of this step, ensuring that the system can respond quickly to switching commands and monitor the status of the switch machine in real time.

[0097] Step S602, determining whether the gap status classification result is a static state; if so, jumping to step S603; if not, not performing any operation; Among them, the static state indicates that the switch machine has not performed any action, which usually means that the equipment is in a stationary state and no track switching operation is performed. This state may be caused by equipment failure or human factors.

[0098] Step S603, generating corresponding status alarm information according to the static status; Specifically, if the switch machine fails to complete the track switching according to the predetermined action, it may cause the system to fail to work properly or there will be safety hazards in the train operation. Therefore, when the switch machine fails to move at the moment when the track should be switched and remains stationary for a certain period of time, the system needs to detect and issue an alarm notification in time.

[0099] Step S604: sending the status alarm information to the management terminal of the switch machine to be detected.

[0100] The status alarm information prompts the operator or the control center to check whether there is any fault in the switch machine, such as electrical fault, mechanical jam, sensor failure, etc. The management terminal can be the operator's computer device or intelligent mobile terminal.

[0101] In the above implementation, the real-time monitoring of the switch machine, the classification of the gap state and the alarm generation mechanism are combined to ensure that the system can quickly detect the abnormal state of the switch machine (such as the static state) and generate corresponding alarm information. By sending the alarm information to the management terminal or the control center in a timely manner, the system can provide real-time response when a problem occurs in the equipment, reduce potential safety risks, and ensure the normal operation and timely maintenance of the equipment.

[0102] This application proposes an integrated learning method that combines the BiLSTM (bidirectional long short-term memory network) and the fully connected network structure (Dense) model. By integrating the advantages of these two models, a powerful switch gap state prediction framework is constructed. In this framework, the BiLSTM model can effectively process the time dependency and contextual information in the switch gap state data, thereby providing a solid foundation for accurately judging the gap state. The fully connected network structure model further improves the processing effect of complex data through its efficient feature extraction and classification capabilities. In order to enhance the overall performance of the model, this application also combines the Random Forest strategy for integration, and further optimizes the prediction accuracy by integrating the output results of different models.

[0103] Through the integrated learning method, this application not only improves the prediction accuracy of the switch gap status, but also effectively reduces the failure rate of the switch, fully utilizes the complementarity of the BiLSTM and Dense models, avoids the limitations that may be brought by a single model, and thus improves the generalization ability and robustness of the model.

[0104] In summary, the integrated learning framework proposed in this application has significant advantages in the field of switch gap state detection, provides a more reliable guarantee for the safe operation of railway transportation, and has broad application prospects.

[0105] The embodiment of the present application also discloses a switch gap state detection system.

[0106] A switch machine gap state detection system, the detection system comprising: The data receiving module is used to receive the gap state data of the switch machine to be detected and store it as time series data; the gap state data includes gap vibration data and gap quantity data; The preprocessing module is used to preprocess the time series data to obtain a feature data set; A feature extraction module is used to extract features according to a feature data set to obtain a feature vector set; A classification prediction module is used to input the feature vector set into a pre-built bidirectional long short-term memory network model and a fully connected network structure model to obtain a first classification prediction result and a second classification prediction result; The classification result generation module is used to perform weighted voting on the first classification prediction result and the second classification prediction result based on the random forest algorithm to obtain the gap state classification result of the switch machine to be detected; wherein the gap state classification result includes the post-conversion state, the static state and the passing vehicle state.

[0107] The switch gap state detection system of the embodiment of the present application can implement any of the above-mentioned switch gap state detection methods, and the specific working process of each module in the switch gap state detection system can refer to the corresponding process in the above-mentioned method embodiment.

[0108] In the several embodiments provided in this application, it should be understood that the provided methods and systems can be implemented in other ways. For example, the system embodiments described above are only illustrative; for example, the division of a certain module is only a logical function division, and there may be other division methods in actual implementation, such as multiple modules can be combined or integrated into another system, or some features can be ignored or not executed.

[0109] The embodiment of the present application also discloses a computer device.

[0110] The computer device comprises a memory, a processor and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the switch machine gap state detection method as described above is implemented.

[0111] The embodiment of the present application also discloses a computer-readable storage medium.

[0112] A computer-readable storage medium stores a computer program that can be loaded by a processor and execute any one of the above-mentioned methods for detecting a gap state of a switch machine.

[0113] Among them, computer-readable storage media can be any tangible medium that contains or stores a program, which can be used by or in conjunction with an instruction execution system, apparatus or device; the program code contained on the computer-readable medium can be transmitted using any appropriate medium, including but not limited to wireless, wire, optical cable, RF, etc., or any suitable combination of the above.

[0114] It should be noted that in the above embodiments, the description of each embodiment has different emphases, and for parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0115] The above are all preferred embodiments of the present application, and are not intended to limit the protection scope of the present application. Any feature disclosed in this specification (including the abstract and drawings), unless otherwise stated, can be replaced by other equivalent or alternative features with similar purposes. That is, unless otherwise stated, each feature is only an example of a series of equivalent or similar features.

Claims

1. A method for detecting a switch machine notch state, characterized in that: The detection method comprises: Receiving the gap state data of the switch machine to be detected and storing it as time series data; the gap state data includes gap vibration data and gap quantity data; Performing data preprocessing on the time series data to obtain a feature data set; Perform feature extraction according to the feature data set to obtain a feature vector set; Inputting the feature vector set into a pre-built bidirectional long short-term memory network model and a fully connected network structure model respectively to obtain a first classification prediction result and a second classification prediction result; Based on the random forest algorithm, the first classification prediction result and the second classification prediction result are weighted voted to obtain the gap state classification result of the switch machine to be detected; wherein the gap state classification result includes a post-conversion state, a static state and a passing vehicle state.

2. A method for detecting a switch notch state according to claim 1, characterized in that: The step of extracting features according to the feature data set to obtain a feature vector set includes: Performing Fourier transformation on the notch vibration data in the feature vector set to obtain vibration spectrum features; According to the gap quantity data in the feature vector set, the average amplitude and standard deviation of the gap quantity data are calculated to obtain the statistical characteristics of the gap quantity; Aligning the vibration spectrum feature and the notch quantity statistical feature at time points; The vibration spectrum characteristics and the notch quantity statistical characteristics at each time point are combined to construct a feature vector set.

3. A method for detecting a switch notch state according to claim 1, characterized in that: The method further includes a training step of the bidirectional long short-term memory network model and the fully connected network structure model, wherein the training step includes: Acquire a sample data set; the sample data set includes gap state sample data and pre-labeled gap state classification result labels; Performing time serialization and data preprocessing on the sample data set, and extracting a set of sample feature vectors in the sample data set; Dividing the sample feature vector set into a training set, a validation set and a test set; The training set is respectively input into the pre-built bidirectional long short-term memory network model and the fully connected network structure model for iterative training, and the model parameters are optimized until the loss function meets the preset conditions, so as to obtain the trained bidirectional long short-term memory network model and the fully connected network structure model; Verify the bidirectional long short-term memory network model and the fully connected network structure model based on the verification set, evaluate performance and adjust model hyperparameters; The prediction capabilities of the adjusted bidirectional long short-term memory network model and the fully connected network structure model are tested based on the test set.

4. A method for detecting a switch machine notch state according to claim 3, characterized in that: The pre-built bidirectional long short-term memory network model includes an input layer, a Masking layer, a BiLSTM layer, a fully connected layer and a Softmax output layer; wherein the BiLSTM layer includes three layers of bidirectional long short-term memory networks, each layer of the bidirectional long short-term memory network includes a forward LSTM unit and a reverse LSTM unit, and the time expansion length of each layer of the bidirectional long short-term memory network is 11, 5, and 11 respectively.

5. A method for detecting a switch machine notch state according to claim 3, characterized in that: Based on the random forest algorithm, the first classification prediction result and the second classification prediction result are weighted voted to obtain the gap state classification result of the switch machine to be detected, including: Respectively configuring the preset weight values ​​of the bidirectional long short-term memory network model and the fully connected network structure model; Based on the preset weight value, calculating the weighted voting result of the first classification prediction result and the second classification prediction result; The category with the highest probability in the weighted voting results is used as the gap state classification result of the switch machine to be detected.

6. A method for detecting a switch machine notch state according to claim 5, characterized in that: The steps of respectively configuring the preset weight values ​​of the bidirectional long short-term memory network model and the fully connected network structure model include: Obtaining gap status sample data and gap status classification result labels in the validation set; Configuring initial weight values ​​of the trained bidirectional long short-term memory network model and the fully connected network structure model; Inputting the gap state sample data in the validation set into the bidirectional long short-term memory network model and the fully connected network structure model respectively, and generating a first label result and a second label result respectively; Based on the gap status classification result label in the validation set, the first label result and the second label result are compared to obtain a comparison result; The initial weight values ​​of the bidirectional long short-term memory network model and the fully connected network structure model are optimized according to the comparison result to obtain the preset weight values ​​of the bidirectional long short-term memory network model and the fully connected network structure model.

7. A method for detecting a switch machine notch state according to claim 1, characterized in that: The detection method further comprises: When the switch machine to be detected receives a track switching command, a gap state classification result of the switch machine to be detected is obtained in real time; Determining whether the gap status classification result is a static state; If so, generating corresponding status alarm information according to the static status; The status alarm information is sent to the management terminal of the switch machine to be detected.

8. A switch machine gap state detection system, characterized in that: The detection system comprises: A data receiving module is used to receive the gap state data of the switch machine to be detected and store it as time series data; the gap state data includes gap vibration data and gap quantity data; A preprocessing module, used for performing data preprocessing on the time series data to obtain a feature data set; A feature extraction module, used to extract features according to the feature data set to obtain a feature vector set; A classification prediction module, used to input the feature vector set into a pre-built bidirectional long short-term memory network model and a fully connected network structure model, respectively, to obtain a first classification prediction result and a second classification prediction result; The classification result generation module is used to perform weighted voting on the first classification prediction result and the second classification prediction result based on the random forest algorithm to obtain the gap state classification result of the switch machine to be detected; wherein the gap state classification result includes a post-conversion state, a static state and a passing vehicle state.

9. A computer device, characterized in that: The method comprises a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the method according to any one of claims 1 to 7 when executing the program.

10. A computer-readable storage medium, characterized in that: A computer program is stored which can be loaded by a processor and execute the method according to any one of claims 1 to 7.

Citation Information

Cited By

  • Remote signaling detection method and device

    CN120408217A