Method for identifying trace gases in seawater based on multi-color column cooperation and machine learning

By employing multi-column collaboration and machine learning methods, a dual-model fusion architecture of KNN and CNN was constructed. Combined with SHAP analysis, this approach solved the problems of insufficient sensitivity, retention time drift, and weak anti-interference ability in seawater trace gas identification, achieving high-precision gas identification.

CN121476498BActive Publication Date: 2026-03-27QILU UNIVERSITY OF TECHNOLOGY (SHANDONG ACADEMY OF SCIENCES) +1
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-01-06
Publication Date
2026-03-27

AI Technical Summary

Technical Problem

Existing seawater trace gas identification technologies suffer from problems such as insufficient sensitivity, identification errors caused by the co-escape of multiple gas components, retention time shifts caused by column temperature drift, weak anti-interference ability of machine learning models, and cumbersome detection procedures.

Method used

By employing a multi-column collaborative and machine learning approach, a dual-model fusion architecture of KNN and CNN is constructed through the fusion of multi-dimensional chromatographic peak features, and combined with SHAP analysis, gas identification is achieved.

Benefits of technology

It significantly improves the accuracy of seawater trace gas identification, can quickly match unknown gases, resist interference, shorten the detection cycle, and enhance the interpretability of results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121476498B_ABST
    Figure CN121476498B_ABST
Patent Text Reader

Abstract

The application discloses a seawater trace gas identification method based on multi-color column cooperation and machine learning, relates to the technical field of gas chromatography analysis, and comprises the following steps: preparing a gas sample to be identified and performing gas chromatography detection on the gas sample; performing denoising, normalization processing and outlier rejection on the gas chromatography; extracting manual peak characteristics and time sequence peak characteristics to form a multi-dimensional feature set; performing hierarchical screening on the feature set and retaining core features; constructing a KNN model and a CNN model double-model fusion architecture; dividing the features into a training set and a verification set, training and verifying the double-model architecture, and optimizing double-model architecture parameters; and applying SHAP analysis to the model decision process to generate a feature importance visualization report. The application does not need to rely on accurate standard sample calibration, efficiency and adaptability are improved, personalized detection demands of different scenes are adapted, SHAP technology is introduced to clearly determine the contribution degree of key identification features, and interpretability and reliability are enhanced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of gas chromatography analysis technology, and in particular to a method for identifying trace gases in seawater based on multi-column synergy and machine learning. Background Technology

[0002] Trace gases in seawater refer to gaseous components that dissolve in seawater at extremely low concentrations (typically less than 1 micromole per liter). Although they are present in minute quantities, they play a crucial role in marine chemistry, atmospheric science, global climate change, and marine ecosystem research.

[0003] Current methods for identifying trace gases in seawater primarily rely on traditional gas chromatography (GC) techniques. These methods classify gases through single-column separation and fixed threshold judgment, but they suffer from significant drawbacks: First, seawater samples have complex matrices and extremely low concentrations of trace gases (often below 1 ppm), making them susceptible to interference from salinity and organic matter. Traditional GC detectors lack sufficient sensitivity, leading to missed detections. Second, multi-component gases are prone to co-elution, making complete separation difficult with a single column, resulting in overlapping peaks that interfere with identification. Third, column temperature drift and column aging can cause retention time shifts, making traditional threshold judgments prone to misjudgment. Fourth, existing gas identification technologies incorporating machine learning do not fully utilize the synergistic separation characteristics of multiple columns, relying only on single-dimensional peak features, resulting in a lack of targeted feature selection and weak model anti-interference capabilities. Fifth, seawater samples require complex pretreatment; current technologies lack an integrated "pretreatment-separation-identification" solution, making the detection process cumbersome. Summary of the Invention

[0004] To overcome the aforementioned problems in the existing technology, this invention proposes a method for identifying trace gases in seawater based on multi-column synergy and machine learning.

[0005] The technical solution adopted by this invention to solve its technical problem is: a method for identifying trace gases in seawater based on multi-column synergy and machine learning, comprising the following steps:

