A Deep Learning-Based Environment Detection Method and System

By performing context-aware reconstruction and dual-dimensional feature extraction on the gas sensor array signals, combined with temporal local features and cross-sensor correlation analysis, the problem of insufficient cross-channel feature fusion is solved, thereby improving the accuracy and robustness of gas identification.

CN122307029APending Publication Date: 2026-06-30ZHEJIANG CHUDI TESTING TECH CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
ZHEJIANG CHUDI TESTING TECH CO LTD
Filing Date
2026-02-05
Publication Date
2026-06-30

AI Technical Summary

Technical Problem

Existing gas sensor feature extraction methods suffer from insufficient cross-channel feature fusion and inadequate feature representation. The models also exhibit poor adaptability to small datasets, weak generalization ability and robustness, resulting in gas recognition accuracy that fails to meet the needs of practical applications.

Method used

By performing context-aware reconstruction, spatiotemporal matrix reorganization, and two-dimensional attention feature extraction on the raw response signals of the gas sensor array, combined with temporal local feature mining and cross-sensor correlation feature analysis, gas category identification is achieved using fully connected layers and Softmax layers.

Benefits of technology

It significantly improves the recognizability and integrity of signal features, reduces the negative impact of environmental interference and individual sensor differences, and enables high-precision gas detection applications.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122307029A_ABST
    Figure CN122307029A_ABST
Patent Text Reader

Abstract

This invention discloses a deep learning-based environmental detection method and system, relating to the field of gas detection technology. It involves real-time acquisition of the raw response signals of a gas sensor array, followed by signal segmentation and context-aware reconstruction to obtain an enhanced sub-signal set. The target enhanced sub-signals are then transformed into a spatiotemporal matrix to obtain two-dimensional features. Temporal features and local temporal features are extracted along the time channel dimension to obtain temporal enhancement features. Sensing features are extracted along the sensor channel dimension, and inter-sensor correlation features are extracted to obtain sensing enhancement features. All sensing enhancement features are flattened and input into a fully connected layer, then passed through a Softmax layer to obtain the gas category recognition result. This method addresses the problems of insufficient cross-channel feature fusion and inadequate feature representation in existing methods through multi-dimensional feature fusion and attention mechanisms. It also expands the training samples from the original signals through signal augmentation and reconstruction, adapting to small dataset scenarios, thereby improving the accuracy of gas recognition.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of gas detection technology, specifically relating to an environmental detection method and system based on deep learning. Background Technology

[0002] Gas detection plays an indispensable and crucial role in many fields such as industrial production, urban environmental management, and indoor air quality monitoring. The accuracy and timeliness of its detection results are directly related to production safety, ecological environment quality, and human health. Traditional gas detection methods mostly rely on the response signal analysis of a single sensor, but are limited by the complexity of gas composition, making it difficult to accurately identify and distinguish multiple gases. As the gas detection scenarios continue to expand, the types of gases to be detected are increasing and often coexist in a mixed state. The cross-interference between different gases further exacerbates the detection difficulty.

[0003] Patent application CN120196858A discloses a gas identification method based on a grouped convolutional-TCN neural network, comprising the following steps: Step 1: Collecting gas data using a MEMS gas sensor array to obtain gas datasets of the MEMS gas sensor array under different flow rates; Step 2: Preprocessing the obtained experimental data; Step 3: Model building: Constructing a model combining a grouped convolutional neural network and a TCN neural network to extract features of the gas sensor that are independent of flow rate and to achieve gas identification; Step 4: Completing model training and performance evaluation; Step 5: Quantizing and deploying the grouped convolutional-TCN neural network model.

[0004] However, this method uses a model combining grouped convolution and TCN neural network to extract flow-independent gas sensor features. The design of grouped convolution with independent operation of channel groups creates a natural barrier between feature information of different groups, making it impossible to achieve effective flow and complementary fusion across groups. It is difficult to fully explore the correlation value contained in the data of each channel in the sensor array, which directly leads to the one-sidedness and incompleteness of feature representation. At the same time, this method has not been adapted and optimized for the real-world scenario where the gas data acquisition process is complex and the amount of available data is relatively limited. The limited dataset is difficult to support the grouped convolution and TCN combined model to complete sufficient training, resulting in incomplete optimization of model parameters, inherently weak generalization ability, large fluctuations in recognition accuracy and insufficient robustness. Ultimately, the gas recognition accuracy cannot meet the needs of practical applications. Summary of the Invention

[0005] The purpose of this invention is to address the problems in existing gas sensor feature extraction methods, such as insufficient cross-channel feature fusion, inadequate feature expression, poor model adaptability to small datasets, and weak generalization and robustness, which make it difficult to meet the gas recognition accuracy requirements of practical applications. Therefore, this invention proposes an environment detection method and system based on deep learning.

[0006] In a first aspect of this invention, a deep learning-based environment detection method is first proposed, the method comprising: Real-time acquisition of raw response signals from the gas sensor array; The original response signal is divided into signals and reconstructed with context awareness to obtain an enhanced sub-signal set; Two-dimensional features are obtained by transforming and reconstructing the spatiotemporal matrix of the target enhancement sub-signal; the row dimension of the spatiotemporal matrix corresponds to the sensor channel, and the column dimension of the matrix corresponds to the time series sampling points; the target enhancement response sub-signal is any one of the enhancement sub-signals in the set of enhancement sub-signals; Temporal features are obtained by extracting temporal features from the two-dimensional features in the time channel dimension using a preset attention module; Temporal local features are extracted from the time-level features to obtain temporal enhancement features; The time-enhancing features are extracted in the sensor channel dimension by a preset attention module to obtain sensor-level features. Sensor enhancement features are obtained by extracting inter-sensor correlation features from the sensor-level features; The sensing enhancement features corresponding to all enhancement sub-signals are flattened and input into a fully connected layer for classification mapping, and the gas category identification result is obtained through a Softmax layer.

