A quality control detection method, system, medium and device for an electronic nose system

By constructing response feature extraction and recognition models for quality control samples and standard sample sets, the problem of insufficient recognition stability of electronic nose systems in the detection of highly similar common samples was solved, and the accuracy and reliability of cross-date detection were improved.

CN123179100APending Publication Date: 2026-11-27ZHEJIANG UNIV +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611694845.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-10-30
Publication Date
2026-11-27

Smart Images

  • Figure CN123179100A_ABST
    Figure CN123179100A_ABST
Patent Text Reader

Abstract

The application provides a quality control detection method, system, medium and equipment for an electronic nose system, relates to the technical field of electronic nose detection, and comprises the following steps: acquiring a multi-channel dynamic response signal of a quality control product, a standard sample and a to-be-detected ordinary sample; constructing a detection state reference based on the quality control product and constructing a category direction reference based on the standard sample; calculating a relative feature of the to-be-detected ordinary sample relative to the two types of references and combining the relative feature into a quality control auxiliary feature; screening stable features to establish an identification model, and test data does not participate in screening and model parameter determination; and inputting the model to output a category identification result and a confidence degree. The method simulates the chemical composition by using the quality control product close to the real sample, enhances the comparability of cross-date and batch results, separates the detection state, the category direction and the individual difference, avoids information confusion, screens stable features and performs strict cross-validation to avoid overfitting, finally forms a closed loop of collection, quality control, identification and re-inspection, and improves the identification accuracy of high-similarity samples and the system robustness.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of electronic nose detection technology, and in particular to a quality control detection method, system, medium and device for electronic nose systems. Background Technology

[0002] Electronic noses acquire the overall response patterns of volatile components in samples through a gas-sensitive sensor array and combine this with a classification model, reference samples, or a fingerprint database to achieve sample identification. Among existing solutions, the closest approach focuses on establishing a single-category identification model or using a standard gas and a single reference sample to handle sensor drift. This approach suffers from the following technical shortcomings in detecting highly similar common samples: a single reference sample is insufficient to characterize the detection state of a complex headspace system formed by the proportions of the main components of the target sample; there is a lack of clear functional distinction between reusable standard samples and real common samples with individual differences; and the classification algorithm output alone cannot determine whether the detection state meets the identification quality requirements for the day.

[0003] Therefore, how to establish a unified quality control system for quality control products, standard samples, and ordinary samples, and form a quality control-assisted identification process that can be collected, compared, judged, and triggered for re-inspection, thereby improving the cross-date identification stability of highly similar ordinary samples, is a technical problem that urgently needs to be solved by those skilled in the art. Summary of the Invention

[0004] The purpose of this application is to provide a quality control detection method, system, computer-readable storage medium, and electronic device for an electronic nose system, which can improve the identification stability and usability of highly similar common samples in cross-date detection.

[0005] To address the aforementioned technical problems, this application provides a quality control testing method for an electronic nose system, the specific technical solution of which is as follows: Acquire multi-channel dynamic response signals based on a set of quality control samples, a set of standard samples, and a common sample to be tested; wherein, the set of quality control samples includes at least two mutually distinct quality control samples prepared according to the volatile components and component ratios corresponding to the target sample; the set of standard samples includes at least two categories of standard samples with odor characteristics and reusable. Feature extraction is performed on the first dynamic response signal of each quality control product in the quality control product set to obtain the response center of each quality control product in the multi-channel response feature space and the response relationship between each quality control product. Based on the response center and the response relationship, a detection state reference characterizing the current detection state is constructed. Feature extraction is performed on the second dynamic response signal of each category of standard sample in the standard sample set to obtain the category center of each category of standard sample in the multi-channel response feature space, and a category direction reference representing the category direction is constructed based on the category center; Feature extraction is performed on the third dynamic response signal corresponding to the ordinary sample to be tested to obtain the original dynamic response features of the ordinary sample to be tested; Calculate the first relative feature of the original dynamic response feature relative to the detection state reference, and the second relative feature of the original dynamic response feature relative to the category orientation reference, and combine the original dynamic response feature, the first relative feature and the second relative feature into a quality control auxiliary feature; The quality control auxiliary features are screened for stable features, and an identification model is established based on the screened stable features; wherein, test data is not involved in the screening of stable features and the determination of the parameters of the identification model; The quality control auxiliary features of the ordinary sample to be tested are input into the recognition model, and the detection result of the ordinary sample to be tested is output; the detection result includes the category recognition result and confidence level of the ordinary sample to be tested.

[0006] Optionally, feature extraction is performed on the first dynamic response signal of each quality control item in the quality control item set to obtain the response center of each quality control item in the multi-channel response feature space and the response relationship between each quality control item. Based on the response center and the response relationship, a detection state reference characterizing the current detection state is constructed, including: Calculate the response center of the first dynamic response signal of each quality control item in the set of quality control items, the response distance between quality control items, and the projection of each quality control item along the reference axis in the multi-channel response feature space; Calculate the repeatability index of the same quality control product under repeated testing, and the drift index of each quality control product relative to the reference test date; The detection state reference is constructed based on the response center, the response distance, the projection, the repeatability index, and the drift index; The detection status reference is determined, and when the repeatability index or the drift index exceeds a set threshold, an abnormal detection status marker is generated.

[0007] Optionally, feature extraction is performed on the second dynamic response signals of standard samples of each category in the standard sample set to obtain the category center of each category of standard samples in the multi-channel response feature space, and a category orientation reference representing the category orientation is constructed based on the category center, including: Feature extraction is performed on the second dynamic response signal of each category of standard sample in the standard sample set, and the extracted features are aggregated in the multi-channel response feature space to obtain the category center; Calculate the inter-class distance between class centers of different categories, and the intra-class fluctuation of standard samples of the same category relative to their class centers; The category orientation reference is constructed based on the category center of each category, the distance between categories, and the intra-category fluctuation.

[0008] Optionally, constructing the detection state reference based on the response center, the response distance, the projection, the repeatability index, and the drift index includes: Obtain the mapping parameters determined based on the quality control response data corresponding to the reference test date; The response characteristics of each quality control product on the current test day are linearly mapped in the multi-channel response characteristic space according to the mapping parameters to obtain the mapped quality control response characteristics. The response center, response distance, and projection are calculated based on the mapped quality control response characteristics, and the drift index is calculated based on the offset between the mapped quality control response characteristics and the quality control response data of the reference test day.

[0009] Optionally, calculating a second relative feature of the original dynamic response feature relative to the category orientation reference includes: Calculate the distance from the original dynamic response feature to the category center of each category to obtain the category distance for each category; Calculate the cosine similarity between the original dynamic response features and the category center; Calculate the difference and ratio between the distances of the ordinary sample to be tested to the center of each category, and the projection of the original dynamic response feature onto the direction of the line connecting the centers of each category; The second relative feature is obtained by combining the category distance, the cosine similarity, the difference, the ratio, and the projection.

[0010] Optionally, the quality control auxiliary features are subjected to stable feature screening, including: Within each cross-validation period or leave-one-test-day validation period, the stability score of each dimension of the quality control auxiliary features is calculated based on the training data; wherein, the numerator of the stability score is the inter-class difference of the corresponding feature, and the denominator of the stability score is the sum of the intra-class fluctuation and cross-date drift of the corresponding feature; The features are sorted according to the stability score, and a set number of the top-ranked features are selected as the stable features; wherein, the test data does not participate in the calculation of the stability score, the selection of the stable features, or the determination of the parameters of the recognition model.