[0006] Step 1: Prepare the gas sample to be identified and perform gas chromatography detection on the gas sample;

[0007] Step 2: Denoise, normalize, and remove outliers from the gas chromatogram;

[0008] Step 3: Extract manual peak features and time-series peak features to form a multi-dimensional feature set;

[0009] Step 4: Perform stratified filtering on the feature set obtained in Step 3, retaining the core features;

[0010] Step 5: Construct a dual-model fusion architecture combining the KNN and CNN models;

[0011] Step 6, the feature obtained in step 4 is divided into a training set and a validation set, and the double model architecture is trained and verified to optimize the double model architecture parameters;

[0012] Step 7, the SHAP analysis model decision process is applied to generate a feature importance visualization report.

[0013] The above-mentioned method for identifying trace gases in seawater based on multi-color column cooperation and machine learning, the gas sample in step 1 includes a plurality of different concentration gradient gases to be identified, and interference gases.

[0014] The above-mentioned method for identifying trace gases in seawater based on multi-color column cooperation and machine learning, step 4 is specifically: dividing the features into physical features suitable for KNN model and time sequence features suitable for CNN model, respectively screening through back verification and single branch verification to retain core features.

[0015] The above-mentioned method for identifying trace gases in seawater based on multi-color column cooperation and machine learning, step 5 is specifically: the KNN model takes manual peak features as input, uses L1 distance to calculate sample similarity, optimizes k value according to gas species, realizes fast matching and classification; the CNN model takes time sequence peak features as input, constructs a lightweight 1D-CNN architecture, avoids gradient disappearance through residual connection, and excavates deep correlations between features; and a voting mechanism is used for model fusion.

[0016] The above-mentioned method for identifying trace gases in seawater based on multi-color column cooperation and machine learning, the voting mechanism is specifically: when the prediction results of the KNN model and the CNN model are consistent, the result is directly output; and when the results are inconsistent, the SHAP value weight is used for weighted judgment.

[0017] The above-mentioned method for identifying trace gases in seawater based on multi-color column cooperation and machine learning, step 7 is specifically: calculating the SHAP value of each peak feature, taking the absolute value of the SHAP value of each feature, calculating the average value, and measuring the average influence degree on the model output.

[0018] The beneficial effects of the present application are that through multi-dimensional chromatographic peak feature fusion and double model cooperation mechanism, the interference such as retention time drift and peak shape distortion can be effectively resisted, and the weak signal characteristics of low-concentration gases are optimized, solving the misjudgment and omission problems of traditional methods, and significantly improving the accuracy of gas identification.

[0019] Efficiency and adaptability are improved: without relying on accurate standard sample calibration, unknown gas matching can be realized only by collecting characteristic samples in advance to build a model, greatly shortening the detection period; at the same time, the feature set and model parameters can be flexibly adjusted, compatible with the identification requirements of multi-component and multi-concentration gases, and adapt to individual detection demands in different scenes.

[0020] Explainability and reliability enhancement: The introduction of SHAP technology explicitly identifies the contribution of key identification features, breaking the "black box" limitation of machine learning models, making the detection results traceable and verifiable, and meeting the requirements of industrial detection, supervision and other scenarios for the reliability of identification results. BRIEF DESCRIPTION OF DRAWINGS

[0021] Figure 1 is the flowchart of the present application;

[0022] Figure 2 is the schematic diagram of the dual model fusion architecture of the present application;

[0023] Figure 3 is the SHAP feature importance analysis diagram of the present application. DETAILED DESCRIPTION

[0024] In order to enable those skilled in the art to better understand the technical solutions of the present application, the present application will be described in detail below in combination with the drawings and specific embodiments.

[0025] The present application realizes accurate identification of gas through "sample collection and GC detection → data preprocessing → peak feature extraction → feature screening → dual model construction → verification and optimization → explainability analysis", and the core is the deep fusion of multi-dimensional features of gas chromatography peaks and machine learning algorithms. The specific process is shown in Figure 1 .

[0026] (I) Sample collection and GC detection