[0007] This solution effectively improves the recognizability and integrity of signal features by performing context-aware reconstruction, spatiotemporal matrix reorganization, and two-dimensional attention feature extraction on the original response signals of the gas sensor array. Combined with temporal local feature mining and cross-sensor correlation feature analysis, it significantly reduces the negative impact of environmental interference and individual sensor differences. Finally, with the precise mapping between the fully connected layer and the Softmax layer, it achieves accurate identification of gas categories, providing reliable technical support for the high-precision application of gas detection systems.

[0008] Optionally, the enhanced response signal set obtained by performing signal segmentation and context-aware reconstruction on the original response signal includes: The original response signal is continuously overlapped and segmented by a preset first sliding window to obtain a sub-signal set; For the target signal, the normalized response signal is intercepted through a preset second sliding window to obtain a context signal containing the target sub-signal; the length of the preset first sliding window is less than the length of the preset second sliding window; the target sub-signal is any one of the sub-signals in the set of sub-signals; The context signal is input into a preset attention localization network to obtain a focus weight vector; Based on the focus weight vector, the context signal is divided into regions to obtain a thresholded region segmentation, which yields the focus signal and the background signal. The focus signal and the background signal are respectively subjected to time-series statistical feature calculations to obtain focus feature vector and background feature vector; The difference between the focused feature vector and the background feature vector in each dimension is calculated to obtain the differentiated feature vector of the focused signal relative to the background signal; The differential feature vector is input into a preset feature compression network to obtain a context feature vector; The target sub-signal and the context feature vector are fused across modalities to obtain the enhanced sub-signal; The set of enhancer signals is obtained by statistically analyzing all enhancer signals.

[0009] This solution uses a sliding window approach to continuously segment the sensor response curve, which can expand the original single sensor response sequence without adding additional hardware acquisition, thereby directly and significantly increasing the size of the training dataset.

[0010] Optionally, the working principle of the preset attention module includes: Obtain input features; The first feature vector is obtained by performing 3×3 max pooling and point convolution on the input features; The input features are subjected to 3×3 average pooling and point convolution to obtain the second feature vector; The first feature vector and the second feature vector are added element by element, and the attention weight vector is obtained by normalizing it through the Sigmoid activation function. The enhanced features are obtained by multiplying the attention weight vector element-wise with the input features.

[0011] This scheme extracts salient texture features and global smoothness features from the input features by performing 3×3 max pooling and average pooling in parallel, combined with pointwise convolution. The input features are then augmented by element-wise addition and a sigmoid activation function to generate an adaptive attention weight vector, which is then multiplied element-wise with the original input features. This process not only accurately focuses on key feature regions and suppresses redundant interference information, but also improves the representational ability and recognizability of features without significantly increasing computational complexity, providing more valuable input data for subsequent temporal and sensor dimension feature extraction.

[0012] Optionally, extracting temporal local features from the time-level features to obtain temporally enhanced features includes: The time-level features are decomposed along the time dimension using different partitioning strategies to obtain a first sub-feature set and a second sub-feature set; the first partitioning strategy is to divide the time-level features into a first half and a second half along the time dimension; the second partitioning strategy is to decompose the time-level features into an odd-order part and an even-order part along the time dimension. The first half and the second half of the first sub-feature set are subjected to time-dimension-separable convolutions, and the convolution results are fused at the time boundary to obtain boundary-enhanced features. The boundary enhancement features are multiplied by the first half and the second half of the features of the first sub-feature set respectively through cross-segment weighted multiplication to obtain the first enhancement feature set; The odd-order and even-order features of the second sub-feature set are stacked alternately in the time dimension to obtain the dual feature matrix; The dual feature matrix is ​​subjected to depthwise separable convolution, and bidirectional pooling is performed on the odd and even dimensions to obtain odd and even co-features. The second enhanced feature set is obtained by co-enhancing the odd and even features in the second sub-feature set according to the odd-even co-enhancing features. The first and second intermediate fusion features are concatenated along the time width dimension of the first and second enhanced feature sets, respectively; The first intermediate fusion feature and the second intermediate fusion feature are respectively shuffled, and the shuffled features are re-divided in the time dimension to obtain the first group feature set and the second group feature set; Each group feature of the first group feature set and the second group feature set is independently convolved pointwise to obtain the first transform feature set and the second transform feature set; The first output feature is obtained by concatenating each transformation feature in the first transformation feature set along the time dimension; The second output feature is obtained by concatenating each transformation feature in the second transformation feature set along the time dimension; The time-enhanced feature is obtained by adding the first output feature, the second output feature, and the time-level feature element by element.

[0013] This solution not only achieves multi-level and multi-dimensional extraction of temporal local features, effectively enriching the diversity of feature representation, but also significantly improves the discriminativeness and robustness of temporal features through feature reuse and fusion. At the same time, it reduces computational complexity by leveraging depthwise separable convolution, providing more timely and discriminative temporal feature support for subsequent sensor dimension feature extraction.

[0014] Optionally, extracting inter-sensor correlation features from the sensor-level features to obtain sensor enhancement features includes: The sensor-level features are divided into similar channels according to sensor type to obtain a feature set of the same type of sensor; The sensor-level features are randomly divided across sensor channels according to a preset number of groups to obtain a hybrid sensor feature set; For each sensor feature in the same type feature set, perform depthwise separable convolution and max pooling operations in the channel dimension, and multiply the pooling results element-wise with the corresponding sensor feature to obtain the same type enhanced feature set. For each hybrid sensor feature in the hybrid sensor feature set, perform channel-dimensional depthwise separable convolution and max pooling operations, and multiply the pooling result element-wise with the corresponding hybrid sensor feature to obtain the hybrid enhanced feature set; Connect the similar enhancement features in the same enhancement feature set along the channel direction to obtain the same type fusion feature; The hybrid enhancement features in the hybrid enhancement feature set are connected along the channel direction to obtain hybrid type fusion features; The sensing enhancement feature is obtained by element-wise addition of the same-type fusion feature, the mixed-type fusion feature, and the sensing-level feature.