[0011] Optionally, after outputting the detection results of the ordinary sample to be tested, the method further includes: When the confidence level is lower than the set value, several local sub-prototypes are established in each candidate category of the recognition model, and the relative distance difference between the ordinary sample to be tested and the nearest local sub-prototype of each candidate category is calculated. Based on the prediction direction of the ordinary sample to be tested by multiple candidate models, a consistency score and a consensus confidence level are calculated. When the consistency score and the consensus confidence level meet the preset conditions, the consensus output of the multiple candidate models is used to update the category recognition result. When the relative distance difference is within a set range, a retest prompt message is generated for the ordinary sample to be tested, and the retest prompt message is appended to the test result and output.

[0012] This application also provides a quality control testing system for an electronic nose system, comprising: The signal acquisition module is used to acquire multi-channel dynamic response signals generated based on a set of quality control samples, a set of standard samples, and a common sample to be tested; wherein, the set of quality control samples includes at least two mutually distinguishable quality control samples prepared according to the volatile components and component ratios corresponding to the target sample; the set of standard samples includes at least two categories of standard samples with odor characteristics and reusable. The detection status reference module is used to extract features from the first dynamic response signal of each quality control product in the quality control product set, obtain the response center of each quality control product in the multi-channel response feature space and the response relationship between each quality control product, and construct a detection status reference that characterizes the current detection status based on the response center and the response relationship. The category orientation reference module is used to extract features from the second dynamic response signals of each category of standard samples in the standard sample set, obtain the category center of each category of standard samples in the multi-channel response feature space, and construct a category orientation reference representing the category orientation based on the category center; The feature extraction module is used to extract features from the third dynamic response signal corresponding to the ordinary sample to be tested, so as to obtain the original dynamic response features of the ordinary sample to be tested. An auxiliary feature generation module is used to calculate a first relative feature of the original dynamic response feature relative to the detection state reference, and a second relative feature of the original dynamic response feature relative to the category direction reference, and to combine the original dynamic response feature, the first relative feature and the second relative feature into a quality control auxiliary feature; The feature selection module is used to select stable features for the quality control auxiliary features and establish a recognition model based on the selected stable features; wherein, the test data does not participate in the selection of stable features and the determination of the parameters of the recognition model; The detection module is used to input the quality control auxiliary features of the ordinary sample to be tested into the recognition model and output the detection result of the ordinary sample to be tested; the detection result includes the category recognition result and confidence level of the ordinary sample to be tested.

[0013] This application also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the method described above.

[0014] This application also provides an electronic device, including a memory and a processor, wherein the memory stores a computer program, and the processor implements the steps of the method described above when it invokes the computer program in the memory.

[0015] This application provides a quality control detection method for an electronic nose system, comprising: acquiring multi-channel dynamic response signals based on a set of quality control samples, a set of standard samples, and a common sample to be tested; wherein, the set of quality control samples includes at least two mutually distinguishable quality control samples prepared according to the volatile components and component ratios corresponding to the target sample; the set of standard samples includes at least two categories of standard samples with odor characteristics and reusable; performing feature extraction on the first dynamic response signals of each quality control sample in the set of quality control samples to obtain the response center of each quality control sample in the multi-channel response feature space and the response relationship between each quality control sample, and constructing a detection state reference characterizing the current detection state based on the response center and the response relationship; performing feature extraction on the second dynamic response signals of each category of standard samples in the set of standard samples to obtain the category center of each category of standard samples in the multi-channel response feature space, and constructing a detection state reference characterizing the current detection state based on the response center and the response relationship; and performing feature extraction on the second dynamic response signals of each category of standard samples in the set of standard samples to obtain the category center of each category of standard samples in the multi-channel response feature space, and constructing a detection state reference characterizing the current detection state based on the odor characteristics of each category of standard samples. The method involves constructing a category orientation reference to represent the category orientation using a category center; extracting features from the third dynamic response signal corresponding to the ordinary sample to be tested to obtain the original dynamic response features of the ordinary sample to be tested; calculating the first relative feature of the original dynamic response features relative to the detection state reference, and the second relative feature of the original dynamic response features relative to the category orientation reference, and combining the original dynamic response features, the first relative feature, and the second relative feature into quality control auxiliary features; performing stable feature screening on the quality control auxiliary features, and establishing a recognition model based on the screened stable features; wherein, test data does not participate in the stable feature screening and the parameter determination of the recognition model; inputting the quality control auxiliary features of the ordinary sample to be tested into the recognition model, and outputting the detection result of the ordinary sample to be tested; the detection result includes the category recognition result and confidence level of the ordinary sample to be tested.

[0016] This application designs quality control samples as artificially prepared samples that closely approximate the main component proportions of the target sample, enabling more accurate simulation of the chemical composition of the actual tested object, thus making them more suitable as a reference for sample state testing. A series of testing state references are established through a set of quality control samples with pre-defined differences. Utilizing the response centers and response relationships formed by multiple distinct quality control samples in the multi-channel response feature space, a reference benchmark reflecting the overall state of the current testing system is constructed, effectively enhancing the comparability of test results across dates and batches. Secondly, this application provides category direction references through standard samples, utilizing standard samples with odor characteristics and reusable properties in multi-channel... By establishing stable category centers in the response feature space, the distribution direction of different categories of samples is clearly defined. Simultaneously, individual differences in real-world application scenarios are preserved through ordinary samples, effectively avoiding the drawback of treating detection state changes, category direction, and real-world sample differences as the same factor. This allows feature extraction and model recognition to be optimized separately for different information dimensions. Furthermore, this application further stabilizes the quality control auxiliary features through feature screening and strictly limits test data from participating in the screening and parameter determination of the recognition model. This effectively avoids overfitting in feature selection and model optimism bias, ensuring the generalization performance and reliability of the recognition model in real-world application scenarios. Ultimately, a closed-loop process is formed, encompassing data collection, quality control judgment, auxiliary recognition, low-confidence alerts, and re-inspection or maintenance suggestions. By outputting detection results that combine category recognition and confidence levels, users can mark low-confidence samples based on confidence levels and trigger re-inspection or maintenance suggestions. This significantly improves the practical usability of recognizing highly similar ordinary samples and comprehensively enhances the detection accuracy, robustness, and result reliability of the electronic nose system in complex real-world application scenarios.

[0017] This application also provides a quality control and testing system, a computer-readable storage medium, and an electronic device for an electronic nose system, which have the aforementioned beneficial effects, and will not be elaborated here. Attached Figure Description

[0018] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of this application. For those skilled in the art, other drawings can be obtained based on the provided drawings without creative effort.

[0019] Figure 1 A flowchart of a quality control testing method for an electronic nose system provided in an embodiment of this application; Figure 2 This is a schematic diagram of a quality control and testing system for an electronic nose system provided in an embodiment of this application; Figure 3This is a structural diagram of an electronic device provided in an embodiment of this application. Detailed Implementation

[0020] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0021] The testing objects involved in this application include three categories: quality control materials, standard samples, and ordinary samples. The quality control material set includes at least two distinct quality control materials formulated according to the volatile components and proportions corresponding to the target sample, used to describe the detection status formed by the sensor, headspace, gas path, and environmental conditions under the same test day or the same test batch. The standard sample set includes at least two categories of standard samples with odor characteristics that are reusable, used to provide category orientation and response scale reference. Ordinary samples are real samples to be identified that have specific odor characteristics but vary in year, batch, origin, storage condition, or individual characteristics.

