Distributed optical fiber sound wave sensing data classification method and device

Through the improved neural network model, using technologies such as multi-head attention mechanism and random inactivation layer, the waterfall diagram signal generated by distributed fiber optic acoustic sensors is solved, and the problem of difficulty in maintaining the dependence of space-time information is achieved and high-precision data classification is achieved.

CN120162630APending Publication Date: 2025-06-17SHANGHAI JIAOTONG UNIV +1
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202510333902.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-20
Publication Date
2025-06-17

AI Technical Summary

Technical Problem

The prior art cannot effectively maintain the space-time information dependence relationship when processing waterfall diagram signals generated by distributed fiber acoustic sensors, resulting in low data classification accuracy.

Method used

Using an improved neural network model, including the first convolutional network, multiple cascades of improved converter encoder networks and the second convolutional network, the spatial and temporal features in the waterfall diagram are extracted and processed through technologies such as multi-head attention mechanism and random inactivation layer, and the classification results of distributed fiber acoustic wave sensing data are generated.

Benefits of technology

It effectively retains the spatial and temporal information dependence, improves the accuracy and efficiency of data classification, and is significantly better than the performance of traditional models.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120162630A_ABST
    Figure CN120162630A_ABST
Patent Text Reader

Abstract

The invention relates to a distributed optical fiber sound wave sensing data classification method and device, and the method employs an improved neural network model to carry out data classification based on a waterfall plot, and the improved neural network model comprises a first convolution network which carries out the convolution operation of the waterfall plot in time, and obtains a first spatial-temporal feature; a plurality of cascaded improved converter encoder networks simultaneously extract spatial and temporal features of the first spatial-temporal feature to obtain a second spatial-temporal feature; the second convolutional network is used for carrying out time information extraction on the second spatiotemporal feature and carrying out time compression on the second spatiotemporal feature to obtain a third spatiotemporal feature; the average layer and the linear layer are used for generating a data classification result based on the third spatio-temporal characteristics, and the device is used for achieving the method. Compared with the prior art, the method has the advantages that high-quality spatio-temporal information can be effectively extracted from the waterfall plot at the same time, and more accurate data classification is carried out.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of distributed fiber optic acoustic wave sensors, and more particularly to a method and apparatus for classifying distributed fiber optic acoustic wave sensing data. Background Art

[0002] Distributed fiber optic sensing, such as Distributed Acoustic Sensor (DAS), is a fiber optic sensing technology used to collect vibration signals. Compared with electrical vibration sensors, it has the advantages of high resolution, small size, light weight, non-electric operation, and adaptability to harsh environments, and is widely used in fields such as seismic monitoring, oil and gas pipeline monitoring, and railway monitoring. For these applications in monitoring scenarios, an effective post-processing algorithm for distributed acoustic sensing signal recognition is needed to capture valid events and further distinguish valid events from inevitable interference events. Deep learning-based methods have achieved great success in recognition tasks of static images (two-dimensional spatial signals), speech signals (one-dimensional time signals), or videos (including two-dimensional space and one-dimensional time) by adopting network structures such as Convolutional Neural Networks (CNNs) and Recurrent Neural Networks (RNNs). However, the signals (waterfall plots) generated by distributed acoustic sensors are two-dimensional signals, containing a time dimension and a spatial dimension, and the data characteristics of waterfall plots are more similar to one-dimensional audio signals rather than images with mature processing networks currently. Therefore, the research on neural networks for waterfall plot recognition is still in its infancy. Currently, common methods include: 1) Introducing a two-dimensional convolutional network to process distributed acoustic sensing data. Although the effectiveness of two-dimensional convolutional networks has been fully proven in the field of image recognition, directly migrating a two-dimensional convolutional network without modification to process waterfall plot data with spatio-temporal information may ignore the differences between the time dimension and the spatial dimension. For example, the two-dimensional convolutional network treats time and spatial information equally, resulting in a decline in the effectiveness of processing waterfall plot signals; 2) Using a one-dimensional sound signal processing network (i.e., a one-dimensional convolutional network) to process each spatial channel of the waterfall plot through deep learning methods. This method treats each spatial channel of the waterfall plot as an independent signal, ignoring the hidden information between adjacent spatial channel signals. Specifically, as described in the Chinese patent application 《CN108932480A》, it provides a method for learning and classifying the features of distributed fiber optic sensing signals based on 1D-CNN, using a 1D-CNN network for feature classification of distributed fiber optic sensing signals. In addition, the prior art has also proposed a CNNs-BiLSTM model, that is, after a one-dimensional convolutional network, adding a Long Short-Term Memory (LSTM) network covering all channels to achieve spatio-temporal interaction of waterfall plot information, or using an ACNN-SA-BiLSTM (ACAB) network, which enhances the spatial feature extraction ability and achieves higher accuracy. However, the one-dimensional convolutional networks included in the above three models will over-sample the time dimension information of the waterfall plot, greatly weakening the mutual dependence between the spatial and time information in the waterfall plot, especially affecting the recognition accuracy of motion events. When using a long short-term memory network to extract spatial features of different channels subsequently, the time features given by the previous network are ignored, resulting in a decline in the overall recognition accuracy of the model.