[0015] This solution not only enhances the consistency and distinguishability of features among sensors of the same type, but also fully explores the complementary correlation information between sensors of different types, effectively enriching the representation dimensions of sensing features, improving the adaptability and distinguishability of features to different gas response modes, and providing more robust sensing feature support for subsequent accurate gas category identification.

[0016] In a second aspect of this invention, a deep learning-based environment detection system is proposed, comprising: The signal acquisition module is used to acquire the raw response signal of the gas sensor array in real time; A partitioning and reconstruction module is used to perform signal partitioning and context-aware reconstruction on the original response signal to obtain an enhanced sub-signal set; The conversion module is used to convert the target enhancement sub-signal into a spatiotemporal matrix and reconstruct it to obtain two-dimensional features; the row dimension of the spatiotemporal matrix corresponds to the sensor channel, and the column dimension of the matrix corresponds to the time series sampling points; the target enhancement response sub-signal is any one of the enhancement sub-signals in the set of enhancement sub-signals; The first feature extraction module is used to extract time-level features from the two-dimensional features in the time channel dimension through a preset attention module. The temporal enhancement feature generation module is used to extract temporal local features from the temporal features to obtain temporal enhancement features; The second feature extraction module is used to extract sensor-level features from the time-enhanced features in the sensor channel dimension through a preset attention module. The sensing enhancement feature generation module is used to extract the inter-sensor correlation features from the sensing-level features to obtain sensing enhancement features; The result generation module is used to flatten the sensing enhancement features corresponding to all enhancement sub-signals and input them into the fully connected layer for classification mapping, and obtain the gas category identification result through the Softmax layer.

[0017] Optionally, the partitioning and reconstruction module includes: The segmentation module is used to continuously overlap and segment the original response signal through a preset first sliding window to obtain a sub-signal set; The interception module is used to intercept the normalized response signal containing the target sub-signal through a preset second sliding window for the target signal; the length of the preset first sliding window is less than the length of the preset second sliding window; the target sub-signal is any one of the sub-signals in the set of sub-signals; A vector generation module is used to input the context signal into a preset attention localization network to obtain a focus weight vector; The region segmentation module is used to segment the context signal into regions based on the focus weight vector to obtain a thresholded region segmentation, which in turn yields the focus signal and the background signal. The time-series statistical feature calculation module is used to perform time-series statistical feature calculations on the focused signal and the background signal respectively to obtain a focused feature vector and a background feature vector; The differential vector generation module is used to calculate the difference between the focusing feature vector and the background feature vector in each dimension to obtain the differential feature vector of the focusing signal relative to the background signal; The context vector generation module is used to input the differential feature vector into a preset feature compression network to obtain the context feature vector; The fusion module is used to perform cross-modal fusion of the target sub-signal and the context feature vector to obtain the enhanced sub-signal; The statistics module is used to statistically analyze all the enhancer signals to obtain the enhancer signal set.

[0018] Optionally, the working principle of the preset attention module includes: Obtain input features; The first feature vector is obtained by performing 3×3 max pooling and point convolution on the input features; The input features are subjected to 3×3 average pooling and point convolution to obtain the second feature vector; The first feature vector and the second feature vector are added element by element, and the attention weight vector is obtained by normalizing it through the Sigmoid activation function. The enhanced features are obtained by multiplying the attention weight vector element-wise with the input features.

[0019] Optionally, the time-enhanced feature generation module includes: The decomposition module is used to decompose the time-level features in the time dimension according to different partitioning strategies to obtain a first sub-feature set and a second sub-feature set; the first partitioning strategy is to divide the time-level features into a first half and a second half in the time dimension; the second partitioning strategy is to decompose the time-level features into odd-order parts and even-order parts in the time dimension. The boundary feature generation module is used to perform time-dimension-separable convolutions on the first half and the second half of the features of the first sub-feature set, and then fuse the convolution results at the time boundary to obtain the boundary enhancement features. The first feature generation module is used to perform cross-segment weighted multiplication of the boundary enhancement features with the first half of the features and the second half of the features of the first sub-feature set to obtain the first enhancement feature set; The matrix generation module is used to perform time-dimension interleaving and stacking of the odd-order and even-order features of the second sub-feature set to obtain a dual feature matrix. The collaborative feature generation module is used to perform depthwise separable convolution on the dual feature matrix and bidirectional pooling on the odd and even dimensions to obtain odd and even collaborative features. The second feature generation module is used to perform collaborative enhancement on the odd and even parts of the features in the second sub-feature set according to the odd-even collaborative features to obtain the second enhanced feature set; The fusion feature generation module is used to concatenate the enhanced sub-features in the first enhanced sub-feature set and the second enhanced sub-feature set in the time width dimension to obtain the first intermediate fusion feature and the second intermediate fusion feature; The group feature generation module is used to perform feature shuffling on the first intermediate fusion feature and the second intermediate fusion feature respectively, and to re-divide the shuffled features in the time dimension to obtain the first group feature set and the second group feature set respectively; The transform feature generation module is used to independently perform pointwise convolution on each group feature of the first group feature set and the second group feature set to obtain the first transform feature set and the second transform feature set; The first connection module is used to connect each transformation feature in the first transformation feature set in the time dimension to obtain the first output feature; The second connection module is used to connect each transformation feature in the second transformation feature set in the time dimension to obtain the second output feature; The first addition module is used to add the first output feature, the second output feature and the time-level feature element by element to obtain the time-enhanced feature.