[0022] The difference between quality control samples and standard samples lies in the following: quality control samples are mainly used to describe the testing status, while standard samples are mainly used to describe the category orientation. The difference between ordinary samples and standard samples lies in the following: standard samples emphasize typical odor characteristics and reusability, and are mainly used to establish category orientation references; ordinary samples emphasize individual differences in real-world application scenarios and are mainly used for the final identification output.

[0023] See Figure 1 , Figure 1 A flowchart of a quality control testing method for an electronic nose system provided in this application embodiment, the method comprising: S101: Acquire multi-channel dynamic response signals based on the quality control sample set, standard sample set, and ordinary sample to be tested; The quality control set includes at least two distinct quality control samples formulated according to the volatile components and component ratios corresponding to the target sample; the standard sample set includes at least two categories of standard samples with odor characteristics and reusable. S102: Extract features from the first dynamic response signal of each quality control product in the quality control product set to obtain the response center of each quality control product in the multi-channel response feature space and the response relationship between each quality control product, and construct a detection state reference representing the current detection state based on the response center and the response relationship. S103: Extract features from the second dynamic response signals of each category of standard samples in the standard sample set to obtain the category center of each category of standard samples in the multi-channel response feature space, and construct a category direction reference representing the category direction based on the category center; S104: Extract features from the third dynamic response signal corresponding to the ordinary sample to be tested to obtain the original dynamic response features of the ordinary sample to be tested; S105: Calculate the first relative feature of the original dynamic response feature relative to the detection state reference, and the second relative feature of the original dynamic response feature relative to the category direction reference, and combine the original dynamic response feature, the first relative feature and the second relative feature into a quality control auxiliary feature; S106: Perform stable feature screening on the quality control auxiliary features, and establish an identification model based on the screened stable features; The test data is not used in the stable feature selection and the parameter determination of the recognition model. S107: Input the quality control auxiliary features of the ordinary sample to be tested into the recognition model, and output the detection result of the ordinary sample to be tested; the detection result includes the category recognition result and confidence level of the ordinary sample to be tested.

[0024] In step S101, it is necessary to acquire multi-channel dynamic response signals generated based on the quality control set, the standard sample set, and the ordinary sample to be tested. The quality control set includes at least two distinct quality control samples formulated according to the volatile components and proportions corresponding to the target sample; the standard sample set includes at least two categories of standard samples with odor characteristics that can be repeatedly used. The quality control set, the standard sample set, and the ordinary sample to be tested can be collected on the same test day, in the same test batch, or in a test procedure that meets preset consistency conditions, so that the response signals of the detection status reference, the category direction reference, and the ordinary sample to be tested are under comparable detection conditions.

[0025] Different quality control samples have pre-defined differences in at least one of the following: component ratio, concentration, proportion, source, processing state, or formulation. These pre-defined differences are used to form a repeatable and comparable series of test status references. The standard sample set includes samples with typical odor characteristics that can be repeatedly taken, used to provide category orientation references; the ordinary samples to be tested are real samples to be identified that have specific odor characteristics and exhibit individual differences. Individual differences include at least one of the following: year, batch, source, processing state, storage state, or differences in natural volatile components.

[0026] In step S102, the first dynamic response signal of each quality control product in the quality control product set is extracted to obtain the response center of each quality control product in the multi-channel response feature space and the response relationship between each quality control product. Based on the response center and the response relationship, a detection state reference representing the current detection state is constructed.

[0027] Specifically, the response center, response distance between quality control samples, and projection of each quality control sample along the reference axis are calculated in the multi-channel response feature space of the first dynamic response signal of each quality control sample in the quality control sample set. The repeatability index of the same quality control sample under repeated testing and the drift index of each quality control sample relative to the reference test day are calculated. A detection status reference is constructed based on the response center, response distance, projection, repeatability index, and drift index. Further, the detection status reference can be judged, and an abnormal detection status marker is generated when the repeatability index or drift index exceeds a set threshold. The aforementioned set threshold can be determined by those skilled in the art based on the statistical distribution of historical testing data. For example, the threshold for the repeatability index can be set to twice the standard deviation of the historical repeatability index mean, or the threshold for the drift index can be set to three times the standard deviation of the drift index mean on the reference day.

[0028] When constructing the detection status reference, the mapping parameters determined based on the corresponding quality control response data of the reference test day can also be obtained; the response characteristics of each quality control product on the current test day in the multi-channel response characteristic space are linearly mapped according to the mapping parameters to obtain the mapped quality control response characteristics; the response center, response distance and projection are calculated based on the mapped quality control response characteristics, and the drift index is calculated according to the offset between the mapped quality control response characteristics and the quality control response data of the reference test day.

[0029] In step S103, features are extracted from the second dynamic response signals of standard samples of each category in the standard sample set to obtain the category center of each category of standard samples in the multi-channel response feature space, and a category direction reference representing the category direction is constructed based on the category center.

[0030] Specifically, features are extracted from the second dynamic response signals of standard samples of each category in the standard sample set, and the extracted features are aggregated in the multi-channel response feature space to obtain the category center; the inter-category distance between the category centers of different categories and the intra-category fluctuation of the standard samples of the same category relative to their respective category centers are calculated; and a category orientation reference is constructed based on the category centers, inter-category distances and intra-category fluctuations of each category.

[0031] In step S104, feature extraction is performed on the third dynamic response signal corresponding to the ordinary sample to be tested to obtain the original dynamic response features of the ordinary sample to be tested. The original dynamic response features may include at least one of the following: response peak value, response area, tail mean, tail residual relative intensity, recovery terminal relative intensity, ratio of recovery segment area to response segment area, recovery time constant, recovery half-amplitude time, recovery segment slope, recovery curve fitting error, cross-cycle trend, cross-cycle difference, cumulative response amount, channel ratio, or globally normalized channel features.

[0032] In step S105, the first relative feature of the original dynamic response feature relative to the detection state reference and the second relative feature of the original dynamic response feature relative to the category direction reference are calculated, and the original dynamic response feature, the first relative feature and the second relative feature are combined into a quality control auxiliary feature.

[0033] The first relative feature may include the ratio of the ordinary sample to be tested relative to the anchor point of the quality control sample on the same day. Specifically, the ratio of the original dynamic response feature of the ordinary sample to be tested to the corresponding channel response value of each quality control sample on the same day in the multi-channel response feature space can be calculated as the first relative feature relative to the detection status reference.

[0034] The second relative feature can be calculated as follows: calculate the distance from the original dynamic response feature to the category center of each category to obtain the category distance for each category; calculate the cosine similarity between the original dynamic response feature and the category center; calculate the difference and ratio between the distances of the ordinary sample to be tested to the category centers of different categories, as well as the projection of the original dynamic response feature onto the direction of the line connecting each category center; combine the category distance, cosine similarity, difference, ratio, and projection to obtain the second relative feature. The combination process described in this application does not require additional data processing; it only requires summarizing the corresponding features.

[0035] In step S106, stable features are screened for quality control auxiliary features, and an identification model is established based on the screened stable features.

[0036] Stable feature selection can be performed within each cross-validation fold or leave-one-test-day validation fold. It's important to note that feature stability scores are calculated only based on data from the training dates; test fold data is not involved in feature selection, threshold determination, or model parameter determination. For each feature dimension in the candidate feature pool, a stability score can be constructed using inter-class difference as the numerator and intra-class fluctuation and cross-date drift as the denominator. Inter-class difference characterizes the feature's discriminative ability across different classes; intra-class fluctuation characterizes instability caused by individual differences within the same class; cross-date drift characterizes the mean change of the feature across different test days. Features with the highest stability scores are selected for the recognition model. This selection method does not simply choose the feature with the largest class difference, but penalizes both intra-class fluctuation and cross-date drift on top of class difference, ensuring that the features entering the model are stable and discriminative, which is beneficial for improving generalization ability during cross-date detection. Based on the selected stable features, a recognition model can be built. The recognition model can be trained using a classifier to classify ordinary samples into preset categories.