[0003] Therefore, it is a technical problem to be solved to provide a method that can maintain the spatio-temporal information dependency and achieve accurate data classification. Summary of the Invention

[0004] The purpose of the present invention is to provide a distributed optical fiber acoustic wave sensing data classification method and device to overcome the defect of low data classification accuracy caused by the inability to maintain the spatio-temporal information dependency in the existing technology.

[0005] The purpose of the present invention can be achieved by the following technical solutions:

[0006] According to the first aspect of the present invention, a distributed optical fiber acoustic wave sensing data classification method is provided. The method is based on a waterfall plot and uses an improved neural network model to classify distributed optical fiber acoustic wave sensing data. Among them, the improved neural network model includes:

[0007] A first convolutional network performs a convolutional operation on the waterfall plot in the time domain to obtain first spatio-temporal features.

[0008] Multiple cascaded improved Transformer encoder networks use a transformed encoder improved based on the multi-head attention mechanism to simultaneously extract the spatial and temporal features of the first spatio-temporal features to obtain second spatio-temporal features.

[0009] A second convolutional network extracts time information from the second spatio-temporal features and performs time compression on the second spatio-temporal features to obtain third spatio-temporal features.

[0010] An average layer and a linear layer generate a distributed optical fiber acoustic wave sensing data classification result based on the third spatio-temporal features.

[0011] The shapes of the first spatio-temporal features, the second spatio-temporal features, and the third spatio-temporal features are: dimension × spatial channel number × time sampling points.

[0012] As a preferred technical solution, the first convolutional neural network includes multiple cascaded convolutional units. Each convolutional unit includes a one-dimensional convolutional layer, a max pooling layer, batch normalization, a non-linear activation function, and a dropout layer stacked in sequence, and the dropout layer is an optional structure. Among them, the input data of the first convolutional unit is the waterfall plot, the input data of the Nth convolutional unit is the output data of the (N - 1)th convolutional unit, and the output data of the last convolutional unit is the first spatio-temporal features. The following steps are performed in each convolutional unit:

[0013] The one-dimensional convolutional layer performs convolution on the input data in the time domain, and the time lengths of the input and output of the one-dimensional convolutional layer are equal.

[0014] The maximum pooling layer receives the output of the one-dimensional convolutional layer and performs pooling on it in the time dimension, and the sampling value of the maximum pooling layer is equal to the stride;

[0015] The output of the maximum pooling layer is processed by batch normalization and a non-linear activation function to obtain the output data; if the first convolutional neural network includes a dropout layer, it is also necessary to be processed by the dropout layer before the output data can be obtained.

[0016] As a preferred technical solution, each of the improved transformer encoder networks includes a multi-head attention mechanism, a dropout layer, and a feed-forward network, and the multi-head attention mechanism includes a plurality of parallel self-attention units; wherein, the input feature of the first improved transformer encoder network is the first spatio-temporal feature, the input feature of the Nth improved transformer encoder is the output of the single-layer transformer encoder of the (N - 1)th transformer encoder, and the output of the single-layer transformer encoder of the last improved transformer encoder is the second spatio-temporal feature;

[0017] The following steps are performed in each of the improved transformer encoder networks:

[0018] Process the input feature using a plurality of parallel self-attention units, obtain queries, keys, and values in each self-attention unit, and perform self-attention operations after reinterpreting the queries, keys, and values to obtain a plurality of first intermediate data;

[0019] Sequentially splice the plurality of first intermediate data along the dimension axis to obtain second intermediate data;

[0020] After performing a linear transformation on the second intermediate data in the dimension, process it using the dropout layer, add it to the feature input to this improved transformer encoder network, and perform layer normalization to obtain third intermediate data;

[0021] Process the third intermediate data in the dimension using the feed-forward network to obtain fourth intermediate data;

[0022] Add the fourth intermediate data to the third intermediate data and perform layer normalization to obtain the output of the single-layer transformer encoder.

[0023] As a preferred technical solution, the method for obtaining queries, keys, and values includes:

[0024] Perform one-dimensional convolution on each dimension of the first spatio-temporal feature along the time axis without a bias matrix to obtain queries;

[0025] Perform one-dimensional convolution on the first spatio-temporal feature along the time axis without a bias matrix to obtain keys;

[0026] Perform a one-dimensional convolution of the first spatio-temporal feature along the time axis with a bias matrix, and add it to the bias matrix to obtain a value.

[0027] As a preferred technical solution, the self-attention operation includes:

[0028] Obtain the query matrix and key matrix corresponding to each time of the first spatio-temporal feature and perform matrix multiplication. The expression is: A = Q t K t T , where Q t represents the query matrix corresponding to time t; K t represents the key matrix corresponding to time t;

[0029] Normalize the result of the matrix multiplication. The expression is: A norm = A / (D1) 0.5 , where D1 represents the dimensionality size of the first spatio-temporal feature;

