A distributed optical fiber vibration signal recognition method based on space-time attention mechanism
By using a spatiotemporal attention mechanism, a two-dimensional spatiotemporal matrix is reconstructed and phase increment weighted compensation and channel repair are performed. Combined with U-Net and bidirectional long short-term memory network, the problem of high false alarm rate in distributed optical fiber vibration signal identification methods under complex environments is solved, and higher identification accuracy and system stability are achieved.
Patent Information
- Application Number
- CN202611683422.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-10-29
- Publication Date
- 2026-11-27
AI Technical Summary
Existing distributed optical fiber vibration signal identification methods have a high false alarm rate in noisy and complex environments, cannot effectively capture the coupling characteristics of vibration signals in the spatial and temporal dimensions of optical fibers, and lack an active suppression mechanism for coherent fading phenomena.
A spatiotemporal attention-based approach is adopted to reconstruct a two-dimensional spatiotemporal matrix, utilize reliable spatial neighborhoods for phase increment weighting compensation and channel repair, and combine a U-Net two-dimensional denoising network and a bidirectional long short-term memory network to extract spatial morphology and temporal evolution features for vibration event classification.
It effectively suppresses the interference of coherent fading, improves the system signal-to-noise ratio, enhances the accuracy of vibration signal identification, reduces the false alarm rate, and meets the needs of industrial applications.
Smart Images