[0037] In one feasible implementation, the classifier includes at least one of the following: ridge classifier, linear support vector machine, radial basis kernel support vector machine, logistic regression classifier, linear discriminant analysis classifier, partial least squares discriminant analysis classifier, random forest classifier, gradient boosting tree classifier, K-nearest neighbor classifier, or neural network classifier.

[0038] The preset categories include the typical category JX for soy sauce aroma and the typical category CT for mellow and sweet aroma. Based on the category determination results given by production experts for ordinary baijiu samples, each ordinary training sample is pre-labeled as JX or CT. The stable features obtained from the screening are used as input to the classifier, and the JX or CT category labels corresponding to the ordinary training samples are used as supervision signals to train the classifier, resulting in a binary classification recognition model used to classify the ordinary baijiu sample to be identified as JX or CT.

[0039] The training parameters of a classifier can be configured according to the classifier type. For example, the training parameters for a Ridge classifier include regularization coefficients; those for a Support Vector Machine include penalty coefficients, kernel type, and kernel parameters; those for a Logistic Regression classifier include regularization type and regularization coefficients; those for a Random Forest classifier include the number of decision trees, maximum tree depth, and minimum number of leaf node samples; those for a Gradient Boosting Tree classifier include the number of base learners, learning rate, and maximum tree depth; those for a K-Nearest Neighbors classifier include the number of neighbors and distance metric; and those for a Neural Network classifier include the number of network layers, number of hidden nodes, learning rate, batch size, and number of training epochs.

[0040] Training parameters can be determined through cross-validation within the training data. Cross-validation groups samples according to their detection date, ensuring that samples from the same detection date are in the same data group, and training parameters are selected based on classification accuracy or balanced accuracy.

[0041] In one exemplary implementation, if a JX / CT binary classification recognition model is built using a Ridge classifier, the regularization coefficient can be set to candidate values ​​of 0.1, 1, 3, and 10. The regularization coefficient is determined by cross-validation of the training data grouped by detection date, with the highest balance accuracy as the selection criterion. After determining the model parameters, the classifier is retrained using all the training data to obtain the final recognition model.

[0042] In step S107, the quality control auxiliary features of the ordinary sample to be tested are input into the recognition model, and the detection results of the ordinary sample to be tested are output. The detection results include the category recognition result and confidence level of the ordinary sample to be tested.

[0043] The identification results can include the category label of a common sample. The confidence level reflects the reliability of the identification results. Risk warnings can include low-confidence markers, retesting recommendations, or maintenance suggestions. When the detection status does not meet preset conditions, the identification confidence level is below a preset threshold, or the sample falls into a boundary area, corresponding risk warning information can be added. The detection results output in this step are a risk warning mechanism geared towards the actual detection process and do not change the true category definition of common samples.

[0044] This embodiment unifies the acquisition and processing of multi-channel dynamic response signals from the quality control set, standard sample set, and ordinary sample to be tested within the same detection process. The quality control set is used to construct a detection state reference, the standard sample set to construct a category orientation reference, and the relationship between the ordinary sample to be tested and these two references is used to construct quality control auxiliary features. This allows the recognition model to utilize both the sample's own discriminative information and the background information of the detection state during training. Stable feature screening further eliminates the adverse effects of intra-class fluctuations and cross-date drift on recognition performance, thereby improving the recognition stability and practical usability of highly similar ordinary samples in cross-date detection.

[0045] Based on the above embodiments, in one feasible implementation, the quality control set may include at least two mutually distinguishable quality control samples. Each quality control sample may be a manually prepared quality control sample based on the main volatile components, concentration range, or component ratio of the target sample. Different quality control samples may have preset differences in at least one of the following: component ratio, concentration, ratio, source, processing state, or preparation composition. For example, for the detection scenario of wine samples, QC0, QC1, and QC2 series quality control samples can be prepared based on the ethanol content, ester ratio, and acid ratio of the target wine sample. Among them, QC0 may correspond to the middle level of the main component ratio, QC1 may correspond to the ratio configuration on the high concentration side, and QC2 may correspond to the low concentration or ratio offset configuration. The above-mentioned preset differences are used to enable each quality control sample to form a mutually distinguishable response mode in the multi-channel response feature space. Since the response difference between different quality control samples is determined by the known component differences, the law of change of this difference with the detection conditions can reflect the actual detection state of the sensor. On the same test day or in the same test batch, the serialized response patterns of the quality control sample set can form a repeatable and comparable test status reference.

[0046] Based on the above embodiments, in one feasible implementation, the detection state reference may include the response center of each quality control sample in the multi-channel response feature space. The response center may be described using the mean, median, or a positional metric obtained after robust estimation. The detection state reference may also include the response distance between quality control samples, which can be calculated as the Euclidean or Mahalanobis distance between the response centers of any two quality control samples. The Euclidean or Mahalanobis distance can reflect the resolution capability of the sensor array for different component compositions under the current detection conditions.

[0047] The detection status reference may also include the projection values ​​of each quality control sample along a reference axis, which can be determined by the principal component direction, discrimination direction, or the direction of the line connecting any two quality control samples. The detection status reference may also include the standardized offset of each quality control sample relative to a reference test day. This offset can be obtained by subtracting the response characteristics of the corresponding quality control sample on the reference test day from the response characteristics of the quality control sample on the current test day, and then dividing by the within-class standard deviation or range of the reference test day. The detection status reference may also include repeatability indicators for repeated testing of the same quality control sample, which can be evaluated using the standard deviation, range, or coefficient of variation of multiple repeated tests within the same day. The detection status reference may also include drift indicators, which can be quantified by the positional offset or directional offset angle of the response center of the quality control sample in consecutive test days. The detection status reference may also include the quality control classification results, i.e., the degree of consistency between the classification labels obtained after clustering or classifying the responses of each quality control sample and the expected labels. The above reference quantities can be used individually or in combination using weighted fusion or threshold judgment methods to form a comprehensive description of the detection status for the day.

[0048] Based on the above embodiments, in one feasible implementation, the standard sample set may include samples with typical odor characteristics and reusable properties. For example, in a wine testing scenario, the standard samples may be representative wine samples from typical batches, or simulated wine samples with stable formulations prepared under controlled conditions. The reusability of the standard samples can be ensured by preparing a sufficient quantity of standard samples and storing them under consistent conditions before testing, and using the same sample quantity and the same headspace balance parameters for each test. The ordinary sample to be tested is a real sample to be identified that has specific odor characteristics and exhibits individual differences. These individual differences may include at least one of the following: differences in year, batch, origin, processing state, storage state, or natural volatile components. The core functional difference between standard samples and ordinary samples is that standard samples primarily provide a stable category orientation reference, and their position in the feature space mainly reflects the typical odor direction of the category; ordinary samples primarily retain the individual differences in real-world application scenarios to verify the generalization ability and recognition effect of the method in actual situations.