[0030] Adjust the normalized result to a normalized weight using the Softmax function, and perform matrix multiplication of the normalized weight and the value to obtain the first intermediate data.

[0031] As a preferred technical solution, the second convolutional network includes a plurality of cascaded convolutional units, and each convolutional unit includes a one-dimensional convolutional layer, a max pooling layer, batch normalization, a non-linear activation function, and a dropout layer stacked in sequence, and the dropout layer is an optional structure; where the input data of the first convolutional unit is the second spatio-temporal feature, the input of the Nth convolutional unit is the output of the (N - 1)th convolutional unit, and the output of the last convolutional unit is the third spatio-temporal feature. The following steps are performed in each convolutional unit:

[0032] The one-dimensional convolutional layer performs convolution on the input in the time domain, and the time lengths of the input and output of the one-dimensional convolutional layer are equal;

[0033] The max pooling layer receives the output of the one-dimensional convolutional layer and performs pooling on it in the time domain. The sampling value of the max pooling layer is equal to the stride;

[0034] The output of the max pooling layer is processed by batch normalization and a non-linear activation function to obtain the output of the convolutional unit; if the structure includes a dropout layer, it also needs to be deactivated by the dropout layer to obtain the output of the convolutional unit.

[0035] As a preferred technical solution, the sampling value and stride of the max pooling layer in the second convolutional network are smaller than those of the max pooling layer in the first convolutional network.

[0036] As a preferred technical solution, the method for generating the classification result of distributed fiber optic acoustic sensing data includes:

[0037] Perform spatial processing on the third spatio-temporal feature to make its spatial size 1;

[0038] Map the dimension of the third spatio-temporal feature after spatial processing to the total number of classifications of distributed fiber optic acoustic sensing data to obtain a vector of the corresponding dimension;

[0039] Use the Softmax function to normalize the vector, map each component in the vector to the interval (0, 1) to obtain a normalized vector, and the i-th component in the normalized vector represents the probability that the input waterfall diagram is the i-th type of event;

[0040] Obtain the classification result of distributed fiber optic acoustic sensing data based on the normalized vector.

[0041] As a preferred technical solution, the neural network model uses a cross-entropy loss function for model training, and the cross-entropy loss function calculates the error between the probability of the improved neural network model predicting an event and the one-hot encoding converted from the event label.

[0042] According to the second aspect of the present invention, there is provided a distributed fiber optic acoustic sensing data classification device, including a memory and a processor. A computer program is stored on the memory, and when the processor executes the program, the above method is implemented.

[0043] Compared with the prior art, the present invention has the following beneficial effects:

[0044] 1) The present invention improves the traditional Transformer Encoder structure for the 2D data pattern of the waterfall diagram. By using the attention mechanism that usually extracts temporal information to calculate the weights of the time series of different channels of the waterfall diagram, the Transformer Encoder can receive 2D spatio-temporal data as input, and can parallelly extract the temporal and spatial features in the waterfall diagram, ensuring that the temporal and spatial information is equally important during the feature extraction process, retaining the ability of the Transformer Encoder architecture to parallelly process sequence data, and enabling it to adapt to the special data format of the waterfall diagram, that is, ensuring the efficiency of the data processing process and the accuracy of event classification based on the waterfall diagram.

[0045] 2) Before inputting the data into the Transformer Encoder, the present invention also uses the first convolutional network to downsample the temporal information carried by it, which can reduce the redundancy of the time dimension of the input data, obtain a similar spatio-temporal information density, maintain the integrity of the key features in the waterfall diagram, and significantly reduce the computational complexity of the attention mechanism, improving the operation efficiency. Description of the Drawings

[0046] Figure 1 is the flowchart of the method of the present invention;

[0047] Figure 2 is the experimental result diagram of the method of the present invention in Embodiment 2 of the present invention;

[0048] Figure 3 is the experimental result diagram of CNNs-BiLSTM in Embodiment 2 of the present invention;

[0049] Figure 4 is the experimental result diagram of ACNN-SA-BiLSTM in Embodiment 2 of the present invention;

[0050] Figure 5 is the experimental result diagram of 1D-CNN in Embodiment 2 of the present invention. Detailed implementation manners

[0051] Next, the technical solutions in the embodiments of the present invention will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, rather than all embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts shall fall within the protection scope of the present invention.

[0052] Unless otherwise defined, the technical terms or scientific terms involved in the present invention shall have the ordinary meanings understood by those with ordinary skills in the technical field to which the present invention belongs. The "one", "a", "an", "the" and other similar words involved in the present invention do not represent a quantity limitation and may represent a singular or plural number. The terms "include", "comprise", "have" and any variations thereof involved in the present invention are intended to cover non-exclusive inclusion; for example, a process, method, system, product or device including a series of steps or modules (units) is not limited to the listed steps or units, but may further include unlisted steps or units, or may further include other steps or units inherent to these processes, methods, products or devices. The "connection", "connection", "coupling" and other similar words involved in the present invention are not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect. The "multiple" involved in the present invention refers to two or more. "And / or" describes the association relationship of associated objects and indicates that three relationships may exist. For example, "A and / or B" may represent: A exists alone, A and B exist simultaneously, and B exists alone. The character " / " generally represents an "or" relationship between the front and rear associated objects. The terms "first", "second", "third", etc. involved in the present invention are only used to distinguish similar objects and do not represent a specific order for the objects.

