Mechanical system fault zero sample positioning method based on unbalanced Transform
By optimizing sensor monitoring channels and constructing a semantic attribute space, combined with adaptive residual denoising and an unbalanced Transformer model, the problems of unreasonable monitoring channel configuration, missing unknown fault samples, and noise interference in the fault location of high-speed train bogie vibration dampers were solved, achieving high-precision fault location identification and positioning.
Patent Information
- Application Number
- CN202610485214.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-04-14
- Publication Date
- 2026-05-19
AI Technical Summary
Existing fault diagnosis technologies suffer from problems in locating faults in high-speed train bogie vibration dampers, such as unreasonable configuration of monitoring channels, improper handling of missing unknown fault samples, difficulty in feature fidelity and noise reduction under strong noise environments, and inter-class imbalance, resulting in insufficient positioning accuracy.
By optimizing the sensor monitoring channel configuration, constructing a semantic attribute space, introducing an adaptive residual noise reduction module and an unbalanced Transformer model, and combining a multi-head self-attention mechanism and an unbalanced loss function, an optimized sensor channel covering all vibration damper positions is generated, and fault location is achieved through a KNN classifier.
It achieves high-precision fault location identification under the condition that no fault location category samples are used for training, improves the precision of fault location and the generalization ability of the model, and is applicable to intelligent operation and maintenance of high-end equipment such as rail transit and aerospace.
Smart Images

