A method for predicting maintenance cycle of smart elevators based on decomposition-autocorrelation and Wavelet
By using decomposition-autocorrelation and Wavelet methods in elevator maintenance prediction, long-term trends, seasonality and high-frequency characteristics in elevator operation data are extracted, and the problems of low prediction accuracy and difficult response to emergencies in the existing technology are solved, achieving more efficient and accurate elevator maintenance cycle prediction.
Patent Information
- Application Number
- CN202510066229.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-16
- Publication Date
- 2025-05-16
- Estimated Expiration
- 2045-01-16
AI Technical Summary
The existing elevator maintenance prediction methods lack the full consideration of the characteristics of complex time series and the relationship between factors, resulting in low accuracy of prediction results, especially in the face of emergencies, which is difficult to effectively identify and respond to emergencies.
Using a decomposition-autocorrelation and Wavelet-based method, long-term trends and seasonal characteristics in elevator operation data are extracted through the autocorrelation mechanism and decomposition module, and high-frequency parts (emergency events) are extracted using Wavelet wavelet transform, which is combined with trends and seasonal components to predict the elevator maintenance cycle.
It improves the ability to capture the characteristics of complex time series and relationships between factors, enhances the response ability and prediction accuracy to emergencies, and can predict elevator maintenance needs more scientifically.
Smart Images