[0020] Optionally, the sensing enhancement feature generation module includes: The same-type segmentation module is used to divide the sensor-level features into same-type channels according to the sensor type to obtain a same-type sensor feature set; The random partitioning module is used to randomly partition the sensor-level features across sensor channels according to a preset number of groups to obtain a hybrid sensor feature set; The same type feature generation module is used to perform channel-dimension-separable convolution and max pooling operations on each same type sensor feature in the same type sensor feature set, and multiply the pooling result with the corresponding same type sensor feature element by element to obtain the same type enhanced feature set. The hybrid feature generation module is used to perform channel-dimensional depthwise separable convolution and max pooling operations on each hybrid sensor feature in the hybrid sensor feature set, and multiply the pooling result with the corresponding hybrid sensor feature element by element to obtain the hybrid enhanced feature set; The third connection module is used to connect the same type of enhancement features in the same type enhancement feature set along the channel direction to obtain the same type fusion feature; The fourth connection module is used to connect the hybrid enhancement features in the hybrid enhancement feature set along the channel direction to obtain hybrid type fusion features; The second addition module is used to perform element-level addition of the same-type fusion features, the mixed-type fusion features, and the sensing-level features to obtain sensing enhancement features.

[0021] The beneficial effects of this invention are as follows: This invention proposes a deep learning-based environment detection method. It acquires the raw response signals of a gas sensor array in real time, generates enhanced sub-signal sets through signal segmentation and context-aware reconstruction, and transforms these into a spatiotemporal matrix where rows correspond to sensor channels and columns correspond to time sampling points to extract two-dimensional features. Then, with the aid of an attention module, it sequentially extracts temporal features and mines temporal local features in the time channel dimension, and extracts sensing features and mines sensor-related features in the sensor channel dimension. Finally, all sensor enhancement features are flattened and input into a fully connected layer, and the gas category recognition result is output through a Softmax layer. This method effectively solves the problems of insufficient cross-channel feature fusion and inadequate feature expression in existing methods through the precise empowerment of multi-dimensional feature fusion and attention mechanisms. Simultaneously, relying on signal segmentation and context-aware reconstruction, it directly generates more enhanced sub-signals from the raw signals to expand the training samples, rather than relying on a lightweight feature extraction process, thus better adapting to small dataset scenarios and improving the accuracy of gas recognition. Attached Figure Description

[0022] The present invention will now be further described with reference to the accompanying drawings.

[0023] Figure 1 A flowchart illustrating a deep learning-based environment detection method provided in this embodiment of the invention; Figure 2 A flowchart of the pre-defined attention module's working process; Figure 3 A flowchart of the time-enhanced feature generation process. Detailed Implementation

[0024] The technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments.

[0025] Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0026] This invention provides an environment detection method based on deep learning. See also... Figure 1 , Figure 1 A flowchart illustrating a deep learning-based environment detection method provided in this embodiment of the invention. The method includes the following steps: S101, acquires the raw response signal of the gas sensor array in real time; S102, the original response signal is divided into signals and reconstructed with context awareness to obtain an enhanced sub-signal set; S103, the target enhancement sub-signal is transformed and the spatiotemporal matrix is ​​recombined to obtain two-dimensional features; S104, Temporal features are obtained by extracting temporal features from two-dimensional features in the time channel dimension through a preset attention module; S105, extract temporal local features from time-level features to obtain time-enhanced features; S106, sensor-level features are obtained by extracting the time-enhanced features in the sensor channel dimension through a preset attention module; S107, Extract the inter-sensor correlation features from the sensor-level features to obtain the sensor enhancement features; S108, flatten the sensing enhancement features corresponding to all enhancement sub-signals and input them into the fully connected layer for classification mapping, and obtain the gas category recognition result through the Softmax layer; The row dimension of the spatiotemporal matrix corresponds to the sensor channels, and the column dimension of the matrix corresponds to the time series sampling points. The target enhancer signal is any one of the enhancer signals in the enhancer signal set.

[0027] This invention provides a deep learning-based environment detection method. It acquires raw response signals from a gas sensor array in real time, generates enhanced sub-signal sets through signal segmentation and context-aware reconstruction, and then reassembles these sub-signals into a spatiotemporal matrix with sensor channels as rows and time sampling points as columns, extracting two-dimensional features from it. Subsequently, through an attention mechanism, it first extracts temporal features and mines their local features in the time dimension, then extracts sensing features in the sensor channel dimension and captures the correlation features between sensors, obtaining multi-dimensional enhanced features. Finally, all enhanced features are flattened and input into a fully connected layer, and the gas category recognition result is output through Softmax classification. This method, with its multi-dimensional feature fusion and attention mechanism, effectively overcomes the shortcomings of existing technologies, such as insufficient cross-channel feature fusion and one-sided feature representation. Simultaneously, by directly expanding the training samples through signal segmentation and context-aware reconstruction, it can adapt to small dataset scenarios without relying on a lightweight feature extraction process, ultimately improving the accuracy and reliability of gas recognition.

[0028] In one implementation, the gas identification result is generated by processing each enhanced sub-signal through deep feature extraction, such as time and sensor dimension multi-attention weighting and staggered convolution, resulting in a four-dimensional structured feature tensor. Its dimensions can typically be represented as [number of samples, number of sensor channels, time step, number of feature maps]. The flattening operation flattens this tensor along all non-batch dimensions to form a long one-dimensional vector. This vector is then fed into one or more fully connected layers, which learn the complex decision boundary from high-dimensional features to gas categories through the superposition of weight matrices and activation functions. Finally, the Softmax layer converts the output of the fully connected layers into probability distributions for each category, and the categories with probabilities greater than a preset threshold are taken as the gas identification results.

