Data prediction method, device and equipment
By acquiring the historical data sequence of the optical module and the adaptive prediction model, the link instability caused by the performance attenuation of the optical module is solved, and efficient and accurate prediction of the health status of the optical module is achieved.
Patent Information
- Application Number
- CN202510737447.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-03
- Publication Date
- 2025-08-15
- Estimated Expiration
- 2045-06-03
AI Technical Summary
The performance attenuation caused by optical modules after long-term operation leads to link unstability, affecting the integrity of data transmission and reception. The prediction methods of the prior art are inefficient and have poor accuracy, and cannot effectively monitor the health status of optical modules.
By obtaining the historical data sequence of the target optical module, combining indicators such as voltage, port error packet number, temperature, bias current and received power, the optical module type is determined, and the adapted prediction model is selected for data prediction, and the prediction results of future time intervals are generated to monitor the health status of the optical module.
It improves the efficiency and accuracy of optical module prediction, can effectively monitor the changes in the health status of optical modules, and achieve efficient and accurate long-term prediction.
Smart Images

Figure CN120263282B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of communication technology, and in particular to a data prediction method, apparatus, and device. Background Art
[0002] An optical module consists of optoelectronic components, functional circuits, and optical interfaces. It includes two parts: a transmitter and a receiver. The function of an optical module is to convert electrical signals into optical signals for transmission via optical fiber. The function of an optical module is to receive optical signals and convert them back into electrical signals. In summary, data transmission and reception on network interfaces requires the use of optical modules.
[0003] When optical modules operate for extended periods, their performance degrades, leading to link instability. This unstable, "sub-healthy" state, while not accompanied by fault alarms, compromises the integrity of data transmission and reception, degrading the network's service quality. This leaves the network in a critical state of intermittent interruptions, fluctuating between "available" and "unavailable," significantly impacting perceived service quality. Summary of the Invention
[0004] The present application provides a data prediction method, the method comprising:
[0005] Obtaining a first data sequence of a target optical module of a network device in a historical time interval, where the target optical module is any optical module among all optical modules of the network device, and the first data sequence includes real operating data at multiple time points in the historical time interval; wherein the real operating data includes a voltage and / or a number of error packets on a port of the target optical module, and the real operating data also includes at least one of a temperature, a bias current, a received power, and a transmitted power corresponding to each channel of the target optical module;
[0006] Determining a target optical module type based on the target channel number of the target optical module, and selecting a target prediction model corresponding to the target optical module type from all prediction models supported by the network device;
[0007] The first data sequence is input into the target prediction model to obtain an initial prediction result, and a target prediction result is determined based on the initial prediction result; wherein, the target prediction result includes a second data sequence of a future time interval, the second data sequence includes predicted operating data of multiple time points in the future time interval, and the predicted operating data is used to determine the health status of the target optical module.
[0008] The present application provides a data prediction device, which includes: an acquisition module for acquiring a first data sequence of a target optical module of a network device in a historical time interval, where the target optical module is any optical module among all optical modules of the network device, and the first data sequence includes real operating data of multiple time points in the historical time interval; wherein the real operating data includes the voltage and / or the number of port error packets of the target optical module, and the real operating data also includes at least one of the temperature, bias current, receiving power and transmitting power corresponding to each channel of the target optical module; a determination module for determining the target optical module type based on the target channel number of the target optical module, and selecting a target prediction model corresponding to the target optical module type from all prediction models supported by the network device; a processing module for inputting the first data sequence into the target prediction model to obtain an initial prediction result, and determining a target prediction result based on the initial prediction result; wherein the target prediction result includes a second data sequence for a future time interval, where the second data sequence includes predicted operating data at multiple time points in the future time interval, and the predicted operating data is used to determine the health status of the target optical module.
[0009] The present application provides an electronic device, comprising: a processor and a machine-readable storage medium, wherein the machine-readable storage medium stores machine-executable instructions that can be executed by the processor; the processor is used to execute the machine-executable instructions to implement the data prediction method of the above example of the present application.
[0010] The present application provides a computer program product, which includes a computer program. When the computer program is executed by a processor, it implements the data prediction method of the above example of the present application.
[0011] The present application provides a machine-readable storage medium, which stores machine-executable instructions that can be executed by a processor; wherein the processor is used to execute the machine-executable instructions, and when the machine-executable instructions are executed, the data prediction method of the above example of the present application is implemented.
[0012] As can be seen from the above technical solution, in the embodiment of the present application, the first data sequence of the target optical module in the historical time interval can be obtained, the first data sequence is input into the target prediction model to obtain the initial prediction result, and the target prediction result is determined based on the initial prediction result. The target prediction result includes the predicted operation data of the future time interval, and the predicted operation data is used to determine the health status of the target optical module. In this way, the target optical module can be predicted and the predicted operation data for a period of time in the future can be obtained, thereby predicting the state change trend of the target optical module and monitoring the health status of the target optical module. Data prediction through the target prediction model has the characteristics of high prediction efficiency, high prediction accuracy, and good long-term prediction effect.
[0013] The first data sequence includes the voltage and number of port error packets of the target optical module, the temperature corresponding to each channel, the bias current, the receive power, and the transmit power. In this way, the target optical module is predicted by combining the actual operating data of the target optical module and the actual operating data of each channel of the target optical module. Then, a channel fusion method is used to fuse the data of all channels for prediction, further improving the prediction accuracy.
[0014] The target optical module type is determined by the target channel number of the target optical module, and a target prediction model corresponding to the target optical module type is selected from all prediction models. The target optical module is predicted by the target prediction model. In this way, the target prediction model that is most suitable for the target optical module can be selected for prediction, thereby further improving the prediction accuracy, increasing the prediction speed, and improving the performance of the optical module prediction algorithm. BRIEF DESCRIPTION OF THE DRAWINGS
[0015] Figure 1 It is a flowchart of a data prediction method in one embodiment of the present application;
[0016] Figure 2 It is a flowchart of a data prediction method in one embodiment of the present application;
[0017] Figure 3 This is a schematic diagram of the structure of a target prediction model in one embodiment of the present application;
[0018] Figure 4 This is a schematic diagram of the structure of a target prediction model in one embodiment of the present application;
[0019] Figure 5 This is a schematic diagram of the structure of a data prediction device in one embodiment of the present application;
[0020] Figure 6 It is a hardware structure diagram of an electronic device in one embodiment of the present application. DETAILED DESCRIPTION
[0021] In the embodiments of the present application, a data prediction method is proposed. The method can be applied to electronic devices. The electronic devices can be network devices (such as routers, switches, etc.), servers, or cloud devices. There is no restriction on the type of electronic devices, as long as they can implement the data prediction method. Figure 1 FIG. 1 is a flow chart of the data prediction method, which may include:
[0022] Step 101: Obtain a first data sequence for a target optical module of a network device during a historical time interval. The target optical module may be any of all optical modules of the network device. The first data sequence may include actual operating data at multiple time points during the historical time interval. The actual operating data may include the voltage and / or number of error packets on a port of the target optical module; the actual operating data may also include at least one of the temperature, bias current, receive power, and transmit power corresponding to each channel of the target optical module.
[0023] For example, if the method is applied to a network device, the network device itself obtains the first data sequence and performs data prediction based on the first data sequence. Alternatively, if the method is applied to a device other than the network device, such as a server, the network device itself obtains the first data sequence and sends the first data sequence to the server, which then performs data prediction based on the first data sequence.
[0024] Step 102: Determine the target optical module type based on the target channel number of the target optical module, and select a target prediction model corresponding to the target optical module type from all prediction models supported by the network device.
[0025] Step 103: Input the first data sequence into a target prediction model to obtain an initial prediction result, and determine a target prediction result based on the initial prediction result. The target prediction result may include a second data sequence for a future time interval, and the second data sequence may include predicted operating data at multiple time points in the future time interval, where the predicted operating data is used to determine the health status of the target optical module.
[0026] In one example, if a network device includes optical modules of K optical module types, the network device supports K prediction models, each of which corresponds one-to-one to the K optical module types, where K is a positive integer. Based on this, when selecting a target prediction model corresponding to a target optical module type from all prediction models supported by the network device, the target prediction model can be the prediction model corresponding to the target optical module type.
[0027] In one example, determining the target optical module type based on the target channel number of the target optical module may include, but is not limited to: based on the target channel number of the target optical module, determining the optical module type corresponding to the target channel number as the target optical module type. Wherein, all optical modules of the network device support a total of K channel numbers, and the K channel numbers correspond to the K optical module types in a one-to-one manner. Or,
[0028] Based on the target number of channels and the target FEC type of the target optical module, the optical module type corresponding to the target number of channels and the target FEC type can be determined as the target optical module type. Among them, all optical modules of the network device support a total of K parameter pairs, and the K parameter pairs correspond one-to-one to K types of optical module types. For example, for each parameter pair, the parameter pair can include the number of channels and the FEC type. Among them, the FEC type includes supporting FEC data and not supporting FEC data; if the target FEC type is supporting FEC data, the actual operation data can also include the FEC data of the target optical module. Or,
[0029] Based on the target number of channels, target FEC type, and configured target scenario parameters of the target optical module, the optical module type corresponding to the target number of channels, the target FEC type, and the target scenario parameters can be determined as the target optical module type. Wherein, all optical modules of the network device support a total of A parameter pairs, and B scenario parameters can be pre-configured. In this way, the K parameter sets consisting of the A parameter pairs and the B scenario parameters correspond one-to-one to the K types of optical module types. Wherein, the scenario parameters can include the total time length of a historical time interval, the time length of two adjacent time points in a historical time interval, the total time length of a future time interval, and the time length of two adjacent time points in a future time interval.
[0030] In one example, determining a target prediction result based on an initial prediction result may include, but is not limited to: determining the initial prediction result as the target prediction result. Alternatively, based on a target model corresponding to a target optical module, selecting a target online network layer corresponding to the target model from all online network layers supported by the network device; all optical modules of the network device support a total of M models, and the network device supports M online network layers; the M models correspond one-to-one to the M online network layers, where M is a positive integer; inputting the initial prediction result into the target online network layer, and optimizing the initial prediction result using the target online network layer to obtain the target prediction result.
[0031] In an example, for each online network layer supported by a network device, the training process of the online network layer may include but is not limited to: obtaining an initial network layer to be trained and obtaining sample data generated by a sample optical module, where the sample optical module may be any optical module among all optical modules of the network device; training the initial network layer based on the sample data to obtain an online network layer corresponding to the model of the sample optical module; wherein the sample data may include a first sample sequence of a first time interval and a second sample sequence of a second time interval, the total time length of the first time interval corresponds to the total time length of the historical time interval, and the total time length of the second time interval corresponds to the total time length of the future time interval.
[0032] Exemplarily, during the training process, the initial network layer is trained based on the sample data to obtain an online network layer corresponding to the model of the sample optical module, which may include but is not limited to: the first sample sequence can be input into the prediction model corresponding to the optical module type of the sample optical module to obtain an initial prediction result, the initial prediction result is input into the initial network layer to obtain a target prediction result, and the loss value is determined based on the target prediction result and the second sample sequence; the network parameters of the prediction model are frozen, and the network parameters of the initial network layer are adjusted based on the loss value to obtain the online network layer corresponding to the model of the sample optical module.
[0033] In one example, the target prediction model includes but is not limited to an iTransformer network, which may include an embedding network layer, a multivariate attention network layer, a first normalized network layer, a feedforward network layer, a second normalized network layer, and a prediction network layer. Based on this, inputting a first data sequence into the target prediction model to obtain an initial prediction result may include but is not limited to: inputting the first data sequence into the embedding network layer to obtain a first feature vector; obtaining a Q vector, a K vector, and a V vector based on the first feature vector, and inputting the Q vector, K vector, and V vector into the multivariate attention network layer to obtain a second feature vector; generating a third feature vector based on the first feature vector and the second feature vector; inputting the third feature vector into the first normalized network layer to obtain a fourth feature vector; inputting the fourth feature vector into the feedforward network layer to obtain a fifth feature vector; generating a sixth feature vector based on the fourth feature vector and the fifth feature vector; inputting the sixth feature vector into the second normalized network layer to obtain a seventh feature vector; and inputting the seventh feature vector into the prediction network layer to obtain the initial prediction result.
[0034] As can be seen from the above technical solution, in the embodiment of the present application, the first data sequence of the target optical module in the historical time interval can be obtained, the first data sequence is input into the target prediction model to obtain the initial prediction result, and the target prediction result is determined based on the initial prediction result. The target prediction result includes the predicted operation data of the future time interval, and the predicted operation data is used to determine the health status of the target optical module. In this way, the target optical module can be predicted and the predicted operation data for a period of time in the future can be obtained, thereby predicting the state change trend of the target optical module and monitoring the health status of the target optical module. Data prediction through the target prediction model has the characteristics of high prediction efficiency, high prediction accuracy, and good long-term prediction effect.
[0035] The first data sequence includes the voltage and number of port error packets of the target optical module, the temperature corresponding to each channel, the bias current, the receive power, and the transmit power. In this way, the target optical module is predicted by combining the actual operating data of the target optical module and the actual operating data of each channel of the target optical module. Then, a channel fusion method is used to fuse the data of all channels for prediction, further improving the prediction accuracy.
[0036] The target optical module type is determined by the target channel number of the target optical module, and a target prediction model corresponding to the target optical module type is selected from all prediction models. The target optical module is predicted by the target prediction model. In this way, the target prediction model that is most suitable for the target optical module can be selected for prediction, thereby further improving the prediction accuracy, increasing the prediction speed, and improving the performance of the optical module prediction algorithm.
[0037] The above technical solutions of the embodiments of the present application are described below in conjunction with specific application scenarios.
[0038] When optical modules operate for extended periods, their performance degrades, leading to link instability. To monitor the health of optical modules, regular data collection and analysis is required, including analysis of the current health status and the future health status. To analyze the future health of optical modules, predictions based on the module data are required. This data is then analyzed to predict module health trends.
[0039] When predicting optical module data, time series prediction algorithms can be used. These include ARIMA (Autoregressive Integrated Moving Average Model), exponential smoothing, LSTM (Long Short-Term Memory), time series decomposition, and DeepAR (Deep Autoregressive Recurrent). However, these time series prediction algorithms suffer from low efficiency, poor prediction results, and low accuracy when used to predict optical module data.
[0040] In response to the above findings, a data prediction method is proposed in an embodiment of the present application. Taking into account that the optical module includes multiple indicator data (such as the voltage of the target optical module, the number of port error packets and FEC (Forward Error Correction) data, the temperature corresponding to each channel, the bias current, the receiving power and the transmitting power), these indicator data have certain correlations. In this embodiment, multiple indicator data can be processed through a prediction model, thereby making full use of the correlation between multiple indicator data for data prediction, which has the characteristics of high prediction efficiency, high prediction accuracy, and good long-term prediction effect.
[0041] In one example, the data prediction method can be applied to network devices, such as routers or switches, etc., and there is no restriction on the type of network devices, as long as the network devices have optical modules. The network devices can include multiple optical modules, such as 10G optical modules, 40G optical modules, 100G optical modules, 200G optical modules, 400G optical modules, etc., and there is no restriction on the optical modules of the network devices. Alternatively, the data prediction method can be applied to servers or cloud devices, etc., as long as the server or cloud device can collect data from the network devices and analyze and predict the network devices based on these data. For the convenience of description, in the subsequent process, the data prediction method will be applied to network devices as an example.
[0042] In an example, assuming that all optical modules of a network device support K optical module types, that is, the network device can include optical modules of K optical module types, then the network device can support K prediction models, and the K prediction models correspond one-to-one to the K optical module types. K can be a positive integer, such as K greater than 1. The network device supporting K prediction models means that the network device deploys these K prediction models.
[0043] For example, assuming that the network device includes optical modules of type a1 (such as optical module 1 and optical module 2), optical modules of type a2 (such as optical module 3, optical module 4, and optical module 5), and optical modules of type a3 (such as optical module 6), that is, the network device has a total of 6 optical modules. Then, the network device can support prediction model b1 corresponding to optical module type a1, prediction model b2 corresponding to optical module type a2, and prediction model b3 corresponding to optical module type a3, that is, a total of 3 prediction models.
[0044] For example, if the server learns that the network device includes an optical module of optical module type a1, the server can send the prediction model b1 to the network device; if the server learns that the network device includes an optical module of optical module type a2, the server can send the prediction model b2 to the network device; if the server learns that the network device includes an optical module of optical module type a3, the server can send the prediction model b3 to the network device.
[0045] In an example, the following method can be used to determine K optical module types:
[0046] Method 1: Determine K optical module types based on the number of channels. For example, all optical modules of the network device support K channels, and the K channels correspond to the K optical module types.
[0047] For example, to achieve high-speed performance, an optical module can include several channels (also called lanes). These channels can transmit and receive data in parallel. For example, an optical module can simultaneously receive data through four channels and transmit data through four channels, thereby achieving high-speed performance. Based on this, the number of channels in an optical module can be determined. The number of channels is a property of the optical module. For example, a 10G optical module has 1 channel, a 40G optical module has 4 channels, a 100G optical module has 4 channels, a 200G optical module has 4 or 8 channels, and a 400G optical module has 4 or 8 channels.
[0048] Assuming that all optical modules in a network device support K channel quantities, the K channel quantities correspond one-to-one to the K optical module types. For example, if K channel quantities are three (channel 1, channel 4, and channel 8), channel 1 corresponds to optical module type a1, channel 4 corresponds to optical module type a2, and channel 8 corresponds to optical module type a3. Furthermore, if optical modules 1 and 2 each have one channel, they correspond to optical module type a1. If optical modules 3, 4, and 5 each have four channels, they correspond to optical module type a2. If optical module 6 has eight channels, it corresponds to optical module type a3.
[0049] To summarize, if all optical modules of a network device support three channel numbers (channel number 1, channel number 4, and channel number 8), then the network device has three optical module types, such as optical module type a1, optical module type a2, and optical module type a3. In this way, the network device can support three prediction models, and the three prediction models correspond one-to-one to the three optical module types, such as prediction model b1 corresponding to optical module type a1, prediction model b2 corresponding to optical module type a2, and prediction model b3 corresponding to optical module type a3.
[0050] Method 2: Determine K optical module types based on the number of parameter pairs. For example, all optical modules in a network device support K parameter pairs, and each K parameter pair corresponds to each of the K optical module types. For example, each parameter pair may include the number of channels and the FEC type. The FEC type may include FEC data support (i.e., the optical module supports the transmission and processing of FEC data) or does not support FEC data.
[0051] For example, FEC data is channel-coded data that recovers lost packets by adding redundant data. It can be divided into correctable FEC data and uncorrectable FEC data. An optical module may or may not support the transmission and processing of FEC data. Based on this, the FEC type of the optical module can be determined. The FEC type is a property of the optical module. For example, the FEC type of a 10G optical module indicates that it does not support FEC data, the FEC type of a 40G optical module indicates that it does not support FEC data, the FEC type of a 100G optical module indicates that it supports FEC data, the FEC type of a 200G optical module indicates that it supports FEC data, and the FEC type of a 400G optical module indicates that it supports FEC data.
[0052] Assume that all optical modules in a network device support K parameter pairs, and each of these K parameter pairs corresponds one-to-one to each of the K optical module types. For example, if all optical modules support three channel counts (i.e., 1 channel, 4 channels, and 8 channels), then a maximum of six parameter pairs are supported (channel 1 with FEC data, channel 1 without FEC data, channel 4 with FEC data, channel 4 without FEC data, channel 8 with FEC data, and channel 8 without FEC data).
[0053] The number of parameter pairs supported by all optical modules in a network device depends on the actual situation of the optical modules. For example, if optical modules 1 and 2 have one channel, optical modules 3, 4, and 5 have four channels, and optical module 6 has eight channels, and optical module 1 supports FEC data, optical module 2 does not, optical module 3 does, optical modules 4 and 5 do not, and optical module 6 does, then all optical modules in the network device support five parameter pairs.
[0054] Optical module 1 corresponds to parameter pair c1 (1 channel and support for FEC data), which corresponds to optical module type a1. Optical module 2 corresponds to parameter pair c2 (1 channel and does not support FEC data), which corresponds to optical module type a2. Optical module 3 corresponds to parameter pair c3 (4 channels and support for FEC data), which corresponds to optical module type a3. Optical modules 4 and 5 correspond to parameter pair c4 (4 channels and do not support FEC data), which corresponds to optical module type a4. Optical module 6 corresponds to parameter pair c5 (8 channels and support for FEC data), which corresponds to optical module type a5.
[0055] To sum up, if all optical modules of the network device support 5 parameter pairs, then there are 5 types of optical modules in the network device, such as optical module type a1, optical module type a2, optical module type a3, optical module type a4 and optical module type a5. In this way, the network device can support 5 prediction models, and these 5 prediction models correspond one-to-one to the 5 types of optical modules, such as prediction model b1 corresponding to optical module type a1, prediction model b2 corresponding to optical module type a2, prediction model b3 corresponding to optical module type a3, prediction model b4 corresponding to optical module type a4, and prediction model b5 corresponding to optical module type a5.
[0056] For example, consider that the number of channels of a 10G optical module is 1, and the FEC type indicates that FEC data is not supported; the number of channels of a 40G optical module is 4, and the FEC type indicates that FEC data is not supported; the number of channels of a 100G optical module is 4, and the FEC type indicates that FEC data is supported; the number of channels of a 200G optical module is 4 or 8, and the FEC type indicates that FEC data is supported; the number of channels of a 400G optical module is 4 or 8, and the FEC type indicates that FEC data is supported. Based on this, there are a total of four parameter pairs, namely: parameter pair c1 (channel number 1 + no support for FEC data), parameter pair c2 (channel number 4 + no support for FEC data), parameter pair c3 (channel number 4 + support for FEC data), and parameter pair c4 (channel number 8 + support for FEC data).
[0057] In summary, parameter pair c1 is applicable to 10G optical modules, parameter pair c2 is applicable to 40G optical modules, parameter pair c3 is applicable to 100G optical modules, 4-channel 200G optical modules, and 400G optical modules, and parameter pair c4 is applicable to 8-channel 200G optical modules and 400G optical modules.
[0058] Method 3: Determine K optical module types based on the number of parameter pairs and scenario parameters. For example, if all optical modules in a network device support A parameter pairs and are pre-configured with B scenario parameters, the K parameter sets (i.e., A*B=K) consisting of A parameter pairs and B scenario parameters correspond one-to-one to the K optical module types. For example, each parameter pair includes the number of channels and the FEC type, with FEC types including those that support FEC data and those that do not. Scenario parameters may include the total duration of a historical time interval, the time duration between two adjacent time points within the historical time interval (i.e., the sampling frequency), the total duration of a future time interval, and the time duration between two adjacent time points within the future time interval.
[0059] In this example, assume that all optical modules on a network device support A parameter pairs (similar to the K parameter pairs in Method 2, replacing K with A) and are pre-configured with B scenario parameters. This results in a total of A*B parameter sets, which can be denoted as K parameter sets. For example, assume that all optical modules on a network device support five parameter pairs and predict two scenario parameters. This results in a total of 10 parameter sets. The network device has 10 optical module types, such as optical module type a1 to optical module type a10. The network device can support 10 prediction models corresponding to these 10 optical module types, such as prediction model b1 to prediction model b10. Assuming that all optical modules on a network device support four parameter pairs and predict three scenario parameters, this results in a total of 12 parameter sets. The network device has 12 optical module types and 12 prediction models. Similarly, a one-to-one correspondence between optical module types and parameter sets is sufficient.
[0060] For example, if A parameter pairs are parameter pair c1, parameter pair c2, parameter pair c3, and parameter pair c4, and B scene parameters are scene parameter d1, scene parameter d2, and scene parameter d3, then parameter set e1 is parameter pair c1 and scene parameter d1, and parameter set e1 corresponds to optical module type a1, parameter set e2 is parameter pair c1 and scene parameter d2, and parameter set e2 corresponds to optical module type a2, parameter set e3 is parameter pair c1 and scene parameter d3, and parameter set e3 corresponds to optical module type a3, parameter set e4 is parameter pair c2 and scene parameter d1, and parameter set e4 corresponds to optical module type a4, and so on.
[0061] In an example, scenario parameters can be configured according to actual business needs. Scenario parameters may include the total time length of a historical time interval, the time length between two adjacent time points in a historical time interval, the total time length of a future time interval, and the time length between two adjacent time points in a future time interval.
[0062] For example, based on actual business needs, at a 30-minute frequency, 7 days of data (7*48=336) are used to predict data for the next 3 days (3*48=144). That is, the historical data length is 336 and the prediction length is 144. Then, the scenario parameter d1 includes the total time length of the historical time interval (such as 7 days), the time length of two adjacent time points in the historical time interval (such as 30 minutes), the total time length of the future time interval (such as 3 days), and the time length of two adjacent time points in the future time interval (such as 30 minutes).
[0063] For example, according to actual business needs, based on a 1-hour frequency, use 10 days (10*24=240) of data to predict the data of the next 5 days (5*24=120). That is, the historical data length is 240 and the prediction length is 120. Then, the scenario parameter d2 includes the total time length of the historical time interval (such as 10 days), the time length of two adjacent time points in the historical time interval (such as 60 minutes), the total time length of the future time interval (such as 5 days), and the time length of two adjacent time points in the future time interval (such as 60 minutes).
[0064] Of course, the above are just two examples of scenario parameters. There is no restriction on the scenario parameters. You can configure the scenario parameters according to actual business needs. The scenario parameters only need to include the above four parameter values.
[0065] To summarize, if all optical modules of a network device support A parameter pairs and are pre-configured with B scenario parameters, then the network device has a total of A*B (i.e., K) optical module types. The network device can support A*B prediction models, and the A*B prediction models correspond one-to-one to the A*B optical module types.
[0066] In this example, using method 3, we'll describe the training process for a prediction model corresponding to an optical module type (for example, prediction model b1 for optical module type a1). Because the training process for each prediction model is the same, we'll use prediction model b1 as an example. Prediction model b1 can be trained on a server and sent to a network device. Alternatively, prediction model b1 can be trained on the network device itself.
[0067] First, obtain sample data for optical module type a1. Considering that optical module type a1 corresponds to parameter pair c1 (number of channels, no FEC support) and scenario parameter d1, it is necessary to obtain sample data corresponding to parameter pair c1 and scenario parameter d1. For example, a large amount of real operating data generated by a specific optical module (i.e., an optical module with one channel and no FEC support) can be collected (for details on real operating data, see the subsequent examples). Based on this real operating data, multiple sample data sets are constructed.
[0068] For example, sample data 1 includes real operating data from multiple time points (30-minute intervals between adjacent time points) during a historical time interval (7 days in total, such as from day 1 to day 7), and real operating data from multiple time points (30-minute intervals between adjacent time points) during a future time interval (3 days in total, such as from day 8 to day 10, the last three days of the historical time interval). Sample data 2 includes real operating data from multiple time points from day 2 to day 8, and from day 9 to day 11. Sample data 3 includes real operating data from multiple time points from day 3 to day 9, and from day 10 to day 12. This process can be repeated to generate a large amount of sample data. These sample data all include real operating data generated by a specific optical module and are constructed based on the requirements of scenario parameter d1.
[0069] Next, the prediction model to be trained (i.e., the pre-configured prediction model to be trained) is trained based on the multiple sample data to obtain prediction model b1. There are no restrictions on the training process for prediction model b1. During the training process, real operating data from multiple time points in the historical time interval is used as input data. This real operating data is fed into the prediction model to be trained for prediction and obtain prediction results. Real operating data from multiple time points in the future time interval is used as label data. A loss value is calculated based on the label data and the prediction results, and the loss value is used to adjust the network parameters of the prediction model to be trained.
[0070] In summary, the prediction model b1 can be trained and then supported on the network device.
[0071] In an example, to train a prediction model for all optical module types, a large amount of real-world operating data is required, such as from an experimental network. This data can then be categorized according to parameter pairs. For example, all real-world operating data can be divided into real-world operating data for parameter pair c1 (1 channel and data that does not support FEC) (generated by the optical module corresponding to parameter pair c1), real-world operating data for parameter pair c2 (4 channels and data that does not support FEC), real-world operating data for parameter pair c3 (4 channels and data that supports FEC), and real-world operating data for parameter pair c4 (8 channels and data that supports FEC). Furthermore, after removing the FEC data, the real-world operating data for parameter pair c3 can also be used as real-world operating data for parameter pair c2.
[0072] Taking scenario parameters d1 and d2 as an example, based on the actual operating data of parameter pair c1, a training dataset corresponding to optical module type a1 (parameter pair c1 + scenario parameter d1) can be generated. This training dataset can include multiple sample data. A training dataset corresponding to optical module type a2 (parameter pair c1 + scenario parameter d2) can also be generated. Based on the actual operating data of parameter pair c2, a training dataset corresponding to optical module type a3 (parameter pair c2 + scenario parameter d1) can be generated, and a training dataset corresponding to optical module type a4 (parameter pair c2 + scenario parameter d2) can be generated. Similarly, training datasets corresponding to eight optical module types can be obtained. Based on this, prediction model b1 for optical module type a1 can be trained based on the training dataset for optical module type a1. Prediction model b2 for optical module type a2 can be trained based on the training dataset for optical module type a2. Similarly, eight prediction models corresponding to the eight optical module types can be trained, with each prediction model corresponding to each of the eight optical module types.
[0073] In the above application scenario, a data prediction method is proposed in the embodiment of the present application, which can be applied to network devices. Figure 2 FIG. 1 is a flow chart of the data prediction method, which may include:
[0074] Step 201: Acquire a first data sequence of a target optical module in a historical time interval.
[0075] In one example, the target optical module can be any optical module among all optical modules of the network device. For example, data prediction can be performed for each optical module of the network device. In the following, the data prediction process for one optical module is used as an example, and the optical module can be referred to as the target optical module.
[0076] In an example, the configured target scene parameters can be obtained. The target scene parameters may include the total time length of the historical time interval, the time length of two adjacent time points in the historical time interval (i.e., the sampling frequency), the total time length of the future time interval, and the time length of two adjacent time points in the future time interval. For example, the target scene parameters may be scene parameter d1 or scene parameter d2.
[0077] Taking the target scenario parameter as scenario parameter d1 as an example, the total time length of the historical time interval is 7 days, the time length between two adjacent time points in the historical time interval is 30 minutes, the total time length of the future time interval is 3 days, and the time length between two adjacent time points in the future time interval is 30 minutes.
[0078] In one example, the first data series may include actual operating data at multiple time points in a historical time interval. For example, the last time point in the historical time interval may be the current time point. Starting from the current time point, traversing forward 336 (7 * 48 = 336) time points (including the current time point) at 30-minute intervals constitutes the multiple time points in the historical time interval.
[0079] To sum up, the total time length of the historical time interval is 7 days, the time length between two adjacent time points in the historical time interval is 30 minutes, and the historical time interval includes 336 time points.
[0080] In one example, for each time point (taking one time point as an example), the actual operating data at that time point may include the voltage of the target optical module and / or the number of error packets on the port. If the target FEC type of the target optical module indicates that it supports FEC data, the actual operating data may also include the FEC data of the target optical module. If the target FEC type indicates that it does not support FEC data, the actual operating data does not include FEC data.
[0081] Regarding the voltage of the target optical module, the network device can periodically collect the voltage of the target optical module without any restrictions. In this way, the voltage of the target optical module can be obtained.
[0082] Regarding the number of port error packets (in_error_packets) of the target optical module, when the network device receives a data packet through the target optical module, it can know whether the data packet is a correct data packet or an error data packet. If the data packet is an error data packet, the number of port error packets can be increased by 1. In this way, the number of port error packets of the target optical module in a specified time period can be counted and used as the actual operation data.
[0083] The FEC data of the target optical module can be divided into correctable FEC data (FEC_Correctable) and uncorrectable FEC data (FEC_UnCorrectable). When a network device receives a data packet through the target optical module, it can also receive FEC data for multiple data fragments of the data packet through the target optical module. If an error occurs in a data fragment and the FEC data for that data fragment can correct the error, the correctable FEC data is incremented by 1. If the FEC data for that data fragment cannot correct the error, the uncorrectable FEC data is incremented by 1. This allows statistics to be collected on the FEC data (correctable and uncorrectable) of the target optical module during a specified time period.
[0084] In one example, to achieve high-speed performance, the target optical module includes at least one channel (also called a lane), which can transmit and receive data in parallel. For example, the target optical module includes one channel, four channels, or eight channels. Based on this, at each point in time (for example), the actual operating data at that point in time can include at least one of the following: temperature, bias current, receive power, and transmit power for each channel.
[0085] For example, a target optical module includes four channels. The target optical module contains circuits for the four channels. Circuit 1 implements the transceiver function of channel 1, circuit 2 implements the transceiver function of channel 2, circuit 3 implements the transceiver function of channel 3, and circuit 4 implements the transceiver function of channel 4.
[0086] For each channel's temperature (Temperature), the network device can periodically collect the temperature of each channel (i.e., the temperature of the circuitry in that channel). This process is not restricted. This allows the temperature of each channel of the target optical module to be determined. For each channel's bias current (Current Bias), the network device can periodically collect the bias current of each channel (i.e., the bias current of the circuitry in that channel). This allows the bias current of each channel of the target optical module to be determined. For each channel's received power (Rx Power), the network device can periodically collect the received power of each channel (i.e., the received power of the circuitry in that channel). This allows the received power of each channel of the target optical module to be determined. For each channel's transmit power (Tx Power), the network device can periodically collect the transmit power of each channel (i.e., the transmit power of the circuitry in that channel). This allows the transmit power of each channel of the target optical module to be determined.
[0087] In summary, at each point in time, the actual operating data at that point in time can include the voltage of the target optical module, the number of error packets on its port, the FEC data of the target optical module, the temperature of each channel of the target optical module, the bias current of each channel of the target optical module, the received power of each channel of the target optical module, and the transmitted power of each channel of the target optical module. Thus, using a channel fusion method, all channel data of the target optical module are fused and combined with the voltage, number of error packets on its port, and FEC data to form the actual operating data for subsequent prediction. Because these data are correlated, fusing them into a multivariate time series data set can help improve prediction accuracy.
[0088] If the target optical module has four channels and supports FEC data, the actual operating data can be expressed as: Voltage + channel1 (Temperature, Current Bias, Rx Power, Tx Power) + channel2 (Temperature, Current Bias, Rx Power, Tx Power) + channel3 (Temperature, Current Bias, Rx Power, Tx Power) + channel4 (Temperature, Current Bias, Rx Power, Tx Power) + in_error_packets + FEC_Correctable + FEC_UnCorrectable. If FEC data is not supported, the actual operating data is expressed as: Voltage + channel1 (Temperature, Current Bias, Rx Power, Tx Power) + channel2 (Temperature, Current Bias, Rx Power, Tx Power) + channel3 (Temperature, Current Bias, Rx Power, Tx Power) + channel4 (Temperature, Current Bias, Rx Power, Tx Power) + in_error_packets.
[0089] Step 202: Determine the target optical module type based on the target channel quantity of the target optical module, and select a target prediction model corresponding to the target optical module type from all prediction models supported by the network device.
[0090] For example, considering that different optical modules may have different channel counts and different FEC types (supporting or not supporting FEC data), all optical modules can be divided into multiple types based on their hardware differences, with each type supporting a specific prediction model. Based on this, the target optical module type is determined based on the target number of channels, and the target prediction model corresponding to the target optical module type is selected from all prediction models supported by the network device.
[0091] In an example, if method 1 is used to determine K optical module types, the target channel number of the target optical module can be determined. Based on the target channel number of the target optical module, the optical module type corresponding to this target channel number can be determined as the target optical module type. For example, if the target channel number is 1, optical module type a1 corresponding to channel 1 is used as the target optical module type, and prediction model b1 corresponding to optical module type a1 is used as the target prediction model. If the target channel number is 4, optical module type a2 corresponding to channel 4 is used as the target optical module type, and prediction model b2 corresponding to optical module type a2 is used as the target prediction model, and so on.
[0092] In an example, if method 2 is used to determine K optical module types, the target number of channels and the target FEC type of the target optical module can be determined. Based on the target number of channels and the target FEC type of the target optical module, the optical module type corresponding to the target number of channels and the target FEC type can be determined as the target optical module type. For example, the target number of channels and the target FEC type can correspond to a target parameter pair, and the optical module type corresponding to the target parameter pair can be determined as the target optical module type.
[0093] For example, taking parameter pairs c1 (1 channel, no FEC data support), c2 (4 channels, no FEC data support), c3 (4 channels, no FEC data support), and c4 (8 channels, no FEC data support), if the target number of channels is 1 and the target FEC type does not support FEC data, then the target parameter pair is c1. Optical module type a1 corresponding to parameter pair c1 is used as the target optical module type, and prediction model b1 corresponding to optical module type a1 is used as the target prediction model. If the target number of channels is 4 and the target FEC type does not support FEC data, then the target parameter pair is c2. Optical module type a2 corresponding to parameter pair c2 is used as the target optical module type, and prediction model b2 corresponding to optical module type a2 is used as the target prediction model. And so on.
[0094] In an example, if method 3 is used to determine K optical module types, the target number of channels for the target optical module, the target FEC type for the target optical module, and the configured target scenario parameters are determined. Based on the target number of channels, target FEC type, and target scenario parameters, the target optical module type corresponding to the target number of channels, target FEC type, and target scenario parameters is determined as the target optical module type. For example, the target number of channels and target FEC type can correspond to a target parameter pair, and the target optical module type corresponding to the parameter set consisting of the target parameter pair and the target scenario parameters is determined as the target optical module type.
[0095] For example, if the target number of channels is 1 and the target FEC type is not to support FEC data, the target parameter pair is parameter pair c1. Assuming the target scene parameter is scene parameter d1, the parameter set consisting of parameter pair c1 and scene parameter d1 corresponds to optical module type a1. In other words, optical module type a1 is used as the target optical module type, and prediction model b1 corresponding to optical module type a1 is used as the target prediction model. Assuming the target scene parameter is scene parameter d2, the parameter set consisting of parameter pair c1 and scene parameter d2 corresponds to optical module type a2, and prediction model b2 corresponding to optical module type a2 is used as the target prediction model.
[0096] If the target number of channels is 4 and the target FEC type does not support FEC data, the target parameter pair is parameter pair c2. Assuming that the target scene parameter is scene parameter d1, the parameter set consisting of parameter pair c2 and scene parameter d1 corresponds to optical module type a3. That is, optical module type a3 is used as the target optical module type, and prediction model b3 corresponding to optical module type a3 is used as the target prediction model. And so on.
[0097] In summary, for different optical modules, the optical module types can be distinguished, and a suitable target prediction model is selected for the target optical module based on the optical module type, and the target optical module is predicted based on the target prediction model.
[0098] For example, parameter pair c1 (1 lane without FEC support) is applicable to a 10G optical module. The actual operating data for this type of optical module can be expressed as: Voltage + (Temperature, Current Bias, Rx Power, Tx Power) + in_error_packets. Parameter pair c2 (4 lanes without FEC support) is applicable to a 40G optical module. The actual operating data for this type of optical module can be expressed as: Voltage + 4*(Temperature, Current Bias, Rx Power, Tx Power) + in_error_packets. Parameter pair c3 (4 lanes with FEC support) is applicable to 100G optical modules, 4-lane 200G optical modules, and 400G optical modules. The actual operating data for this type of optical module can be expressed as: Voltage + 4*(Temperature, Current Bias, Rx Power, Tx Power) + in_error_packets + FEC_Correctable + FEC_UnCorrectable. Parameter pair c4 (8 channels + FEC data support) is applicable to 8-channel 200G and 400G optical modules. The actual operating data of this type of optical module can be expressed as: Voltage + 8 * (Temperature, Current Bias, Rx Power, Tx Power) + in_error_packets + FEC_Correctable + FEC_UnCorrectable.
[0099] Step 203: Input the first data sequence into the target prediction model to obtain an initial prediction result.
[0100] In this example, for each forecasting model (using the target forecasting model as an example), the target forecasting model can be any type of time series forecasting model, such as the ARIMA forecasting model, exponential smoothing forecasting model, LSTM forecasting model, time series decomposition forecasting model, DeepAR forecasting model, etc. Considering the poor forecasting performance of these time series forecasting models, the Transformer network or iTransformer network can also be used as the target forecasting model. The iTransformer network is used as the target forecasting model as an example.
[0101] The iTransformer network is a multivariate time series data prediction network. After inputting real operating data (voltage, port error packet count, and FEC data of the target optical module, and temperature, bias current, receive power, and transmit power of each channel of the target optical module) into the iTransformer network, the iTransformer network can make predictions based on multivariate time series data. It can consider the correlation between multiple variables (such as data from multiple channels), better handle long-term dependencies, better describe the correlation between various data, extract multi-layer representations of sequences, and effectively mine the correlation between multiple variables (sequences). It has good performance, improved computing speed, and prediction accuracy, meeting the needs of optical module fault prediction.
[0102] In one example, the target prediction model includes but is not limited to the iTransformer network and the Transformer network. There is no restriction on the type of the target prediction model. The iTransformer network is used as an example for illustration. Of course, when other types of target prediction models are used, the implementation method is similar and will not be repeated here.
[0103] In one example, a first data sequence can be input into the target prediction model (iTransformer network) to obtain an initial prediction result. For example, assuming the target scenario parameter is scenario parameter d1, the first data sequence includes real operating data from 336 time points. For each time point, the real operating data can include the voltage, number of port error packets, and FEC data of the target optical module, as well as the temperature, bias current, receive power, and transmit power of each channel of the target optical module. The target prediction model (iTransformer network) performs predictions based on the real operating data from 336 time points to obtain an initial prediction result.
[0104] The initial prediction result may include a third data sequence for the future time interval, and the third data sequence may include predicted operating data for multiple time points in the future time interval. For example, under scenario parameter d1, the total time length of the future time interval is 3 days, and the time length between two adjacent time points in the future time interval is 30 minutes. Based on this, the first time point in the future time interval can be the current time point + a fixed duration (such as 30 minutes). Starting from the first time point, with an interval of 30 minutes as the granularity, 144 (3*48=144) time points are traversed backwards. These time points are multiple time points in the future time interval.
[0105] In summary, the total time length of the future time interval is 3 days, the time length between two adjacent time points in the future time interval is 30 minutes, and the future time interval includes 144 time points.
[0106] The third data sequence includes predicted operational data at 144 time points. For each time point, the predicted operational data can include the voltage, number of port error packets, and FEC data of the target optical module, as well as the temperature, bias current, receive power, and transmit power of each channel of the target optical module. Obviously, the data types corresponding to the predicted operational data are the same as those corresponding to the actual operational data, except that the predicted operational data is predicted by the target prediction model, while the actual operational data is actually collected from the target optical module.
[0107] For an example, see Figure 3 The figure shows the structure of the target prediction model (iTransformer network). The iTransformer network can include an embedding network layer (Embedding), a multivariate attention network layer (MultivariateAttention), a first normalized network layer (LayerNorm), a feed-forward network layer (Feed-forward), a second normalized network layer (LayerNorm), and a prediction network layer (Projection). Figure 3 This is just an example of the iTransformer network, and there is no restriction on the structure of the iTransformer network.
[0108] In an example, based on Figure 3 In the iTransformer network shown, in step 203, the process of inputting a first data sequence (e.g., actual operating data at 336 time points) into the iTransformer network to obtain an initial prediction result (e.g., predicted operating data at 144 time points) may include:
[0109] The first data sequence is input into the embedding layer to obtain the first feature vector. For example, embedding is a technique that converts data into vector representations. Embedding can convert words, sentences, or documents into low-dimensional vectors, enabling better understanding and processing of text data. The core idea of embedding is to map the data into a low-dimensional vector space by learning its intrinsic structure and semantic information. In this vector space, similar data points are mapped to similar locations, allowing similarity between data to be measured by calculating the similarity between vectors. In this example, embedding treats the historical data of each variable as a token, so that the multivariate sequence (i.e., the first data sequence) corresponds to multiple tokens. In summary, after the first data sequence is input into the embedding layer, the embedding layer processes the first data sequence to obtain the first feature vector. There are no restrictions on this processing process.
[0110] After obtaining the first eigenvector, the Q, K, and V vectors can be obtained based on the first eigenvector. For example, the input data of the multivariate attention network layer is the Q, K, and V vectors. Therefore, the Q, K, and V vectors can be obtained based on the first eigenvector. There is no restriction on the acquisition method, as long as the Q, K, and V vectors can be obtained.
[0111] After obtaining the Q, K, and V vectors, they are fed into a multivariate attention network layer to obtain the second eigenvector. For example, a multivariate attention network layer is a self-attention layer used to capture correlations between multiple sequences. After the Q, K, and V vectors are fed into the multivariate attention network layer, they can be processed based on the Q, K, and V vectors to obtain the second eigenvector. There are no restrictions on this processing process.
[0112] After the second eigenvector is obtained, a third eigenvector is generated based on the first eigenvector and the second eigenvector, such as by performing an addition operation on the first eigenvector and the second eigenvector to obtain the third eigenvector.
[0113] After obtaining the third eigenvector, it can be input into the first normalization network layer (LayerNorm) to obtain the fourth eigenvector. For example, LayerNorm is a regularization technique used in neural networks that normalizes the neuron activation values within a layer for a single sample to reduce the problem of internal covariate shift. The core idea of LayerNorm is to normalize the neuron activation values of each layer. Specifically, for an input vector (x), LayerNorm first calculates the mean and standard deviation of the layer, then uses these statistics to normalize the activation values, and finally scales and translates them using learnable parameters. In summary, after the third eigenvector is input into the first normalization network layer, the first normalization network layer can process the third eigenvector to obtain the fourth eigenvector.
[0114] After obtaining the fourth eigenvector, it is fed into a feed-forward network layer to obtain the fifth eigenvector. For example, a feed-forward network (FFN) is a fully connected layer used to encode each sequence. After the fourth eigenvector is fed into the feed-forward network layer, it processes the fourth eigenvector to obtain the fifth eigenvector.
[0115] After the fifth eigenvector is obtained, a sixth eigenvector is generated based on the fourth eigenvector and the fifth eigenvector, for example, by performing an addition operation on the fourth eigenvector and the fifth eigenvector to obtain the sixth eigenvector.
[0116] After obtaining the sixth eigenvector, the sixth eigenvector is input to the second normalization network layer (LayerNorm) to obtain the seventh eigenvector. For example, after inputting the sixth eigenvector to the second normalization network layer, the seventh eigenvector can be obtained by processing based on the sixth eigenvector.
[0117] After obtaining the seventh eigenvector, it is input into a projection network layer to obtain the initial prediction result, which is then output. For example, the projection network layer may be an MPL (Multiple Layer Perceptron). Based on this, the seventh eigenvector can be processed by the MPL to ultimately obtain the initial prediction result. This process is not limited.
[0118] In summary, after the first data sequence is input into the iTransformer network, the iTransformer network can process the first data sequence and finally obtain an initial prediction result.
[0119] Step 204 : Based on the target model corresponding to the target optical module, a target online network layer corresponding to the target model is selected from all online network layers supported by the network device.
[0120] In one example, a network device may include multiple models (types) of optical modules. The model of an optical module indicates the product to which the module belongs. Optical modules from different manufacturers may have different models. Optical modules from the same manufacturer may have the same model (i.e., optical modules from the same batch), or they may have different models (i.e., optical modules from different batches). When using the same prediction model to predict the performance of optical modules of different models, prediction errors may occur, resulting in differences in predictions for different models. Therefore, in this embodiment, an online network layer can be added to the prediction model, specifically, an online network layer for each model.
[0121] When adding an online network layer, instead of deploying it within the prediction model, an additional online network layer is added. For example, if there are 10 prediction models, adding an online network layer within the prediction model, such as adding three online network layers for three models, would require deploying 30 prediction models. If three additional online network layers are added for three models, then 10 prediction models and three online network layers would need to be deployed. This reduces the number of models and avoids deploying a large number of prediction models.
[0122] For example, assuming all optical modules on a network device support M models, the network device only needs to support M online network layers. The M models correspond to the M online network layers, where M is a positive integer. Supporting M online network layers on a network device can mean deploying M online network layers. For example, if all optical modules on a network device support models f1 and f2, the network device can support online network layer g1 corresponding to model f1 and online network layer g2 corresponding to model f2.
[0123] In this example, the training process for the online network layer is the same for each online network layer, so the training process for online network layer g1 is used as an example. Online network layer g1 is trained on the network device, that is, it is trained online based on data generated locally by the network device.
[0124] First, the initial network layer to be trained can be obtained, that is, all online network layers share the same initial network layer. That is, the online network layer g1 is trained on the basis of the initial network layer, and the online network layer g2 is trained on the basis of the initial network layer. Here, the training of the online network layer g1 is taken as an example.
[0125] Then, multiple sample data generated by a sample optical module are obtained. The sample optical module can be any optical module from all optical modules of the network device. For example, when training to obtain online network layer g1, the optical module corresponding to model f1 can be used as the sample optical module. The number of sample optical modules can be at least one. For example, if the model of optical module 1 and optical module 2 is model g1, optical module 1 and optical module 2 can be used as sample optical modules to obtain sample data generated by optical module 1 and sample data generated by optical module 2.
[0126] For each sample data, the sample data may include a first sample sequence in a first time interval and a second sample sequence in a second time interval, the total time length of the first time interval corresponds to the total time length of the historical time interval, and the total time length of the second time interval corresponds to the total time length of the future time interval.
[0127] For example, a large amount of real operating data generated by optical module 1 (optical module 2) can be collected and multiple sample data sets can be constructed based on this real operating data. Sample data 1 includes real operating data from multiple time points (30-minute intervals between adjacent time points) in the first time interval (corresponding to the historical time interval, for example, a total time length of 7 days, such as from day 1 to day 7), and real operating data from multiple time points (30-minute intervals between adjacent time points) in the second time interval (corresponding to the future time interval, for example, a total time length of 3 days, such as from day 8 to day 10, which is the three days after the first time interval). Sample data 2 includes real operating data from multiple time points from day 2 to day 8, and from day 9 to day 11, and so on.
[0128] Then, the sample data may include a first sample sequence (the content of the first sample sequence is similar to the content of the first data sequence, such as actual operation data at 336 time points) and a second sample sequence (the content of the second sample sequence is similar to the content of the first data sequence, such as actual operation data at 144 time points). The first sample sequence may be input into the prediction model corresponding to the optical module type of the sample optical module to obtain an initial prediction result.
[0129] For example, for the sample data of light module 1, the parameter pair of light module 1 can be determined. Combined with the scene parameters, a prediction model can be selected from all prediction models. The selection method is similar to the above method 3. This prediction model is used as the prediction model corresponding to light module 1. In this way, the first sample sequence can be input into the prediction model to obtain an initial prediction result. The processing process of the prediction model is shown in step 203.
[0130] Then, the initial prediction result is input into the initial network layer to obtain the target prediction result. For example, the initial network layer is used to optimize the initial prediction result to obtain the target prediction result. The initial network layer does not modify the dimension of the initial prediction result, but only optimizes and adjusts the numerical value in the initial prediction result.
[0131] For example, referring to step 203, the initial prediction result includes the predicted operating data for 144 time points, and therefore, the target prediction result includes the predicted operating data for 144 time points. The predicted operating data in the initial prediction result includes the voltage of the optical module, the number of port error packets, and FEC data, and the temperature, bias current, receiving power, and transmitting power of each channel. The predicted operating data in the target prediction result includes the voltage of the optical module, the number of port error packets, and FEC data, and the temperature, bias current, receiving power, and transmitting power of each channel. The initial network layer may optimize and adjust the voltage, the number of port error packets, the bias current, and so on, and there is no restriction on this adjustment process.
[0132] Then, a loss value can be determined based on the target prediction result and the second sample sequence. For example, the target prediction result includes predicted operational data from 144 time points, and the second sample sequence includes actual operational data from 144 time points. The second sample sequence can serve as label data for the target prediction result, and a loss value can be determined based on the target prediction result and the second sample sequence. For example, the loss value can be determined using the MSE (Mean Square Error) algorithm or the MAE (Mean Absolute Error) algorithm. There is no restriction on the method for determining the loss value.
[0133] After obtaining the loss value, the network parameters of the initial network layer can be adjusted based on the loss value to obtain the online network layer corresponding to the sample optical module model. There are no restrictions on the network parameter adjustment process, and network parameters can be adjusted using methods such as gradient descent. During the training process, the online network layer can be ultimately trained and obtained through multiple iterations based on a large amount of sample data.
[0134] When adjusting the network parameters of the initial network layer, the network parameters of the prediction model need to be frozen, and the network parameters of the prediction model are not adjusted, but only the network parameters of the initial network layer are adjusted.
[0135] To summarize, the online network layer g1 corresponding to model f1 is obtained through training. Similarly, the online network layer g2 corresponding to model f2 can be obtained through training, that is, the online network layer of all models supported by the network device.
[0136] In the above process, the online network layer is trained online based on the actual operating data of the optical module, which greatly improves the adaptability of the online network layer and further improves the prediction accuracy.
[0137] In step 204, based on the target model corresponding to the target optical module, a target online network layer corresponding to the target model is selected from all online network layers. If the target model corresponding to the target optical module is model f1, the online network layer g1 corresponding to model f1 is used as the target online network layer. If the target model corresponding to the target optical module is model f2, the online network layer g2 corresponding to model f2 is used as the target online network layer.
[0138] Step 205: Input the initial prediction result into the target online network layer, and optimize the initial prediction result through the target online network layer to obtain a target prediction result. The target prediction result may include a second data sequence for a future time interval, and the second data sequence may include predicted operating data for multiple time points in the future time interval. The predicted operating data is used to determine the health status of the target optical module.
[0139] For an example, see Figure 4 The figure shows a schematic diagram of adding a target online network layer to the prediction model. In step 203, the first data sequence is input into the target prediction model to obtain an initial prediction result. In this way, the initial prediction result can be input into the target online network layer, and the target online network layer optimizes the initial prediction result to obtain the target prediction result. There is no restriction on this optimization process.
[0140] For example, the target online network layer optimizes the initial prediction results to obtain the target prediction results. The target online network layer does not modify the dimensions of the initial prediction results; it only optimizes and adjusts the values within the initial prediction results. For example, if the initial prediction results include prediction data for 144 time points, the target prediction results will include prediction data for 144 time points (i.e., the second data series for the future time interval, where the second data series includes prediction data for multiple time points in the future time interval).
[0141] For example, if the predicted operating data in the initial prediction results includes the optical module voltage, port error packet count, FEC data, and each channel's temperature, bias current, receive power, and transmit power, the predicted operating data in the target prediction results will also include the optical module voltage, port error packet count, FEC data, and each channel's temperature, bias current, receive power, and transmit power. The target online network layer may optimize the voltage and port error packet count, with no restrictions on this adjustment process.
[0142] After obtaining the predicted operating data at multiple time points in the future time interval, the health status of the target optical module can be determined based on the predicted operating data, and there is no restriction on the analysis process of the health status.
[0143] As can be seen from the above technical solutions, in this embodiment, the target optical module is predicted by combining the real operating data of the target optical module (voltage, number of port error packets, FEC data) and the real operating data of each channel of the target optical module (temperature, bias current, receiving power and transmitting power corresponding to each channel), thereby adopting a channel fusion method to fuse the data of all channels for prediction, thereby improving the prediction accuracy, and having the characteristics of high prediction efficiency, high prediction accuracy, and good long-term prediction effect. By selecting the target prediction model corresponding to the target optical module type for prediction, the most suitable target prediction model can be selected for prediction, further improving the prediction accuracy, improving the prediction speed, and improving the performance of the optical module prediction algorithm. An online network layer is added for different models, and the online network layer is trained online according to the actual scene data of the optical module of this model, thereby improving the adaptability of the online network layer.
[0144] Based on the same application concept as the above method, a data prediction device is proposed in the embodiment of the present application and applied to network equipment, see Figure 5 FIG. 1 is a schematic structural diagram of the device, which includes:
[0145] An acquisition module 51 is configured to acquire a first data sequence of a target optical module of a network device during a historical time interval, where the target optical module is any optical module among all optical modules of the network device, and the first data sequence includes real operating data at multiple time points during the historical time interval; wherein the real operating data includes a voltage and / or a number of error packets on a port of the target optical module, and further includes at least one of a temperature, a bias current, a received power, and a transmitted power corresponding to each channel of the target optical module;
[0146] a determination module 52, configured to determine a target optical module type based on the target channel number of the target optical module, and select a target prediction model corresponding to the target optical module type from all prediction models supported by the network device;
[0147] The processing module 53 is used to input the first data sequence into the target prediction model to obtain an initial prediction result, and determine the target prediction result based on the initial prediction result; wherein, the target prediction result includes a second data sequence of a future time interval, and the second data sequence includes predicted operating data of multiple time points in the future time interval, and the predicted operating data is used to determine the health status of the target optical module.
[0148] In an example, if the network device includes optical modules of K types of optical modules, the network device supports K prediction models, and the K prediction models correspond one-to-one to the K types of optical modules, and K is a positive integer; wherein, when the determination module 52 selects the target prediction model corresponding to the target optical module type from all prediction models supported by the network device, the target prediction model is the prediction model corresponding to the target optical module type.
[0149] In one example, the determining module 52 determines the target optical module type based on the target channel number of the target optical module, and is specifically configured to: determine, based on the target channel number of the target optical module, the optical module type corresponding to the target channel number as the target optical module type; wherein all optical modules of the network device support a total of K channel numbers, and the K channel numbers correspond one-to-one to the K optical module types;
[0150] Alternatively, based on the target number of channels and the target FEC type of the target optical module, the optical module type corresponding to the target number of channels and the target FEC type is determined as the target optical module type; wherein all optical modules of the network device support a total of K parameter pairs, the K parameter pairs correspond one-to-one to the K types of optical module types, and the parameter pairs include the number of channels and the FEC type; wherein the FEC type includes supporting FEC data and not supporting FEC data; if the target FEC type is supporting FEC data, then the actual operation data also includes the FEC data of the target optical module;
[0151] Or, based on the target channel number, target FEC type and configured target scene parameters of the target optical module, the optical module type corresponding to the target channel number, the target FEC type and the target scene parameters is determined as the target optical module type; wherein, all optical modules of the network device support a total of A parameter pairs, and are pre-configured with B scene parameters, and the K parameter sets composed of the A parameter pairs and the B scene parameters correspond one-to-one to the K types of optical module types; the scene parameters include the total time length of the historical time interval, the time length of two adjacent time points in the historical time interval, the total time length of the future time interval, and the time length of two adjacent time points in the future time interval.
[0152] In one example, when the processing module 53 determines the target prediction result based on the initial prediction result, it is specifically used to: determine the initial prediction result as the target prediction result; or, based on the target model corresponding to the target optical module, select a target online network layer corresponding to the target model from all online network layers supported by the network device; wherein, all optical modules of the network device support a total of M models, the network device supports M online network layers, the M models correspond one-to-one to the M online network layers, and M is a positive integer; input the initial prediction result into the target online network layer, and optimize the initial prediction result through the target online network layer to obtain the target prediction result.
[0153] In one example, the target prediction model includes an iTransformer network; wherein the iTransformer network includes an embedding network layer, a multi-attention network layer, a first normalization network layer, a feedforward network layer, a second normalization network layer, and a prediction network layer; wherein, when the processing module 53 inputs the first data sequence into the target prediction model to obtain an initial prediction result, it is specifically used to:
[0154] Inputting the first data sequence into the embedding network layer to obtain a first feature vector;
[0155] Obtain a Q vector, a K vector, and a V vector based on the first feature vector, and input the Q vector, the K vector, and the V vector into the multivariate attention network layer to obtain a second feature vector;
[0156] generating a third eigenvector based on the first eigenvector and the second eigenvector;
[0157] Inputting the third eigenvector into the first normalized network layer to obtain a fourth eigenvector;
[0158] Inputting the fourth eigenvector into the feedforward network layer to obtain a fifth eigenvector;
[0159] generating a sixth eigenvector based on the fourth eigenvector and the fifth eigenvector;
[0160] Inputting the sixth eigenvector into the second normalized network layer to obtain a seventh eigenvector;
[0161] The seventh eigenvector is input into the prediction network layer to obtain the initial prediction result.
[0162] Based on the same application concept as the above method, an electronic device is proposed in the embodiment of the present application, see Figure 6As shown, the electronic device includes: a processor 61 and a machine-readable storage medium 62, the machine-readable storage medium 62 stores machine-executable instructions that can be executed by the processor 61; the processor 61 is used to execute the machine-executable instructions to implement the data prediction method disclosed in the above example of this application.
[0163] Based on the same application concept as the above method, an embodiment of the present application also provides a machine-readable storage medium, on which a number of computer instructions are stored. When the computer instructions are executed by a processor, the data prediction method disclosed in the above example of the present application can be implemented.
[0164] The machine-readable storage medium may be any electronic, magnetic, optical, or other physical storage device that may contain or store information, such as executable instructions, data, and the like. For example, the machine-readable storage medium may be: RAM (Random Access Memory), volatile memory, non-volatile memory, flash memory, a storage drive (such as a hard disk drive), a solid-state drive, any type of storage disk (such as a CD, DVD, etc.), or similar storage media, or a combination thereof.
[0165] Based on the same application concept as the above method, an embodiment of the present application further provides a computer program product, which may include a computer program. When the computer program is executed by a processor, it can implement the data prediction method disclosed in the above example of the present application.
[0166] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may take the form of a fully hardware embodiment, a fully software embodiment, or an embodiment combining software and hardware. Furthermore, the embodiments of the present application may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0167] The foregoing is merely an embodiment of the present application and is not intended to limit the present application. For those skilled in the art, the present application may have various changes and variations. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the present application should all be included within the scope of the claims of the present application.
Claims
1. A data prediction method, characterized in that: The method comprises: Obtaining a first data sequence of a target optical module of a network device in a historical time interval, where the target optical module is any optical module among all optical modules of the network device, and the first data sequence includes real operating data of multiple time points in the historical time interval; wherein the real operating data includes a voltage and / or a number of port error packets of the target optical module, and the real operating data also includes at least one of a temperature, a bias current, a received power, and a transmitted power corresponding to each channel of the target optical module; wherein the target optical module includes multiple channels, and the multiple channels transmit and receive data in parallel; Determining a target optical module type based on the target channel number of the target optical module, and selecting a target prediction model corresponding to the target optical module type from all prediction models supported by the network device; wherein, if the network device includes optical modules of K types of optical modules, the network device supports K prediction models, and the K prediction models correspond one-to-one to the K types of optical modules, where K is a positive integer; The first data sequence is input into the target prediction model to obtain an initial prediction result, and a target prediction result is determined based on the initial prediction result; wherein, the target prediction result includes a second data sequence of a future time interval, the second data sequence includes predicted operating data of multiple time points in the future time interval, and the predicted operating data is used to determine the health status of the target optical module.
2. The method according to claim 1, characterized in that The determining of the target prediction result based on the initial prediction result includes: Based on the target model corresponding to the target optical module, a target online network layer corresponding to the target model is selected from all online network layers supported by the network device; wherein, all optical modules of the network device support a total of M models, the network device supports M online network layers, the M models correspond one-to-one to the M online network layers, and M is a positive integer; the initial prediction result is input into the target online network layer, and the initial prediction result is optimized by the target online network layer to obtain the target prediction result.
3. The method according to claim 2, characterized in that For each online network layer supported by the network device, the training process of the online network layer includes: Obtaining an initial network layer to be trained and obtaining sample data generated by a sample optical module, where the sample optical module is any optical module among all optical modules of the network device; training the initial network layer based on the sample data to obtain an online network layer corresponding to the model of the sample optical module; The sample data includes a first sample sequence in a first time interval and a second sample sequence in a second time interval, the total time length of the first time interval corresponds to the total time length of the historical time interval, and the total time length of the second time interval corresponds to the total time length of the future time interval; The initial network layer is trained based on the sample data to obtain an online network layer corresponding to the model of the sample optical module, specifically including: inputting the first sample sequence into a prediction model corresponding to the optical module type of the sample optical module to obtain an initial prediction result, inputting the initial prediction result into the initial network layer to obtain a target prediction result, and determining a loss value based on the target prediction result and the second sample sequence; freezing the network parameters of the prediction model, and adjusting the network parameters of the initial network layer based on the loss value to obtain an online network layer corresponding to the model of the sample optical module.
4. The method according to claim 1, wherein The target prediction model includes an iTransformer network, which includes an embedding network layer, a multi-attention network layer, a first normalization network layer, a feedforward network layer, a second normalization network layer, and a prediction network layer; Inputting the first data sequence into the target prediction model to obtain an initial prediction result includes: Inputting the first data sequence into the embedding network layer to obtain a first feature vector; Obtain a Q vector, a K vector, and a V vector based on the first feature vector, and input the Q vector, the K vector, and the V vector into the multivariate attention network layer to obtain a second feature vector; generating a third eigenvector based on the first eigenvector and the second eigenvector; Inputting the third eigenvector into the first normalized network layer to obtain a fourth eigenvector; Inputting the fourth eigenvector into the feedforward network layer to obtain a fifth eigenvector; generating a sixth eigenvector based on the fourth eigenvector and the fifth eigenvector; Inputting the sixth eigenvector into the second normalized network layer to obtain a seventh eigenvector; The seventh eigenvector is input into the prediction network layer to obtain the initial prediction result.
5. A data prediction method, characterized in that: The method comprises: Obtaining a first data sequence of a target optical module of a network device in a historical time interval, where the target optical module is any optical module among all optical modules of the network device, and the first data sequence includes real operating data of multiple time points in the historical time interval; wherein the real operating data includes a voltage and / or a number of port error packets of the target optical module, and the real operating data also includes at least one of a temperature, a bias current, a received power, and a transmitted power corresponding to each channel of the target optical module; wherein the target optical module includes multiple channels, and the multiple channels transmit and receive data in parallel; Determine the target optical module type based on the target number of channels and the target FEC type of the target optical module, and select a target prediction model corresponding to the target optical module type from all prediction models supported by the network device; wherein, if the network device includes optical modules of K types of optical module types, then the network device supports K prediction models, and the K prediction models correspond one-to-one to the K types of optical module types, and K is a positive integer; wherein all optical modules of the network device support a total of K parameter pairs, and the K parameter pairs correspond one-to-one to the K types of optical module types, and the parameter pairs include the number of channels and the FEC type; wherein the FEC type includes supporting FEC data and not supporting FEC data; The first data sequence is input into the target prediction model to obtain an initial prediction result, and a target prediction result is determined based on the initial prediction result; wherein, the target prediction result includes a second data sequence of a future time interval, the second data sequence includes predicted operating data of multiple time points in the future time interval, and the predicted operating data is used to determine the health status of the target optical module.
6. The method according to claim 5, characterized in that The determining of the target prediction result based on the initial prediction result includes: Based on the target model corresponding to the target optical module, a target online network layer corresponding to the target model is selected from all online network layers supported by the network device; wherein, all optical modules of the network device support a total of M models, the network device supports M online network layers, the M models correspond one-to-one to the M online network layers, and M is a positive integer; the initial prediction result is input into the target online network layer, and the initial prediction result is optimized by the target online network layer to obtain the target prediction result.
7. The method according to claim 6, characterized in that For each online network layer supported by the network device, the training process of the online network layer includes: Obtaining an initial network layer to be trained and obtaining sample data generated by a sample optical module, where the sample optical module is any optical module among all optical modules of the network device; training the initial network layer based on the sample data to obtain an online network layer corresponding to the model of the sample optical module; The sample data includes a first sample sequence in a first time interval and a second sample sequence in a second time interval, the total time length of the first time interval corresponds to the total time length of the historical time interval, and the total time length of the second time interval corresponds to the total time length of the future time interval; The initial network layer is trained based on the sample data to obtain an online network layer corresponding to the model of the sample optical module, specifically including: inputting the first sample sequence into a prediction model corresponding to the optical module type of the sample optical module to obtain an initial prediction result, inputting the initial prediction result into the initial network layer to obtain a target prediction result, and determining a loss value based on the target prediction result and the second sample sequence; freezing the network parameters of the prediction model, and adjusting the network parameters of the initial network layer based on the loss value to obtain an online network layer corresponding to the model of the sample optical module.
8. The method according to claim 5, characterized in that The target prediction model includes an iTransformer network, which includes an embedding network layer, a multi-attention network layer, a first normalization network layer, a feedforward network layer, a second normalization network layer, and a prediction network layer; Inputting the first data sequence into the target prediction model to obtain an initial prediction result includes: Inputting the first data sequence into the embedding network layer to obtain a first feature vector; Obtain a Q vector, a K vector, and a V vector based on the first feature vector, and input the Q vector, the K vector, and the V vector into the multivariate attention network layer to obtain a second feature vector; generating a third eigenvector based on the first eigenvector and the second eigenvector; Inputting the third eigenvector into the first normalized network layer to obtain a fourth eigenvector; Inputting the fourth eigenvector into the feedforward network layer to obtain a fifth eigenvector; generating a sixth eigenvector based on the fourth eigenvector and the fifth eigenvector; Inputting the sixth eigenvector into the second normalized network layer to obtain a seventh eigenvector; The seventh eigenvector is input into the prediction network layer to obtain the initial prediction result.
9. A data prediction method, characterized in that: The method comprises: Obtaining a first data sequence of a target optical module of a network device in a historical time interval, where the target optical module is any optical module among all optical modules of the network device, and the first data sequence includes real operating data of multiple time points in the historical time interval; wherein the real operating data includes a voltage and / or a number of port error packets of the target optical module, and the real operating data also includes at least one of a temperature, a bias current, a received power, and a transmitted power corresponding to each channel of the target optical module; wherein the target optical module includes multiple channels, and the multiple channels transmit and receive data in parallel; Based on the target channel number, target FEC type and configured target scene parameters of the target optical module, determine the target optical module type, and select a target prediction model corresponding to the target optical module type from all prediction models supported by the network device; wherein, if the network device includes optical modules of K types of optical module types, the network device supports K prediction models, and the K prediction models correspond one-to-one to the K types of optical module types, and K is a positive integer; all optical modules of the network device support a total of A parameter pairs, and are pre-configured with B scene parameters, and the K parameter sets composed of the A parameter pairs and the B scene parameters correspond one-to-one to the K types of optical module types; the parameter pairs include the number of channels and the FEC type, and the FEC type includes supporting FEC data and not supporting FEC data; the scene parameters include the total time length of the historical time interval, the time length of two adjacent time points in the historical time interval, the total time length of the future time interval, and the time length of two adjacent time points in the future time interval; The first data sequence is input into the target prediction model to obtain an initial prediction result, and a target prediction result is determined based on the initial prediction result; wherein, the target prediction result includes a second data sequence of a future time interval, the second data sequence includes predicted operating data of multiple time points in the future time interval, and the predicted operating data is used to determine the health status of the target optical module.
10. The method according to claim 9, characterized in that The determining of the target prediction result based on the initial prediction result includes: Based on the target model corresponding to the target optical module, a target online network layer corresponding to the target model is selected from all online network layers supported by the network device; wherein, all optical modules of the network device support a total of M models, the network device supports M online network layers, the M models correspond one-to-one to the M online network layers, and M is a positive integer; the initial prediction result is input into the target online network layer, and the initial prediction result is optimized by the target online network layer to obtain the target prediction result.
11. The method according to claim 10, characterized in that For each online network layer supported by the network device, the training process of the online network layer includes: Obtaining an initial network layer to be trained and obtaining sample data generated by a sample optical module, where the sample optical module is any optical module among all optical modules of the network device; training the initial network layer based on the sample data to obtain an online network layer corresponding to the model of the sample optical module; The sample data includes a first sample sequence in a first time interval and a second sample sequence in a second time interval, the total time length of the first time interval corresponds to the total time length of the historical time interval, and the total time length of the second time interval corresponds to the total time length of the future time interval; The initial network layer is trained based on the sample data to obtain an online network layer corresponding to the model of the sample optical module, specifically including: inputting the first sample sequence into a prediction model corresponding to the optical module type of the sample optical module to obtain an initial prediction result, inputting the initial prediction result into the initial network layer to obtain a target prediction result, and determining a loss value based on the target prediction result and the second sample sequence; freezing the network parameters of the prediction model, and adjusting the network parameters of the initial network layer based on the loss value to obtain an online network layer corresponding to the model of the sample optical module.
12. The method according to claim 9, characterized in that The target prediction model includes an iTransformer network, which includes an embedding network layer, a multi-attention network layer, a first normalization network layer, a feedforward network layer, a second normalization network layer, and a prediction network layer; Inputting the first data sequence into the target prediction model to obtain an initial prediction result includes: Inputting the first data sequence into the embedding network layer to obtain a first feature vector; Obtain a Q vector, a K vector, and a V vector based on the first feature vector, and input the Q vector, the K vector, and the V vector into the multivariate attention network layer to obtain a second feature vector; generating a third eigenvector based on the first eigenvector and the second eigenvector; Inputting the third eigenvector into the first normalized network layer to obtain a fourth eigenvector; Inputting the fourth eigenvector into the feedforward network layer to obtain a fifth eigenvector; generating a sixth eigenvector based on the fourth eigenvector and the fifth eigenvector; Inputting the sixth eigenvector into the second normalized network layer to obtain a seventh eigenvector; The seventh eigenvector is input into the prediction network layer to obtain the initial prediction result.
13. A data prediction device, characterized in that: The device comprises: An acquisition module is configured to acquire a first data sequence of a target optical module of a network device in a historical time interval, where the target optical module is any optical module among all optical modules of the network device, and the first data sequence includes real operating data of multiple time points in the historical time interval; wherein the real operating data includes the voltage and / or the number of port error packets of the target optical module, and the real operating data also includes at least one of the temperature, bias current, receive power, and transmit power corresponding to each channel of the target optical module; the target optical module includes multiple channels, and the multiple channels transmit and receive data in parallel; A determination module, configured to determine a target optical module type based on the target channel number of the target optical module, and select a target prediction model corresponding to the target optical module type from all prediction models supported by the network device; wherein, if the network device includes optical modules of K types of optical modules, the network device supports K prediction models, and the K prediction models correspond one-to-one to the K types of optical modules, where K is a positive integer; A processing module is used to input the first data sequence into the target prediction model to obtain an initial prediction result, and determine a target prediction result based on the initial prediction result; wherein, the target prediction result includes a second data sequence of a future time interval, and the second data sequence includes predicted operating data of multiple time points in the future time interval, and the predicted operating data is used to determine the health status of the target optical module.
14. The device according to claim 13, characterized in that The processing module is specifically configured to determine the target prediction result based on the initial prediction result: Based on the target model corresponding to the target optical module, a target online network layer corresponding to the target model is selected from all online network layers supported by the network device; wherein, all optical modules of the network device support a total of M models, the network device supports M online network layers, the M models correspond one-to-one to the M online network layers, and M is a positive integer; the initial prediction result is input into the target online network layer, and the initial prediction result is optimized by the target online network layer to obtain the target prediction result.
15. The device according to claim 13, characterized in that The target prediction model includes an iTransformer network; wherein the iTransformer network includes an embedding network layer, a multivariate attention network layer, a first normalization network layer, a feedforward network layer, a second normalization network layer, and a prediction network layer; wherein, when the processing module inputs the first data sequence into the target prediction model to obtain an initial prediction result, it is specifically used to: Inputting the first data sequence into the embedding network layer to obtain a first feature vector; Obtain a Q vector, a K vector, and a V vector based on the first feature vector, and input the Q vector, the K vector, and the V vector into the multivariate attention network layer to obtain a second feature vector; generating a third eigenvector based on the first eigenvector and the second eigenvector; Inputting the third eigenvector into the first normalized network layer to obtain a fourth eigenvector; Inputting the fourth eigenvector into the feedforward network layer to obtain a fifth eigenvector; generating a sixth eigenvector based on the fourth eigenvector and the fifth eigenvector; Inputting the sixth eigenvector into the second normalized network layer to obtain a seventh eigenvector; The seventh eigenvector is input into the prediction network layer to obtain the initial prediction result.
16. A data prediction device, characterized in that: The device comprises: An acquisition module is configured to acquire a first data sequence of a target optical module of a network device in a historical time interval, where the target optical module is any optical module among all optical modules of the network device, and the first data sequence includes real operating data of multiple time points in the historical time interval; wherein the real operating data includes the voltage and / or the number of port error packets of the target optical module, and the real operating data also includes at least one of the temperature, bias current, receive power, and transmit power corresponding to each channel of the target optical module; the target optical module includes multiple channels, and the multiple channels transmit and receive data in parallel; A determination module is configured to determine a target optical module type based on a target number of channels and a target FEC type of the target optical module, and select a target prediction model corresponding to the target optical module type from all prediction models supported by the network device; wherein, if the network device includes optical modules of K types of optical module types, the network device supports K prediction models, and the K prediction models correspond one-to-one to the K types of optical module types, where K is a positive integer; wherein all optical modules of the network device support a total of K parameter pairs, and the K parameter pairs correspond one-to-one to the K types of optical module types, and the parameter pairs include the number of channels and the FEC type; wherein the FEC type includes supporting FEC data and not supporting FEC data; A processing module is used to input the first data sequence into the target prediction model to obtain an initial prediction result, and determine a target prediction result based on the initial prediction result; wherein, the target prediction result includes a second data sequence of a future time interval, and the second data sequence includes predicted operating data of multiple time points in the future time interval, and the predicted operating data is used to determine the health status of the target optical module.
17. The device according to claim 16, characterized in that The processing module is specifically configured to determine the target prediction result based on the initial prediction result: Based on the target model corresponding to the target optical module, a target online network layer corresponding to the target model is selected from all online network layers supported by the network device; wherein, all optical modules of the network device support a total of M models, the network device supports M online network layers, the M models correspond one-to-one to the M online network layers, and M is a positive integer; the initial prediction result is input into the target online network layer, and the initial prediction result is optimized by the target online network layer to obtain the target prediction result.
18. The device according to claim 16, characterized in that The target prediction model includes an iTransformer network; wherein the iTransformer network includes an embedding network layer, a multivariate attention network layer, a first normalization network layer, a feedforward network layer, a second normalization network layer, and a prediction network layer; wherein, when the processing module inputs the first data sequence into the target prediction model to obtain an initial prediction result, it is specifically used to: Inputting the first data sequence into the embedding network layer to obtain a first feature vector; Obtain a Q vector, a K vector, and a V vector based on the first feature vector, and input the Q vector, the K vector, and the V vector into the multivariate attention network layer to obtain a second feature vector; generating a third eigenvector based on the first eigenvector and the second eigenvector; Inputting the third eigenvector into the first normalized network layer to obtain a fourth eigenvector; Inputting the fourth eigenvector into the feedforward network layer to obtain a fifth eigenvector; generating a sixth eigenvector based on the fourth eigenvector and the fifth eigenvector; Inputting the sixth eigenvector into the second normalized network layer to obtain a seventh eigenvector; The seventh eigenvector is input into the prediction network layer to obtain the initial prediction result.
19. A data prediction device, characterized in that: The device comprises: An acquisition module is configured to acquire a first data sequence of a target optical module of a network device in a historical time interval, where the target optical module is any optical module among all optical modules of the network device, and the first data sequence includes real operating data of multiple time points in the historical time interval; wherein the real operating data includes the voltage and / or the number of port error packets of the target optical module, and the real operating data also includes at least one of the temperature, bias current, receive power, and transmit power corresponding to each channel of the target optical module; the target optical module includes multiple channels, and the multiple channels transmit and receive data in parallel; A determination module is used to determine the target optical module type based on the target channel number, target FEC type and configured target scene parameters of the target optical module, and select a target prediction model corresponding to the target optical module type from all prediction models supported by the network device; wherein, if the network device includes optical modules of K types of optical modules, the network device supports K prediction models, and the K prediction models correspond one-to-one to the K types of optical module types, and K is a positive integer; all optical modules of the network device support a total of A parameter pairs, and are pre-configured with B scene parameters, and the K parameter sets composed of the A parameter pairs and the B scene parameters correspond one-to-one to the K types of optical module types; the parameter pairs include the number of channels and the FEC type, and the FEC type includes supporting FEC data and not supporting FEC data; the scene parameters include the total time length of a historical time interval, the time length of two adjacent time points in the historical time interval, the total time length of a future time interval, and the time length of two adjacent time points in the future time interval; A processing module is used to input the first data sequence into the target prediction model to obtain an initial prediction result, and determine a target prediction result based on the initial prediction result; wherein, the target prediction result includes a second data sequence of a future time interval, and the second data sequence includes predicted operating data of multiple time points in the future time interval, and the predicted operating data is used to determine the health status of the target optical module.
20. The device according to claim 19, characterized in that The processing module is specifically configured to determine the target prediction result based on the initial prediction result: Based on the target model corresponding to the target optical module, a target online network layer corresponding to the target model is selected from all online network layers supported by the network device; wherein, all optical modules of the network device support a total of M models, the network device supports M online network layers, the M models correspond one-to-one to the M online network layers, and M is a positive integer; the initial prediction result is input into the target online network layer, and the initial prediction result is optimized by the target online network layer to obtain the target prediction result.
21. The device according to claim 19, characterized in that The target prediction model includes an iTransformer network; wherein the iTransformer network includes an embedding network layer, a multivariate attention network layer, a first normalization network layer, a feedforward network layer, a second normalization network layer, and a prediction network layer; wherein, when the processing module inputs the first data sequence into the target prediction model to obtain an initial prediction result, it is specifically used to: Inputting the first data sequence into the embedding network layer to obtain a first feature vector; Obtain a Q vector, a K vector, and a V vector based on the first feature vector, and input the Q vector, the K vector, and the V vector into the multivariate attention network layer to obtain a second feature vector; generating a third eigenvector based on the first eigenvector and the second eigenvector; Inputting the third eigenvector into the first normalized network layer to obtain a fourth eigenvector; Inputting the fourth eigenvector into the feedforward network layer to obtain a fifth eigenvector; generating a sixth eigenvector based on the fourth eigenvector and the fifth eigenvector; Inputting the sixth eigenvector into the second normalized network layer to obtain a seventh eigenvector; The seventh eigenvector is input into the prediction network layer to obtain the initial prediction result.
22. An electronic device, characterized in that: include: a processor and a machine-readable storage medium storing machine-executable instructions capable of being executed by the processor; The processor is configured to execute machine-executable instructions to implement the method according to any one of claims 1 to 12.
Citation Information
Patent Citations
Optical module performance prediction method and device, electronic equipment and storage medium
CN115146532A