Figure CN122065984A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of mechanical system fault diagnosis technology, and specifically to a zero-sample fault localization method for mechanical systems based on unbalanced Transformer. Background Technology
[0002] With the continuous development of the Industrial Internet of Things (IIoT) and monitoring technologies, a large amount of mechanical condition monitoring data generated during train operation can be collected and stored in real time, providing rich data support for mechanical equipment fault diagnosis. In recent years, deep learning technology has been widely used in the field of mechanical fault diagnosis and has achieved remarkable results. For example, models such as multi-task parallel deep residual networks and convolutional neural networks are used to mine the potential correlations between fault states, or network structures that integrate multimodal data and shift window attention mechanisms are adopted to achieve effective fault diagnosis of rotating machinery in environments with limited samples and strong noise.
[0003] While the aforementioned methods perform well in routine fault classification tasks, their diagnostic effectiveness is highly dependent on sufficient and high-quality labeled training samples. Furthermore, in actual high-speed train operation scenarios, due to the randomness of component service life and the influence of regular maintenance strategies, it is difficult to obtain sufficient historical fault samples for some fault types (especially vibration damper faults at specific locations on the bogie). This results in traditional supervised learning methods facing a severe sample shortage problem in fault location identification tasks.
[0004] To address the problem of fault identification under conditions of small or even no samples, zero-shot learning and generalized zero-shot learning have gradually attracted attention. By constructing a semantic attribute space, they enable the transfer of knowledge from known categories to unknown categories and have been initially applied in fields such as bearing fault diagnosis and industrial process fault diagnosis. Meanwhile, the Transformer model, with its excellent global feature modeling capabilities, has also been used to construct attribute classifiers and realize cross-device composite fault diagnosis.
[0005] However, when applying existing zero-shot learning and related deep learning methods directly to fault location of high-speed train bogie dampers, the following technical shortcomings still exist: (1) The monitoring channel configuration is not reasonable enough, and the level of precision in monitoring the condition of the shock absorbers, especially the anti-hunting shock absorbers, is insufficient, making it difficult to effectively distinguish faults in different locations; (2) Although existing zero-shot learning methods can complete knowledge transfer, they lack an effective fitting mechanism for samples of unknown fault locations, thus limiting the model's generalization ability. (3) The measured orbital spectrum data is significantly affected by noise. Traditional noise reduction methods are difficult to suppress noise while retaining effective fault features, which reduces the recognition accuracy of the attribute classifier. (4) The number of samples between known and unknown categories differs greatly, and the imbalance between classes is prominent. Traditional loss functions tend to cause the model to predict the category with a larger proportion of samples, which further affects the positioning accuracy.
[0006] In summary, existing fault diagnosis technologies have significant shortcomings in areas such as monitoring channel optimization, handling of missing unknown fault samples, feature fidelity denoising in high-noise environments, and inter-class imbalance learning, making it difficult to meet the practical engineering needs for accurate fault location of high-speed train bogie vibration dampers. Summary of the Invention
[0007] To address the aforementioned shortcomings in existing technologies, this invention provides a zero-sample fault location method for mechanical systems based on unbalanced Transformers, which solves the problem of inaccurate fault location in existing methods.
[0008] To achieve the above-mentioned objectives, the technical solution adopted by this invention is as follows: A zero-sample fault localization method for mechanical systems based on unbalanced Transformers includes the following steps: The type and location of the vibration dampers to be monitored in the high-speed train bogie system are determined. At the same time, the configuration information of the original sensor monitoring channels is obtained. Based on the spatial distribution characteristics of the vibration dampers and the fault propagation mechanism, the original sensor monitoring channels are optimized, reorganized and expanded to generate optimized sensor channels covering all vibration damper locations. Based on the optimized sensor channel, vibration signals of various vibration dampers at different locations are collected and input into the adaptive residual noise reduction module for noise reduction to generate denoised vibration signals. Based on the denoised vibration signal, samples are divided into known and unknown fault location categories. Simultaneously, samples of the known fault location category are fitted to generate transitional samples of the unknown fault location category, and training and test sets are constructed. Based on the spatial distribution characteristics of the vibration damper fault locations, a semantic description matrix containing several attributes is constructed. For each attribute in the semantic description matrix, an independent Transformer model is constructed and trained by inputting the training set into the corresponding Transformer model to learn the mapping relationship between the data and the corresponding attribute. At the same time, an imbalanced loss function is introduced to optimize the model parameters, and finally a set of mapping functions from data to attributes and a set of attribute vectors for each training sample are generated. The attribute vector set of each training sample is paired with the corresponding fault location category label to form a sample. This sample is then input into the KNN classifier for training, a feature space index is constructed, and a trained KNN model is generated. Each test sample in the test set is input into a set of mapping functions to obtain a set of attribute vectors for each test sample. These vectors are then input into a trained KNN model for inference to generate fault location results for each test sample.
[0009] The present invention has the following beneficial effects: This invention proposes a zero-shot fault localization method for mechanical systems based on unbalanced Transformers. By constructing a semantic attribute space, it establishes a progressive mapping path from data to attributes and then to labels. For the first time, it deeply couples zero-shot learning with fault location category recognition, achieving high-precision recognition even without fault location category samples participating in training. Simultaneously, by systematically optimizing the sensor monitoring channel configuration, it improves the precision of fault localization from the source. An adaptive residual denoising module is introduced, utilizing dynamic thresholds and residual structures to enhance and robustly extract fault features in noisy environments. A multi-head self-attention mechanism is introduced to give the model global... By leveraging modeling capabilities and combining a positional encoding mechanism to impart temporal and spatial symmetry perception, the invention explicitly models the cross-component propagation path of faults. Utilizing the structural symmetry of the bogie, it generates transitional samples for unknown positions from known positions through polynomial fitting, effectively alleviating the problem of missing samples. The constructed unbalanced loss function balances the learning intensity of known and unknown classes at the class weight level. Ultimately, this invention forms a complete technical closed-loop route from data acquisition, noise reduction, sample fitting, model training to fault inference, possessing good replicability and engineering promotion value. It can provide a systematic solution for the intelligent operation and maintenance of key components of high-end equipment such as rail transit and aerospace. Attached Figure Description
[0010] Figure 1 This is a flowchart illustrating a zero-sample fault localization method for mechanical systems based on an unbalanced Transformer proposed in this invention. Figure 2 This is a schematic diagram of the zero-sample fault localization method for mechanical systems containing a Transformer model structure and an adaptive residual denoising module structure. Detailed Implementation
[0011] The specific embodiments of the present invention are described below to enable those skilled in the art to understand the present invention. However, it should be understood that the present invention is not limited to the scope of the specific embodiments. For those skilled in the art, various changes are obvious as long as they are within the spirit and scope of the present invention as defined and determined by the appended claims. All inventions utilizing the concept of the present invention are protected.
[0012] The specific embodiments of this invention are as follows: like Figures 1-2As shown, a zero-sample fault localization method for mechanical systems based on unbalanced Transformers includes the following steps: Step 1: Determine the type and location of the vibration damper to be monitored in the high-speed train bogie system, and at the same time obtain the configuration information of the original sensor monitoring channels. Combining the spatial distribution characteristics of the vibration dampers and the fault propagation mechanism, optimize, reorganize and expand the original sensor monitoring channels to generate optimized sensor channels covering all vibration damper locations.
[0013] In this step, the research object of fault location is first determined, that is, the type and location of the vibration damper in the high-speed train bogie system that needs to be monitored for faults are selected, specifically: The transverse dampers, anti-hunting dampers, and vertical dampers in the high-speed train bogie system are used as the research objects for fault location. Among them, the anti-hunting dampers have four installation positions (left front, left rear, right front, and right rear) (Label1 / 2 / 3 / 4), the transverse dampers have two installation positions (left and right transverse dampers) (Label5 / 6), and the vertical dampers have four installation positions (front left, front right, rear left, and rear right) (Label7 / 8 / 9 / 10), totaling 10 damper fault locations to be located. At the same time, the normal operation state (i.e., healthy state Label0) when no fault occurs in any of the damper installation positions is obtained. The purpose is that fault diagnosis tasks require one or more healthy states because in actual operation, healthy state data is always much more abundant than fault data. Therefore, fault diagnosis tasks cannot ignore this state. If a fault diagnosis model can only detect fault modes but cannot identify the majority of healthy state data, then the model is meaningless.
[0014] Secondly, the original sensor monitoring channels were optimized to enhance the ability to perceive the operating status of various vibration dampers in a more refined manner, specifically as follows: (1) Collect configuration information of existing sensor monitoring channels in the high-speed train bogie system, including sensor type, installation location, measurement direction, sampling frequency and other attribute information.
[0015] (2) Based on the spatial distribution characteristics and fault propagation mechanism of various vibration dampers, the original P sensor monitoring channels in the high-speed train bogie system are optimized, reorganized and expanded to construct a new Q sensor monitoring channel. The specific optimization principles include: eliminating channels that are weakly correlated with the vibration damper status, adding vertical and lateral acceleration monitoring channels for lateral vibration dampers (LDs) and primary vertical vibration dampers (PVDs), and expanding the monitoring channels for anti-hunting vibration dampers (ADs) from 2 to multiple dimensions (i.e., x / y / z three axes) to ensure that each vibration damper position is covered by a corresponding sensor monitoring channel.
[0016] In this invention, the selected high-speed train bogie system has 58 sensor monitoring channels (Ch1, Ch2, ..., Ch58). After optimization using the method proposed in this invention, 80 new sensor monitoring channels (Ch1, Ch2, ..., Ch80) are generated. In summary, by analyzing the installation location of each sensor and its sensitivity to vibration damper failures, this invention shifts the monitoring focus from global status monitoring to specific monitoring of three types of vibration dampers, generating an optimized monitoring strategy with 80 sensor monitoring channels.
[0017] Step 2: Based on the optimized sensor channel, collect vibration signals of various vibration dampers at different locations, and input them into the adaptive residual noise reduction module for noise reduction to generate the noise-reduced vibration signal.
[0018] This step involves collecting vibration signal data from the high-speed train bogie dampers and then using an adaptive residual noise reduction module for noise suppression. The structure and connection relationships of the adaptive residual noise reduction module are as follows: Figure 2 As shown, it includes a first convolutional module, a second convolutional module, a global average pooling layer (GAP), a max pooling layer (MP), a first fully connected layer (FC1), a second fully connected layer (FC2), a third fully connected layer (FC3), a fourth fully connected layer (FC4), and a fifth fully connected layer (FC5). Both the first and second convolutional modules include a convolutional layer (Conv), a batch normalization layer (BN), and a ReLU activation function layer (ReLU).
[0019] Therefore, based on the above adaptive residual noise reduction module structure, the process of denoising the vibration signals of various vibration dampers at different locations is as follows: (1) Obtain vibration signals of various vibration dampers at different locations; In this invention, based on the measured track spectrum of the Wuhan-Guangzhou high-speed railway (the "track condition information map" measured by the inspection vehicle from the actual railway), a vehicle dynamics simulation model of a selected high-speed train model is established using SIMPACK software to simulate and collect vibration signal data of different positions of different shock absorbers at specific operating speeds. Considering that the train has a critical speed limit after the shock absorber fails, in order to ensure the effectiveness of the simulation, the operating speed is uniformly set to 210 km / h. The sampling frequency is set to 243 Hz, which is based on the characteristic that the vibration signal of the high-speed train bogie is mainly concentrated in [0, 60] Hz. According to the Nyquist sampling theorem and taking into account the equipment parameters and test requirements, the integrity of the signal acquisition is ensured. The sampling duration is 205 seconds. After removing the interference of the first 5 seconds of start-up pulse, 200 seconds of valid data are retained for analysis. This duration is determined based on 30,000 meters of track spectrum data, taking into account the computing resources and experimental requirements.
[0020] (2) Input the collected vibration signal into the adaptive residual noise reduction module (ARNRM) for noise reduction processing; In this invention, vibration signals collected at several time points are first sequentially input into the first convolutional module, the second convolutional module's convolutional layer, the batch normalization layer, and the ReLU activation function layer of the adaptive residual module to extract high-dimensional features. Next, the high-dimensional features are input into a global average pooling layer and a max pooling layer to generate global and local features (one-dimensional vectors). Then, the global features are sequentially input into a first fully connected layer and a second fully connected layer to generate a global feature threshold. Simultaneously, the local features are sequentially input into a third and a fourth fully connected layer to generate local feature thresholds. Then, the global and local feature thresholds are concatenated and input into a fifth fully connected layer to generate a fused feature threshold. Finally, the fused feature threshold is added to the vibration signal to generate the denoised vibration signal.
[0021] In this step, adding the fused feature threshold to the vibration signal aims to ensure the stability of the output dimension; furthermore, the denoised output vibration signal is a low signal-to-noise ratio vibration signal consistent with the original input dimension. Meanwhile, in Figure 2 middle, The sample size of the input data. , These represent the length and width of each sample, respectively.
[0022] Step 3: Based on the denoised vibration signal, divide the samples into known and unknown fault location categories. At the same time, fit the samples of the known fault location category to generate transitional samples of the unknown fault location category, and construct the training set and test set.
[0023] This step involves classifying known fault locations into known fault location categories and unknown fault location categories, and then performing fitting enhancement on the samples of the unknown fault location category. Specifically: From the denoised vibration signal, one location is randomly selected from each type of vibration damper fault and designated as the unknown fault location category to construct a test set. Among them, the test set The label for the category of unknown fault location is represented as follows: .
[0024] Meanwhile, the remaining locations excluding unknown fault location categories and normal state locations are used as known fault location categories to construct the initial training set. The initial training set The label for the known fault location category is represented as follows: .
[0025] Based on the symmetrical layout characteristics of the bogie structure, transitional samples for unknown fault location categories are generated by fitting samples with known fault location categories.
[0026] In the formula, For the first Transitional samples of unknown fault location categories; This represents the total number of known fault location categories. This represents the total number of unknown fault location categories. For the first The polynomial fitting coefficients for samples of known fault location categories; For the first A sample of known fault location categories.
[0027] In this step, samples of unknown fault location categories are fitted and enhanced using samples of known fault location categories. Specifically, for each unknown fault location category, the aforementioned polynomial fitting formula is used to generate transitional samples corresponding to that unknown fault location category based on samples of known fault location categories. Among them, transitional samples The label for the category of unknown fault location is represented as follows:
[0028] Transitional samples are added to the initial training set to generate the final training set.
[0029] In this invention, each set of experiments includes 3 unknown fault locations and 8 known fault locations (including normal state). The final test set has 600 test samples and the training set has 1600 training samples.
[0030] Step 4: Based on the spatial distribution characteristics of the vibration damper fault locations, construct a semantic description matrix containing several attributes.
[0031] Specifically, the attributes of the semantic description matrix include whether it is a fault-free normal state, whether it is a fault on the left side of the anti-hunting damper, whether it is a fault on the right side of the anti-hunting damper, whether it is a fault on the upper part of the anti-hunting damper, whether it is a fault on the lower part of the anti-hunting damper, whether it is a fault at the front end of the lateral damper, whether it is a fault at the rear end of the lateral damper, whether it is a fault near the front wheel of the vertical damper, whether it is a fault near the rear wheel of the vertical damper, whether it is a fault near the left wheel of the vertical damper, and whether it is a fault near the right wheel of the vertical damper.
[0032] In this step, the purpose of constructing the semantic description matrix is to facilitate the subsequent steps in building the mapping relationship between fault location categories (labels) and attribute vectors. That is, for each fault location category (whether it is a known fault participating in training or an unknown fault not participating in training), a unique 11-dimensional attribute vector is generated using the semantic description matrix based on its spatial distribution characteristics, serving as the prototype representation of this type of fault in the semantic space. In this way, all fault location categories (including known and unknown) are uniformly mapped to the same semantic attribute space, enabling the Transformer model to learn the association between vibration signals and attribute vectors during the training phase, and to achieve fault diagnosis under zero-sample conditions by comparing the similarity between the attribute vectors corresponding to the test samples and the prototype attribute vectors of each unknown fault category during the testing phase.
[0033] Step 5: For each attribute in the semantic description matrix, construct an independent Transformer model and train it by inputting the training set into the corresponding Transformer model to learn the mapping relationship between the data and the corresponding attribute. At the same time, introduce an imbalanced loss function to optimize the model parameters, and finally generate a set of mapping functions from data to attributes and a set of attribute vectors for each training sample.
[0034] In this step, the structure and connections of the Transformer model are as follows: Figure 2 As shown, it includes a position encoding module, several cascaded encoders, and several cascaded decoders; each encoder includes a first self-attention module and a first feedforward network module; each decoder includes a second self-attention module, an encoder-decoder self-attention module, and a second feedforward network module.
[0035] Therefore, based on this structure, an independent Transformer model is constructed for each attribute in the semantic description matrix, and the corresponding Transformer model is trained by inputting the training set to learn the mapping relationship between data and corresponding attributes. At the same time, an imbalanced loss function is introduced to optimize the model parameters. The process of finally generating the set of mapping functions from data to attributes and the set of attribute vectors for each training sample is as follows: Each attribute and each training sample in the training set are input into the position encoding module of the corresponding Transformer model, which maps them into a sequence of feature vectors with position information.
[0036] In the position encoding module, this step first converts each time step or feature value of the input data into a dense vector representation (i.e., embedding the temporal features of the vibration signal into vectors), and then adds temporal position information to generate a sequence of feature vectors with position information. Since the self-attention mechanism itself does not contain a concept of order, introducing position encoding allows the Transformer model to perceive the sequential order of the vibration signals on the time axis, facilitating the Transformer model's capture of the temporal evolution of the vibration signals. Figure 2 middle, , , , They are respectively the 1st, 2nd, 3rd, and 4th. Each attribute serves as auxiliary information and is used to train the Transformer model corresponding to each training sample in the training set.
[0037] The feature vector sequence is sequentially input into each encoder. In the first self-attention module of each encoder, a multi-head self-attention mechanism is used to capture the global dependencies between different positions of the input data. After generating the output features of the first self-attention module, it is input into the first feedforward network module connected to it. By performing independent nonlinear transformations on the vectors at each time step, high-level fault or state features are extracted, and finally the output features of the last encoder are obtained.
[0038] In this step, the first self-attention module of each encoder receives input data with positional information from the previous module connected to it. Then, a multi-head self-attention mechanism is adopted, allowing the vibration features of each time step to simultaneously focus on the features of all other time steps in the entire vibration signal sequence, achieving bidirectional contextual understanding, capturing long-distance temporal dependencies and pattern features in the vibration signal, and inputting its output features into the first feedforward network module connected to it. The second feedforward network module independently performs nonlinear transformation on the vector of each time step, first expanding its dimension and then compressing it back to the original dimension, thereby performing deep feature abstraction and processing on the vibration features aggregated by self-attention, extracting higher-level fault or state features, and enhancing the model's ability to express complex vibration modes. Finally, after stacking multiple encoders, the output features of the last encoder contain the deep feature information of the entire vibration signal sequence (corresponding to the vibration signal of each training sample in the training set), and are passed as key vectors and value vectors to the first decoder.
[0039] The output features of the last encoder are sequentially input into each decoder. In the second self-attention module of each decoder, a causal mask is used to ensure that each position pays attention to the current and historically generated positions. After generating the output features of the second self-attention module, it is input into the encoder-decoder self-attention module connected to it. The output features of the second self-attention module connected to it are used as the query vector, and the output features of the previous module connected to the decoder are used as the key vector and value vector. The most discriminative feature fragments in the vibration signal are extracted to generate the output features of the encoder-decoder self-attention module.
[0040] This step utilizes the second self-attention module (a masked multi-head self-attention module) of the first decoder to receive the output features of the last encoder. Causal masking ensures that each position can only focus on the current and previously generated positions, maintaining the causal consistency of the autoregressive generation. Then, the output features of the second self-attention module are input into the encoder-decoder self-attention module connected to it. The output features of the second self-attention module are used as the query vector, and the output features of the last encoder are used as the key and value vectors. This allows the first decoder to dynamically align and extract the most discriminative feature segments in the vibration signal when generating class predictions, thereby realizing information interaction between the input signal and the output class.
[0041] The output features of the encoder-decoder self-attention module are input into the second feedforward network module connected to it. Through position-level nonlinear transformation, the output features of the second feedforward network module are generated. Finally, the output features of the last decoder are transformed using the Softmax function to obtain the probability distribution of each training sample, which is the set of attribute vectors of each training sample.
[0042] In this step, the output features of the encoder-decoder self-attention module are input into the second feedforward network module connected to it. The second feedforward network module performs independent position-level nonlinear transformation and refinement on the vector that integrates category history information and vibration signal features, further refining the features most relevant to the classification decision. Finally, after being stacked through multiple layers of decoders, the output features of the last decoder are the score vector of the category attribute, which is then converted into a probability distribution by the SoftMax function. This probability distribution is the set of attribute vectors of each training sample.
[0043] Construct an unbalanced loss function and use it to optimize the model parameters to generate several trained Transformer models, thus obtaining a set of data-to-attribute mapping functions and a set of attribute vectors for each training sample.
[0044] In this step, the formula for calculating the unbalanced loss function is:
[0045] In the formula, This represents the value of the non-equilibrium loss function. The raw scores for each fault location category predicted by the model, i.e., the output features of the last decoder; The actual fault location category label; For the weight tensor of the fault location category; It is a logarithmic function; It is an exponential function; To determine the total number of fault categories in the training set, This is the traversal index for the fault category.
[0046] The unbalanced loss function in this step is the cross-entropy loss function that introduces class weights. Compared with the traditional loss function, this unbalanced loss function can guide the model to focus on the minority class during training by assigning higher weights to the unknown fault location class with fewer samples, thereby improving the ability to identify the unknown fault location class.
[0047] Finally, the model parameters are backpropagated using an imbalanced loss function. After multiple iterations, the set of mapping functions from data to attributes is obtained as follows:
[0048] In the formula, It is a set of mapping functions from data to attributes, determined by the parameters of the trained Transformer model, used to map the characteristics of the input vibration signal of the shock absorber into the attribute vector of the corresponding fault location category; The total number of attributes; , , They are the 1st, 2nd, and 3rd respectively. The mapping function corresponding to each attribute is used to map the input data to the corresponding attribute space.
[0049] Based on the above set of mapping functions, by inputting each training sample of the training set into this set of mapping functions, we can obtain the attribute vector set of each training sample, as shown below:
[0050] In the formula, The set of attribute vectors corresponding to the training samples; These are training samples.
[0051] Furthermore, the Transformer model used in this invention has an encoder layer of 1, an embedding dimension of 80, an attention head of 4 in the first and second self-attention modules, a dimension of 128 in the first and second feedforward network modules, and a dropout ratio of 0.1; and the position encoding module adopts sine and cosine function forms, enabling the model to learn the relative positional relationships of different time steps in the input sequence.
[0052] Step 6: Pair the attribute vector sets of each training sample with the corresponding fault location category labels, input them into the KNN classifier for training, construct the feature space index, and generate the trained KNN model.
[0053] This step first involves matching the attribute vector set corresponding to each training sample with its corresponding fault location category label. To form paired samples, that is: Then, all paired samples are used as training data to input into the KNN classifier. The KNN classifier does not require an explicit parameter learning process. Its core is to construct the feature space index of the training set attribute vectors, store the attribute vector set of all training samples and their corresponding fault location category labels, and obtain the trained KNN model.
[0054] Finally, in the inference stage, based on the trained KNN model, Euclidean distance or cosine similarity is used as the metric to calculate the Euclidean distance or cosine similarity between the attribute vector set of the test sample and the attribute vector set of all training samples. The fault location categories of the K training samples with the smallest Euclidean distance or the highest similarity are selected. Through the majority voting principle, the fault location category with the most votes is taken as the fault location result of the test sample, thereby achieving accurate location under no-fault conditions.
[0055] Based on the above principles, the training of a KNN classifier from the attribute space to the label space can be completed, thereby obtaining a set of mapping functions from attributes to labels. This set of mapping functions searches for the K nearest neighbor samples in the training set based on the input attribute vector set, and outputs the final fault category label through a majority voting mechanism. Thus, the complete end-to-end mapping function from data to attribute space and then to label space is represented as follows:
[0056] In the formula, This is an end-to-end mapping function used to realize the original vibration signal data. A complete mapping to the final failure location category label; This is the original vibration signal data; This is a set of mapping functions from attributes to labels (corresponding to a trained KNN classifier). This is a set of mapping functions from data to attributes (corresponding to a trained Transformer model).
[0057] Step 7: Input each test sample in the test set into the mapping function set to obtain the attribute vector set for each test sample. Then, input this set into the trained KNN model for inference to generate the fault location result for each test sample. Specifically: Each test sample in the test set is input into a set of mapping functions to obtain a set of attribute vectors for each test sample.
[0058] Input the attribute vector set of each test sample into the trained KNN model, and calculate the Euclidean distance or cosine similarity between the attribute vector set of each test sample and the attribute vector set of all training samples.
[0059] Select the fault location categories corresponding to the K training samples with the smallest Euclidean distance or the highest similarity, and use the majority voting principle to select the fault location category with the most votes as the fault location result of the test sample.
[0060] In this step, the reasoning process does not require predefined fault prototype attribute vectors. It makes decisions entirely based on the attribute distribution of real samples in the training set, which can effectively adapt to the unseen fault conditions in zero-sample fault location scenarios.
[0061] In summary, the zero-shot fault localization method for mechanical systems based on unbalanced Transformer proposed in this invention achieves accurate fault location identification under the condition that no fault location category samples are used in the training, as demonstrated below: 1. By constructing a semantic attribute space, fault location information is transformed into a transferable semantic representation, establishing a progressive mapping path from data to attributes to labels. This solves the fundamental problem that traditional deep learning methods cannot be applied to scenarios with scarce fault data due to their reliance on a large number of labeled samples. Furthermore, this invention, for the first time, deeply couples zero-shot learning methods with fault location identification tasks, taking into account the symmetrical structure and complex spatial distribution of bogie shock absorbers. In the case where there are no training samples at the target fault location, it improves the average identification accuracy and provides a practical technical solution for intelligent operation and maintenance of high-speed trains.
[0062] 2. This invention systematically optimizes the sensor monitoring channel configuration, improving the precision of fault location from the data source. Addressing the issue of insufficient monitoring granularity for lateral, anti-hunting, and vertical dampers in existing systems, this invention redesigns the original sensor monitoring channels, generating an optimized signal acquisition strategy with 80 sensor monitoring channels. Furthermore, the monitoring channels for anti-hunting dampers are expanded from two to multi-dimensional coverage, ensuring that each damper location has a corresponding sensor monitoring channel. This optimization effectively separates fault features from previously difficult-to-distinguish adjacent locations, providing high-quality input data for the Transformer model's self-attention mechanism, significantly improving the model's spatial location identification ability. Moreover, the optimized monitoring strategy significantly reduces the misjudgment rate of the model in the anti-hunting damper fault location task.
[0063] 3. The Adaptive Residual Noise Reduction Module (ARNRM) designed in this invention achieves effective enhancement and robust extraction of fault features in high-noise environments. Since measured orbital spectrum data contains significant orbital irregularities and noise, traditional noise reduction methods struggle to retain weak fault features while suppressing noise. The ARNRM module proposed in this invention extracts global and local features through global average pooling and max pooling operations, dynamically calculates adaptive thresholds, and utilizes residual structures (residual connections) to ensure output dimension stability. This mechanism enables the module to automatically adjust the noise reduction intensity based on the noise level of the input signal, effectively suppressing background noise while preserving fault impulse features.
[0064] 4. This invention introduces a multi-head self-attention mechanism into the Transformer model, enabling deep modeling of global dependencies in vibration signals. The fault response of bogie dampers exhibits complex characteristics such as multi-source excitation coupling, long-term time-history dependence, and inter-channel spatial correlation. Traditional convolutional neural networks (CNNs) and recurrent neural networks (RNNs) struggle to effectively capture the long-range relationships of fault propagation across multiple structural components. This invention utilizes the Transformer's self-attention mechanism, allowing the model to establish direct interactions between any time step and any channel within a single layer, explicitly modeling the cross-component propagation path of the fault response. The multi-head attention mechanism allows the model to learn various types of heterogeneous features in parallel across different subspaces (such as low-frequency energy distribution, impulse response waveforms, inter-channel phase relationships, and temporal envelope features), forming a complete description of the semantic attributes of the fault location through feature fusion. This global modeling capability enables the model to extract more discriminative fault features from vibration sequences, providing strong feature support for zero-shot learning.
[0065] 5. This invention utilizes the structural symmetry of the bogie to propose a data augmentation strategy based on fitting samples from known locations to samples from unknown locations, effectively solving the problem of missing samples in zero-shot learning. The bogie dampers adopt a symmetrical layout design, with dampers of the same type exhibiting similar functional structures and vibration response modes at different installation positions. This invention fully leverages this prior structural knowledge, generating transitional samples for unknown locations from fault samples at known locations through polynomial fitting, providing learnable intermediate states for the Transformer model. This strategy allows the model to "see" approximate samples at unknown locations during training, thereby achieving more accurate generalization to true unknown locations during the testing phase.
[0066] 6. This invention introduces an imbalanced loss function to alleviate the sample imbalance problem between known and unknown classes at the class weight level. In zero-shot learning methods, the number of known fault class samples is far greater than that of unknown classes. If a traditional loss function is used, the model will naturally favor the majority class during training, leading to a decrease in the ability to identify unknown classes. This invention introduces a class weight tensor into the cross-entropy loss function, giving higher attention to the unknown fault class with fewer samples, and guiding the model to balance the learning intensity of each class during training.
[0067] 7. This invention also achieves a complete technical closed loop from data acquisition, noise reduction, sample fitting, model training to fault reasoning, possessing good replicability and engineering promotion value. This method is not only specifically designed for fault location tasks of high-speed train bogie vibration dampers, but its core ideas include semantic attribute space construction, symmetrical structure fitting, adaptive noise reduction, Transformer global modeling, and non-equilibrium loss, which can be extended to fault diagnosis scenarios of key components in other high-end equipment. Especially for mechanical systems with structural symmetry, scarce fault samples, and complex monitoring environments, this invention provides a systematic technical solution. Compared with existing methods, this invention has significant advantages in technical integrity, module replaceability, and scenario adaptability, and can provide important reference for intelligent operation and maintenance research and practice in fields such as rail transit, aerospace, and energy equipment.
[0068] 8. This invention introduces a position encoding mechanism into the Transformer model, endowing it with the ability to perceive the temporal position and spatial symmetry of vibration signals. Through absolute position encoding in the form of sine and cosine functions, the model can learn the relative positional relationships at different time steps in the input sequence. Simultaneously, due to the linear transformation characteristics of the sine function, symmetrical positions exhibit a deterministic mapping relationship in the encoding space, providing mathematically learnable conditions for utilizing the bogie's symmetrical structure to "fit unknown positions from known positions." This design enables the Transformer not only to capture dependencies in the temporal dimension but also to implicitly learn prior symmetry in the spatial dimension, further enhancing its generalization ability to unknown fault locations.
[0069] Specific embodiments have been used to illustrate the principles and implementation methods of this invention. The descriptions of the embodiments above are only for the purpose of helping to understand the method and core ideas of this invention. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of this invention. Therefore, the content of this specification should not be construed as a limitation of this invention.
[0070] Those skilled in the art will recognize that the embodiments described herein are intended to help the reader understand the principles of the invention, and should be understood that the scope of protection of the invention is not limited to such specific statements and embodiments. Those skilled in the art can make various other specific modifications and combinations based on the technical teachings disclosed in this invention without departing from the spirit of the invention, and these modifications and combinations are still within the scope of protection of this invention.
Claims
1. A zero-sample fault localization method for mechanical systems based on unbalanced Transformer, characterized in that, Includes the following steps: The type and location of the vibration dampers to be monitored in the high-speed train bogie system are determined. At the same time, the configuration information of the original sensor monitoring channels is obtained. Based on the spatial distribution characteristics of the vibration dampers and the fault propagation mechanism, the original sensor monitoring channels are optimized, reorganized and expanded to generate optimized sensor channels covering all vibration damper locations. Based on the optimized sensor channel, vibration signals of various vibration dampers at different locations are collected and input into the adaptive residual noise reduction module for noise reduction to generate denoised vibration signals. Based on the denoised vibration signal, samples are divided into known and unknown fault location categories. Simultaneously, samples of the known fault location category are fitted to generate transitional samples of the unknown fault location category, and training and test sets are constructed. Based on the spatial distribution characteristics of the vibration damper fault locations, a semantic description matrix containing several attributes is constructed. For each attribute in the semantic description matrix, an independent Transformer model is constructed and trained by inputting the training set into the corresponding Transformer model to learn the mapping relationship between the data and the corresponding attribute. At the same time, an imbalanced loss function is introduced to optimize the model parameters, and finally a set of mapping functions from data to attributes and a set of attribute vectors for each training sample are generated. The attribute vector set of each training sample is paired with the corresponding fault location category label to form a sample. This sample is then input into the KNN classifier for training, a feature space index is constructed, and a trained KNN model is generated. Each test sample in the test set is input into a set of mapping functions to obtain a set of attribute vectors for each test sample. These vectors are then input into a trained KNN model for inference to generate fault location results for each test sample.
2. The zero-sample fault localization method for mechanical systems based on unbalanced Transformer according to claim 1, characterized in that, The configuration information of the original sensor monitoring channel includes the sensor type, installation location, measurement direction, and sampling frequency.
3. The zero-sample fault localization method for mechanical systems based on unbalanced Transformer according to claim 1, characterized in that, Based on the spatial distribution characteristics of the vibration damper and the fault propagation mechanism, the process of optimizing, reorganizing, and expanding the original sensor monitoring channels is as follows: Sensor channels with weak correlation to the status of each damper were removed, and vertical acceleration monitoring channels for lateral dampers and lateral acceleration monitoring channels for a series of vertical dampers were added. At the same time, the sensor monitoring channels for anti-hunting dampers were extended to the x-axis, y-axis, and z-axis.
4. The zero-sample fault localization method for mechanical systems based on unbalanced Transformer according to claim 1, characterized in that, The adaptive residual noise reduction module includes a first convolutional module, a second convolutional module, a global average pooling layer, a max pooling layer, a first fully connected layer, a second fully connected layer, a third fully connected layer, a fourth fully connected layer, and a fifth fully connected layer; Both the first and second convolutional modules include convolutional layers, batch normalization layers, and ReLU activation function layers.
5. The zero-sample fault localization method for mechanical systems based on unbalanced Transformer according to claim 4, characterized in that, The process of collecting vibration signals from various vibration dampers at different locations and inputting them into an adaptive residual noise reduction module for denoising to generate the denoised vibration signal is as follows: The vibration signal is sequentially input into the first convolutional module, the second convolutional module's convolutional layer, the batch normalization layer, and the ReLU activation function layer of the adaptive residual module to extract high-dimensional features; High-dimensional features are input into the global average pooling layer and the max pooling layer respectively to generate global features and local features; The global features are sequentially input into the first fully connected layer and the second fully connected layer to generate the global feature threshold. Local features are sequentially input into the third and fourth fully connected layers to generate local feature thresholds. The global feature threshold and the local feature threshold are concatenated and then input into the fifth fully connected layer to generate the fused feature threshold. Finally, the fused feature thresholds are added to the vibration signal to generate the denoised vibration signal.
6. The zero-sample fault localization method for mechanical systems based on unbalanced Transformer according to claim 1, characterized in that, Based on the denoised vibration signal, samples are divided into known and unknown fault location categories. Simultaneously, samples of the known fault location category are fitted to generate transitional samples of the unknown fault location category. The process of constructing the training set and test set is as follows: In the denoised vibration signal, one location is randomly selected from each type of vibration damper fault and used as the unknown fault location category to construct a test set; Meanwhile, the remaining locations other than the unknown fault location category and the normal state locations are used as known fault location categories to construct the initial training set; Based on the symmetrical layout characteristics of the bogie structure, transitional samples for unknown fault location categories are generated by fitting samples with known fault location categories. in, For the first Transitional samples of unknown fault location categories, This represents the total number of known fault location categories. This represents the total number of unknown fault location categories. For the first The polynomial fitting coefficients corresponding to samples of known fault location categories. For the first A sample of known fault location categories; Transitional samples are added to the initial training set to generate the final training set.
7. The zero-sample fault localization method for mechanical systems based on unbalanced Transformer according to claim 1, characterized in that, The attributes of the semantic description matrix include whether it is a fault-free normal state, whether it is a fault on the left side of the anti-hunting damper, whether it is a fault on the right side of the anti-hunting damper, whether it is a fault on the upper part of the anti-hunting damper, whether it is a fault on the lower part of the anti-hunting damper, whether it is a fault at the front end of the lateral damper, whether it is a fault at the rear end of the lateral damper, whether it is a fault near the front wheel of the vertical damper, whether it is a fault near the rear wheel of the vertical damper, whether it is a fault near the left wheel of the vertical damper, and whether it is a fault near the right wheel of the vertical damper.
8. The zero-sample fault localization method for mechanical systems based on unbalanced Transformer according to claim 1, characterized in that, The Transformer model includes a position encoding module, several cascaded encoders, and several cascaded decoders. Each encoder includes a first self-attention module and a first feedforward network module; Each decoder includes a second self-attention module, an encoder-decoder self-attention module, and a second feedforward network module.
9. The zero-sample fault localization method for mechanical systems based on unbalanced Transformer according to claim 8, characterized in that, For each attribute in the semantic description matrix, an independent Transformer model is constructed and trained using the training set as input. This process learns the mapping relationship between data and the corresponding attribute. Simultaneously, an imbalanced loss function is introduced to optimize the model parameters. The final process of generating the set of data-to-attribute mapping functions and the set of attribute vectors for each training sample is as follows: Each attribute and each training sample in the training set are input into the position encoding module of the corresponding Transformer model, which maps them into a sequence of feature vectors with position information. The feature vector sequence is sequentially input into each encoder. In the first self-attention module of each encoder, a multi-head self-attention mechanism is used to capture the global dependencies between different positions of the input data. After generating the output features of the first self-attention module, it is input into the first feedforward network module connected to it. By performing independent nonlinear transformations on the vectors at each time step, high-level fault or state features are extracted, and finally the output features of the last encoder are obtained. The output features of the last encoder are sequentially input into each decoder. In the second self-attention module of each decoder, a causal mask is used to ensure that each position pays attention to the current and historical generated positions. After generating the output features of the second self-attention module, it is input into the encoder-decoder self-attention module connected to it. The output features of the second self-attention module connected to it are used as the query vector, and the output features of the previous module connected to the decoder are used as the key vector and value vector. The most discriminative feature fragments in the vibration signal are extracted to generate the output features of the encoder-decoder self-attention module. The output features of the encoder-decoder self-attention module are input into the second feedforward network module connected to it. The output features of the second feedforward network module are generated through position-level nonlinear transformation. Finally, the output features of the last decoder are transformed using the Softmax function to obtain the probability distribution of each training sample, which is the set of attribute vectors of each training sample. Construct an unbalanced loss function, namely: in, The value of the non-equilibrium loss function. The raw scores for each fault location category predicted by the model; The actual fault location category label, For the weight tensor of the fault location category, It is a logarithmic function. It is an exponential function. To determine the total number of fault categories in the training set, The traversal index for the fault category; The model parameters are optimized using an imbalanced loss function to generate several trained Transformer models, resulting in a set of data-to-attribute mapping functions and a set of attribute vectors for each training sample.
10. The zero-sample fault localization method for mechanical systems based on unbalanced Transformer according to claim 1, characterized in that, The process of inputting each test sample in the test set into a mapping function set to obtain the attribute vector set for each test sample, and then inputting it into a trained KNN model for inference to generate the fault location result for each test sample is as follows: Each test sample in the test set is input into a set of mapping functions to obtain a set of attribute vectors for each test sample. Input the attribute vector set of each test sample into the trained KNN model, and calculate the Euclidean distance or cosine similarity between the attribute vector set of each test sample and the attribute vector set of all training samples. Select the fault location categories corresponding to the K training samples with the smallest Euclidean distance or the highest similarity, and use the majority voting principle to select the fault location category with the most votes as the fault location result of the test sample.