[0029] In one embodiment, the enhanced response signal set obtained by segmenting the original response signal and performing context-aware reconstruction includes: Sub-signal sets are obtained by continuously overlapping and segmenting the original response signal through a preset first sliding window; For the target signal, the normalized response signal is intercepted through a preset second sliding window to obtain the context signal containing the target sub-signal; the length of the preset first sliding window is less than the length of the preset second sliding window; the target sub-signal is any sub-signal in the set of sub-signals; The contextual signals are input into a pre-defined attention localization network to obtain the focus weight vector; Based on the focus weight vector, the context signal is divided into regions to obtain thresholded region segmentation, which yields the focus signal and background signal. The focus feature vector and background feature vector are obtained by performing time-series statistical feature calculations on the focus signal and background signal, respectively. The difference between the focused feature vector and the background feature vector in each dimension is calculated to obtain the differentiated feature vector of the focused signal relative to the background signal; The differential feature vector is input into a pre-defined feature compression network to obtain the context feature vector; The enhanced sub-signal is obtained by cross-modal fusion of the target sub-signal and the context feature vector; The set of enhancer signals is obtained by statistically analyzing all enhancer signals.

[0030] In one implementation, the lengths of the first and second sliding windows are set by the technician. For example, when processing a speech signal with a sampling rate of 16 kHz, the length of the first sliding window is set to 32 milliseconds, the step size is 16 milliseconds, and the overlap rate is 50%. The length of the second sliding window is set to L2 = 96 milliseconds.

[0031] In one implementation, the core function of the preset attention localization network is to automatically evaluate and assign importance weights to different time regions in the input signal through learnable parameters.

[0032] In one implementation, each element in the focus weight vector represents the importance score of the corresponding time point of the context signal. All time points are divided into two categories using a preset adjustable threshold. Time points with weight scores higher than the threshold are classified as high-importance regions, and their corresponding continuous time segments are extracted and combined into a focus signal, which concentrates the historical response features most relevant to the current target. Time points with weight scores lower than the threshold are classified as low-importance regions, and their corresponding signal segments are combined into a background signal, representing relatively minor or redundant contextual information. For the divided focus signal (high-weight continuous time segment) and background signal (low-weight time segment), a set of predefined statistical features are calculated along their time dimension. These features include the signal's mean, variance, peak value, root mean square, slope, curvature, zero-crossing rate, and higher-order moment features. Each statistic characterizes the amplitude distribution, fluctuation intensity, trend, and morphological characteristics of the signal segment from a specific perspective. After the above calculations, the resulting set of statistical values ​​are arranged in a fixed order, forming the focus feature vector and background feature vector, respectively.

[0033] In one implementation, the working principle of the preset feature compression network is to purify and reduce the dimensionality of high-dimensional and potentially redundant differential feature vectors through a neural network with a bottleneck structure. That is, the network is usually composed of one-dimensional convolutional layers. Its structural design adopts the method of compression followed by expansion or direct projection. First, the input differential feature vector is mapped to a bottleneck layer with a significantly lower dimension, and noise and redundant information are filtered out. Then, the bottleneck features are mapped to the target output dimension through subsequent layers to form the final context feature vector.

[0034] In one implementation, cross-modal fusion is achieved through a learnable fusion layer that receives contextual feature vectors as guidance information and dynamically generates a set of modulation parameters or fusion weights based on them. These parameters are then applied to the target sub-signal to perform structured adjustments and enhancements. Through this context-conditional modulation, the original observation signal is injected with historical background knowledge that is highly relevant to the current recognition task, thereby generating an enhanced sub-signal that retains the original details and is rich in discriminative semantics.

[0035] In one embodiment, see Figure 2 , Figure 2 The flowchart illustrates the working process of the preset attention module. The working principle of the preset attention module includes: Obtain input features; The first feature vector is obtained by performing 3×3 max pooling and dotted convolution on the input features; The second feature vector is obtained by performing 3×3 average pooling and dotted convolution on the input features; The first and second feature vectors are added element by element, and the attention weight vector is obtained by normalizing it using the Sigmoid activation function. The enhanced features are obtained by multiplying the attention weight vector element-wise with the input features.

[0036] In one embodiment, see Figure 3 , Figure 3 This is a flowchart of the time-enhanced feature generation process. Extracting temporal local features from time-level features to obtain time-enhanced features includes: The time-level features are decomposed along the time dimension using different partitioning strategies to obtain the first and second sub-feature sets. The first partitioning strategy is to divide the time-level features into a first half and a second half along the time dimension. The second partitioning strategy is to decompose the time-level features into odd-order parts and even-order parts along the time dimension. The first half and the second half of the first feature set are subjected to time-dimension-separable convolutions, and the convolution results are fused at the time boundary to obtain the boundary-enhanced features. The first enhanced feature set is obtained by performing cross-segment weighted multiplication of the boundary enhancement features with the first half and the second half of the features of the first sub-feature set respectively; The odd-order and even-order features of the second sub-feature set are stacked alternately in the time dimension to obtain the dual feature matrix; The dual feature matrix is ​​subjected to depthwise separable convolution, and bidirectional pooling is performed on the odd and even dimensions to obtain the odd and even co-features. The second enhanced feature set is obtained by co-enhancing the odd and even parts of the features in the second sub-feature set based on the odd-even co-enhancing features. The first intermediate fusion feature and the second intermediate fusion feature are obtained by concatenating the enhanced features in the first and second enhanced feature sets in the time width dimension, respectively. The first intermediate fusion feature and the second intermediate fusion feature are respectively shuffled, and the shuffled features are re-divided in the time dimension to obtain the first group feature set and the second group feature set; Each group feature of the first group feature set and the second group feature set is independently convolved pointwise to obtain the first transform feature set and the second transform feature set; The first output feature is obtained by concatenating each transformation feature in the first transformation feature set along the time dimension; The second output feature is obtained by concatenating each transformation feature in the second transformation feature set along the time dimension; The time-enhanced feature is obtained by adding the first output feature, the second output feature, and the time-level feature element by element.

[0037] In one implementation, a first partitioning strategy is used to capture continuous temporal information, and a second partitioning strategy is used to capture interleaved temporal information.