Figure CN123179135A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of optical fiber vibration signal recognition technology, and in particular to a distributed optical fiber vibration signal recognition method based on a spatiotemporal attention mechanism. Background Technology
[0002] Distributed fiber optic sensing technology detects external vibrations by laying sensing fibers along the monitoring area and is widely used in fields such as perimeter intrusion alarms. Among these, a distributed fiber optic acoustic sensing system based on a phase-sensitive optical time-domain reflectometer injects narrow-linewidth laser pulses into the sensing fiber and utilizes Rayleigh backscattered light interference within the fiber to demodulate strain or acoustic wave information applied to the fiber. Existing technical solutions typically involve extracting phase information using Hilbert transform or orthogonal demodulation, and then using traditional bandpass filters or wavelet transforms to filter and denoise the one-dimensional time series signal at a single spatial sampling point. Finally, the signal is input into a support vector machine or a one-dimensional convolutional neural network for event classification such as mining, climbing, and knocking.
[0003] However, the existing technologies still have the following drawbacks. First, directly filtering the demodulated phase signal lacks an active suppression mechanism for coherent fading. Due to the random distribution of scattering centers in the fiber, the interference light intensity at some locations approaches zero, and the demodulated phase exhibits shot noise with random jumps. Direct filtering cannot recover the true vibration at these locations, leading to missed detections. Second, existing denoising methods only process one-dimensional time series at a single spatial point, ignoring the spatial broadening effect of physical vibration propagating along the fiber axis. This disrupts the spatial correlation of the fiber signal, easily misjudging real weak high-frequency vibrations as isolated noise and filtering them out, thus reducing the system signal-to-noise ratio. Furthermore, existing support vector machines or one-dimensional convolutional neural networks can only extract local temporal features within a limited receptive field, failing to capture the coupling characteristics of vibration signals in the spatial and temporal dimensions of the fiber and the global dependence in the long spatiotemporal dimension. This results in a high false alarm rate in complex environments such as strong winds and rain, making it difficult to meet the needs of industrial applications. At present, a distributed fiber vibration signal identification method based on a spatiotemporal attention mechanism is needed. Summary of the Invention
[0004] To address the high false alarm rate in existing distributed optical fiber vibration signal identification methods under noisy and complex environments, this invention provides a distributed optical fiber vibration signal identification method based on a spatiotemporal attention mechanism.
[0005] In a first aspect, the present invention provides a distributed optical fiber vibration signal identification method based on a spatiotemporal attention mechanism, which adopts the following technical solution: A distributed optical fiber vibration signal identification method based on a spatiotemporal attention mechanism includes: S1. Obtain the vibration phase signal output by the distributed optical fiber sensing system and the corresponding in-phase demodulation signal and quadrature demodulation signal, and reconstruct the vibration phase signal into a two-dimensional spatiotemporal matrix according to the spatial and temporal dimensions. S2. Based on the combined amplitude of the in-phase demodulated signal and the quadrature demodulated signal, the fading point and the window-level low amplitude fading channel in the two-dimensional spatiotemporal matrix are detected. Phase increment weighted compensation, phase expansion and channel repair are performed using the reliable spatial neighborhood to obtain the anti-fading spatiotemporal matrix. S3. Input the anti-fading spatiotemporal matrix into a two-dimensional denoising network for spatiotemporal joint denoising to obtain the reconstructed spatiotemporal matrix; S4. Input the reconstructed spatiotemporal matrix into the parallel spatial stream and temporal stream respectively. Use convolution and channel attention in the spatial stream to extract spatial morphological features and obtain spatial feature vectors. Use bidirectional long short-term memory network and temporal attention in the temporal stream to extract temporal evolution features and obtain temporal feature vectors. S5. Based on the fusion of spatial feature vectors and temporal feature vectors, and after integration by a fully connected network, the probability of vibration events belonging to each predefined category is output to obtain the vibration event type within the current spatiotemporal window.
[0006] Furthermore, the step of reconstructing the vibration phase signal into a two-dimensional spatiotemporal matrix according to the spatial and temporal dimensions includes using a preset spatiotemporal window to extract the vibration phase signal of M consecutive spatial channels and N consecutive time sampling points to form an M×N two-dimensional spatiotemporal matrix, wherein the row index of the two-dimensional spatiotemporal matrix corresponds to the spatial channel and the column index corresponds to the time sampling point; Using the same spatiotemporal window and index as the vibration phase signal, the in-phase demodulated signal and the quadrature demodulated signal are synchronously intercepted and reconstructed to obtain multiple two-dimensional spatiotemporal matrices; Where M and N are both positive integers, M is the number of spatial channels within the preset spatiotemporal window, and N is the number of time sampling points within the preset spatiotemporal window.
[0007] Furthermore, the detection of fading points and window-level low-amplitude fading channels in the two-dimensional spatiotemporal matrix includes calculating the synthesized amplitude of the demodulated signal at each time point in the two-dimensional spatiotemporal matrix based on the in-phase demodulated signal and the quadrature demodulated signal when the vibration phase signal is demodulated. The synthesis amplitude and the preset fading threshold are compared. When comparing, At that time, determine the spatial point exist It is constantly in the decline zone; The average composite amplitude of each spatial channel within the same time window is calculated to obtain the window average composite amplitude of each spatial channel. ,when At that time, the corresponding spatial channel will be identified as a window-level low-amplitude fading channel; Calculate the standard deviation of the phase sequence of each spatial channel within the time window, and use the standard deviation to assist in screening the channels to be checked; in, For spatial points exist The synthesized amplitude of the demodulated signal at time t. The fading threshold, The spatial location of the nth spatial channel. For the j-th time, The average composite amplitude of the window for the nth spatial channel.
[0008] Furthermore, the phase increment weighted compensation using a reliable spatial neighborhood includes selecting spatial sampling points that are not determined to be window-level low-amplitude fading channels, and which are located within the fading zone at both the current and previous times, with the spatial location of the fading point as the center and a preset spatial distance R as the neighborhood radius, to form the effective spatial neighborhood corresponding to the fading point. For phase increments that fade at least at one end between two adjacent time points, the synthesized amplitude of the demodulated signal at the current time point of each sampling point in the effective spatial neighborhood is used as the weight to perform a weighted average of the phase increments of adjacent channels after principal optimization processing, to obtain the compensated phase increment. The expression for the amplitude-weighted interpolation compensation is as follows: , in, The phase increment after compensation. For Let m be the effective spatial neighborhood centered at R and with radius R, where m is the index of the effective spatial sampling point in the neighborhood. This represents the phase increment between adjacent sampling points in the neighborhood after principal optimization. For weighted weights, Spatial location The synthesized amplitude of the demodulated signal at time j.
[0009] Further, step S2 also includes subtracting an integer multiple of 2π from the original phase difference between the two adjacent ends so that it is located in the interval [-π,π), using a neighborhood compensation value for the phase increment that fades at least at one end in two adjacent time moments, and accumulating along the time axis to obtain a continuous phase change sequence for each non-window-level fading channel. The window-level low-amplitude fading channel is determined based on the average synthesis amplitude within the same window. Reliable spatial channels with complete and continuous phase change sequences are selected from within its preset radius. Each sequence is referenced by the starting phase of the window and normalized and weighted by the average synthesis amplitude of each reliable channel within the window. The weighted sequence replaces the phase change sequence of the window-level low-amplitude fading channel. The processed spatiotemporal matrix is subjected to adaptive gain adjustment and normalization to obtain the anti-fading spatiotemporal matrix.
[0010] Furthermore, the two-dimensional denoising network adopts a U-Net architecture network, including an encoder and a decoder, and inputs the anti-fading spatiotemporal matrix as a single-channel grayscale image into the two-dimensional denoising network; The encoder includes multiple convolutional blocks, each of which consists of a two-dimensional convolutional layer, a batch normalization layer, and a LeakyReLU activation function, and a max pooling layer is connected after each convolutional block for downsampling; The decoder includes multiple upsampling blocks. Each upsampling block uses deconvolution to recover the feature map size and uses skip connections to concatenate the feature maps of the corresponding scale in the encoder with the feature maps of the decoder in the channel dimension. The decoder outputs a reconstructed spatiotemporal matrix.
[0011] Further, step S3 also includes constructing a joint loss function using mean squared error loss and spatial structure similarity loss, and using the joint loss function to optimize the two-dimensional denoising network. The expression of the joint loss function is:
[0012] in, To reconstruct the matrix, For the baseline label matrix under the same index and normalization rules, Let Frobenius norm be the square of the norm, SSIM(·) be the structural similarity function, and α and β be non-negative loss weights that are not simultaneously zero.
[0013] Furthermore, the extraction of spatial morphological features includes convolving the reconstructed spatiotemporal matrix with a spatial asymmetric convolution kernel to extract long-term features within a single spatial channel, thereby obtaining a convolutional feature map. Global average pooling is used to compress the two-dimensional feature maps of each feature channel in the convolutional feature map into global scalar features, resulting in channel description vectors. Based on the channel description vector, the non-linear dependencies between feature channels are learned through a bottleneck structure containing fully connected layers, and the weight coefficient vector of each feature channel is output. The enhanced feature map is obtained by multiplying each weight coefficient by the corresponding feature channel in the convolutional feature map channel by channel. Global average pooling is then performed on the enhanced feature map to obtain the spatial feature vector. The expression for the weight coefficient vector is as follows: , in, This is the weight coefficient vector. The channel description vector, It is the ReLU activation function. It is the Sigmoid activation function. This is the dimensionality-reduced weight matrix for the first fully connected layer. This is the weight matrix of the second fully connected layer.
[0014] Furthermore, the extraction of temporal evolution features includes inputting the reconstructed spatiotemporal matrix along the time axis into a bidirectional long short-term memory network, extracting the temporal evolution features of the vibration signal using forward and backward contextual information, and outputting a temporal feature matrix. The dot product similarity between the hidden state vectors is calculated for the temporal feature matrix of each spatial channel, and Softmax normalization is performed on the dimension of the weighted time step for each query time step to generate the temporal attention matrix of that spatial channel. Multiply the temporal attention matrix of each spatial channel with the corresponding temporal feature matrix to obtain the attention-weighted temporal feature matrix; take the average along the time dimension, and then concatenate them in the order of the spatial channels to obtain a fixed-dimensional temporal feature vector.
[0015] Further, obtaining the vibration event type within the current spatiotemporal window includes concatenating the spatial feature vector and the temporal feature vector, inputting them into a fully connected network containing a Dropout layer for feature integration, obtaining integrated features, normalizing the integrated features through a Softmax layer, outputting the probability of the vibration event belonging to each predefined category, and determining the predefined category with the highest probability as the vibration event type within the current spatiotemporal window. The probability is calculated using the following formula: , in, Let be the probability that a vibration event within the current spatiotemporal window belongs to the i-th predefined category. For spatiotemporal fusion feature vectors, , Let be the learnable weight matrices for the i-th and j-th predefined categories in a fully connected network, respectively. , These are the bias terms corresponding to the i-th and j-th predefined categories, respectively. The total number of predefined categories.
[0016] In summary, the present invention has the following beneficial technical effects: 1. This invention utilizes demodulation and synthesis amplitude to perform sampling point-level detection and window-level channel detection respectively. Through phase increment weighting compensation and channel repair in reliable spatial neighborhood, it suppresses the interference of unreliable phase caused by coherent fading on subsequent identification.
[0017] 2. This invention uses 2π principalization and time accumulation to process phase winding, and repairs the window-level low-amplitude fading channel by removing the initial reference and using the adjacent channel continuous phase change sequence. Combined with gain adaptive adjustment and normalization, it improves the continuity and amplitude consistency of the network input.
[0018] 3. This invention inputs the anti-fading spatiotemporal matrix into a U-Net two-dimensional denoising network, uses encoders, decoders and skip connections to simultaneously characterize spatiotemporal correlation, and outputs the results by joint constraints of mean square error and structural similarity, so as to balance noise suppression and preservation of effective vibration structures.
[0019] 4. This invention sets up spatial feature extraction with channel attention and bidirectional temporal feature extraction with time attention in parallel, and fuses them to form an event representation, which helps to utilize the complementary information between spatial morphology and the moment of impact; the degree of performance improvement is evaluated through comparison and ablation experiments. Attached Figure Description
[0020] Figure 1 This is an overall architecture diagram of a distributed optical fiber vibration signal recognition method based on a spatiotemporal attention mechanism according to an embodiment of the present invention.
[0021] Figure 2 This is a diagram of the U-Net network architecture for two-dimensional spatiotemporal matrix denoising according to an embodiment of the present invention.
[0022] Figure 3 This is a diagram of the spatiotemporal attention mechanism dual-stream neural network architecture for vibration classification according to an embodiment of the present invention.
[0023] Figure 4 This is a schematic diagram of the overall process of a distributed optical fiber vibration signal identification method based on a spatiotemporal attention mechanism according to an embodiment of the present invention.
[0024] Figure 5 This is a flowchart of the anti-fading and denoising preprocessing algorithm according to an embodiment of the present invention. Detailed Implementation
[0025] The present invention will be further described in detail below with reference to the accompanying drawings.
[0026] Example 1 Reference Figure 1 This embodiment of a distributed optical fiber vibration signal identification method based on a spatiotemporal attention mechanism includes: S1. Obtain the vibration phase signal output by the distributed optical fiber sensing system and the corresponding in-phase demodulation signal and quadrature demodulation signal, and reconstruct the vibration phase signal into a two-dimensional spatiotemporal matrix according to the spatial and temporal dimensions. S2. Based on the combined amplitude of the in-phase demodulated signal and the quadrature demodulated signal, the fading point and the window-level low amplitude fading channel in the two-dimensional spatiotemporal matrix are detected. Phase increment weighted compensation, phase expansion and channel repair are performed using the reliable spatial neighborhood to obtain the anti-fading spatiotemporal matrix. S3. Input the anti-fading spatiotemporal matrix into a two-dimensional denoising network for spatiotemporal joint denoising to obtain the reconstructed spatiotemporal matrix; S4. Input the reconstructed spatiotemporal matrix into the parallel spatial stream and temporal stream respectively. Use convolution and channel attention in the spatial stream to extract spatial morphological features and obtain spatial feature vectors. Use bidirectional long short-term memory network and temporal attention in the temporal stream to extract temporal evolution features and obtain temporal feature vectors. S5. Based on the fusion of spatial feature vectors and temporal feature vectors, and after integration by a fully connected network, the probability of vibration events belonging to each predefined category is output to obtain the vibration event type within the current spatiotemporal window.
[0027] Specifically, a distributed optical fiber vibration signal identification method based on a spatiotemporal attention mechanism includes the following: like Figure 1 , Figure 4 As shown, S1, the distributed fiber optic sensing system injects narrow-linewidth laser pulses into the sensing fiber to receive Rayleigh backscattered light. The strain caused by external vibration modulates the phase of the backscattered light. After photoelectric detection and orthogonal demodulation, the in-phase component I and the quadrature component Q are obtained. The four-quadrant arctangent function is used to calculate the winding phase to retain quadrant information and maintain consistency with the subsequent 2π phase unfolding. , in, The phase is wrapped, and atan2(Q,I) is the arctangent function in the four quadrants. I(t) and Q(t) are the in-phase and quadrature demodulated components of the corresponding spatial channel at time t, respectively. When both components are close to the system noise floor, the phase is unreliable and is handled by the amplitude criterion in step S2. The system outputs the phase sequence and the corresponding I / Q sequence according to the spatial location and time point.
[0028] By setting a spatiotemporal sliding window, the entangled phase of M consecutive spatial channels and N consecutive temporal sampling points is extracted, and a two-dimensional spatiotemporal matrix X of size M×N is constructed. The matrix elements... Let be the phase demodulation value of the nth spatial channel at time j. The row index corresponds to the spatial channel, and the column index corresponds to the time sampling point. I, Q, and the synthesized amplitude all use the same index. The spatial sampling interval is denoted as ΔL, and the time sampling interval is denoted as Δt. In this embodiment, a spatial sampling interval of approximately 2m and a time window of approximately 2s can be used. The actual sampling rate and the number of sampling points within the window are determined according to the system configuration.
[0029] The sliding window moves along the spatial and temporal dimensions at preset steps, reconstructing a series of spatiotemporal matrices. To avoid different phase references from adjacent overlapping windows, the phase baselines can be aligned in the effective overlap area when stitching windows together. The matrices simultaneously retain the axial distribution and temporal evolution information of the vibrations.
[0030] S2. Perform coherent fading detection on the two-dimensional spatiotemporal matrix obtained in step S1. Due to the random distribution of scattering centers in the optical fiber, the interference light intensity at some spatial locations approaches zero, causing the demodulated signal at these locations to be submerged by the system noise floor. To locate such fading locations, calculate the composite amplitude of the demodulated signal at each spatial point in the two-dimensional spatiotemporal matrix at each time step based on the in-phase demodulated signal and the quadrature demodulated signal obtained from the vibration phase signal by orthogonal demodulation. The formula for calculating the composite amplitude of the demodulated signal is as follows: , in, , specifically For spatial points At any moment The synthesized amplitude of the demodulated signal is denoted as in the two-dimensional spatiotemporal matrix. , , These are the row and column indices corresponding to the spatial point and time within the current window, respectively. I and Q are the demodulated components at the same spatial location and time.
[0031] With preset amplitude threshold Constructing a sampling point-level mask : , in, =1 indicates that the phase of this sampling point is unreliable. =0 indicates that the phase of the sampling point is reliable. This indicates the preset amplitude threshold.
[0032] It should be noted that the above-mentioned preset amplitude threshold This is not a fixed constant independent of the equipment, but a relative quantity calibrated based on the system's noise floor level before system operation. Its establishment is based on the fact that the interference light intensity at the coherent fading point approaches zero, and both the in-phase component I and the quadrature component Q degenerate to the system noise floor. At this point, the four-quadrant arctangent demodulation result is dominated by noise. Therefore, the criterion is whether the synthesized amplitude degenerates to the noise floor level. Calibration can be performed using any of the following methods: Method 1: Noise Floor Multiplier Method. Background data is collected under static conditions without external disturbance, and the root mean square value of the synthesized amplitude is taken as the noise floor benchmark. and take , This is a preset multiplier, usually set to 2 to 5, which is about 6 to 14 dB higher than the noise floor. Method 2: Statistical quantile method. This involves statistically determining the empirical distribution of all A(n,j) in the records and taking the lowest quantile (usually the 5th to 10th percentile) as the statistical quantile. This method utilizes the statistical properties that the synthesized amplitude of Rayleigh backscattering approximately follows a Rayleigh distribution and that the fading points are only a minority; Method 3: Relative Mean Method, taking... , The preset scaling factor is typically set to 0.2–0.3. Increasing the values of κ, quantiles, or η increases the number of sampling points identified as fading, expanding the phase compensation coverage area, but may also compensate for normal low-amplitude sampling points; decreasing these values may miss deep fading points. The above thresholds and their calibration methods are determined solely based on training and validation data and remain fixed during the testing phase.
[0033] like Figure 5 As shown, the window-level low-amplitude fading channels are then determined. A fading point is a low-amplitude sampling point at a specific spatial location at a certain time, while a fading channel is a spatial channel within the same window with an overall low synthesized amplitude. They have different processing granularities: scattered fading points are compensated using local phase increments, while window-level low-amplitude fading channels are repaired using a complete and continuous sequence of reliable adjacent channels. The channel criterion is given by the average synthesized amplitude within the window. , in, This indicates a window-level low-amplitude fading channel. This indicates that the fading criterion for this channel is not met; 1[·] is an indicator function that takes 1 if the condition is met and 0 otherwise. This criterion describes that the average amplitude of the window is low, which does not mean that every sampling point in the window is fading, nor can the fading of the entire channel be directly inferred from a single fading point.
[0034] The above window-level criterion uses the average composite amplitude of the window. With sampling point level threshold The comparison implies that the average synthesized amplitude of the spatial channel within the entire time window has degraded to below the sampling point-level fading threshold, corresponding to a channel that is continuously in a deep fading state; this condition is relatively conservative, only applicable when the amplitude is low for most of the time within the window. Only then will it be lower than Therefore, scattered fading points will not trigger full channel repair.
[0035] To improve the robustness of the judgment, the proportion of the sampling point-level mask within the window can also be calculated simultaneously. and with and This also serves as a criterion for determining a window-level low-amplitude fading channel. The preset percentage threshold is usually set to 0.5 to 0.8. At this time, channels with average amplitude close to the threshold but sparse distribution of fading points are not replaced as whole channels, but only their scattered fading points are compensated locally.
[0036] As another alternative implementation, an independent threshold can be set for the channel-level criterion. , The preset coefficient, typically between 1.0 and 1.5, allows for individual adjustment of the triggering conditions for whole-channel repair without altering the detection sensitivity at the sampling point level. The aforementioned criteria rely solely on the existing I and Q sequences from the quadrature demodulation and their synthesized amplitudes. The calculations involve summation, averaging, threshold comparison, and counting within a window, requiring no additional hardware and can be implemented in real-time within the existing data processing flow of a phase-sensitive optical time-domain reflectometer.
[0037] Then, standard deviation testing is used as an auxiliary verification: the standard deviation of the phase sequence within this window is calculated. Less than the preset threshold The channel was then added to the set to be checked. The final fading marker was still confirmed by the synthesized amplitude criterion. A low phase standard deviation may also correspond to a normal channel without vibration. Therefore, it is not advisable to rely solely on the following criteria: Alternative amplitude detection, standard deviation The calculation formula is: , in, This represents the average phase of the nth spatial channel within the current time window. Two-dimensional spacetime matrix X The element in the nth row and jth column represents the phase demodulation value of the nth spatial channel at the jth time. This represents the total number of time sampling points within the current time window.
[0038] The above-mentioned preset threshold Similarly, the calibration is based on the system phase noise level. This is based on the fact that in channels continuously experiencing deep fading, the demodulated phase is dominated by noise, and after principal optimization, the fluctuation range within the window is limited, resulting in a small phase standard deviation. Significantly lower than channels where actual vibrations exist; however, quiet channels without events may also have lower [percentages]. Therefore, this condition is only used to narrow down the scope of verification and is not used as a sole basis for determining fading.
[0039] The calibration method is as follows: Statistical analysis of each channel is performed on background records where no events have been confirmed. Based on the empirical distribution, its low quantile (usually the 5th to 10th percentile) is taken as... , or take c is a preset coefficient, usually taken as 0.3 to 0.5; when expressed in radians, its order of magnitude is usually [missing value]. The specific value varies with the system's phase noise level. Since the final fading criterion is still determined by the synthesized amplitude criterion... confirm, A larger value only increases the number of channels to be checked and does not directly lead to misjudgment; a smaller value may miss some fading channels. This threshold is also determined only through training and validation data.
[0040] For channels not identified as window-level low-amplitude fading channels The scattered decay points existing in the space, in terms of spatial location Candidate neighborhoods are determined with the center as the center and a preset spatial distance R as the radius, where, , The preset positive integer channel radius, The spatial sampling interval is defined as follows: Candidate channels must be located within the same spatially correlated local vibration region as the target location to ensure that their phase changes can be used to characterize the true vibration at the target point.
[0041] Furthermore, for the phase increment at time j (j≥2), since the phase increment is composed of the phase difference between two adjacent times, it is required that the adjacent channel is not in the fading region at both time j and time j-1, and is not marked as a window-level low-amplitude fading channel, thus obtaining the effective neighborhood: , in, Let the effective spatial neighborhood be centered on the nth spatial channel at the jth time. This is the index of the effective spatial sampling points in the neighborhood. This indicates that adjacent channel m was not identified as a window-level low-amplitude fading channel. This indicates that the sampling point-level mask of adjacent channel m at time j and time j-1 are both 0, meaning that the demodulation phase of this adjacent channel is reliable at both adjacent times. The reason for requiring reliability at both times is that the phase increment used for subsequent compensation is composed of the phase difference between these two times. If either end is in a fading state, this phase difference will be dominated by the noise floor and cannot characterize the true vibration. (Condition) This indicates that the spatial distance between the adjacent channel m and the target channel n does not exceed the neighborhood radius R and is not zero, thus excluding the target channel itself and limiting the adjacent channels participating in the compensation to the same local vibration region that has spatial correlation with the target point. Therefore, Ω(n,j) is the set of adjacent channel indices that can actually be used to compensate the nth spatial channel at the j-th time, and this set changes dynamically with time.
[0042] This neighborhood is a one-dimensional distance interval along the fiber optic axis, including effective channels on both sides of the target point; at the fiber end or window boundary, only channels that actually exist and meet the conditions are selected. R is calibrated before operation based on the system spatial resolution and vibration influence range, and should not cross unrelated vibration areas in order to obtain adjacent channels.
[0043] For effective spatial neighborhood For each valid adjacent channel, the original winding phase difference between its two adjacent time points is first calculated, and then mapped to a principal value function. To avoid mistaking the 2π winding transition as the true phase increment, the principal-valued phase increment is calculated using the following formula: , The principal value function is defined as follows: , in, Let m be the phase increment of adjacent channel m after principal optimization from time j-1 to time j. , Let be the winding phase values of adjacent channel m at times j and j-1, respectively. This is the floor function. Original phase difference Beyond the principal value range Number of times compensation is required.
[0044] Subsequently, using the synthesized amplitude of the demodulated signal of each neighboring channel at the current time as the reliability weight, the principal-valued phase increments of each neighboring channel in the neighborhood are weighted and averaged to obtain the compensated phase increment at this fading point: , in, The phase increment after compensation. For Let R be the effective spatial neighborhood centered at R, and m be the index of the effective spatial sampling point in the neighborhood. This represents the phase increment between adjacent sampling points in the neighborhood after principal optimization. The weight of the composite amplitude at the current moment should be noted, and it is only applicable if the effective spatial neighborhood is within the range of 100%. Non-empty and weighted Only if the above compensation is performed; otherwise, it will be treated as an irreparable situation and the division by zero operation will not be performed.
[0045] For phase data identified as non-fading regions, a principal valueization and time accumulation algorithm is used for phase unwrapping. This algorithm requires a sampling rate sufficient to make the absolute value of the phase change between real adjacent samples less than π. If this condition is not met, the unwrapping result cannot be uniquely determined by relying solely on the wrapped phase, and the sampling rate should be increased or the sampling interval shortened.
[0046] First, the phase difference between adjacent samples is calculated as follows: , in, The original entanglement phase difference, , The first n The entangled phase demodulation values of each spatial channel at times j and j-1 are then calculated using the following formula: 2π compensation times and principal phase increment. , in, For 2π compensation times, For located The principal phase increment within the interval is calculated by subtracting a corresponding integer multiple of 2π when the original difference exceeds [-π, π). The compensation count is zero when the value is within the principal value interval. For example, a difference of 1.8π results in -0.2π after compensation, and a difference of -1.8π results in 0.2π after compensation. This formula is used when both sampling points are reliable. When sampling at either end fails, the compensated phase increment obtained by neighborhood weighting is accumulated time-by-time with the window start point as the zero reference: , in, Let be the continuous phase change value of the nth spatial channel at time j. exist and Time equals Otherwise equals Thus, in the non-window-level fading channel, the reliable increment and the compensation increment together constitute a continuous phase change sequence Y(n,:); taking the phase reference to zero only eliminates the static initial phase of the window, without changing the time change.
[0047] against Window-level low-amplitude fading channels are selected within the same spatial radius R. And the adjacent channels for which a complete and valid continuous sequence has been obtained are denoted as The average composite amplitude of adjacent channels within this window is used as the weight, and the initial reference of adjacent channels is first eliminated. Then, the entire channel is repaired using the following formula: , in, The average composite amplitude of adjacent channel m within this window. To repair the low-amplitude fading channel at the nth window level, the normalized weights corresponding to adjacent channel m are... For fading channel n, within the same spatial radius R The set of reliable neighboring paths selected within the network. Let m be the continuous phase change value of the reliable adjacent channel at time j. Let $\frac{ ...
[0048] Fixed window weights avoid introducing additional fluctuations by changing weights time-by-time; removing the initial window reference prevents the static initial phase bias of different spatial channels from being mixed into the repair results. This process uses the spatial correlation of local vibrations to estimate the missing phase change, and does not express the adjacent channel estimation as an accurate recovery of the true phase of the target point.
[0049] If Ω(n,j) or If the value is empty, the weight sum is zero, or the missing range exceeds the calibrated spatial correlation range, the corresponding position will be marked as unrepairable, and no division by zero or forced replacement with an irrelevant adjacent channel will be performed. Window containing unrepairable positions will not be considered as valid classification input, and a new available window will be obtained.
[0050] After completing the above processing, the repaired phase matrix within the effective window is denoted as Yrestored. The root mean square value is calculated for a preset local spatiotemporal region, and the lower bound of the denominator is limited by a non-zero positive number ε for gain normalization; then, the matrix is normalized to [−1,1] or [0,1] according to a preset mapping range. Training and inference use consistent windows, local regions, and mapping rules to obtain the anti-fading spatiotemporal matrix. .
[0051] like Figure 2 As shown, S3, will As a single-channel two-dimensional matrix input to the U-Net denoising network, to maintain consistency with S1, the M rows of the matrix correspond to spatial channels, and the N columns correspond to time points, without swapping the two axes. Two-dimensional processing simultaneously utilizes the spatially continuous distribution and temporal evolution of vibrations, outputting a reconstructed matrix with the same spatial and temporal indices as the input. .
[0052] The 2D denoising network employs a U-Net encoder and decoder. The encoder consists of four convolutional layers, each composed of two 3×3 convolutional layers, a batch normalization layer, and a LeakyReLU activation function, connected to a 2×2 max-pooling layer for downsampling, progressively extracting spatiotemporal features. If the input size is not divisible by 16, padding is applied at the network input boundaries, and the output is cropped back to the original M×N size to avoid size mismatch caused by four downsampling operations and skip stitching.
[0053] The decoder consists of four upsampling layers. It uses deconvolution to restore the size, concatenating encoder and decoder features at the corresponding scale along the feature channel dimension, then performing convolutional reconstruction, and finally outputting a single-channel reconstruction matrix. Skip connections provide shallow details to the decoder, helping to preserve the local structure of effective vibrations while suppressing background noise.
[0054] When training a 2D denoising network, a joint loss function is constructed using mean squared error loss and spatial structure similarity loss, and the network is optimized using this joint loss function. The expression for the joint loss function is as follows: , in, To reconstruct the matrix, The matrix represents the baseline label matrix under the same index and normalization rule; the Frobenius norm squared in the formula represents the sum of squares of all elements in the matrix, which, when divided by M×N, is the mean square error; SSIM(·) is the structural similarity function, and α and β are non-negative loss weights that are not simultaneously zero. The baseline labels are obtained from traceable, high signal-to-noise ratio records or known clean signals, and maintain their correspondence with the input during training. After training, the matrix is... For input, The output is subjected to joint spatiotemporal denoising, and finally the spatiotemporal matrix is reconstructed from the output. This serves as the input for the two-stream feature extraction in step S4.
[0055] like Figure 3 As shown, S4 and the classification network are configured with parallel spatial and temporal streams, both receiving the same data. The spatial flow employs a 1×K asymmetric convolution kernel, where 1 corresponds to the spatial row direction and K corresponds to the temporal column direction, extracting the temporal local morphology within each spatial channel while preserving the arrangement information of each channel along the spatial axis; channel attention then selects discriminative feature channels. Here, the convolution kernel is unfolded along the temporal axis, not interpreted as unfolding along the spatial distance axis.
[0056] The spatial flow embeds a channel attention module after convolution, adaptively weighting the convolutional feature map along the channel dimension. Let the convolutional feature map input to the channel attention module be... ,in, , These represent the spatial and temporal dimensions of the feature map, respectively. The number of feature channels, For the first The two-dimensional feature maps of each feature channel are generated. The channel attention module performs three levels of operations sequentially: squeezing, activation, and scaling. The squeezing operation compresses the two-dimensional feature maps of each feature channel into global scalar features using global average pooling. Global scalar features of each feature channel The calculation formula is: , The global scalar features of each feature channel constitute the channel description vector. The activation operation takes the channel description vector as input to a bottleneck structure containing two fully connected layers, and processes it sequentially through dimensionality reduction, nonlinear activation, and dimensionality increase, outputting a weight coefficient vector. The calculation formula is: , in, This is the weight coefficient vector. For channel description vectors, It is the ReLU activation function. Use the Sigmoid activation function; , These are the dimensionality reduction and dimensionality increase weight matrices, with dimensions of (C / r)×C and C×(C / r) respectively, where r is a preset positive integer reduction ratio, and C / r is the achievable integer dimension. Here, C is the number of feature channels, which, along with the number of event categories in S5, are defined according to their respective formulas.
[0057] The scaling operation multiplies each weight coefficient in the weight coefficient vector with the corresponding feature channel in the convolutional feature map channel by channel. The enhancement result of the c-th feature channel is expressed as: , in, This is the enhanced feature map for the c-th feature channel. The first element in the weight coefficient vector The weight coefficients corresponding to each feature channel are used to create an enhanced feature map, which is a weighted set of all feature channels. A global average is taken along the spatial and temporal dimensions for each enhanced feature channel to obtain a scalar value for that channel; all scalar values together form the spatial feature vector. Channel attention weights are learned together with the classification target during network training and are used to adjust the contribution of different feature channels to classification.
[0058] The temporal flow encodes N time points for each spatial channel using bidirectional long short-term memory. The forward and backward hidden states are concatenated at each time step, and the concatenated dimension is D, resulting in an N×D temporal feature matrix for the nth spatial channel. The i-th row is the hidden state vector. The transpose of the matrix. The results of all spatial channels can be combined to form an M×N×D tensor; the subsequent N×N attention matrix is multiplied only by the corresponding N×D matrix of the channel to ensure dimensionality consistency.
[0059] Temporal self-attention is introduced after bidirectional temporal coding. Each time step is used as a query to aggregate relevant temporal information within the entire window of the same spatial channel. The unnormalized score is defined using a dot product. , in, Let be the unnormalized attention score between the i-th and j-th time steps in the n-th spatial channel, where i is the query time step and j is the weighted time step. Let be the concatenated hidden state vector of the nth spatial channel at the i-th time step. The denominator is summed over the time dimension containing j, and the weights of each query row sum to 1. This weight represents the content correlation between temporal features, but does not directly indicate that the i-th time step has been independently determined to be a certain event category. The attention matrix for this channel is: , in, To perform Softmax normalization row by row on the matrix, The attention-weighted temporal feature matrix is then used for... By averaging along the time dimension, we obtain the D-dimensional time feature vector of the nth spatial channel. By concatenating the data according to the spatial channel order, we obtain the temporal feature vector of the current fixed M-channel window: , in, For matrix The i-th row, i.e., the n-th spatial channel, is in the... i Attention-weighted feature vectors at each time step This step, which uses the temporal feature vector of the current spatiotemporal window, redistributes the temporal contribution based on the feature content of each window before aggregation, compared to using only the final hidden state of the bidirectional network or directly averaging the unweighted hidden state. This allows the query location to access the impacts, repeating impulses, and their preceding and following contexts within the window. Then, it is fused with the channel-weighted features of the spatial flow.
[0060] S5. The spatial feature vector output from the spatial stream in step S4. With the time feature vector output by the time stream By concatenating the vectors, a spatiotemporal fusion feature vector is obtained. : , in, For spatiotemporal fusion feature vectors, For spatial feature vectors, For time feature vectors, This represents the vector concatenation operation. The concatenated spatiotemporal fusion feature vector simultaneously carries the spatial morphological features and temporal evolution features of the vibration signal, forming a complete spatiotemporal feature representation of the vibration event within the current spatiotemporal window.
[0061] Subsequently, the spatiotemporal fusion feature vector The input is a fully connected network containing a Dropout layer. This fully connected network integrates the spatiotemporal fusion feature vector. The Dropout layer randomly discards some neuron connections during training to regularize the network and prevent overfitting. The output of the fully connected network is connected to a Softmax layer. The Softmax layer normalizes the integrated features and outputs the probability that the vibration event belongs to each predefined category. , in, Let be the probability that a vibration event within the current spatiotemporal window belongs to the i-th predefined category. For spatiotemporal fusion feature vectors, , These are the learnable weight matrices for the i-th and j-th predefined categories in a fully connected network, respectively. , These are the bias terms corresponding to the i-th and j-th predefined categories, respectively. The total number of predefined categories, such as background noise, personnel intrusion, mechanical excavation, and manual damage, is set according to the alarm requirements of the monitoring scenario. The probability values of each predefined category are compared, and the predefined category with the highest probability is determined as the vibration event type within the current spatiotemporal window, thus completing the intelligent identification of vibration events.
[0062] Example 2 This embodiment provides an experimental verification scheme for validating the method of Embodiment 1, including data and configuration, comparison and ablation settings, evaluation index definitions, and result recording format. The experiment uses distributed fiber optic vibration recordings and synchronous I / Q recordings with real event labels, or simulation sequences with known clean phase labels; measured results and simulation results are recorded separately. Table 1 below provides an exemplary experimental configuration, and Tables 2 and 3 provide the result recording format when performing the experiment according to this scheme, where each index is statistically analyzed according to the definitions in Section 3 and filled in by the measured records.
[0063] 1. Data and Configuration Collect or construct samples according to task categories such as background noise, personnel intrusion, mechanical excavation, and manual destruction, and record the sensor system, sampling rate, spatial resolution, fiber length, event distance, and collection batch. The window can use a spatial sampling interval of approximately 2m and a time length of approximately 2s, with fixed M and N and recorded overlap step size. In the simulation, set the background noise level and low amplitude region separately, and save clean labels, I / Q generation rules, and random seeds; simulation performance should not be directly used as field performance.
[0064] All overlapping windows of the same consecutive record or the same event batch are assigned to the same data subset. Training, validation, and test sets are divided according to independent records or collection batches to avoid leakage between adjacent overlapping windows. Thresholds, radius R, denoising weights, and network hyperparameters are determined only through training and validation data; they are not used for hyperparameter tuning after the test set is fixed.
[0065] Table 1. Exemplary Experimental Configuration and Data Division
[0066] 2. Comparison and ablation settings The traditional control group used bandpass or wavelet denoising with a one-dimensional classifier, and recorded the actual configuration; our method group used the complete S1 to S5. In the ablation group, anti-fading compensation, 2D U-Net denoising, channel attention, and temporal attention were removed respectively, while the remaining input partitioning, training process, and evaluation conditions remained consistent. The input dimensions after module removal were matched using the same pooling rule to avoid confusion in comparisons due to different test data or training conditions.
[0067] 3. Evaluation Indicators The classification accuracy is calculated as Acc = number of correctly classified windows / total number of test windows. For each category c, Precisionc = TPc / (TPc + FPc), Recallc = TPc / (TPc + FNc), and F1c = 2TPc / (2TPc + FPc + FNc). The macro-average F1 is the arithmetic mean of F1 for each category. TP, FP, and FN represent the number of true positive, false positive, and false negative windows for that category, respectively. When the denominator is zero, a pre-defined processing rule is applied.
[0068] This experiment defines the above event categories, excluding background noise, as alarm categories. The false alarm rate is calculated as "number of background windows judged as alarm categories / total number of background windows"; the false negative rate is calculated as "number of real alarm windows judged as background / total number of real alarm windows". Deployment false alarms can be reported separately as the number of false alarms per hour, and the monitoring duration is recorded. Inference time is calculated as the end-to-end processing time for each window under the same hardware and fixed batch conditions, including preprocessing, denoising, and classification.
[0069] For simulation or paired data with clean reference labels, the mean squared error of reconstruction (MSE) = (1 / (M×N))ΣnΣj(Sclean(n,j)−Sgt(n,j))² and the structural similarity (SSIM) are calculated to evaluate numerical error and spatiotemporal structure preservation, respectively. For experimental records without clean references, no reference-type denoising metrics are directly provided.
[0070] Table 2. Classification Comparison and Module Ablation Results
[0071] Note: Table 2 shows the measured results under simulation conditions, statistically analyzed based on 3 independent replicates (random seeds 0-2), with values representing mean ± standard deviation. The test set had 108 windows, and the training set had 324 windows. Windows were divided according to independent events, with all overlapping windows of the same event grouped into the same subset. In the simulation, each window detected an average of 4.22 window-level low-amplitude fading channels. The definitions of each indicator are given in Section 3 of this embodiment. This group of experiments was completed in a pure CPU environment. The channel width of the 2D denoising network was 16 / 32 / 64 / 128 (half of the exemplary values in Table 1), and its number of layers, convolutional block structure, skip connections, and joint loss were consistent with those in Table 1. The classification network was the size of Table 1 (K=9, number of feature channels 32, D=128, r=16). The processing time is the end-to-end processing time for a single window, including preprocessing, denoising, and classification, and is greatly affected by the operating environment. The above results are obtained under simulation conditions and should not be directly used as field performance. Additionally, when the training window size was increased to 864 (120 independent events per class), the ablation process was repeated. The accuracy of the complete method was 85.42%, with 85.42% achieved after removing temporal attention, and 83.68% after removing channel attention (one repetition). This indicates that as the amount of training data increased, temporal attention changed from a negative contribution to a near-neutral contribution, while channel attention became a positive contribution. This demonstrates that the gain of the attention module depends on the amount of training samples, and overfitting occurs under small sample conditions.
[0072] Table 3. Phase reconstruction and denoising results of paired reference data
[0073] Note: Table 3 shows the measured results under simulation conditions, statistically analyzed on three independent replicates. The values are mean ± standard deviation, calculated on a test set (108 windows) of paired simulation data with known clean phase labels. MSE and SSIM are both based on clean labels under the same window and normalization rules. The SSIM of "anti-fading only" is lower than that of "no anti-fading or denoising" because anti-fading compensation restores the true phase change of the fading location but retains high-frequency noise, which is highly sensitive to structural similarity. After two-dimensional denoising, this noise is suppressed, and both MSE and SSIM are improved. These two items are not included in the measured records without a clean reference.
[0074] 4. Results Analysis Methods The results were analyzed and recorded as follows: The indicators of the complete method in Table 2 were compared with those of the traditional control group and each ablation group to evaluate the contributions of anti-fading compensation, two-dimensional denoising, channel attention, and temporal attention modules; the phase reconstruction and denoising quality were evaluated using MSE and SSIM data in Table 3, and the causes of misjudgments were analyzed based on the error category distribution and fading location. Repeated experiments were conducted using random seeds, and the mean and dispersion were statistically analyzed and reported. Regarding the results obtained under simulation conditions in this embodiment: the classification accuracy of the complete method was improved by approximately 42.9 percentage points compared to the traditional control group, and the background false alarm rate decreased from 86.4% to 25.9%; the accuracy decreased by approximately 26.2 percentage points after removing anti-fading compensation, and by approximately 8.6 percentage points after removing two-dimensional denoising, indicating that these two treatments have a substantial impact on the recognition results under coherent fading conditions; Table 3 shows that the complete anti-fading and two-dimensional denoising reduced the reconstruction mean square error from 0.0893 to 0.0299. The contribution of the attention module is related to the training sample size. It did not show a positive gain under the condition of a small sample size in this group, but turned positive as the sample size increased. See the notes in Table 2 for specific values.
Claims
1. A distributed optical fiber vibration signal identification method based on a spatiotemporal attention mechanism, characterized in that, include: S1. Obtain the vibration phase signal output by the distributed optical fiber sensing system and the corresponding in-phase demodulation signal and quadrature demodulation signal, and reconstruct the vibration phase signal into a two-dimensional spatiotemporal matrix according to the spatial and temporal dimensions. S2. Based on the combined amplitude of the in-phase demodulated signal and the quadrature demodulated signal, the fading point and the window-level low amplitude fading channel in the two-dimensional spatiotemporal matrix are detected. Phase increment weighted compensation, phase expansion and channel repair are performed using the reliable spatial neighborhood to obtain the anti-fading spatiotemporal matrix. S3. Input the anti-fading spatiotemporal matrix into a two-dimensional denoising network for spatiotemporal joint denoising to obtain the reconstructed spatiotemporal matrix; S4. Input the reconstructed spatiotemporal matrix into the parallel spatial stream and temporal stream respectively. Use convolution and channel attention in the spatial stream to extract spatial morphological features and obtain spatial feature vectors. Use bidirectional long short-term memory network and temporal attention in the temporal stream to extract temporal evolution features and obtain temporal feature vectors. S5. Based on the fusion of spatial feature vectors and temporal feature vectors, and after integration by a fully connected network, the probability of vibration events belonging to each predefined category is output to obtain the vibration event type within the current spatiotemporal window.
2. The distributed optical fiber vibration signal identification method based on spatiotemporal attention mechanism according to claim 1, characterized in that, The step of reconstructing the vibration phase signal into a two-dimensional spatiotemporal matrix according to the spatial and temporal dimensions includes using a preset spatiotemporal window to extract the vibration phase signal of M consecutive spatial channels and N consecutive time sampling points to form an M×N two-dimensional spatiotemporal matrix, wherein the row index of the two-dimensional spatiotemporal matrix corresponds to the spatial channel and the column index corresponds to the time sampling point; Using the same spatiotemporal window and index as the vibration phase signal, the in-phase demodulated signal and the quadrature demodulated signal are synchronously intercepted and reconstructed to obtain multiple two-dimensional spatiotemporal matrices; Where M and N are both positive integers, M is the number of spatial channels within the preset spatiotemporal window, and N is the number of time sampling points within the preset spatiotemporal window.
3. The distributed optical fiber vibration signal identification method based on spatiotemporal attention mechanism according to claim 1, characterized in that, The detection of fading points and window-level low-amplitude fading channels in the two-dimensional spatiotemporal matrix includes calculating the synthesized amplitude of the demodulated signal at each time point in the two-dimensional spatiotemporal matrix based on the in-phase demodulated signal and the quadrature demodulated signal when the vibration phase signal is demodulated. The synthesis amplitude and the preset fading threshold are compared. When comparing, At that time, determine the spatial point exist It is constantly in the decline zone; The average composite amplitude of each spatial channel within the same time window is calculated to obtain the window average composite amplitude of each spatial channel. ,when At that time, the corresponding spatial channel will be identified as a window-level low-amplitude fading channel; Calculate the standard deviation of the phase sequence of each spatial channel within the time window, and use the standard deviation to assist in screening the channels to be checked; in, For spatial points exist The amplitude of the demodulated signal at time t. The fading threshold, The spatial location of the nth spatial channel. For the j-th time, The average composite amplitude of the window for the nth spatial channel.
4. The distributed optical fiber vibration signal identification method based on spatiotemporal attention mechanism according to claim 3, characterized in that, The phase increment weighted compensation using a reliable spatial neighborhood includes selecting spatial sampling points that are not determined to be window-level low-amplitude fading channels and are located in the fading zone at the current time and the previous time, with the spatial location of the fading point as the center and a preset spatial distance R as the neighborhood radius, to form the effective spatial neighborhood corresponding to the fading point. For phase increments that fade at least at one end between two adjacent time points, the synthesized amplitude of the demodulated signal at the current time point of each sampling point in the effective spatial neighborhood is used as the weight to perform a weighted average of the phase increments of adjacent channels after principal optimization processing, to obtain the compensated phase increment. The expression for the amplitude-weighted interpolation compensation is as follows: , in, The phase increment after compensation. For Let R be the effective spatial neighborhood centered at R, and m be the index of the effective spatial sampling point in the neighborhood. This represents the phase increment between adjacent sampling points in the neighborhood after principal optimization. For weighted weights, Spatial location The synthesized amplitude of the demodulated signal at time j.
5. The distributed optical fiber vibration signal identification method based on spatiotemporal attention mechanism according to claim 4, characterized in that, Step S2 further includes subtracting an integer multiple of 2π from the original phase difference between the two adjacent ends so that it is located in the interval [−π,π), using the neighborhood compensation value for the phase increment that fades at least at one end in two adjacent time moments, and accumulating it along the time axis to obtain a continuous phase change sequence for each non-window-level fading channel. The window-level low-amplitude fading channel is determined based on the average synthesis amplitude within the same window. Reliable spatial channels with complete and continuous phase change sequences are selected from within its preset radius. Each sequence is referenced by the starting phase of the window and normalized and weighted by the average synthesis amplitude of each reliable channel within the window. The weighted sequence replaces the phase change sequence of the window-level low-amplitude fading channel. The processed spatiotemporal matrix is subjected to adaptive gain adjustment and normalization to obtain the anti-fading spatiotemporal matrix.
6. The distributed optical fiber vibration signal identification method based on spatiotemporal attention mechanism according to claim 1, characterized in that, The two-dimensional denoising network adopts the U-Net architecture, which includes an encoder and a decoder. The anti-fading spatiotemporal matrix is used as a single-channel grayscale image input to the two-dimensional denoising network. The encoder includes multiple convolutional blocks, each of which consists of a two-dimensional convolutional layer, a batch normalization layer, and a LeakyReLU activation function, and a max pooling layer is connected after each convolutional block for downsampling; The decoder includes multiple upsampling blocks. Each upsampling block uses deconvolution to recover the feature map size and uses skip connections to concatenate the feature maps of the corresponding scale in the encoder with the feature maps of the decoder in the channel dimension. The decoder outputs a reconstructed spatiotemporal matrix.
7. The distributed optical fiber vibration signal identification method based on spatiotemporal attention mechanism according to claim 6, characterized in that, Step S3 further includes constructing a joint loss function using mean squared error loss and spatial structure similarity loss, and optimizing the two-dimensional denoising network using the joint loss function. The expression of the joint loss function is as follows: , in, To reconstruct the matrix, For the baseline label matrix under the same index and normalization rules, Let Frobenius norm be the square of the norm, SSIM(·) be the structural similarity function, and α and β be non-negative loss weights that are not simultaneously zero.
8. The distributed optical fiber vibration signal identification method based on spatiotemporal attention mechanism according to claim 1, characterized in that, The extraction of spatial morphological features includes using a spatial asymmetric convolution kernel to convolve the reconstructed spatiotemporal matrix, extracting long-term features within a single spatial channel, and obtaining a convolutional feature map. Global average pooling is used to compress the two-dimensional feature maps of each feature channel in the convolutional feature map into global scalar features, thus obtaining the channel description vector; Based on the channel description vector, the non-linear dependencies between feature channels are learned through a bottleneck structure containing fully connected layers, and the weight coefficient vector of each feature channel is output. The enhanced feature map is obtained by multiplying each weight coefficient by the corresponding feature channel in the convolutional feature map channel by channel. Global average pooling is then performed on the enhanced feature map to obtain the spatial feature vector. The expression for the weight coefficient vector is as follows: , in, This is the weight coefficient vector. For channel description vectors, It is the ReLU activation function. It is the Sigmoid activation function. This is the dimensionality-reduced weight matrix for the first fully connected layer. This is the weight matrix of the second fully connected layer.
9. A distributed optical fiber vibration signal identification method based on a spatiotemporal attention mechanism according to claim 8, characterized in that, The extraction of temporal evolution features includes inputting the reconstructed spatiotemporal matrix along the time axis into a bidirectional long short-term memory network, extracting the temporal evolution features of the vibration signal using forward and backward contextual information, and outputting a temporal feature matrix. The dot product similarity between the hidden state vectors is calculated for the temporal feature matrix of each spatial channel, and Softmax normalization is performed on the dimension of the weighted time step for each query time step to generate the temporal attention matrix of that spatial channel. Multiply the temporal attention matrix of each spatial channel with the corresponding temporal feature matrix to obtain the attention-weighted temporal feature matrix; take the average along the time dimension, and then concatenate them in the order of the spatial channels to obtain a fixed-dimensional temporal feature vector.
10. The distributed optical fiber vibration signal identification method based on spatiotemporal attention mechanism according to claim 1, characterized in that, Obtaining the vibration event type within the current spatiotemporal window includes concatenating spatial and temporal feature vectors, inputting them into a fully connected network containing a Dropout layer for feature integration, obtaining integrated features, normalizing the integrated features through a Softmax layer, outputting the probability of the vibration event belonging to each predefined category, and determining the predefined category with the highest probability as the vibration event type within the current spatiotemporal window. The probability calculation formula is as follows: , in, Let be the probability that a vibration event within the current spatiotemporal window belongs to the i-th predefined category. For spatiotemporal fusion feature vectors, , Let be the learnable weight matrices for the i-th and j-th predefined categories in a fully connected network, respectively. , These are the bias terms corresponding to the i-th and j-th predefined categories, respectively. The total number of predefined categories.