[0049] Based on the above embodiments, in one feasible implementation, the quality control sample set, the standard sample set, and the ordinary sample to be tested can be collected on the same test day, in the same test batch, or in a test process that meets preset consistency conditions. Preset consistency conditions may include at least one of the following: sensor baseline drift does not exceed a preset baseline deviation threshold; ambient temperature and humidity are within a preset acceptable range; the coefficient of variation of intra-day repeatability testing of the quality control sample is lower than a preset threshold; or the sample injection sequence is strictly executed according to a predetermined sequence. By collecting three types of samples in the same test process, it can be ensured that the response signals of the detection status reference, category orientation reference, and the ordinary sample to be tested are under comparable detection conditions, thereby enabling the quality control auxiliary features to truly reflect the relative relationship between the ordinary sample to be tested and the detection status and category orientation of the day.

[0050] Based on the above embodiments, in one feasible implementation, the original dynamic response characteristics can be selected from at least one of the following types of characteristics, or any combination of several: The peak response can be extracted when the sensor response reaches its maximum amplitude after sample gas injection. It can be obtained by using the baseline-normalized relative amplitude value or the original resistance change amplitude value.

[0051] The response area can be obtained by integrating the baseline normalized response curve over a predetermined time window in the sample gas section, and is used to characterize the overall response of the sensor in the sample gas stage.

[0052] The tail-end mean can be calculated as the average value of the sensor response within a predetermined end-of-recovery time window (e.g., the last 30 seconds of the recovery period) and is used to describe the residual response level at the end of the recovery period.

[0053] The relative intensity of tail segment residuals can be expressed as the ratio of the tail segment mean to the peak response. The closer this ratio is to 0, the more complete the recovery; the closer it is to 1, the more severe the residuals.

[0054] The relative strength at the end of recovery can be expressed as the relative deviation between the response value at the end of recovery and the baseline response value, and is used to evaluate whether the response has recovered to the baseline level.

[0055] The ratio of the recovery segment area to the response segment area can be used to describe the duration of the recovery process relative to the response process.

[0056] The recovery time constant can be extracted from the fitting parameters by fitting an exponential decay function to the response curve of the recovery segment, and used to quantitatively describe the recovery rate.

[0057] The recovery half-amplitude time can be calculated as the time interval between the peak moment and the moment when the response decays to half of the peak moment.

[0058] The recovery slope can be obtained by linearly fitting the response value within a time window in the early stage of the recovery phase (e.g., the first 5 to 15 seconds after the start of recovery), and the fitted slope can be extracted as an indicator of the early recovery rate. The recovery curve fitting error can be calculated by taking the root mean square value of the fitting residuals of the selected decay model (such as a single exponential decay model or a double exponential decay model) to the actual recovery curve, and is used to evaluate the applicability of the model.

[0059] Cross-cycle trend describes the pattern of change of the same feature value with cycle number across multiple injection cycles (e.g., two or three consecutive injections), and can be characterized by the slope of a linear trend or the direction of monotonicity. Cross-cycle difference calculates the difference of the same feature between adjacent cycles, used to describe the magnitude of feature change between consecutive injections.

[0060] The cumulative response can be calculated as the sum of the peak response or response area over multiple cycles, and is used to characterize the total contribution of the sample throughout the entire test cycle.

[0061] The channel ratio can be calculated as the ratio of the peak response or the response area of ​​any two sensor channels, and is used to describe the selectivity differences of different sensitive materials to different components.

[0062] Globally normalized channel features can divide the response values ​​of all channels by the sum, maximum, or root mean square of all channel response values, making the feature vector scale invariant. This helps to eliminate the influence of differences in injection volume or overall changes in sensor sensitivity.

[0063] Based on the above embodiments, the quality control auxiliary features can be selected from at least one of the following types of features: The proportionality feature calculates the ratio of the response value of a test sample in a specified channel to the response value of a quality control sample in the corresponding channel on the same day. This ratio can eliminate variations in the overall response amplitude caused by the testing conditions of the day. The distance feature calculates various distance measures from the original dynamic response feature vector or quality control auxiliary feature vector of the test sample to the standard sample category center, including but not limited to Euclidean distance, Mahalanobis distance, or Manhattan distance. The cosine similarity feature calculates the cosine of the angle between the feature vector of the test sample and the feature vector of the standard sample category center. This value measures the directional consistency between the two in multidimensional space. The distance difference feature calculates the difference in distance from the test sample to the standard sample centers of different categories. Positive and negative values ​​reflect the bias direction of the test sample relative to the two category centers. The distance ratio feature calculates the ratio of the distance of the test sample to the first category standard sample center to the distance to the second category standard sample center. A ratio closer to 1 indicates that the sample is located in the boundary region between the two categories. Projection features can project the feature vector of a common sample to be tested onto the line connecting the centers of two standard samples of different categories or onto the discriminant analysis direction. The relative position of the projection points can serve as an auxiliary basis for category discrimination. The aforementioned quality control auxiliary features can be added to the candidate feature pool as supplementary information to the original dynamic response features, enabling the recognition model to learn discrimination patterns simultaneously from the sample's own information and the relative relationship between the sample and the reference.

[0064] Based on the above embodiments, stable feature selection can be performed within each cross-validation fold or leave-one-test-day validation fold. For each feature dimension in the candidate feature pool, its inter-class variance, intra-class volatility, and cross-date drift can be calculated based on the data from the training date, and a stable feature score can be calculated according to predetermined rules. Inter-class variance can be represented as the sum of squares or the maximum difference between the means of each class. Intra-class volatility can be represented as the variance or standard deviation of the feature values ​​of each sample within the same class, which reflects the instability caused by individual sample differences. Cross-date drift can be represented as the variance or standard deviation of the mean of the same class feature between different test days, which reflects the response shift caused by changes in detection conditions. The stability score can be defined as the inter-class variance divided by the sum of intra-class volatility, cross-date drift, and a minimum constant, where the minimum constant is used to prevent zero. Features with higher scores have both greater inter-class discriminative power and smaller intra-class volatility and date drift. According to the stability scores from high to low, a predetermined number of top-ranked features can be selected as a stable feature subset. Feature selection, threshold determination, and model training are all completed within the training fold; test fold data is not involved in the determination of any of these parameters. This internal filtering mechanism helps avoid data leakage and enables more accurate estimation of the model's generalization performance on unseen data.

[0065] Based on the above embodiments, in one feasible implementation, after obtaining the category identification result, intra-category sub-prototype representation can be performed on low-confidence samples or boundary samples.

[0066] Ordinary samples may exhibit multiple response subtypes within the same category. These subtypes can be caused by differences in year, batch, source, or processing status. Intra-category sub-prototype representation can establish multiple local sub-prototypes within each candidate category, each representing a feature response subtype within that category. Sub-prototype establishment can be achieved by using a stable, filtered low-dimensional representation as input, and dividing the training samples into K sub-prototype groups within each category according to a predetermined algorithm. This ensures high feature similarity among samples within the same sub-prototype group, while feature differences between different sub-prototype groups describe different response patterns within the category. Here, K is a predetermined number that can be set by those skilled in the art. After establishing the sub-prototypes, the distance from the ordinary sample to be tested to each sub-prototype can be calculated, and the association between the ordinary sample and the nearest sub-prototype can be determined based on the minimum distance. The distance difference or ratio between the ordinary sample to be tested and the nearest sub-prototype within the candidate category and to the nearest sub-prototype within other categories can be calculated to generate supplementary discriminative information. The maximum cosine similarity between the tested ordinary sample and each sub-prototype can be calculated to reflect the degree of directional matching between the tested ordinary sample and each sub-prototype. Through intra-category sub-prototype representation, the model can describe the local response differences within the same category caused by year, batch, source, or processing status without changing the true category label, which is beneficial to improving the recognition effect of ordinary samples with subtype differences.