[0038] In one implementation, the first and second halves of the first feature set are subjected to depthwise separable convolutions in the time dimension, with the kernel size set to 3. This aims to capture the local dependencies and change patterns between adjacent time points in the two halves of the time series with a smaller receptive field. After convolution, two feature blocks with slightly reduced length in the time dimension are obtained. These two feature blocks are then aligned and concatenated at their original time boundaries, thereby generating a more continuous feature representation that integrates information from the preceding and following halves at the original midpoint of the sequence, i.e., a boundary-enhanced feature. This process, while extracting local temporal patterns, pays special attention to and repairs the temporal continuity loss that may be caused by hard partitioning, ensuring that long-range temporal structural information spanning the midpoint of the sequence is effectively preserved and enhanced.

[0039] In one implementation, the staggered time period feature extraction explicitly models the odd-even staggered dependency relationship in the time series by rearranging the temporal structure. That is, the odd-numbered time point features and even-numbered time point features separated from the original sequence are no longer regarded as two independent segments, but are staggered and spliced ​​along the time dimension, that is, they are recombined into a continuous new feature matrix with a regular alternation in the order of odd-even-odd-even...

[0040] In one implementation, a depthwise separable convolution is performed on the dual feature matrix, with the kernel size set to 3. On the reconstructed alternating temporal structure, local patterns spanning odd and even positions are extracted, such as joint change features between adjacent odd and even point pairs. After the convolution is completed, independent pooling operations, such as max pooling or average pooling, are performed along the odd and even index rows of the matrix to extract the most significant or typical features of the odd and even sequences, respectively. The two pooling results are then concatenated or interacted to obtain the odd-even joint features.

[0041] In one implementation, collaborative enhancement refers to using high-level abstract features representing odd-even correlation extracted from interleaving and pooling as guiding signals to modulate and enrich the original odd-order and even-order features respectively. That is, the odd-even collaborative features encode the complementarity and dependency relationship between odd and even sequences, and apply them to the original odd-part features and even-part features respectively through learnable mapping. For example, it can enhance the pattern of strong correlation between even part and odd part features, or correct the trend of even part features affected by odd part.

[0042] In one implementation, the transformation feature generation process involves first shuffling two intermediate fused features obtained from continuous and interleaved branches, respectively. This involves breaking the original temporal order and randomly or regularly rearranging and exchanging features from different sources to promote cross-branch information interaction. Next, the shuffled features are uniformly divided along the time dimension to form multiple time segments, constituting a first group feature set and a second group feature set. Subsequently, each independent time segment feature in these two group feature sets undergoes pointwise convolution processing. This convolution operates independently on each group, aiming to learn and enhance the refined feature representation within each segment.

[0043] In one embodiment, extracting sensor-level correlation features from sensor-level features to obtain sensor enhancement features includes: The sensor-level features are divided into similar channels according to the sensor type to obtain a feature set of the same type of sensor; The sensor-level features are randomly divided across sensor channels according to a preset number of groups to obtain a hybrid sensor feature set; For each feature of the same type of sensor in the feature set of the same type of sensor, perform depthwise separable convolution and max pooling operations in the channel dimension, and multiply the pooling results element-wise with the corresponding feature of the same type of sensor to obtain the enhanced feature set of the same type. For each hybrid sensor feature in the hybrid sensor feature set, perform depthwise separable convolution and max pooling operations in the channel dimension, and multiply the pooling results element-wise with the corresponding hybrid sensor feature to obtain the hybrid enhanced feature set; Connect the same type of enhancement features in the same enhancement feature set along the channel direction to obtain the same type of fused features; The hybrid enhancement features in the hybrid enhancement feature set are connected along the channel direction to obtain the hybrid type fusion feature; The sensing enhancement feature is obtained by element-wise addition of the same type fusion feature, the mixed type fusion feature and the sensing level feature.

[0044] In one implementation, the process of classifying channels of the same type involves categorizing all sensor channels based on the physical or response characteristic category of each sensor channel, which has already been enhanced with time-dimensional sensing features. This categorization is done according to the manufacturer, the type of sensitive gas, or the material type. Subsequently, the feature data corresponding to multiple sensor channels belonging to the same category are extracted and combined to form multiple feature subsets. Each subset specifically contains information about all channels of the same type of sensor, and the collection of these subsets constitutes the feature set of the same type of sensor.

[0045] In one implementation, random cross-sensor channel partitioning is based on sensor-level features, not on sensor type. Instead, all sensor channels are randomly shuffled and evenly or according to preset rules into a fixed number of groups, each containing combinations of channels from different sensor types. This random partitioning breaks the inherent boundaries of sensor types, forcing the subsequent feature extraction process to learn and fuse the correlation patterns between sensor signals from different response characteristics and different sensitive sources. The resulting hybrid sensor feature set can capture broader, heterogeneous cross-information that transcends the internal correlations of similar sensors, enhancing the model's overall perception and discrimination capabilities in complex gas environments.

[0046] The foregoing has described one embodiment of the present invention in detail, but this content is merely a preferred embodiment and should not be considered as limiting the scope of the present invention. All equivalent variations and modifications made within the scope of the claims of this invention should still fall within the scope of the claims of this invention.

Claims

1. A deep learning-based environment detection method, characterized in that, The method includes: Real-time acquisition of raw response signals from the gas sensor array; The original response signal is divided into signals and reconstructed with context awareness to obtain an enhanced sub-signal set; Two-dimensional features are obtained by transforming and reconstructing the spatiotemporal matrix of the target enhancement sub-signal; the row dimension of the spatiotemporal matrix corresponds to the sensor channel, and the column dimension of the matrix corresponds to the time series sampling points; the target enhancement response sub-signal is any one of the enhancement sub-signals in the set of enhancement sub-signals; Temporal features are obtained by extracting temporal features from the two-dimensional features in the time channel dimension using a preset attention module; Temporal local features are extracted from the time-level features to obtain temporal enhancement features; The time-enhancing features are extracted in the sensor channel dimension by a preset attention module to obtain sensor-level features. Sensor enhancement features are obtained by extracting inter-sensor correlation features from the sensor-level features; The sensing enhancement features corresponding to all enhancement sub-signals are flattened and input into a fully connected layer for classification mapping, and the gas category identification result is obtained through a Softmax layer.