[0027] 1. Sample preparation: Prepare the gas sample to be identified (cover multiple different concentration gradients of target gas and interfering gas), collect at least 30 effective samples for each gas sample, and increase to 50 samples for low concentration (≤5ppm) samples to ensure sample balance.

[0028] 2. GC instrument parameter setting: Use a combination of multiple chromatographic columns (5A molecular sieve, Hayesep D, GDX-502) integrated in the same column oven. The column oven is programmed to rise to 60°C and maintain; the carrier gas is high-purity helium, and the flow rate is 30 mL / min in constant flow mode; the detector is EPD. The core of the system is to realize the center cutting and separation of each component by accurately controlling the valve switching time.

[0029] (II) Data preprocessing

[0030] 1. Denoising: Use wavelet denoising algorithm to remove instrument noise, baseline drift interference and retain peak shape core features.

[0031] 2. Normalization: Map the peak-related data to the [0, 1] interval by the formula to eliminate the dimension difference.

[0032] 3. Outlier rejection: Hotelling's T2 method is used to exclude samples with abnormal peaks caused by instrument failure, ensuring data reliability.

[0033] (Three) Peak feature extraction

[0034] Extract two types of core features to form a multi-dimensional feature set:

[0035] 1. Manual peak features (physically interpretable features): including peak height, peak area, relative retention time (instead of absolute retention time to resist drift), peak rising slope (to resist peak shape distortion), peak start time, peak end time, a total of 7 types of features, covering key physical indicators for gas identification.

[0036] 2. Time series peak features: intercept the original time series data (about 500 sampling points) before and after the characteristic peak, retaining peak shape detail information, adapting to the feature mining needs of deep learning models.

[0037] (Four) Feature selection

[0038] Use a combination strategy of "hierarchical screening + dual model collaborative verification":

[0039] Hierarchical screening: divide features into KNN-adapted physical features and CNN-adapted time series features according to the characteristics of the dual model, and screen them through reverse verification / single branch verification respectively, retaining core features.

[0040] Collaborative verification: integrate features into dual model architecture verification, with fusion accuracy ≥95% and feature contribution ≥20% as the standard, retaining core features and eliminating redundant information.

[0041] (Five) Dual model construction and fusion

[0042] Build a "KNN + CNN" dual model fusion architecture that balances fast recognition and accurate classification. The dual model fusion architecture is shown in Figure 2

[0043] 1. KNN model: input manual peak features, use L1 distance to calculate sample similarity, optimize k value (30-60 interval) according to gas species, achieve fast matching classification, and adapt to the emergency identification scene without standards.

[0044] 2. CNN model: input "time series peak features", build a lightweight 1D-CNN architecture (3 convolution layers, 16-64 filters, kernel size 3-5), avoid gradient disappearance through residual connection, and mine deep associations between features.

[0045] 3. Model fusion: use a voting mechanism, when the dual model prediction results are consistent, directly output; when the results are inconsistent, use SHAP value weight to determine, improve classification reliability.​

[0046] (VI) Model validation and optimization

[0047] 1. Dataset split: Divide the training set and test set in a 7:3 ratio, and use 5-fold cross-validation to evaluate model performance.

[0048] 2. Performance indicators: Identify accuracy, recall rate, and F1 value as core indicators, with a target accuracy of ≥95%.

[0049] 3. Optimization strategy: Optimize model parameters (KNN k value, CNN learning rate size) through grid search; use oversampling to enhance data for low-concentration samples; and reselect feature subsets if there is feature redundancy.

[0050] (VII) Explainability analysis

[0051] Apply SHAP (Shapley Additive exPlanations) technology to analyze the model decision-making process: calculate the SHAP value of each peak feature, quantify the contribution of features to the identification result, clarify the key identification basis, generate a feature importance visualization report, and improve the credibility of the detection result.

[0052] This example focuses on the identification of CH4 (covering a concentration gradient of 1-10 ppm, with the simultaneous addition of interfering gases such as C2H6), with a focus on verifying the ability to resist "retention time drift and peak distortion" interference. The specific process is as follows:

[0053] I. CH4-specific samples and GC detection configuration