[0067] Based on the above embodiments, in one feasible implementation, after obtaining the category identification result, high-confidence consistency arbitration can also be performed on low-confidence samples or boundary samples.

[0068] High-confidence consensus arbitration can make a comprehensive judgment based on the output results of multiple candidate models. The candidate model set can include classifiers of different algorithm types, or model instances of the same algorithm type but using different feature subsets and hyperparameter configurations. For each candidate model, its predicted probability value for each category of the sample can be calculated. The model confidence interval for the predicted probabilities of each candidate model can be calculated, which reflects the degree of consistency in predictions for the same category by different models. Candidate consensus labels can be determined based on the predicted labels output by each candidate model; the consensus label can be the label with the highest frequency of occurrence or the result of weighted voting based on model weights. A consensus score can be calculated, which reflects the degree of support each candidate model provides for the consensus label. A consensus confidence score can be calculated, which combines the predicted probabilities of each candidate model for the consensus label and the model weights. When the risk label, consensus score, and consensus confidence score of the base model all meet preset threshold conditions, the consensus output of the candidate model can be used as the final identification result. The specific values ​​of the above threshold conditions can be set by those skilled in the art based on model validation results and practical application requirements. For example, the consensus score threshold can be set between 0.6 and 0.8, and the consensus confidence threshold can be set between 0.7 and 0.9. When these conditions are not met, the output of the base model can be retained or the process can be transferred to a re-examination procedure. Through high-confidence consensus arbitration, the identification reliability of low-confidence samples or boundary samples can be improved based on the consensus of multiple models.

[0069] Based on the above embodiments, in one feasible implementation, gray area re-inspection output can be set for boundary samples.

[0070] The gray zone re-examination output is used to identify boundary samples most prone to misclassification and transfer them to manual review or supplementary detection processes. Gray zone determination can be based on a combination of the following parameters: The relative distance difference between the tested ordinary sample and the nearest sub-prototype of different candidate categories can be calculated; this distance difference reflects the relative position of the tested ordinary sample near the boundary between two categories. Historical model confidence information for this sample or similar samples can be obtained to assess the reliability of the current identification result. A training date quantile threshold can be calculated; this threshold can be determined by the quantiles of the distance distribution from each sample in the training set to its own category center; the specific quantile level can be set by those skilled in the art according to accuracy requirements. When the relative distance difference between the tested ordinary sample and the nearest sub-prototype of different candidate categories is less than a preset distance difference threshold, and the historical model confidence is lower than a preset confidence threshold, and the distance between the tested ordinary sample and its nearest sub-prototype exceeds the upper bound of the training date quantile, the sample can be determined to fall into the gray zone. The gray zone re-examination output can be used to prompt re-examination, supplementary detection, or manual review. Samples marked as gray areas are not used as the final identification output, but they can provide auxiliary identification information and a basis for triggering retesting. The gray area retesting mechanism can maintain the accuracy of high-confidence output samples at a high level, while providing clear retesting trigger conditions for boundary samples. The specific threshold for determining the gray area can be adjusted by those skilled in the art based on their tolerance for false positive and false negative rates.

[0071] Building upon the above embodiments, this embodiment further adds detection status marking and risk warning functions. Based on the relative position, relative response structure, repeatability index, drift index, or quality control classification results of the quality control sample set, the current detection status can be marked.

[0072] In one feasible implementation, the relative position of the quality control sample set can be characterized by the positional offset of the response center of each quality control sample between the current test day and the reference test day. When this offset exceeds a preset first threshold, it can be determined that the detection state has changed significantly. The relative response structure of the quality control sample set can be characterized by the proportional relationship or distance relationship between the responses of each quality control sample. When the change in this response structure exceeds a preset second threshold, it can be determined that the internal structure of the detection state has changed. Repeatability indicators can be quantified by the coefficient of variation or range of repeated tests of the same quality control sample within the day. When the repeatability indicator is higher than a preset third threshold, it can be determined that the repeatability under the current detection conditions does not meet the requirements. Drift indicators can be quantified by the change in the trajectory length or direction of the response center of the quality control sample in the feature space during consecutive test days. When the drift indicator is higher than a preset fourth threshold, it can be determined that there is a non-negligible drift in the sensor array. The quality control classification results can be evaluated by the consistency between the labels obtained after clustering or classifying the quality control sample responses and the expected labels. When the consistency is lower than a preset fifth threshold, it can be determined that the distinguishability between quality control samples is insufficient or the classification results are unreliable. The above thresholds can be set by those skilled in the art based on historical data analysis and actual application needs.

[0073] When the detection status does not meet preset conditions, a low-confidence marker can be added to the identification results of subsequent ordinary samples to be tested, or a prompt can be made to perform at least one of the following operations: retest, instrument maintenance, reacquiring the response signal of the quality control sample, or re-establishing the detection status reference. For example, when the repeatability index exceeds the threshold, a prompt can be made to check the airtightness of the sample introduction system and the working status of the sensor. When the drift index exceeds the threshold, a prompt can be made to clean or age the sensor. When the quality control classification results are abnormal, a prompt can be made to re-prepare the quality control sample or calibrate the instrument. The above risk warning mechanism can provide a practical and operable auxiliary decision-making basis for the reliability of the detection process without affecting the true category definition of ordinary samples.

[0074] In practice, the number of quality control samples, standard samples, sensors, test cycles, feature types, thresholds, model types, and output formats can all be adjusted according to the target samples, electronic nose device configuration, and actual testing procedures.

[0075] For implementations involving threshold setting, the threshold can be determined by a person skilled in the art in at least one of the following ways: determined based on the statistical distribution of historical detection data, for example, setting the threshold as the mean of historical data plus or minus a certain number of standard deviations; determined based on performance optimization on a validation set, for example, trying different thresholds on a validation set and selecting the threshold that optimizes the performance indicators; determined based on empirical values, for example, based on the instrument manufacturer's recommended values ​​or industry standards.

[0076] For implementation methods involving parameter settings, the parameters can be adjusted by those skilled in the art according to the actual application scenario and performance requirements.

[0077] The method described in this application can be applied to cross-date detection of highly similar ordinary samples such as complex wine samples, and can also be extended to other scenarios that require electronic nose detection, including but not limited to food quality testing, environmental monitoring, medical diagnosis, chemical process control and other fields.

[0078] The above methods can be executed by electronic nose devices, host computers, servers, or cloud computing platforms.

[0079] In a non-limiting experimental example, the effectiveness of the above-described quality control testing method for an electronic nose system is verified. In this example, QC0, QC1, and QC2 serve as the QC control layers, CT and JX standard samples from the standard sample set serve as the ST standard layer, and CT and JX ordinary samples from the ordinary sample set serve as the ordinary sample layer.

[0080] The experiment was validated at three levels. The first level was the QC (Quality Control) layer, used to evaluate the separability and calibration capability of the quality control samples. The second level was the ST (Standardized Sample) standard layer, used to verify the separability of typical odor samples and provide a stability assessment for category orientation reference. The third level was the ordinary sample layer, used to examine the cross-date generalization ability under real batch and individual differences.

[0081] In the experimental verification of the QC quality control layer, after reference date mapping, the accuracy of the one-day-left-behind test for QC1 and QC2 improved from approximately 0.66 to approximately 0.96, the average value of the inter-day drift index decreased from approximately 2.09 to approximately 1.05, and the proportion of severe drift decreased from approximately 42% to approximately 5%. These results indicate that QC samples can serve as internal anchors for the instrument, headspace, gas path, and environmental conditions of the day, and reference date mapping can largely eliminate the impact of inter-day drift on the QC quality control layer.