Figure CN119476747B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to elevator fault warning technology, and in particular to a smart elevator maintenance cycle prediction method based on decomposition-autocorrelation and Wavelet. Background Art
[0002] With the continuous development of intelligent technology, the operation and maintenance management of elevators is gradually moving towards digitalization and automation. Traditional elevator maintenance methods often rely on manual experience and regular maintenance, lacking scientific prediction methods and effective cycle management, which not only increases the risk of elevator failures, but also leads to low maintenance costs and efficiency. In order to improve the scientificity and accuracy of elevator operation and maintenance management, intelligent maintenance systems based on data analysis have gradually attracted attention and application. With the development of the Internet of Things, cloud computing and big data technologies, the elevator industry has begun to rely on historical data of elevators to build prediction models, thereby realizing intelligent and automated maintenance cycle prediction. This type of intelligent maintenance system usually involves data collection, processing and analysis, which can monitor the operating status of the elevator in real time, identify potential faults, and predict future maintenance needs in advance.
[0003] There are two main defects in existing technologies: 1) Traditional elevator maintenance prediction methods mostly rely on rule-based models or simple statistical analysis methods, and lack sufficient consideration of the complex time series characteristics of the elevator operation process. These methods often cannot effectively capture the long-term trends, seasonal fluctuations and complex relationships between various factors in the elevator historical data, resulting in low accuracy of the prediction results; 2) Existing technologies usually attempt to mine dependencies in data at different granularities, but when faced with emergencies in elevator operation, traditional algorithms often find it difficult to effectively identify and respond to the impact of these events. The impact of emergencies on elevator failures and maintenance needs is significant, and the neglect of traditional methods makes the prediction results unable to accurately reflect the actual situation. Summary of the invention
[0004] In order to overcome the shortcomings of the prior art, the present invention provides a smart elevator maintenance cycle prediction method based on decomposition-autocorrelation and Wavelet.
[0005] In order to achieve the above object, the present invention provides a method for predicting the maintenance cycle of an intelligent elevator based on decomposition-autocorrelation and Wavelet, and the specific steps include:
[0006] S1: Collect and store the original data of IoT elevators according to time, and normalize the original data;
[0007] S2: Divide each feature after normalization into equal frequency bins to construct a frequency table of elevator failures; obtain the P value through the chi-square test frequency table, compare the P value with the significance level α, determine the correlation between the feature and the category label, and screen out features with low correlation;
[0008] S3: Divide the original data into samples, datasets, training sets, validation sets, and test sets;
[0009] S4: Use the Embedding layer to encode the input features of the dataset and convert the input features into a low-dimensional, dense time series ;
[0010] S5: Convert time series Input into a multi-layer encoder containing a decomposition module and an autocorrelation mechanism to extract the trend and seasonality characteristics of the time series and obtain the encoder output ;
[0011] S6: Apply Wavelet transform from the input vector Analyze emergencies and extract high-frequency parts of data ; Output the encoder With high frequency part Fusion to obtain fusion features ;
[0012] S7: Fusion features Input into the multi-layer perceptron, through multiple fully connected layers and nonlinear layers, through The activation function generates the binary label probability for each time step and obtains the output ; That is, the model predicted probability;
[0013] S8: Calculate the predicted probability using the loss function With the actual label The binary cross entropy between them uses the optimizer to perform backpropagation and update the model parameters;
[0014] S9: training and validating the prediction model to obtain the final prediction model;
[0015] S10: The prediction of multiple future time periods is set as a multi-label classification task, and the final prediction model is used to predict the elevator maintenance cycle.
[0016] Preferably, in step S4, the specific step of encoding the input features of the data set includes:
[0017] S4.1: Input features Divide into categories according to type and continuous features , where l is the length of the time series, d is the number of original features, m is the number of categorical features, n is the number of continuous features, and ;
[0018] S4.2: Construct the embedding matrix of category feature C , is the number of category features, is the embedded dimension and the weights are randomly initialized:
[0019] ,
[0020] in, represents a normal distribution, is the standard deviation of the distribution;
[0021] S4.3: Categorical features With the embedding matrix Multiply to obtain the category feature vector :
[0022] ,
[0023] in, , is the embedding dimension, which is a hyperparameter that needs to be adjusted;
[0024] S4.4: Convert continuous features Normalize and obtain :
[0025] ,
[0026] in, is the normalized continuous eigenvector, is the normalization function;
[0027] S4.5: Embedded category feature vector and the normalized continuous feature vector Splicing to form a unified low-dimensional, dense time series :
[0028] ,
[0029] in, , is the time step, is the concatenated feature dimension.
[0030] Preferably, in step S4.4, The specific implementation of the function is Z-Score standardization:
[0031] ,
[0032] in, is the input feature, For input features The mean of For input features The standard deviation of .
[0033] Preferably, in step S5, the encoder output is obtained by decomposing the module and the autocorrelation mechanism The specific steps include:
[0034] S5.1: The original sequence is input into the decomposition module, and the decomposition module performs the following steps:
[0035] Use the moving average operation to calculate the concatenated time series Smoothing, removing high-frequency fluctuations, and obtaining trend components :
[0036] ,
[0037] in, is the moving average operation, is the trend component;
[0038] S5.2: Using the original time series Subtract the trend component , to obtain the seasonal component :
[0039] ,
[0040] in, is the seasonal component, used to capture periodic fluctuations;
[0041] S5.3: Use autocorrelation mechanisms to handle seasonal components:
[0042] ,
[0043] in, For the processed seasonal components, is the autocorrelation mechanism function;
[0044] S5.4: Use linear projection to handle trend components:
[0045] ,
[0046] in, is the trend component after projection, is a linear projection.
[0047] S5.5: Re-fuse the features of the two and output the global features after stacking multiple layers of encoders ;
[0048] ,
[0049] ,
[0050] in, Indicates that and After fusion, Represents the final output after passing through multiple layers of encoders; For a multi-layer encoder, this is accomplished by repeating steps S5.1 to S5.5 multiple times.
[0051] Preferably, in step S5.1, the moving average operation The specific steps include:
[0052] S5.1.1: For input time series , in dimension Apply zero padding on the dimension unchanged in time series The top and bottom padding Rows with all zero time steps:
[0053] ,
[0054] in, is the number of rows to be filled. is the sliding window size, the padded input vector ;
[0055] S5.1.2: For the input vector , the trend component is calculated using the following formula:
[0056] ,
[0057] in, Represents trend component No. time steps, Indicates the first values, is the sliding window size.
[0058] Preferably, in step S5.3, the specific steps of the autocorrelation mechanism include:
[0059] S5.3.1: Calculate seasonal components The autocorrelation function of is as follows:
[0060] ,
[0061] in, is the autocorrelation function, which indicates the similarity of time series under time lag; is the length of the sequence, i.e. the total step length, Indicates time steps, is the time lag, which represents the interval between two time points;
[0062] S5.3.2: Calculate different time lags The autocorrelation function of , select the largest The lag time corresponding to the autocorrelation value is:
[0063] ,
[0064] in, For the The lag time corresponding to the large autocorrelation value is To get the maximum The function of the lag time corresponding to the autocorrelation value;
[0065] S5.3.3: Seasonal components Perform a rolling operation to align corresponding subsequences according to the selected time delay:
[0066] ,
[0067] in, This is a rolling operation, which means that the seasonal component Moving forward step;
[0068] S5.3.4: For each scrolled subsequence , according to its autocorrelation value Perform weighted aggregation operation. The formula for weighted aggregation is:
[0069] ,
[0070] in, is the seasonal component after being processed by the autocorrelation mechanism, is the selected lag time number.
[0071] Preferably, in step S5.4, linear projection is performed The specific steps include:
[0072] S5.4.1: Randomly initialize a projection matrix to be learned , control it to conform to the distribution:
[0073] ,
[0074] in, is a standard normal distribution.
[0075] S5.4.2: Perform matrix multiplication and project the input:
[0076] ,
[0077] in, is the trend component after projection, It is the original trend component.
[0078] Preferably, in step S6, the high frequency part of the data is extracted The encoder output With high frequency part The specific steps for fusion include:
[0079] S6.1: Use discrete wavelet transform to decompose the input time series into low-frequency and high-frequency components of different scales:
[0080] For a given input , ,in, Represents the time series corresponding to each feature, and uses Wavelet transformation to transform each Decomposed into low-frequency coefficients and high-frequency coefficients, the formula is:
[0081] ,
[0082] in, for The wavelet decomposition result is: represents the wavelet transform function;
[0083] S6.2: Wavelet decomposition results Extract the high frequency part :
[0084] ,
[0085] in, To extract high frequency function;
[0086] S6.3: Extract the high frequency part Perform inverse wavelet transform to obtain a sequence that is consistent with the input sequence Sequences of the same shape :
[0087] ,
[0088] in, is the inverse wavelet transform;
[0089] S6.4: Input vector Every After processing, reassemble and get the output ;
[0090] S6.5: Output the encoder With high frequency part Fusion to obtain fusion features :
[0091] .
[0092] Preferably, the wavelet transform function in step S6 use In the package Function completed.
[0093] Preferably, in step S7, the fusion feature Input to the multilayer perceptron to get the output The specific steps include:
[0094] S7.1: Fusion features Input into the multi-layer perceptron, pass through the first fully connected layer, and map to the hidden dimension ,Right now:
[0095] ,
[0096] in, represents the output of the first layer, represents the first layer weight matrix, represents the first layer bias, Represents a nonlinear activation function, which is used to introduce nonlinear features;
[0097] S7.2: The output of the first layer It is passed to the subsequent fully connected layers in sequence to gradually learn the features, namely:
[0098] ,
[0099] in, Indicates The output of the layer, Indicates The output of the layer, Indicates The layer weight matrix, Indicates Layer bias;
[0100] S7.3: Map features to output dimensions through fully connected layers and through The activation function generates the binary classification probability at each time step:
[0101] ,
[0102] in, Indicates The output of the layer, that is, the output of the second-to-last layer, represents the output layer weight matrix, represents the output layer bias, Represents the classification probability of the corresponding label of the sample in multiple future time steps;
[0103] The formula for the activation function is:
[0104] ,
[0105] in, is the input value, and is applied element by element to the input matrix .
[0106] The invention provides a method for predicting maintenance cycle of intelligent elevators based on decomposition-autocorrelation and Wavelet, which has the following beneficial effects compared with the prior art:
[0107] In order to capture the complex time series characteristics and the relationship between factors, the present invention adopts the autocorrelation mechanism and decomposition module, which can effectively extract the long-term trend and seasonal fluctuation in the elevator operation data.
[0108] In view of the difficulty in dealing with the impact of emergencies, the present invention uses Wavelet transform to extract the high-frequency part (emergency) in the data and combines it with the trend and seasonal components. Through this fusion, the model can not only capture long-term patterns, but also sensitively respond to short-term abnormal fluctuations, thereby improving the responsiveness and accuracy of forecasts to emergencies. BRIEF DESCRIPTION OF THE DRAWINGS
[0109] Figure 1 A flowchart of a method for predicting maintenance cycle of an intelligent elevator based on decomposition-autocorrelation and Wavelet provided by the present invention;
[0110] Figure 2 This is a schematic diagram of the original data category information mentioned in an embodiment of the present invention;
[0111] Figure 3 This is a schematic diagram of the steps of data cleaning according to an embodiment of the present invention. DETAILED DESCRIPTION
[0112] The following describes the embodiments of the present invention by specific examples, and those skilled in the art can easily understand other advantages and effects of the present invention from the contents disclosed in this specification. The present invention can also be implemented or applied through other different specific embodiments, and the details in this specification can also be modified or changed in various ways based on different viewpoints and applications without departing from the spirit of the present invention. It should be noted that the following embodiments and features in the embodiments can be combined with each other without conflict.
[0113] like Figure 1 As shown, the present invention provides a smart elevator maintenance cycle prediction method based on decomposition-autocorrelation and Wavelet.
[0114] S1: Collect and store the original data of IoT elevators according to time, and normalize the original data;
[0115] S2: Divide each feature after normalization into equal frequency bins to construct a frequency table of elevator failures; obtain the P value through the chi-square test frequency table, compare the P value with the significance level α, determine the correlation between the feature and the category label, and screen out features with low correlation;
[0116] S3: Divide the original data into samples, datasets, training sets, validation sets, and test sets;
[0117] S4: Use the Embedding layer to encode the input features of the dataset and convert the input features into a low-dimensional, dense time series ;
[0118] S5: Convert time series Input into a multi-layer encoder containing a decomposition module and an autocorrelation mechanism to extract the trend and seasonality characteristics of the time series and obtain the encoder output ;
[0119] S6: Apply Wavelet transform from the input vector Analyze emergencies and extract high-frequency parts of data ; Output the encoder With high frequency part Fusion to obtain fusion features ;
[0120] S7: Fusion features Input into the multi-layer perceptron, through multiple fully connected layers and nonlinear layers, through The activation function generates the binary label probability for each time step and obtains the output ; That is, the model predicted probability;
[0121] S8: Calculate the predicted probability using the loss function With the actual label The binary cross entropy between them uses the optimizer to perform backpropagation and update the model parameters;
[0122] S9: training and validating the prediction model to obtain the final prediction model;
[0123] S10: The prediction of multiple future time periods is set as a multi-label classification task, and the final prediction model is used to predict the elevator maintenance cycle.
[0124] Specifically, the present invention provides a method for predicting the maintenance cycle of an intelligent elevator based on decomposition-autocorrelation and Wavelet. The present invention uses the autocorrelation mechanism and decomposition architecture to capture the characteristics of complex time series and the relationship between factors, and effectively extracts long-term trends and seasonal fluctuations in elevator operation data. In addition, the present invention also uses wavelet transform to extract high-frequency components (mutation events) and combines them with trend and seasonal components. By integrating the two major features, the model can not only capture long-term patterns, but also respond sensitively to short-term abnormal fluctuations, thereby improving the prediction ability and accuracy to respond to emergencies.
[0125] In this embodiment, the collected IoT elevator raw data includes: basic information, fault data, maintenance data, operation data and other raw data. The specific data types are as follows: Figure 2 These data need to be cleaned first to remove noise, outliers, missing items and inconsistencies in the original data. The steps of data cleaning are as follows: Figure 3 As shown. In the deduplication process, duplicate records are removed to ensure that each fault information in the database is unique. Avoid the model from misjudging the fault frequency, resulting in unnecessary maintenance or delayed fault response. When faced with missing data, use appropriate filling methods (such as mean, median, interpolation, etc.) to fill in the missing data. By setting reasonable rules and ranges, identify and correct obvious erroneous data, such as unreasonable installation time, to ensure data consistency and reliability. Then use the Z-score method to identify and process outliers that deviate from the normal range to avoid their negative impact on model analysis and prediction results. After the above processing, the data is standardized (zero mean, unit variance) and normalized (scaled to the range of 0-1) to ensure that different features are compared on the same scale. The relevant data fields after processing are shown in Table 1-4.
[0126]
[0127] Table 1
[0128]
[0129] Table 2
[0130]
[0131] Table 3
[0132]
[0133] Table 4
[0134] Among them, the specific steps of data cleaning data include:
[0135] S1.1: Identify and remove noise data and outliers through the Z-score method, and correct or delete data that are significantly deviated from the normal range.
[0136] S1.2: Use interpolation to fill missing values, or delete the relevant data rows or columns if there are too many missing values.
[0137] S1.3: Unify the formats of different data sources, including date format, numerical units, etc., so that the data can be processed under the same standard.
[0138] Each feature after normalization is binned with equal frequency, and a frequency table related to the elevator fault label is constructed. Then, the correlation between the feature and the category label is evaluated by the chi-square test. The purpose of the chi-square test is to test whether there is a significant statistical association between different categories of features and labels. In this process, the P value needs to be calculated first. The P value indicates the probability of the observed data results appearing under the premise that the null hypothesis is established. Then the P value is compared with the significance level α, which is usually set to 0.05, which means that a maximum of 5% probability of the first type of error is allowed, that is, the null hypothesis is incorrectly rejected. If the P value is less than α, the null hypothesis can be rejected, and it is believed that there is a significant correlation between the feature and the label; if the P value is greater than or equal to α, it indicates that there is no significant correlation between the feature and the label, and the null hypothesis is established. The calculation of the P value can be achieved through the chi2_contingency function in the python library scikitlearn. Through this statistical test process, features that are closely related to the label can be effectively screened out, and features that are weakly associated with the label can be eliminated to reduce the impact of redundant information. When performing feature screening, domain knowledge is also combined to further evaluate features with lower relevance to ensure that the retained features are not only statistically significant but also have explanatory and predictive value in actual business, thereby improving the stability and prediction accuracy of subsequent models.
[0139] In step S3, the relevant elevator data of the past two years are used as samples, and the fault data of the next four and a half months are used as labels to generate a data set, wherein the method for generating the data set is the sliding window method. The data division follows the time order, and each sample corresponds to the data of the elevator in the past two years at the current time point. The number of labels of the sample is 4, corresponding to the fault data of the elevator in the next four and a half months. The training set contains data from the past nine years, the validation set selects data from the last six months for parameter adjustment, and the test set uses data from the next six months to evaluate the model performance.
[0140] In step S4, in order to encode the input features, the input data is converted into a low-dimensional, dense vector representation , the specific conversion steps are:
[0141] S4.1: Input features Divide into categories according to type and continuous features ; where l is the length of the time series, d is the number of original features, m is the number of categorical features, n is the number of continuous features, and .
[0142] S4.2: Constructing an embedding matrix for categorical features , is the number of category features, is the embedded dimension and the weights are randomly initialized:
[0143] ,
[0144] in, represents a normal distribution, is the standard deviation of the distribution. During the training process, the embedding matrix The parameters will be optimized.
[0145] S4.3: Categorical features With the embedding matrix Multiply them together to get the eigenvector :
[0146]
[0147] in, , is the embedding dimension and is a hyperparameter that needs to be adjusted.
[0148] S4.4: Convert continuous features Normalize it and get :
[0149]
[0150] in, is the normalized continuous eigenvector, is the normalization function.
[0151] S4.5: Embedded category feature vector and the normalized continuous feature vector Splicing to form a unified low-dimensional, dense time series :
[0152]
[0153] in ,in, is the time step, is the concatenated feature dimension.
[0154] In step S.4.4, The specific implementation of the function is Z-Score standardization:
[0155]
[0156] in, is the input feature, Features The mean of Features The standard deviation of .
[0157] In this example, the torch.nn.Embedding layer is used to create an embedding matrix for the categorical features, the continuous features are processed using Z-Score normalization, and then the two are concatenated to form a unified low-dimensional dense time series. .
[0158] In step S5, the encoder output is obtained by decomposing the module and the autocorrelation mechanism The specific steps include:
[0159] S5.1: Input the original sequence into the decomposition module. The decomposition module mainly includes two key steps:
[0160] 1) Use moving average (MA) to obtain trend components;
[0161] 2) Subtract the trend component from the original sequence to obtain the seasonal component. Thus, the original sequence is decomposed into the trend component and the seasonal component.
[0162] Use the moving average operation to perform the concatenated time series data samples. Smooth and remove high-frequency fluctuations to obtain trend components .
[0163]
[0164] in, represents the moving average operation, It is the trend component, indicating longer-term stable changes.
[0165] S5.2: Using the original sequence Subtract the trend component Get seasonal ingredients :
[0166]
[0167] in, is the seasonal component, capturing periodic fluctuations.
[0168] S5.3: Use autocorrelation mechanisms to handle seasonal components:
[0169]
[0170] in, For the processed seasonal components, is the autocorrelation mechanism function.
[0171] S5.4: Use linear projection to handle trend components:
[0172]
[0173] in, is the trend component after projection, is a linear projection.
[0174] S5.5: Re-fuse the features of the two and output the global features after stacking multiple layers of encoders .
[0175] ,
[0176] ,
[0177] in, Indicates that and After fusion, represents the final output after passing through multiple layers of encoders, For a multi-layer encoder, this is achieved by repeating steps S5.1 to S5.5 multiple times.
[0178] In step S5.1, the moving average operation The specific steps include:
[0179] S5.1.1: For input time series , in dimension Apply zero padding on the unchanged in time series The top and bottom padding Rows with all zero time steps:
[0180]
[0181] in, is the number of rows to be filled. is the sliding window size, after padding .
[0182] S5.1.2: For the input vector , the trend component is calculated using the following formula:
[0183] ,
[0184] in, Represents trend component No. time steps, Indicates the first values, is the sliding window size.
[0185] In step S5.3, the specific steps of the autocorrelation mechanism include:
[0186] S5.3.1: Calculate seasonal components The autocorrelation function of is as follows:
[0187] ,
[0188] in, is the autocorrelation function, which indicates the similarity of time series under time lag. is the length of the sequence, i.e. the total step length, Indicates time steps, is the time lag, which represents the interval between two time points.
[0189] S5.3.2: Calculate different lags The autocorrelation function of , select the largest The lag time corresponding to the autocorrelation value is:
[0190] ,
[0191] in, For the The lag time corresponding to the large autocorrelation value is To get the maximum The autocorrelation value is a function of the lag time.
[0192] S5.3.3: Seasonal components A rolling operation is performed to align these subsequences according to the selected time delay.
[0193] ,
[0194] in, This is a rolling operation, which means that the seasonal component Moving forward step.
[0195] S5.3.4: For each scrolled subsequence , according to its autocorrelation value Perform weighted aggregation operation. The formula for weighted aggregation is as follows:
[0196] ,
[0197] in, is the seasonal component after being processed by the autocorrelation mechanism, is the selected lag time number.
[0198] In step S5.4, linear projection is performed The specific steps include:
[0199] S5.4.1: Randomly Initialize a Learnable Projection Matrix , so that it conforms to the distribution:
[0200] ,
[0201] in, is a standard normal distribution.
[0202] S5.4.2: Perform matrix multiplication and project the input:
[0203] ,
[0204] in, is the trend component after projection, It is the original trend component.
[0205] In this embodiment, in the entire step S5, the time series data is feature processed and encoded through a series of steps, specifically including: embedding of category features, standardization of continuous features, and decomposition and feature fusion based on autocorrelation mechanism and linear projection. The torch.nn.Embedding layer is used to create an embedding matrix, and the embedding weights are generated by random initialization. These weights are continuously optimized during the training process. The moving average operation uses torch.nn.AvgPool1d to extract the trend component. The autocorrelation mechanism is implemented by using torch.corrcoef, and the trend component is processed by linear projection. A projection matrix that conforms to the standard normal distribution is randomly initialized, and then projected by matrix multiplication.
[0206] In step S6, the high frequency part of the data is extracted The encoder output With high frequency part The specific steps for fusion include:
[0207] S6.1: Use discrete wavelet transform (DWT) to decompose the input time series into low-frequency and high-frequency components of different scales. Specifically, for a given input time series , ,in, Represents the time series corresponding to each feature, and uses Wavelet transformation to transform each Decomposed into low-frequency coefficients and high-frequency coefficients, the wavelet basis here is selected :
[0208] ,
[0209] in, for The wavelet decomposition result is: Represents the wavelet transform function.
[0210] S6.2: Wavelet decomposition results Extract the high frequency part :
[0211] ,
[0212] in, For the high frequency part, is a function for extracting high frequencies.
[0213] S6.3: Extract the high frequency part Perform inverse wavelet transform to obtain a sequence that is consistent with the input sequence Sequences of the same shape :
[0214] ,
[0215] in, is the output sequence, is the inverse wavelet transform function.
[0216] S6.4: Input Every After processing, reassemble and get the output .
[0217] S6.5: Output the encoder With high frequency part Fusion is performed to obtain fusion features , as the input of the subsequent classifier:
[0218] ,
[0219] In step S6.1, the wavelet transform function use In the package Function implementation.
[0220] In step S6.3, the inverse wavelet transform use In the package Function implementation.
[0221] In this embodiment, in step S6, specifically, first, a wavelet transform function is used. Each time series is decomposed into low-frequency and high-frequency components. Then, use The high-frequency coefficients in the result (here in Python, it is the operation of accessing list elements). Then apply the inverse wavelet transform to the high-frequency part Restore its shape to be consistent with the original input sequence.
[0222] In step S7, the fusion feature Input to the multilayer perceptron to get the output The specific steps include:
[0223] S7.1: Fusion features Input into the multi-layer perceptron, pass through the first fully connected layer, and map to the hidden dimension .
[0224] ,
[0225] in, represents the output of the first layer, represents the first layer weight matrix, represents the first layer bias, Represents a nonlinear activation function, which is used to introduce nonlinear features.
[0226] S7.2: The output of the first layer It is passed to the subsequent fully connected layers in sequence to gradually learn more abstract features.
[0227] ,
[0228] in, Indicates The output of the layer, Indicates The output of the layer, Indicates The layer weight matrix, Indicates Layer bias.
[0229] S7.3: Finally, the features are mapped to the output dimension through the fully connected layer and through The activation function generates the binary classification probability at each time step:
[0230] ,
[0231] in, Indicates The output of the layer, that is, the output of the second-to-last layer, represents the output layer weight matrix, represents the output layer bias, Represents the classification probability of the corresponding label of the sample in multiple future time steps.
[0232] In step S7.3, The formula for the activation function is:
[0233] ,
[0234] in, is the input value, and is applied element by element to the input matrix .
[0235] In this embodiment, in step S7, torch.nn.Linear is used to define the fully connected layer of each layer, and torch.relu and torch.sigmoid are used as activation functions to introduce nonlinear features and generate output probabilities. The input and output of each layer will depend on the calculation results of the previous layer, and finally the binary classification probability of each time step is obtained through the Sigmoid activation function.
[0236] In step S8, the loss function used is the BCELoss loss function, and the optimizer is RAdam. BCELoss is suitable for binary classification tasks. By calculating the cross entropy between the model output and the true label, it can effectively evaluate the gap between the predicted probability and the actual label, and help the model optimize the output probability. In the elevator prediction task, the ratio of positive and negative samples is extremely unbalanced. BCELoss can give positive samples a greater weight to prevent the model from ignoring positive samples. The RAdam optimizer combines the advantages of the Adam optimizer, which can automatically adjust the learning rate and improve the instability in the gradient descent process. Especially in the early stage of training, it can effectively avoid the oscillation problem caused by excessive learning rate, and by correcting the adaptive learning rate, it makes the training more stable and avoids the common problem of non-convergence in training.
[0237] In step S9, the training is continued for a maximum of 300 , while monitoring the validation set loss, if the validation loss is in 10 consecutive If there is no improvement within , the training will stop early to prevent overfitting and save training time. At the end, save the parameters of the current best model and terminate training if the validation loss does not improve.
[0238] In step S10, the specific steps of using the optimal model to predict the maintenance cycle of the smart elevator include:
[0239] S10.1: Input the data to be predicted into the best model to obtain the model's predictions for multiple future time periods.
[0240] S10.2: Use the model output and hyperparameter classification thresholds to predict maintenance requirements for multiple future cycles.
[0241] The test data set of the present invention preferably uses 26,190 IoT elevators in use as the data source, uses the data from 2015 to 2023 as the training set to train the model, and uses the data from January to August 2024 as the test set. The specific experimental verification results are shown in Table 5.
[0242]
[0243] Table 5
[0244] Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.
Claims
1. A method for predicting the maintenance cycle of intelligent elevators based on decomposition-autocorrelation and Wavelet, characterized in that: The specific steps include: S1: Collect and store the original data of IoT elevators according to time, and normalize the original data; S2: Divide each feature after normalization into equal frequency bins to construct a frequency table of elevator failures; obtain the P value through the chi-square test frequency table, compare the P value with the significance level α, determine the correlation between the feature and the category label, and screen out features with low correlation; S3: Divide the original data into samples, datasets, training sets, validation sets, and test sets; S4: Use the Embedding layer to encode the input features of the dataset and convert the input features into a low-dimensional, dense time series ; S5: Convert time series Input into a multi-layer encoder containing a decomposition module and an autocorrelation mechanism to extract the trend and seasonality characteristics of the time series and obtain the encoder output ; S6: Apply Wavelet transform to the input time series Analyze emergencies and extract high-frequency parts of data ; Output the encoder With high frequency part Fusion to obtain fusion features ; S7: Fusion features Input into the multi-layer perceptron, through multiple fully connected layers and nonlinear layers, through The activation function generates the binary label probability for each time step and obtains the output , i.e., the model prediction probability; S8: Use the loss function to calculate the model prediction probability With the actual label The binary cross entropy between them uses the optimizer to perform backpropagation and update the model parameters; S9: training and validating the prediction model to obtain the final prediction model; S10: The prediction of multiple future time periods is set as a multi-label classification task, and the final prediction model is used to predict the elevator maintenance cycle.
2. The intelligent elevator maintenance cycle prediction method based on decomposition-autocorrelation and Wavelet according to claim 1 is characterized in that: In step S4, the specific steps of encoding the input features of the data set include: S4.1: Input features Divide into categories according to type and continuous features , where l is the length of the time series, d is the number of original features, m is the number of categorical features, n is the number of continuous features, and ; S4.2: Construct the embedding matrix of category feature C , is the number of category features, is the embedded dimension and the weights are randomly initialized: ,in, represents a normal distribution, is the standard deviation of the distribution; S4.3: Categorical features With the embedding matrix Multiply to obtain the category feature vector : ,in, , is the embedding dimension, which is a hyperparameter that needs to be adjusted; S4.4: Convert continuous features Normalize and obtain : ,in, is the normalized continuous eigenvector, is the normalization function; S4.5: Embedded category feature vector and the normalized continuous feature vector Splicing to form a unified low-dimensional, dense time series : ,in, , is the time step, is the concatenated feature dimension.
3. The intelligent elevator maintenance cycle prediction method based on decomposition-autocorrelation and Wavelet according to claim 2 is characterized in that: In the step S4.4, The specific implementation of the function is Z-Score standardization: ,in, is the input feature, For input features The mean of For input features The standard deviation of .
4. The intelligent elevator maintenance cycle prediction method based on decomposition-autocorrelation and Wavelet according to claim 1 is characterized in that: In step S5, the encoder output is obtained by decomposing the module and the autocorrelation mechanism. The specific steps include: S5.1: Convert time series Enter the decomposition module and perform the following steps in the decomposition module: Using moving average operation to analyze time series Smoothing, removing high-frequency fluctuations, and obtaining trend components : ,in, is the moving average operation, is the trend component; S5.2: Using the original time series Subtract the trend component , to obtain the seasonal component : ,in, is the seasonal component, used to capture periodic fluctuations; S5.3: Use autocorrelation mechanisms to handle seasonal components: ,in, For the processed seasonal components, is the autocorrelation mechanism function; S5.4: Use linear projection to handle trend components: , in, is the trend component after projection, is a linear projection; S5.5: Re-fuse the features of the two and output the global features after stacking multiple layers of encoders ; , ,in, Indicates that and After fusion, Represents the final output after passing through multiple layers of encoders; For a multi-layer encoder, this is accomplished by repeating steps S5.1 to S5.5 multiple times.
5. The intelligent elevator maintenance cycle prediction method based on decomposition-autocorrelation and Wavelet according to claim 4 is characterized in that: In step S5.1, the moving average operation The specific steps include: S5.1.1: For the input time series , in dimension Apply zero padding on the unchanged in time series The top and bottom padding Rows with all zero time steps: ,in, is the number of rows to be filled. is the sliding window size, the padded input vector ; S5.1.2: For the input vector , the trend component is calculated using the following formula: ,in, Represents trend component No. time steps, Indicates the first values, is the sliding window size.
6. The intelligent elevator maintenance cycle prediction method based on decomposition-autocorrelation and Wavelet according to claim 4 is characterized in that: In step S5.3, the specific steps of the autocorrelation mechanism include: S5.3.1: Calculate seasonal components The autocorrelation function of is as follows: ,in, is the autocorrelation function, which indicates the similarity of time series under time lag; is the length of the sequence, i.e. the total step length, Indicates time steps, is the time lag, which represents the interval between two time points; S5.3.2: Calculate different time lags The autocorrelation function of , select the largest The lag time corresponding to the autocorrelation value is: ,in, For the The lag time corresponding to the large autocorrelation value is To get the maximum The function of the lag time corresponding to the autocorrelation value; S5.3.3: For the seasonal component Perform a rolling operation to align corresponding subsequences according to the selected time delay: ,in, This is a rolling operation, which means that the seasonal component Moving forward Step; S5.3.4: For each scrolled subsequence , according to its autocorrelation value Perform weighted aggregation operation. The formula for weighted aggregation is: ,in, is the seasonal component after being processed by the autocorrelation mechanism, is the selected lag time number.
7. The intelligent elevator maintenance cycle prediction method based on decomposition-autocorrelation and Wavelet according to claim 4 is characterized in that: In step S5.4, linear projection is completed The specific steps include: S5.4.1: Randomly initialize a projection matrix to be learned , control it to conform to the distribution: ,in, is the standard normal distribution; S5.4.2: Perform matrix multiplication and project the input: ,in, is the trend component after projection, It is the original trend component.
8. The intelligent elevator maintenance cycle prediction method based on decomposition-autocorrelation and Wavelet according to claim 1 is characterized in that: In step S6, the high frequency part of the data is extracted The encoder output With high frequency part The specific steps for fusion include: S6.1: Decompose the input time series into low-frequency and high-frequency components of different scales using discrete wavelet transform: For a given input time series , ,in, Represents the time series corresponding to each feature, and uses Wavelet transformation to transform each Decomposed into low-frequency coefficients and high-frequency coefficients, the formula is: ,in, for The wavelet decomposition result of represents the wavelet transform function; S6.2: Wavelet decomposition results Extract the high frequency part : ,in, To extract high frequency function; S6.3: Extract the high frequency part Perform inverse wavelet transform to obtain a sequence that is consistent with the input sequence Sequences of the same shape : ,in, is the inverse wavelet transform; S6.4: Input vector Every After processing, reassemble and get the output ; S6.5: Output the encoder With high frequency part Fusion to obtain fusion features : .
9. The intelligent elevator maintenance cycle prediction method based on decomposition-autocorrelation and Wavelet according to claim 8 is characterized in that: The wavelet transform function in step S6 use In the package Function completed.
10. The intelligent elevator maintenance cycle prediction method based on decomposition-autocorrelation and Wavelet according to claim 1 is characterized in that: In step S7, the fusion feature Input to the multilayer perceptron to get the output The specific steps include: S7.1: Fusion features Input into the multi-layer perceptron, pass through the first fully connected layer, and map to the hidden dimension ,Right now: ,in, represents the output of the first layer, represents the first layer weight matrix, represents the first layer bias, Represents a nonlinear activation function, which is used to introduce nonlinear features; S7.2: The output of the first layer It is passed to the subsequent fully connected layers in sequence to gradually learn the features, namely: , in, Indicates The output of the layer, Indicates The output of the layer, Indicates The layer weight matrix, Indicates Layer bias; S7.3: Map features to output dimensions through fully connected layers and through The activation function generates the binary classification probability at each time step: ,in, Indicates The output of the layer, that is, the output of the second-to-last layer, represents the output layer weight matrix, represents the output layer bias, Represents the classification probability of the corresponding label of the sample in multiple future time steps; Said The formula for the activation function is: ,in, is the input value, and is applied element by element to the input matrix .
Citation Information
Patent Citations
Timing sequence prediction system and method based on multistage decomposition and fusion
CN114817773A
Long time sequence prediction method based on trend correlation feature learning
CN116911419A