[0054] Sample preparation: Prepare 6 concentration gradient samples of CH4 (1 ppm, 2 ppm, 4 ppm, 6 ppm, 8 ppm, 10 ppm), collect 30 basic samples for each concentration, and additionally collect 20 samples (total 50) for 1 ppm and 2 ppm low-concentration samples; simultaneously mix equal concentrations of C2H6, CO, N2O, H2, and 50 times CO2 as interference components to simulate the actual complex gas environment.

[0055] GC anti-interference parameter settings: Use a combination of 5Å molecular sieve column (adapted for CH4 separation) + Hayesep D column, and use a valve switching system to direct CH4 into the 5Å molecular sieve column; program the column oven to heat to 60°C and maintain (reduce retention time drift caused by temperature fluctuations), and maintain a constant flow of 30 mL / min of carrier gas (high-purity helium); focus the CH4 characteristic response interval with the EPD detector to reduce the influence of interference gas signal superposition.

[0056] II. Interference preprocessing for CH4

[0057] 1. Peak distortion resistance preprocessing:

[0058] CH4 peak is prone to distortion such as "peak width increase, small inflection point addition" due to injection pressure fluctuation. Wavelet denoising algorithm is used for targeted filtering of the time interval (386-466s) where CH4 peak is located (select db4 wavelet basis, 3 layers of decomposition), and the core rising / falling slope characteristics of CH4 peak are retained. Then, the distorted samples (a total of 8 distorted samples at low concentration of 2ppm) are removed by Hotelling's T2 method.

[0059] 2. Normalization to weaken the retention time drift:

[0060] The retention time data of CH4 is normalized by "relative retention time" (using stable CO2 peak as reference), which converts absolute retention time into relative value and preliminarily offsets the drift interference within ±2s.

[0061] Three, feature extraction and anti-interference selection of CH4

[0062] 1. Anti-interference feature extraction:

[0063] (1) Manual features: extract the peak height of CH4 , where y peak is the y value corresponding to the maximum value of y in the peak interval, y_baseline is the baseline corresponding to the peak; peak area , where s: the sampling point index corresponding to the peak start, e: the sampling point index corresponding to the peak end, t k , y k : the time and response value of the kth sampling point; : the trapezoidal area formed by the adjacent two sampling points and the baseline, and the summation is the total peak area; relative retention time , where is the retention time of CH4 peak; is the retention time of CO2 peak; peak rising slope , where is the response value of the peak start point, is the time corresponding to the peak start point, y peak , t peak : the response value and time of the peak vertex; high area ratio ; tail factor T=W 0.05h / 2d1, W 0.05h : the entire peak width at 5% peak height, 2d1: the distance between the peak vertex and the peak front edge. A total of 7 physical characteristics.

[0064] (2) Time sequence features: extract the original signal of 500 sampling points before and after CH4 peak (including peak width, inflection point and other distortion details), and retain the time sequence texture information after peak distortion.

[0065] 2. Anti-interference feature screening:

[0066] In hierarchical screening, the combination of "peak width, peak symmetry, and peak rising edge slope" (sensitive to chromatographic separation quality and providing time dynamic information), "peak height" (sensitive to concentration information) is preferentially retained, and "retention time, peak area, and peak height area ratio" features sensitive to interference are eliminated, finally retaining 4 core features.

[0067] Four, dual-model resistance mechanism to CH4 interference

[0068] KNN resists retention time drift:

[0069] With "peak width, peak symmetry, and peak rising edge slope" as input, L1 distance is used to calculate sample similarity, and k value is optimized to 10, which adapts to the concentration gradient distribution of CH4. Even if the retention time of CH4 drifts ± 3s, the fluctuation range of relative retention time is compressed, and the stable features of peak symmetry and peak rising edge slope can compensate for the deviation of retention time, ensuring that the matching accuracy of KNN to CH4 is not affected by drift.

[0070] CNN resists peak distortion:

[0071] With "500-point time series peak data" as input, a 1D-CNN is constructed with 3 convolutional layers, kernel size 3 / 5 / 3, and filter number 32 / 64 / 32. When CH4 peaks appear "widening and additional small inflection points" distortion, convolutional layers can extract time series texture features after distortion, such as "CH4 exclusive texture of flat rising edge + narrow falling edge", and retain deep features through residual connection to avoid feature loss caused by peak distortion.

[0072] Fusion verifies anti-interference effect:

[0073] When CH4 has a compound interference of "retention time drift 2s + peak width increase 1 times", the retention time feature of KNN has a slight deviation, but CNN can identify CH4 through time series peak texture. At this time, SHAP weighted judgment is used, and the SHAP contribution degree of "time series peak data" of CH4 reaches 40%, and the final output is the correct CH4 identification result.

[0074] SHAP feature importance analysis as Figure 3As shown, the SHAP value of each feature in the model prediction process is calculated, the absolute value of the SHAP value of each feature is taken, and the average value is calculated to measure the average influence degree of the feature on the model output, and the contribution ratio of the feature to the CH4 gas. In the KNN model in FIG. 3, the average SHAP value of the peak width is higher (the bar is longer), which is a core feature that has a greater influence on the model decision; the peak symmetry, the peak rising slope, and the peak height have a relatively small average influence; in the CNN model, the 78th point of the time sequence peak (the steepest rising slope) has the highest contribution, followed by the 66th point (the node of the accelerated steepness), the 59th point (the initial rising slope), and the 101st point (the transition zone of the peak value), which accurately reflects the CNN's ability to capture the key nodes of the CH4 time sequence peak rising slope.

[0075] In this embodiment, the recognition accuracy of CH4 remains stable under the interference of "retention time drift ± 3s, peak type distortion (peak width increased by 1 times)", verifying the effective resistance of the method to the two types of interference.

[0076] The above embodiments are only exemplary embodiments of the present application and are not used to limit the present application. Those skilled in the art can make various modifications or equivalent replacements to the present application within the spirit and protection scope of the present application, and such modifications or equivalent replacements shall also be considered to fall within the protection scope of the present application.

Claims

1. A method for identifying trace gases in seawater based on multi-column synergy and machine learning, characterized in that, Includes the following steps: Step 1: Prepare the gas sample to be identified and perform gas chromatography detection on the gas sample; Step 2: Denoise, normalize, and remove outliers from the gas chromatogram; Step 3: Extract manual peak features and time-series peak features to form a multi-dimensional feature set; Step 4: Perform stratified filtering on the feature set obtained in Step 3, retaining the core features; Step 5: Construct a dual-model fusion architecture combining the KNN and CNN models; Step 6: Divide the features obtained in Step 4 into training set and validation set, train and validate the dual-model architecture, and optimize the dual-model architecture parameters. Step 7: Apply the SHAP analysis model to the decision-making process and generate a feature importance visualization report; Step 5 specifically involves: the KNN model using manually generated peak features as input, calculating sample similarity using L1 distance, optimizing the k value based on gas type to achieve fast matching and classification; the CNN model using time-series peak features as input, constructing a lightweight 1D-CNN architecture, avoiding gradient vanishing through residual connections, and mining deep correlations between features; and using a voting mechanism for model fusion. The voting mechanism is as follows: when the prediction results of the KNN model and the CNN model are consistent, the result is output directly; when the results are inconsistent, the result is determined by weighting the SHAP value. Step 7 specifically involves: calculating the SHAP value of each peak feature, taking the absolute value of the SHAP value of each feature, and then calculating the average value to measure the average impact on the model output.

2. The method for identifying trace gases in seawater based on multi-column collaboration and machine learning according to claim 1, characterized in that, In step 1, the gas sample includes multiple gases to be identified and interfering gases with different concentration gradients.

3. The method for identifying trace gases in seawater based on multi-column collaboration and machine learning according to claim 1, characterized in that, Step 4 specifically involves dividing the features into physical features adapted to the KNN model and temporal features adapted to the CNN model, and filtering them through reverse verification and single-branch verification respectively, retaining the core features.

Citation Information

Patent Citations

  • Special detection device for analyzing three-channel mine drainage gas

    CN102590422A