[0082] In experimental validation of the ST standard layer, both the original feature strategy and the QC relative reference strategy can achieve a leave-one-out-of-test-day accuracy of approximately 0.91. This result indicates that the state reference feature appending method can preserve the effective class differences of the standard samples and does not reduce the discriminability of the standard samples by introducing reference information.

[0083] In the identification experiment of ordinary high-similarity samples, a progressive comparison scheme was set up. With quality control samples and standard samples completely removed, the accuracy on the one-day test was approximately 0.52. Introducing quality control samples and standard samples improved the accuracy to approximately 0.71. Further adding in-category sub-prototype representation improved the accuracy to approximately 0.73. Adding high-confidence consistency arbitration further improved the accuracy to approximately 0.80, with an average daily accuracy of approximately 0.81. Based on this, further implementing gray-zone re-examination achieved a high-confidence output accuracy of approximately 0.85.

[0084] The aforementioned progressive experimental results demonstrate the synergistic effect among the various technical features of this application. The introduction of quality control auxiliary features provides a detection status reference for cross-date recognition; intra-category sub-prototype representation solves the description problem of different subtypes within the same category; high-confidence consistency arbitration improves the discrimination reliability of low-confidence samples based on the consensus of multiple models; the gray zone re-examination mechanism separates the effective processing of boundary samples from the recognition process, improving the output accuracy of retained samples. In summary, this application can significantly improve the cross-date stability of electronic noses in the detection of highly similar common samples and can serve the reliability evaluation and re-examination decision of real common sample recognition.

[0085] See Figure 2 , Figure 2 This is a schematic diagram of a quality control and testing system for an electronic nose system provided in an embodiment of this application. The quality control and testing system for an electronic nose system provided in this application includes the following modules: The signal acquisition module is used to acquire multi-channel dynamic response signals generated based on the quality control sample set, standard sample set, and ordinary sample to be tested. This module connects to the data acquisition interface of the electronic nose device and receives the raw response data output by the sensor array.

[0086] The detection status reference module is used to extract features from the first dynamic response signal of each quality control product in the quality control product set, obtain the response center of each quality control product in the multi-channel response feature space and the response relationship between each quality control product, and construct a detection status reference that represents the current detection status based on the response center and response relationship.

[0087] The category orientation reference module is used to extract features from the second dynamic response signals of standard samples of each category in the standard sample set, obtain the category center of each category standard sample in the multi-channel response feature space, and construct a category orientation reference representing the category orientation based on the category center.

[0088] The feature extraction module is used to extract features from the third dynamic response signal corresponding to the ordinary sample under test, so as to obtain the original dynamic response features of the ordinary sample under test.

[0089] The auxiliary feature generation module is used to calculate the first relative feature of the original dynamic response feature relative to the detection state reference, and the second relative feature of the original dynamic response feature relative to the category orientation reference, and to combine the original dynamic response feature, the first relative feature and the second relative feature into a quality control auxiliary feature.

[0090] The feature selection module is used to select stable features from quality control auxiliary features and to build a recognition model based on the selected stable features. Test data is not used in the selection of stable features or the determination of the recognition model parameters.

[0091] The detection module is used to input the quality control auxiliary features of the ordinary sample to be tested into the recognition model and output the detection results of the ordinary sample to be tested. The detection results include the category recognition result and confidence level of the ordinary sample to be tested.

[0092] Based on the above embodiments, as a preferred embodiment, the system may further include an in-category sub-prototype module, which is used to establish several local sub-prototypes in each candidate category of the recognition model when the confidence level is lower than a set value, and calculate the relative distance difference between the ordinary sample to be tested and the nearest local sub-prototype of each candidate category.

[0093] Based on the above embodiments, as a preferred embodiment, the system may further include a high-confidence consistency arbitration module, which is used to calculate the consistency score and consensus confidence of the prediction direction of the ordinary sample to be tested based on multiple candidate models. When the consistency score and consensus confidence meet the preset conditions, the consensus output of multiple candidate models is used to update the category recognition result.

[0094] Based on the above embodiments, as a preferred embodiment, the system may further include a gray area re-inspection module, which generates re-inspection prompt information for the ordinary sample to be tested when the relative distance difference is within a set range, and outputs the re-inspection prompt information in the test result.

[0095] Based on the above embodiments, as a preferred embodiment, the system may further include a result output and risk warning module, used to output identification results, confidence level, low confidence markers, re-inspection suggestions, or maintenance suggestions.

[0096] The modules described above can be implemented using software, hardware, or a combination of both. The modules can communicate and transfer data with each other via data interfaces.

[0097] This application also provides an embodiment of a computer-readable storage medium and a computer program product. Both the computer-readable storage medium and the computer program product may store a computer program that, when executed by a processor, implements the steps of the method described in the above method embodiments.

[0098] It is understood that if the methods in the above embodiments are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and executes all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0099] The computer-readable storage medium provided in this embodiment includes computer programs that implement the corresponding embodiments of the above methods, and the effects are the same as above.

[0100] This application also provides an electronic device, see [link to document]. Figure 3 The present application provides a structural diagram of an electronic device, as shown in the embodiment. Figure 3 As shown, it may include a processor 1410 and a memory 1420.

[0101] The processor 1410 may include one or more processing cores, such as a quad-core processor or an octa-core processor. The processor 1410 may be implemented using at least one hardware form selected from DSP (Digital Signal Processing), FPGA (Field-Programmable Gate Array), and PLA (Programmable Logic Array). The processor 1410 may also include a main processor and a coprocessor. The main processor, also known as a CPU (Central Processing Unit), is used to process data in the wake-up state; the coprocessor is a low-power processor used to process data in the standby state. In some embodiments, the processor 1410 may integrate a GPU (Graphics Processing Unit), which is responsible for rendering and drawing the content to be displayed on the screen. In some embodiments, the processor 1410 may also include an AI (Artificial Intelligence) processor, which is used to handle computational operations related to machine learning.

[0102] The memory 1420 may include one or more computer-readable storage media, which may be non-transitory. The memory 1420 may also include high-speed random access memory and non-volatile memory, such as one or more disk storage devices or flash memory devices. In this embodiment, the memory 1420 is used to store at least the following computer program 1421, which, after being loaded and executed by the processor 1410, is capable of implementing the relevant steps in the methods executed by the electronic device side as disclosed in any of the foregoing embodiments. In addition, the resources stored in the memory 1420 may also include an operating system 1422 and data 1423, etc., and the storage method may be temporary storage or permanent storage. The operating system 1422 may include Windows, Linux, Android, etc.

[0103] In some embodiments, the electronic device may further include a display screen 1430, an input / output interface 1440, a communication interface 1450, a sensor 1460, a power supply 1470, and a communication bus 1480.

[0104] certainly, Figure 3 The structure of the electronic device shown does not constitute a limitation on the electronic device in the embodiments of this application. In practical applications, the electronic device may include more than [other components]. Figure 3 More or fewer components as shown, or combinations of certain components.

[0105] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on its differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. As the system provided in the embodiments corresponds to the method provided in the embodiments, the description is relatively simple; relevant parts can be found in the method section.

[0106] This document uses specific examples to illustrate the principles and implementation methods of this application. The descriptions of the above embodiments are only for the purpose of helping to understand the methods and core ideas of this application. It should be noted that those skilled in the art can make several improvements and modifications to this application without departing from the principles of this application, and these improvements and modifications also fall within the protection scope of this application.

[0107] It should also be noted that, in this specification, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

Claims