[0053] Embodiment 1

[0054] In recent years, the field of deep learning has developed rapidly. Models based on the Transformer framework that apply the self-attention mechanism have achieved remarkable success in natural language processing, video and image processing, and other fields. The self-attention mechanism enables the model to effectively capture the dependencies between different positions in the input sequence, thereby better understanding the context information; the Transformer architecture significantly improves the training efficiency and performance by processing sequence data in parallel. The combination of the two has shown excellent performance in multiple tasks, such as machine translation, text generation, and sentiment analysis, which has promoted the development of deep learning and become the basis for many advanced models (such as the BERT and GPT series). Overall, the success of the Transformer and the self-attention mechanism marks the gradual abandonment of the concept of designing targeted network structures for different signal features in the field of deep learning, and instead using a unified, efficient, and high-performance Transformer structure to process different types of signals.

[0055] Specifically, applying the Transformer and the self-attention mechanism to the field of distributed fiber optic acoustic wave sensor technology, using their combination for data classification. However, due to the special data format of the waterfall diagram generated by the distributed fiber optic acoustic wave sensor, the existing Transformer cannot directly process the waterfall diagram to achieve event classification based on the waterfall diagram. Therefore, this embodiment provides a method for classifying distributed fiber optic acoustic wave sensor data based on a neural network, which improves the traditional Transformer structure so that it can process the waterfall diagram with a special data format. Specifically, the neural network includes a first convolutional network, multiple cascaded improved Transformer encoder networks, a second convolutional network, an average layer, and a linear layer, and its processing flow is as Figure 1 shown, and the data shape output by each structure is: dimension × spatial channel number × time sampling points, including:

[0056] S1. In the first convolutional network, perform a convolutional operation on the waterfall diagram in the time dimension to obtain the first spatio-temporal feature.

[0057] In this embodiment, the first convolutional neural network includes two cascaded convolutional units. Each convolutional unit includes a one-dimensional convolutional layer, a max pooling layer, batch normalization, a non-linear activation function, and a dropout layer stacked in sequence, where the dropout layer is an optional structure. It is set that the convolutional kernel size of the one-dimensional convolutional layer in the first convolutional unit is 25 sampling points, the convolution sliding stride is 1 sampling point each time, the size of the max pooling layer is the same as the convolutional kernel size of the one-dimensional convolutional layer, which is 25 sampling points, and the sliding stride is 25 sampling points; it is set that the convolutional kernel size of the one-dimensional convolutional layer in the second convolutional unit is 25 sampling points, the convolution sliding stride is 1 sampling point, the size of the max pooling layer is 10 sampling points, and the sliding stride is 10 sampling points; if the structure includes a dropout layer, it is set that the dropout probability of the dropout layers in both convolutional units is 0.04 (that is, there is a 4% possibility of disabling neurons).

[0058] S11. The first convolutional unit.

[0059] S111. The one-dimensional convolutional layer receives a waterfall diagram with a shape of dimension × spatial channel number × time sampling points, and a size of D × Z × T0 = 1 × 12 × 10000, where D represents the dimension, Z represents the spatial channel number, and T0 represents the time sampling points. It performs convolution on it in the time dimension and maps the dimension from 1 to 32. To keep the time lengths at both ends of the input and output of the waterfall diagram in the one-dimensional convolutional layer unchanged, 12 zeros are padded at both the front and back ends of the input waterfall diagram.

[0060] S112. The max pooling layer receives the output of the one-dimensional convolutional layer and performs pooling on it in the time dimension.

[0061] S113. After the output of the max pooling layer is processed by batch normalization and a non-linear activation function, the output data of the first convolutional unit is obtained, with a size of 32 × 12 × 400; if it includes a dropout layer, it is also necessary to be processed by the dropout layer for inactivation before the output data of the first convolutional unit can be obtained.

[0062] S12. The second convolutional unit.

[0063] S121. The one-dimensional convolutional layer receives the output data of the first convolutional unit, performs convolution on it in the time dimension, and maps the dimension from 32 to 64. To keep the time lengths at both ends of the output result of the first convolutional unit in the input and output of the one-dimensional convolutional layer unchanged, 12 zeros are padded at both the front and back ends of the input result of the first convolutional unit.

[0064] S112. The max pooling layer receives the output of the one-dimensional convolutional layer and performs pooling on it in the time dimension.

[0065] After the output of the max-pooling layer is processed by batch normalization and a non-linear activation function, the output data of the second convolutional unit, i.e., the first spatio-temporal feature, is obtained, with a size of 64×12×40; if a dropout layer is included, it is also necessary to perform dropout processing by the dropout layer before the first spatio-temporal feature can be obtained.