2. The deep learning-based environment detection method according to claim 1, characterized in that, The enhanced response signal set obtained by performing signal segmentation and context-aware reconstruction on the original response signal includes: The original response signal is continuously overlapped and segmented by a preset first sliding window to obtain a sub-signal set; For the target signal, the normalized response signal is intercepted through a preset second sliding window to obtain a context signal containing the target sub-signal; the length of the preset first sliding window is less than the length of the preset second sliding window; the target sub-signal is any one of the sub-signals in the set of sub-signals; The context signal is input into a preset attention localization network to obtain a focus weight vector; Based on the focus weight vector, the context signal is divided into regions to obtain a thresholded region segmentation, which yields the focus signal and the background signal. The focus signal and the background signal are respectively subjected to time-series statistical feature calculations to obtain focus feature vector and background feature vector; The difference between the focused feature vector and the background feature vector in each dimension is calculated to obtain the differentiated feature vector of the focused signal relative to the background signal; The differential feature vector is input into a preset feature compression network to obtain a context feature vector; The target sub-signal and the context feature vector are fused across modalities to obtain the enhanced sub-signal; The set of enhancer signals is obtained by statistically analyzing all enhancer signals.

3. The environment detection method based on deep learning according to claim 1, characterized in that, The working principle of the preset attention module includes: Obtain input features; The first feature vector is obtained by performing 3×3 max pooling and point convolution on the input features; The input features are subjected to 3×3 average pooling and point convolution to obtain the second feature vector; The first feature vector and the second feature vector are added element by element, and the attention weight vector is obtained by normalizing it through the Sigmoid activation function. The enhanced features are obtained by multiplying the attention weight vector element-wise with the input features.

4. The environment detection method based on deep learning according to claim 1, characterized in that, Extracting temporal local features from the aforementioned time-level features to obtain temporal enhancement features includes: The time-level features are decomposed along the time dimension using different partitioning strategies to obtain a first sub-feature set and a second sub-feature set; the first partitioning strategy is to divide the time-level features into a first half and a second half along the time dimension; the second partitioning strategy is to decompose the time-level features into an odd-order part and an even-order part along the time dimension. The first half and the second half of the first sub-feature set are subjected to time-dimension-separable convolutions, and the convolution results are fused at the time boundary to obtain boundary-enhanced features. The boundary enhancement features are multiplied by the first half and the second half of the features of the first sub-feature set respectively through cross-segment weighted multiplication to obtain the first enhancement feature set; The odd-order and even-order features of the second sub-feature set are stacked alternately in the time dimension to obtain the dual feature matrix; The dual feature matrix is ​​subjected to depthwise separable convolution, and bidirectional pooling is performed on the odd and even dimensions to obtain odd and even co-features. The second enhanced feature set is obtained by co-enhancing the odd and even features in the second sub-feature set according to the odd-even co-enhancing features. The first and second intermediate fusion features are concatenated along the time width dimension of the first and second enhanced feature sets, respectively; The first intermediate fusion feature and the second intermediate fusion feature are respectively shuffled, and the shuffled features are re-divided in the time dimension to obtain the first group feature set and the second group feature set; Each group feature of the first group feature set and the second group feature set is independently convolved pointwise to obtain the first transform feature set and the second transform feature set; The first output feature is obtained by concatenating each transformation feature in the first transformation feature set along the time dimension; The second output feature is obtained by concatenating each transformation feature in the second transformation feature set along the time dimension; The time-enhanced feature is obtained by adding the first output feature, the second output feature, and the time-level feature element by element.

5. The deep learning-based environment detection method according to claim 1, characterized in that, The sensor enhancement features obtained by extracting inter-sensor correlation features from the aforementioned sensor-level features include: The sensor-level features are divided into similar channels according to sensor type to obtain a feature set of the same type of sensor; The sensor-level features are randomly divided across sensor channels according to a preset number of groups to obtain a hybrid sensor feature set; For each sensor feature in the same type feature set, perform depthwise separable convolution and max pooling operations in the channel dimension, and multiply the pooling results element-wise with the corresponding sensor feature to obtain the same type enhanced feature set. For each hybrid sensor feature in the hybrid sensor feature set, perform channel-dimensional depthwise separable convolution and max pooling operations, and multiply the pooling result element-wise with the corresponding hybrid sensor feature to obtain the hybrid enhanced feature set; Connect the similar enhancement features in the same enhancement feature set along the channel direction to obtain the same type fusion feature; The hybrid enhancement features in the hybrid enhancement feature set are connected along the channel direction to obtain hybrid type fusion features; The sensing enhancement feature is obtained by element-wise addition of the same-type fusion feature, the mixed-type fusion feature, and the sensing-level feature.

6. A deep learning-based environment detection system, characterized in that, The system includes: The signal acquisition module is used to acquire the raw response signal of the gas sensor array in real time; A partitioning and reconstruction module is used to perform signal partitioning and context-aware reconstruction on the original response signal to obtain an enhanced sub-signal set; The conversion module is used to convert the target enhancement sub-signal into a spatiotemporal matrix and reconstruct it to obtain two-dimensional features; the row dimension of the spatiotemporal matrix corresponds to the sensor channel, and the column dimension of the matrix corresponds to the time series sampling points; the target enhancement response sub-signal is any one of the enhancement sub-signals in the set of enhancement sub-signals; The first feature extraction module is used to extract time-level features from the two-dimensional features in the time channel dimension through a preset attention module. The temporal enhancement feature generation module is used to extract temporal local features from the temporal features to obtain temporal enhancement features; The second feature extraction module is used to extract sensor-level features from the time-enhanced features in the sensor channel dimension through a preset attention module. The sensing enhancement feature generation module is used to extract the inter-sensor correlation features from the sensing-level features to obtain sensing enhancement features; The result generation module is used to flatten the sensing enhancement features corresponding to all enhancement sub-signals and input them into the fully connected layer for classification mapping, and obtain the gas category identification result through the Softmax layer.