1. A quality control testing method for an electronic nose system, characterized in that, include: Acquire multi-channel dynamic response signals based on a set of quality control samples, a set of standard samples, and a common sample to be tested; wherein, the set of quality control samples includes at least two mutually distinct quality control samples prepared according to the volatile components and component ratios corresponding to the target sample; the set of standard samples includes at least two categories of standard samples with odor characteristics and reusable. Feature extraction is performed on the first dynamic response signal of each quality control product in the quality control product set to obtain the response center of each quality control product in the multi-channel response feature space and the response relationship between each quality control product. Based on the response center and the response relationship, a detection state reference characterizing the current detection state is constructed. Feature extraction is performed on the second dynamic response signal of each category of standard sample in the standard sample set to obtain the category center of each category of standard sample in the multi-channel response feature space, and a category direction reference representing the category direction is constructed based on the category center; Feature extraction is performed on the third dynamic response signal corresponding to the ordinary sample to be tested to obtain the original dynamic response features of the ordinary sample to be tested; Calculate the first relative feature of the original dynamic response feature relative to the detection state reference, and the second relative feature of the original dynamic response feature relative to the category orientation reference, and combine the original dynamic response feature, the first relative feature and the second relative feature into a quality control auxiliary feature; The quality control auxiliary features are screened for stable features, and an identification model is established based on the screened stable features; wherein, test data is not involved in the screening of stable features and the determination of the parameters of the identification model; The quality control auxiliary features of the ordinary sample to be tested are input into the recognition model, and the detection result of the ordinary sample to be tested is output; the detection result includes the category recognition result and confidence level of the ordinary sample to be tested.

2. The quality control testing method for an electronic nose system according to claim 1, characterized in that, Feature extraction is performed on the first dynamic response signal of each quality control item in the quality control item set to obtain the response center of each quality control item in the multi-channel response feature space and the response relationship between each quality control item. Based on the response center and the response relationship, a detection state reference characterizing the current detection state is constructed, including: Calculate the response center of the first dynamic response signal of each quality control item in the set of quality control items, the response distance between quality control items, and the projection of each quality control item along the reference axis in the multi-channel response feature space; Calculate the repeatability index of the same quality control product under repeated testing, and the drift index of each quality control product relative to the reference test date; The detection state reference is constructed based on the response center, the response distance, the projection, the repeatability index, and the drift index; The detection status reference is determined, and when the repeatability index or the drift index exceeds a set threshold, an abnormal detection status marker is generated.

3. The quality control testing method for an electronic nose system according to claim 1, characterized in that, Feature extraction is performed on the second dynamic response signals of standard samples of each category in the standard sample set to obtain the category center of each category of standard samples in the multi-channel response feature space, and a category orientation reference representing the category orientation is constructed based on the category center, including: Feature extraction is performed on the second dynamic response signal of each category of standard sample in the standard sample set, and the extracted features are aggregated in the multi-channel response feature space to obtain the category center; Calculate the inter-class distance between class centers of different categories, and the intra-class fluctuation of standard samples of the same category relative to their class centers; The category orientation reference is constructed based on the category center of each category, the distance between categories, and the intra-category fluctuation.

4. The quality control testing method for an electronic nose system according to claim 2, characterized in that, The detection state reference is constructed based on the response center, the response distance, the projection, the repeatability index, and the drift index, including: Obtain the mapping parameters determined based on the quality control response data corresponding to the reference test date; The response characteristics of each quality control product on the current test day are linearly mapped in the multi-channel response characteristic space according to the mapping parameters to obtain the mapped quality control response characteristics. The response center, response distance, and projection are calculated based on the mapped quality control response characteristics, and the drift index is calculated based on the offset between the mapped quality control response characteristics and the quality control response data of the reference test day.

5. The quality control testing method for an electronic nose system according to claim 3, characterized in that, Calculating the second relative feature of the original dynamic response feature relative to the category orientation reference includes: Calculate the distance from the original dynamic response feature to the category center of each category to obtain the category distance for each category; Calculate the cosine similarity between the original dynamic response features and the category center; Calculate the difference and ratio between the distances of the ordinary sample to be tested to the center of each category, and the projection of the original dynamic response feature onto the direction of the line connecting the centers of each category; The second relative feature is obtained by combining the category distance, the cosine similarity, the difference, the ratio, and the projection.

6. The quality control testing method for an electronic nose system according to claim 1, characterized in that, The quality control auxiliary features are subjected to stable feature screening, including: Within each cross-validation period or leave-one-test-day validation period, the stability score of each dimension of the quality control auxiliary features is calculated based on the training data; wherein, the numerator of the stability score is the inter-class difference of the corresponding feature, and the denominator of the stability score is the sum of the intra-class fluctuation and cross-date drift of the corresponding feature; The features are sorted according to the stability score, and a set number of the top-ranked features are selected as the stable features; wherein, the test data does not participate in the calculation of the stability score, the selection of the stable features, or the determination of the parameters of the recognition model.

7. The quality control testing method for an electronic nose system according to claim 1, characterized in that, After outputting the detection results of the ordinary sample to be tested, the method also includes: When the confidence level is lower than the set value, several local sub-prototypes are established in each candidate category of the recognition model, and the relative distance difference between the ordinary sample to be tested and the nearest local sub-prototype of each candidate category is calculated. Based on the prediction direction of the ordinary sample to be tested by multiple candidate models, a consistency score and a consensus confidence level are calculated. When the consistency score and the consensus confidence level meet the preset conditions, the consensus output of the multiple candidate models is used to update the category recognition result. When the relative distance difference is within a set range, a retest prompt message is generated for the ordinary sample to be tested, and the retest prompt message is appended to the test result and output.

8. A quality control and inspection system for an electronic nose system, characterized in that, include: The signal acquisition module is used to acquire multi-channel dynamic response signals generated based on a set of quality control samples, a set of standard samples, and a common sample to be tested; wherein, the set of quality control samples includes at least two mutually distinguishable quality control samples prepared according to the volatile components and component ratios corresponding to the target sample; the set of standard samples includes at least two categories of standard samples with odor characteristics and reusable. The detection status reference module is used to extract features from the first dynamic response signal of each quality control product in the quality control product set, obtain the response center of each quality control product in the multi-channel response feature space and the response relationship between each quality control product, and construct a detection status reference that characterizes the current detection status based on the response center and the response relationship. The category orientation reference module is used to extract features from the second dynamic response signals of each category of standard samples in the standard sample set, obtain the category center of each category of standard samples in the multi-channel response feature space, and construct a category orientation reference representing the category orientation based on the category center; The feature extraction module is used to extract features from the third dynamic response signal corresponding to the ordinary sample to be tested, so as to obtain the original dynamic response features of the ordinary sample to be tested. An auxiliary feature generation module is used to calculate a first relative feature of the original dynamic response feature relative to the detection state reference, and a second relative feature of the original dynamic response feature relative to the category direction reference, and to combine the original dynamic response feature, the first relative feature and the second relative feature into a quality control auxiliary feature; The feature selection module is used to select stable features for the quality control auxiliary features and establish a recognition model based on the selected stable features; wherein, the test data does not participate in the selection of stable features and the determination of the parameters of the recognition model; The detection module is used to input the quality control auxiliary features of the ordinary sample to be tested into the recognition model and output the detection result of the ordinary sample to be tested; the detection result includes the category recognition result and confidence level of the ordinary sample to be tested.

9. An electronic device, characterized in that, include: Memory, used to store computer programs; A processor for executing the computer program to implement the steps of the method as claimed in any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed, implements the steps of the method as described in any one of claims 1 to 7.