[0066] S2. In multiple cascaded improved Transformer encoder networks, the improved Transformer encoder based on the multi-head attention mechanism is used to extract the spatial and temporal features of the first spatio-temporal feature simultaneously, and the second spatio-temporal feature is obtained.

[0067] In this embodiment, the neural network includes three cascaded improved Transformer encoder networks. Each improved Transformer encoder network includes a multi-head attention mechanism, a dropout layer, and a feed-forward network, and the dropout layer is an optional structure; the multi-head attention mechanism includes four parallel self-attention units, and its structure is as Figure 1 shown. Among them, the input feature of the first improved Transformer encoder network is the first spatio-temporal feature, the input feature of the Nth (N∈[1,3]) improved Transformer encoder is the output of the single-layer Transformer encoder of the (N - 1)th Transformer encoder, and the output of the single-layer Transformer encoder of the third improved Transformer encoder is the second spatio-temporal feature.

[0068] The following steps are executed in each improved Transformer encoder network:

[0069] S21. The input feature is processed by multiple parallel self-attention units. In each self-attention unit, a query, a key, and a value are obtained, and after reinterpreting the query, the key, and the value, a self-attention operation is performed to obtain multiple first intermediate data. Among them, the method for obtaining the query, the key, and the value is:

[0070] S221. For each dimension of the first spatio-temporal feature, i.e., Z = 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, a one-dimensional convolution without a bias matrix is performed along the time axis to obtain a query.

[0071] S222. A one-dimensional convolution without a bias matrix is performed on the first spatio-temporal feature along the time axis to obtain a key.

[0072] S223. A one-dimensional convolution with a bias matrix is performed on the first spatio-temporal feature along the time axis, and then added to the bias matrix to obtain a value.

[0073] In steps S221 to S223, the convolution kernel size of the convolution is set to 5 sampling points each time, the convolution sliding stride is 1 sampling point each time, and in order to keep the number of time sampling points of the input and output signals unchanged, 2 zeros are padded at both ends of the signal. This process does not change the dimension of the input signal, and the sizes of the obtained query, key, and value are still D1×Z×T1 = 64×12×40.

[0074] The self-attention operation includes:

[0075] S224. Obtain the query matrix and the key matrix corresponding to each time of the first spatio-temporal feature and perform matrix multiplication. The expression is: A = Q t K t T , where Q t represents the query matrix corresponding to time t; K t represents the key matrix corresponding to time t;

[0076] S225. Normalize the result of the matrix multiplication. The expression is: A norm = A / (D1) 0.5 , where D1 represents the dimension size of the first spatio-temporal feature;

[0077] S226. Adjust the normalized result to a normalized weight using the Softmax function, and perform matrix multiplication on the normalized weight and the value to obtain the first intermediate data.

[0078] The self-attention operations in steps S224 to S226 do not change the size of the input and output results, remaining 64×12×40.

[0079] S22. Sequentially splice multiple first intermediate data along the dimension axis to obtain the second intermediate data, and its size becomes 4D1×Z×T1 = 256×12×40.

[0080] S23. After performing a linear transformation on the second intermediate data in terms of dimensions, its size changes back to D1×Z×T1 = 64×12×40. It is processed using a dropout layer with a dropout probability of 0.1, added to the features of the input of this improved transformer encoder network, and then layer normalization is performed to obtain the third intermediate data with a size of D1×Z×T1 = 64×12×40.

[0081] S24. Use a feedforward network to process the dimension of the third intermediate data. The detailed feedforward network includes two layers of linear networks. A non-linear activation function ReLU is provided between the two layers of linear networks to introduce non-linearity. Both layers of linear networks only transform the dimension of the data and do not operate on the time axis and the space axis. The first layer transforms the dimension from 40 to 80, and the second layer transforms the dimension from 80 back to 40. Therefore, the size of the fourth intermediate data output by the feedforward network is still D1×Z×T1 = 64×12×40.

[0082] S25. Add the fourth intermediate data to the third intermediate data and perform layer normalization to obtain the output of the single-layer transformer encoder.

[0083] S3. In the second convolutional network, extract the time information from the second spatio-temporal feature and perform time compression on the second spatio-temporal feature to obtain the third spatio-temporal feature.

[0084] In this embodiment, the second convolutional network includes two cascaded convolutional units, and each convolutional unit includes a one-dimensional convolutional layer, a max pooling layer, batch normalization, a non-linear activation function, and a dropout layer stacked in sequence, and the dropout layer is an optional structure. Among them, the input data of the first convolutional unit is the second spatio-temporal feature, the input of the second convolutional unit is the output of the first convolutional unit, and the output of the second convolutional unit is the third spatio-temporal feature. And it is set that the convolutional kernel size of the one-dimensional convolutional layer of the first convolutional unit is 5 sampling points, and the convolution sliding stride each time is 1 sampling point; the size of the max pooling layer is 8 sampling points, and the sliding stride is 8 sampling points; the dropout probability of the dropout layer is 0.04. Set the convolutional kernel size of the one-dimensional convolutional layer of the second convolutional unit to 5 sampling points, and the convolution sliding stride each time is 1 sampling point; the size of the max pooling layer is 4 sampling points, and the sliding stride is 4 sampling points; the dropout probability of the dropout layer is 0.04.