7. The deep learning-based environment detection system according to claim 6, characterized in that, The partitioning and reconstruction module includes: The segmentation module is used to continuously overlap and segment the original response signal through a preset first sliding window to obtain a sub-signal set; The interception module is used to intercept the normalized response signal containing the target sub-signal through a preset second sliding window for the target signal; the length of the preset first sliding window is less than the length of the preset second sliding window; the target sub-signal is any one of the sub-signals in the set of sub-signals; A vector generation module is used to input the context signal into a preset attention localization network to obtain a focus weight vector; The region segmentation module is used to segment the context signal into regions based on the focus weight vector to obtain a thresholded region segmentation, which in turn yields the focus signal and the background signal. The time-series statistical feature calculation module is used to perform time-series statistical feature calculations on the focused signal and the background signal respectively to obtain a focused feature vector and a background feature vector; The differential vector generation module is used to calculate the difference between the focusing feature vector and the background feature vector in each dimension to obtain the differential feature vector of the focusing signal relative to the background signal; The context vector generation module is used to input the differential feature vector into a preset feature compression network to obtain the context feature vector; The fusion module is used to perform cross-modal fusion of the target sub-signal and the context feature vector to obtain the enhanced sub-signal; The statistics module is used to statistically analyze all the enhancer signals to obtain the enhancer signal set.

8. The deep learning-based environment detection system according to claim 6, characterized in that, The working principle of the preset attention module includes: Obtain input features; The first feature vector is obtained by performing 3×3 max pooling and point convolution on the input features; The input features are subjected to 3×3 average pooling and point convolution to obtain the second feature vector; The first feature vector and the second feature vector are added element by element, and the attention weight vector is obtained by normalizing it through the Sigmoid activation function. The enhanced features are obtained by multiplying the attention weight vector element-wise with the input features.

9. The deep learning-based environment detection system according to claim 6, characterized in that, The time-enhanced feature generation module includes: The decomposition module is used to decompose the time-level features in the time dimension according to different partitioning strategies to obtain a first sub-feature set and a second sub-feature set; the first partitioning strategy is to divide the time-level features into a first half and a second half in the time dimension; the second partitioning strategy is to decompose the time-level features into odd-order parts and even-order parts in the time dimension. The boundary feature generation module is used to perform time-dimension-separable convolutions on the first half and the second half of the features of the first sub-feature set, and then fuse the convolution results at the time boundary to obtain the boundary enhancement features. The first feature generation module is used to perform cross-segment weighted multiplication of the boundary enhancement features with the first half of the features and the second half of the features of the first sub-feature set to obtain the first enhancement feature set; The matrix generation module is used to perform time-dimension interleaving and stacking of the odd-order and even-order features of the second sub-feature set to obtain a dual feature matrix. The collaborative feature generation module is used to perform depthwise separable convolution on the dual feature matrix and bidirectional pooling on the odd and even dimensions to obtain odd and even collaborative features. The second feature generation module is used to perform collaborative enhancement on the odd and even parts of the features in the second sub-feature set according to the odd-even collaborative features to obtain the second enhanced feature set; The fusion feature generation module is used to concatenate the enhanced sub-features in the first enhanced sub-feature set and the second enhanced sub-feature set in the time width dimension to obtain the first intermediate fusion feature and the second intermediate fusion feature; The group feature generation module is used to perform feature shuffling on the first intermediate fusion feature and the second intermediate fusion feature respectively, and to re-divide the shuffled features in the time dimension to obtain the first group feature set and the second group feature set respectively; The transform feature generation module is used to independently perform pointwise convolution on each group feature of the first group feature set and the second group feature set to obtain the first transform feature set and the second transform feature set; The first connection module is used to connect each transformation feature in the first transformation feature set in the time dimension to obtain the first output feature; The second connection module is used to connect each transformation feature in the second transformation feature set in the time dimension to obtain the second output feature; The first addition module is used to add the first output feature, the second output feature and the time-level feature element by element to obtain the time-enhanced feature.

10. The deep learning-based environment detection system according to claim 6, characterized in that, The sensing enhancement feature generation module includes: The same-type segmentation module is used to divide the sensor-level features into same-type channels according to the sensor type to obtain a same-type sensor feature set; The random partitioning module is used to randomly partition the sensor-level features across sensor channels according to a preset number of groups to obtain a hybrid sensor feature set; The same type feature generation module is used to perform channel-dimension-separable convolution and max pooling operations on each same type sensor feature in the same type sensor feature set, and multiply the pooling result with the corresponding same type sensor feature element by element to obtain the same type enhanced feature set. The hybrid feature generation module is used to perform channel-dimensional depthwise separable convolution and max pooling operations on each hybrid sensor feature in the hybrid sensor feature set, and multiply the pooling result with the corresponding hybrid sensor feature element by element to obtain the hybrid enhanced feature set; The third connection module is used to connect the same type of enhancement features in the same type enhancement feature set along the channel direction to obtain the same type fusion feature; The fourth connection module is used to connect the hybrid enhancement features in the hybrid enhancement feature set along the channel direction to obtain hybrid type fusion features; The second addition module is used to perform element-level addition of the same-type fusion features, the mixed-type fusion features, and the sensing-level features to obtain sensing enhancement features.