[0085] In each convolutional unit, the following steps are executed:

[0086] S31. The one-dimensional convolutional layer performs convolution on the input in the time dimension. And in order to ensure that the time lengths of the input and output of the one-dimensional convolutional layer are equal, 2 zeros are padded at both ends of the input data.

[0087] S32. The max pooling layer receives the output of the one-dimensional convolutional layer and performs pooling on it in the time dimension.

[0088] The output of the max pooling layer is processed by batch normalization and a non-linear activation function, and then inactivated by the dropout layer to obtain the output of the convolutional unit.

[0089] During the processing of steps S31 to S33, in the one-dimensional convolutional layer of the first convolutional unit, it is also necessary to map the dimension of the input data from 64 to 128, and the output size is 128×12×5; in the one-dimensional convolutional layer of the second convolutional unit, it is also necessary to map the dimension of the input data from 128 to 256, and the output size is 256×12×1, that is, the size of the third spatio-temporal feature is D2×Z×1 = 256×12×1.

[0090] S4. In the average layer and the linear layer, generate a data classification result based on the third spatio-temporal feature.

[0091] S41. Compress the third spatio-temporal feature spatially so that its spatial size is 1.

[0092] S42. Map the dimension of the third spatio-temporal feature after spatial processing to the total number of distributed fiber optic acoustic sensing data classifications, obtain a vector of the corresponding dimension, and in this embodiment, it is set to include six different events, that is, first perform an average operation on the number of spatial channels to reduce 12 spatial channels to 1, and then use linear processing to map 256 dimensions to 6 to obtain a vector containing 6 dimensions.

[0093] S43. Normalize the 6-dimensional vector using the Softmax function, map each component in the 6-dimensional vector to the interval (0, 1) to obtain a normalized vector, and the i-th component in the normalized vector represents the probability that the input waterfall diagram is the i-th type of event.

[0094] S44. Convert the normalized vector into a one-hot encoding with a dimension of 6 by the linear layer, that is, the event label type, to obtain the distributed fiber optic acoustic sensing data classification result. The detailed one-hot encoding sets the corresponding category label to 1, and the remaining category labels are all set to 0, forming a sparse binary vector representation.

[0095] In the present invention, the improved neural network model adopted is trained on a labeled distributed fiber optic acoustic sensing dataset (DAS). The loss function uses the cross-entropy loss function to measure the error between the probability of each type of event predicted by the improved neural network model and the one-hot encoding converted from the event label. The Adam optimization function is used, and the fixed learning rate is set to 0.0001. The cross-entropy loss function is optimized 200 times. By observing the loss value, it is found that the model has converged, so it is judged that the training is completed. The trained model is run on the DAS classification test set to test the generalization ability of the model, and the training parameters are adjusted until the model with the best effect is obtained.

[0096] This embodiment also provides a distributed fiber optic acoustic sensing data classification device, including a central processing unit (CPU), which can execute various appropriate actions and processes according to computer program instructions stored in a read-only memory (ROM) or computer program instructions loaded from a storage unit into a random access memory (RAM). In the RAM, various programs and data required for device operation can also be stored. The CPU, ROM, and RAM are connected to each other via a bus. An input / output (I / O) interface is also connected to the bus.

[0097] Multiple components in the device are connected to the I / O interface, including: an input unit, such as a keyboard, a mouse, etc.; an output unit, such as various types of displays, speakers, etc.; a storage unit, such as a disk, an optical disc, etc.; and a communication unit, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit allows the device to exchange information / data with other devices via a computer network such as the Internet and / or various telecommunication networks.

[0098] The processing unit executes the various methods and processes described above, such as methods S1 to S4. For example, in some embodiments, methods S1 to S4 can be implemented as a computer software program, which is tangibly contained in a machine-readable medium, such as a storage unit. In some embodiments, part or all of the computer program can be loaded and / or installed onto the device via the ROM and / or the communication unit. When the computer program is loaded into the RAM and executed by the CPU, one or more steps of methods S1 to S4 described above can be executed. Alternatively, in other embodiments, the CPU can be configured to execute methods S1 to S4 in any other suitable manner (e.g., by means of firmware).

[0099] The functions described above herein can be at least partially executed by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that can be used include: field programmable gate arrays (FPGA), application specific integrated circuits (ASIC), application specific standard products (ASSP), system on a chip (SOC), complex programmable logic devices (CPLD), and so on.

[0100] The program code for implementing the method of the present invention can be written in any combination of one or more programming languages. These program codes can be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable data processing devices, such that when the program codes are executed by the processor or controller, the functions / operations specified in the flowchart and / or block diagram are implemented. The program codes can be executed entirely on the machine, partially on the machine, executed partially on the machine and partially on a remote machine as an independent software package, or executed entirely on a remote machine or server.

[0101] In the context of the present invention, a machine-readable medium may be a tangible medium that can contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. The machine-readable medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatuses, or devices, or any suitable combination of the foregoing. More specific examples of machine-readable storage media would include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fibers, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.

[0102] Example 2

[0103] To verify the accuracy and practicality of the method provided by the present invention, this example conducts a comparative experiment on the publicly available DAS classification dataset (Cao X, et al. An open dataset of events with two classification models as baselines. Results in Optics, 2023, 10: 100372.). This dataset contains a total of six different types of events, namely: background noise (0), excavation (1), tapping (2), watering (3), shaking the railing (4), walking (5); the content in the brackets is the label corresponding to the event. Each event contains multiple different signal sources to ensure the diversity of the dataset. This dataset contains approximately 15,000 pieces of data in total, which are divided into a training set and a test set according to a ratio of 4:1, with more than 12,000 and more than 2,000 respectively. The number of samples of each type of event is roughly equal, and it is a balanced dataset. In the test set, according to the training requirements provided in Example 1, the proposed improved neural network model is trained with a learning rate of 0.0001 for 200 rounds to obtain a stable convergence result (CE Loss is approximately 0.001).

[0104] In the test set, a comparative experiment was conducted between the trained improved neural network model and the one-dimensional convolutional model 1D CNN, the sequential spatio-temporal model CNNs-BiLSTM, and the sequential spatio-temporal model ACAB. Among them, only the ACAB model adopted a semi-supervised training mode, while the remaining three models were trained using supervised learning. To obtain a more comprehensive and integrated analysis, different numbers of labeled samples were used for training (for semi-supervised training, the remaining training samples were regarded as unlabeled data), and the classification accuracies of the four models on the test set were compared when there were 30 samples, 150 samples, 600 samples, and 1200 samples respectively. The number of samples used here refers to the total number of six different events in the dataset. For each specific event type, the number of samples used for training should be one-sixth of the total. Taking the total number of 30 samples for training as an example, that is, 5 samples of each event type were randomly selected from the six types of events. The results of the comparative experiment are as shown in Figure 2 , Figure 3 , Figure 4 , Figure 5 and Table 1.

[0105] Table 1 Results of the Comparative Experiment

[0106]

[0107]

[0108] As can be seen from Table 1, at different sample sizes, the correct rates of each model showed significant differences. However, as the number of samples increased, the performance of all four models was significantly improved. Although the correct rate of the method of the present invention reached 68.18% when the sample size was 30, when the sample size increased to 150, 600, and 1200, the correct rates were increased to 92.02%, 97.76%, and 98.80% respectively; and compared with the other three models, the improved neural network model provided by the present invention had a higher accuracy than other models regardless of the sample size. That is, the method of the present invention demonstrated excellent performance at each sample size. Especially when the sample size was large, its positive accuracy was significantly improved, showing good application potential.

[0109] The above is only a specific implementation manner of the present invention, but the protection scope of the present invention is not limited thereto. Any person skilled in the art within the technical scope disclosed by the present invention can easily think of various equivalent modifications or substitutions, and these modifications or substitutions should all be covered within the protection scope of the present invention. Therefore, the protection scope of the present invention should be subject to the protection scope of the claims.

Claims

1. A distributed optical fiber acoustic wave sensing data classification method, characterized in that: The method is based on a waterfall chart and uses an improved neural network model to classify distributed optical fiber acoustic wave sensor data; wherein the improved neural network model includes: A first convolutional network performs a convolution operation on the waterfall graph in time to obtain a first spatiotemporal feature; A plurality of cascaded improved transformer encoder networks utilize an improved transformer encoder based on a multi-head attention mechanism to simultaneously extract the spatial and temporal features of the first spatiotemporal feature to obtain a second spatiotemporal feature; A second convolutional network extracts time information from the second spatiotemporal feature and performs time compression on the second spatiotemporal feature to obtain a third spatiotemporal feature; The average layer and the linear layer generate the classification results of the distributed optical fiber acoustic wave sensing data based on the third spatiotemporal feature; The shapes of the first space-time feature, the second space-time feature and the third space-time feature are: dimension×number of spatial channels×number of time sampling points.

2. A distributed optical fiber acoustic wave sensing data classification method according to claim 1, characterized in that: The first convolutional neural network includes multiple layers of cascaded convolutional units, each of which includes a one-dimensional convolutional layer, a maximum pooling layer, a batch normalization, and a nonlinear activation function stacked in sequence; wherein the input data of the first convolutional unit is a waterfall graph, the input data of the Nth convolutional unit is the output data of the N-1th convolutional unit, and the output data of the last convolutional unit is the first spatiotemporal feature, and the following steps are performed in each convolutional unit: The one-dimensional convolution layer performs convolution on the input data in time, and the time length of the input and output of the one-dimensional convolution layer is equal; The maximum pooling layer receives the output of the one-dimensional convolutional layer and performs temporal pooling on it, and the sampling value of the maximum pooling layer is equal to the sliding stride; The output of the maximum pooling layer is processed by batch normalization and nonlinear activation function to obtain the output data.

3. A distributed optical fiber acoustic wave sensing data classification method according to claim 1, characterized in that: Each of the improved transformer encoder networks includes a multi-head attention mechanism and a feedforward network, wherein the multi-head attention mechanism includes a plurality of parallel self-attention units; wherein the input feature of the first improved transformer encoder network is the first spatiotemporal feature, the input feature of the Nth improved transformer encoder is the single-layer transformer encoder output of the N-1th transformer encoder, and the single-layer transformer encoder output of the last improved transformer encoder is the second spatiotemporal feature; In each of the improved converter encoder networks described the following steps are performed: Processing the input features using multiple self-attention units in parallel, obtaining a query, a key, and a value in each self-attention unit, and performing a self-attention operation on the query, the key, and the value after re-interpreting the query, the key, and the value to obtain multiple first intermediate data; Sequentially concatenate the plurality of first intermediate data along the dimension axis to obtain second intermediate data; After performing a linear transformation on the second intermediate data in terms of dimension, adding the second intermediate data to the input feature of the improved transformer encoder network and performing layer normalization processing, the third intermediate data is obtained; Performing dimension processing on the third intermediate data using the feedforward network to obtain fourth intermediate data; The fourth intermediate data is added to the third intermediate data and layer normalized to obtain a single-layer transformer encoder output.

4. A distributed optical fiber acoustic wave sensing data classification method according to claim 3, characterized in that: The method for obtaining query, key and value includes: Performing a one-dimensional convolution without a bias matrix on each dimension of the first spatiotemporal feature along the time axis to obtain a query; Performing a one-dimensional convolution on the first spatiotemporal feature along the time axis without a bias matrix to obtain a key; The first spatiotemporal feature is subjected to a one-dimensional convolution with a bias matrix along the time axis, and a value is obtained by adding the convolution matrix to the bias matrix.

5. A distributed optical fiber acoustic wave sensing data classification method according to claim 3, characterized in that: The self-attention operation includes: Obtain the query matrix and key matrix corresponding to each time of the first spatiotemporal feature and perform matrix multiplication, the expression is: A = Q t K t T , where Q t represents the query matrix corresponding to time t; K t represents the key matrix corresponding to time t; Normalize the result of matrix multiplication, and its expression is: norm =A / (D1) 0.5 , where D1 represents the dimension of the first spatiotemporal feature; The normalized result is adjusted to a normalized weight using a Softmax function, and the normalized weight is matrix multiplied with the value to obtain the first intermediate data.

6. A distributed optical fiber acoustic wave sensing data classification method according to claim 2, characterized in that: The second convolutional network includes a plurality of cascaded convolutional units, and each convolutional unit includes a one-dimensional convolutional layer, a maximum pooling layer, a batch normalization, and a nonlinear activation function stacked in sequence; wherein the input data of the first convolutional unit is the second spatiotemporal feature, the input of the Nth convolutional unit is the output of the N-1th convolutional unit, and the output of the last convolutional unit is the third spatiotemporal feature, and the following steps are performed in each convolutional unit: The one-dimensional convolution layer performs convolution on the input in time, and the time length of the input and output of the one-dimensional convolution layer is equal; The maximum pooling layer receives the output of the one-dimensional convolutional layer and performs pooling on it in time, and the sampling value of the maximum pooling layer is equal to the sliding stride; The output of the maximum pooling layer is processed by batch normalization and nonlinear activation function to obtain the output of the convolution unit.

7. A distributed optical fiber acoustic wave sensing data classification method according to claim 6, characterized in that: The sampling value and sliding stride of the maximization layer in the second convolutional network are smaller than the sampling value and sliding stride of the maximization layer in the first convolutional network.

8. A distributed optical fiber acoustic wave sensing data classification method according to claim 1, characterized in that: The method for generating the classification result of distributed optical fiber acoustic wave sensing data includes: Processing the third spatiotemporal feature spatially so that its spatial size is 1; Mapping the dimension of the third spatiotemporal feature after spatial processing to the total number of classifications of distributed optical fiber acoustic wave sensing data to obtain a vector of corresponding dimension; The vector is normalized using a Softmax function, and each component in the vector is mapped to the interval (0, 1) to obtain a normalized vector, wherein the i-th component in the normalized vector represents the probability that the input waterfall graph is an i-th event; The distributed optical fiber acoustic wave sensing data classification result is obtained based on the normalized vector.

9. A distributed optical fiber acoustic wave sensing data classification method according to claim 8, characterized in that: The neural network model uses a cross entropy loss function for model training, and the cross entropy loss function is to calculate the error between the probability of the event predicted by the improved neural network model and the one-hot encoding converted from the event label.

10. A distributed optical fiber acoustic wave sensor data classification device, comprising a memory and a processor, wherein a computer program is stored in the memory, characterized in that: When the processor executes the program, the method according to any one of claims 1 to 9 is implemented.

Citation Information

Patent Citations

  • 1D-CNN based distributed optical fiber sensing signal feature learning and classification method

    CN108932480A