Liquid identification method and system based on optic nerves
Through the liquid recognition method based on visual nerves, the visual nerve mixing model and semi-supervised learning optimized liquid recognition is solved, and the problem of insufficient recognition accuracy and adaptability in the prior art is achieved, and efficient and accurate liquid recognition and continuous optimization are achieved.
Patent Information
- Application Number
- CN202510266057.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-07
- Publication Date
- 2025-04-04
- Estimated Expiration
- 2045-03-07
AI Technical Summary
When faced with complex and changing liquid types and environments, existing liquid recognition technologies have low recognition accuracy and generalization capabilities, insufficient adaptability and flexibility, and lack real-time feedback and intelligent analysis functions.
The liquid recognition method based on visual nerves is adopted, and the liquid image and environmental perception images are collected for adaptive preprocessing, a hybrid model of visual nerves is constructed, and a semi-supervised learning and incremental learning are optimized, and a real-time feedback mechanism and intelligent analysis function are introduced.
Improve the accuracy and efficiency of liquid recognition, enhance the adaptability and flexibility of the model, realize real-time feedback and intelligent analysis, and can continuously adapt to new liquid types and identification needs.
Smart Images

Figure CN119762944A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of liquid identification, and specifically relates to a liquid identification method and system based on visual nerves. Background Art
[0002] Liquid identification method refers to the method of identifying and classifying unknown or specific types of liquids through specific technical means. In the field of liquid identification technology, traditional methods mainly include radar, optical, image and sensor-based technologies. Although radar-type liquid level measuring instruments have a long service life and less maintenance, they are expensive and have poor results in measuring the oil-water interface; optical liquid level measurement uses changes in light wave intensity and has the advantages of simple structure and low cost, but its long-term stability is poor, its accuracy is low, and it is easily affected by fluctuations in light source intensity; image-based liquid level measurement uses a high-resolution CCD camera to collect liquid level images and identifies water level lines through computer processing. It has high detection accuracy and a wide range of uses, but this method is difficult to capture the liquid surface in dark environments or at obstructed angles, limiting its scope of application; sensor-based technologies, such as capacitive sensors, sense water levels by affecting capacitance changes due to liquids, but require the device to be in direct contact with the liquid, and physical constraints limit its scalability.
[0003] For example, the patent application with publication number CN110646347A discloses a liquid identification system and a liquid identification method with a warning notification, including: a liquid sensing device, a database and a judgment module. The liquid sensing device is used to sense a liquid provided according to a preset liquid demand information to obtain a liquid waveform information. The database contains a preset liquid waveform information corresponding to at least one preset liquid. The judgment module receives and judges whether the liquid waveform information from the liquid sensing device and the preset liquid waveform information of the information library are different, wherein when the liquid waveform information is different from the preset liquid waveform information, a warning notification is issued. In addition, the technical solution further provides a liquid identification method with a warning notification.
[0004] For example, the Chinese patent application with the authorization announcement number CN109470720B discloses a liquid identification method, a vector extraction method, a liquid identification device and a storage medium, including: collecting microwave reflection signals of the liquid to be tested; obtaining microwave data of the liquid to be tested based on the microwave reflection signals; calculating a feature vector of the liquid to be tested based on the microwave data; inputting the feature vector into a preset classifier for identification, and obtaining an identification result. Through this liquid identification method, the liquid to be tested can be quickly identified and the accuracy rate can be improved.
[0005] The above existing technologies all have the following problems: CN110646347A relies on the matching of liquid waveform information with preset waveform information, and may have relatively low recognition accuracy and generalization ability, and poor adaptability and flexibility when facing complex and changeable liquid types and environments; CN109470720B relies on microwave reflection signals for recognition, and has limited recognition effect for certain specific types of liquids or complex environments, and is relatively weak in intelligence, lacking real-time feedback and intelligent analysis functions, resulting in the inability to make timely adjustments and optimizations when recognition errors occur. Summary of the invention
[0006] In view of the shortcomings of the prior art, the present invention proposes a liquid recognition method and system based on visual nerves, which collects liquid images and environmental perception images and performs adaptive preprocessing to generate liquid perception images; constructs a visual nerve hybrid model based on feature extraction; uses feature data and corresponding liquid labels to perform semi-supervised learning training, and uses an incremental learning method to optimize the model; inputs real-time liquid perception images into the optimized model to identify liquids, preliminarily judges the consistency of the recognition results with the preset results, and introduces a correction algorithm when they do not match; finally, performs intelligent analysis on the correction results, and introduces a real-time feedback mechanism to fine-tune the model; the present invention improves the accuracy and efficiency of liquid recognition.
[0007] To achieve the above object, the present invention provides the following technical solutions: A liquid recognition method based on visual nerves, comprising: Step S1: collecting liquid images and environment perception images, and performing adaptive preprocessing to generate liquid perception images; Step S2: extracting features from the liquid perception image, and constructing a visual neural hybrid model based on the extracted features; Step S3: using the extracted feature data and the corresponding liquid labels to perform semi-supervised learning training on the visual neural hybrid model, and using an incremental learning method to optimize the trained visual neural hybrid model to obtain an optimized visual neural hybrid model; Step S4: input the real-time liquid perception image into the optimized visual neural hybrid model for liquid recognition, output the liquid recognition result, and make a preliminary judgment on the recognition result to determine whether it is consistent with the preset result. If it is not consistent, a correction algorithm is introduced to correct the recognition result; Step S5: Perform intelligent analysis on the corrected recognition results. At the same time, introduce a real-time feedback mechanism to fine-tune the optimized visual neural hybrid model based on the intelligent analysis results and the differences between the recognition results and the preset results.
[0008] Specifically, the specific steps of step S3 include: S3.1: Obtain feature data of the liquid sensing image, collect liquid labels corresponding to the feature data, and divide them into training set and validation set; S3.2: Initialize the visual neural hybrid model and train it using labeled data and unlabeled data in a ratio of 2:8. At the same time, build a generative model to learn the generative distribution of feature data. If there is new labeled data or unlabeled data, use the generative model to evaluate the new data and generate pseudo labels. The pseudo label generation formula is: ; in, represents the generated pseudo-label, Y represents the label data set, x Represents new labeled data or unlabeled data, Indicates that the generated model is given a label y The reconstructed data is Representation Tags y The uncertainty function of represents the feature importance function, represents the regularization term, represents the L2 norm, , , , represents the weight coefficient, Indicates that in the domain The value of the independent variable that corresponds to the minimum value within .
[0009] Specifically, the specific steps of step S3 also include: S3.3: Merge the new data with pseudo labels with the training set of the original feature data to form a new training set; S3.4: Use the incremental learning algorithm to train the new training set, and update the parameters of the visual neural hybrid model trained in S3.2 according to the training results; S3.5: Use the validation set to evaluate the visual neural hybrid model after incremental learning. If the performance of the adjusted visual neural hybrid model is improved, update the parameters of the visual neural hybrid model. Otherwise, return to S3.2 to continue training the visual neural hybrid model.
[0010] Specifically, the visual neural hybrid model parameter update formula in S3.4 is: ; in, represents the parameters of the visual neural hybrid model after incremental learning, represents the parameters of the visual neural hybrid model before incremental learning, represents the learning rate, represents the coefficient of the regularization term, represents the coefficient of the momentum term, represents the difference of the previous parameter update, Represents the loss function Adding new data The gradient on Represents the coefficients of the influencing terms of multiple data sets, Indicates the new training set i The weight of the data, Indicates the new training set i New data, N represents the number of data in the new training set, Represents the parameters of the visual neural mixture model.
[0011] Specifically, the specific steps in step S4 include: S4.1: Obtain the optimized visual neural hybrid model, set liquid type judgment rules according to the extracted feature data and combined with the physical and chemical properties of the liquid, and build a liquid type judgment logic library based on the liquid type judgment rules; S4.2: Input the real-time liquid perception image into the optimized visual neural hybrid model to obtain the preliminary recognition result of the liquid; S4.3: According to the preliminary recognition result, the liquid type judgment rule in the liquid type judgment logic library is automatically triggered to perform intelligent verification; S4.4: Output the liquid type after intelligent verification and correction as the final recognition result.
[0012] Specifically, the specific steps of S4.3 include: S4.31: Obtain preliminary liquid recognition results from the optimized visual neural hybrid model; S4.32: Based on the preliminary recognition results, automatically trigger the corresponding judgment rules in the liquid type judgment logic library for intelligent verification to evaluate the confidence of the preliminary recognition results ,in, Indicates the category with the highest probability in the preliminary recognition results, Indicates the category with the second highest probability in the preliminary recognition result, g represents the normalization factor; S4.33: Compare the preliminary identification result with the expected result in the liquid type judgment logic library; If the confidence of the preliminary recognition result is higher than the preset matching threshold and is consistent with the expected result in the liquid type judgment logic library, the recognition result is directly confirmed without further correction; If the preliminary recognition result does not match the expected result in the liquid type judgment logic library, or the confidence level is lower than the preset matching threshold, the advanced judgment strategy in the logic library is triggered, using the advanced judgment strategy based on the multi-feature fusion method. Perform in-depth analysis on the preliminary recognition results, and judge whether the preliminary recognition results are wrong based on the analysis results of the advanced judgment strategy, where F represents the final classification result. Represents the rule engine function, Indicates n feature data, s Indicates the physical state information of the liquid. Represents actual measurements over time; If the preliminary recognition result is judged to be wrong according to the advanced judgment strategy, the error recognition is performed, and the preliminary recognition result is corrected according to the liquid type judgment rule.
[0013] Specifically, the liquid type judgment rules in S4.1 include feature data matching, physical property analysis, chemical property comparison, and multi-attribute comprehensive judgment.
[0014] A liquid recognition system based on visual nerves, comprising: an image processing module, a model building module, a model optimization module, a liquid recognition module, and a fine-tuning module; The image processing module is used to collect liquid images and environment perception images, and perform adaptive preprocessing to generate liquid perception images; The model building module builds a visual neural hybrid model based on the features of the extracted liquid perception image; The model optimization module is used to perform semi-supervised learning training on the constructed visual neural hybrid model and optimize the visual neural hybrid model using an incremental learning method; The liquid recognition module is used to input the real-time liquid perception image into the optimized visual neural hybrid model to perform liquid recognition, and to make a preliminary judgment and correction on the recognition result; The fine-tuning module is used to perform intelligent analysis on the corrected recognition result, and to fine-tune the visual neural hybrid model according to the intelligent analysis result and the difference between the recognition result and the preset result.
[0015] Specifically, the liquid identification module includes: an identification unit, a judgment unit, and a correction unit; The recognition unit is used to input the real-time liquid perception image into the visual neural hybrid model for recognition and output the recognition result; The judgment unit is used to make a preliminary judgment on the recognition result and compare it with the preset result; The correction unit uses a correction algorithm to correct the recognition result that does not match the preset result.
[0016] Compared with the prior art, the present invention has the following beneficial effects: 1. The present invention proposes a liquid identification system based on visual nerves, and optimizes and improves the architecture, operating steps and processes. The system has the advantages of simple process, low investment and operation costs, and low production work costs.
[0017] 2. The present invention proposes a liquid recognition method based on visual nerves. By collecting liquid images and environmental perception images, and performing adaptive preprocessing and feature extraction, a high-precision visual nerve hybrid model is constructed. This model can be continuously optimized using semi-supervised learning and incremental learning methods, thereby achieving fast and accurate recognition of liquids. At the same time, a real-time feedback mechanism and intelligent analysis function are introduced, which can fine-tune the model according to the difference between the recognition results and the preset results, further improving the accuracy and reliability of recognition. This dynamic adjustment and optimization mechanism enables the method to continuously adapt to new liquid types and recognition requirements, providing a more efficient and stable solution for liquid recognition. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] Figure 1 A schematic diagram of a liquid identification method based on visual nerves according to the present invention; Figure 2 This is a principle flow chart of a liquid identification method based on visual nerves of the present invention; Figure 3 This is a flow chart of the recognition result judgment of a liquid recognition method based on visual nerves of the present invention; Figure 4 This is an architecture diagram of a liquid identification system based on visual nerves according to the present invention. DETAILED DESCRIPTION
[0019] Example 1 See also Figure 1-Figure 3 , an embodiment of the present invention provides: a liquid identification method based on visual nerves, comprising the following steps: Step S1: collecting liquid images and environment perception images, and performing adaptive preprocessing to generate liquid perception images; Furthermore, the specific steps of step S1 include: (1) Use high-resolution cameras or sensors to capture liquid images and environmental perception images, ensuring that the captured images are clear and accurate and can reflect the actual state of the liquid and environmental characteristics; (2) Adaptively preprocessing the captured image to improve the image quality and the accuracy of subsequent processing, wherein the preprocessing step may include denoising, image enhancement, grayscale conversion and other operations. In the present invention, denoising uses a mean filtering method to remove noise interference in the image, and improves the visual effect of the image by using methods such as histogram equalization and regularization. At the same time, the color image is converted into a grayscale image to simplify the image information and improve the processing speed. The grayscale conversion formula is: Gray = 0.29900* R + 0.58700 * G + 0.11400 * B, wherein Gray is the grayscale value, and R, G, and B are the brightness values of the primary colors of red, green, and blue, respectively; (3) Generate a liquid perception image based on the processed information.
[0020] Step S2: extracting features from the liquid perception image, and constructing a visual neural hybrid model based on the extracted features; Furthermore, the specific steps of step S2 include: (1) Extracting features from the liquid sensing image, which should be able to accurately reflect the state, properties or environmental information of the liquid, wherein the feature extraction method uses a deep learning algorithm to automatically learn the features. The deep learning algorithm is the prior art content in this field and is not the inventive solution of this application, and will not be described in detail here; (2) Match the extracted features with corresponding labels, such as liquid type, concentration, and temperature, to form a training data set, and preprocess the data, such as normalization and standardization, to improve the training effect of the model; (3) Select a visual neural hybrid model architecture that integrates convolutional neural networks and Transformer. Based on the selected architecture, build a visual neural hybrid model, including input layer, convolution layer, pooling layer, Transformer layer, and fully connected layer; The specific steps to build a visual neural hybrid model include: 1) Visual neural hybrid model: Select convolutional neural network and Transformer, and fuse the convolutional neural network and Transformer by splicing to form a visual neural hybrid model to improve the performance of the model. This is achieved by embedding the Transformer component into the convolutional neural network; 2) Initialization parameters: Randomly initialize the parameters of the visual neural hybrid model; 3) Training strategy: Use optimization algorithms such as back propagation algorithm to minimize prediction errors by continuously adjusting network parameters. At the same time, in order to improve the generalization ability of the model, data enhancement, regularization and other technologies can be used to prevent overfitting. 4) Optimizer and loss function: Select optimizer and loss function to accelerate convergence and improve model performance; 5) Evaluation Metrics: Use accuracy metrics to evaluate the performance of the model and use grid search to adjust the model’s hyperparameters to further improve performance; 6) Model interpretability: Consider the interpretability of the model and ensure that the model can provide meaningful results and explanations to users; 7) Model compression and acceleration: In order to reduce the computational complexity and memory requirements of the model, quantization technology is used to compress and accelerate the model, and the trained hybrid model is deployed to the target environment, such as a cloud server.
[0021] (4) Using the training data set to train the visual neural hybrid model, optimizing the model parameters through the back propagation algorithm, and monitoring the loss function and accuracy index of the model during the training process to evaluate the performance of the model, wherein the back propagation algorithm, loss function and accuracy index are the prior art contents in this field, and are not the inventive solutions of the present application, and are not described in detail here; (5) Use the validation dataset to evaluate the trained visual neural hybrid model, check the generalization ability of the visual neural hybrid model, and adjust and optimize the visual neural hybrid model based on the evaluation results to improve its performance.
[0022] Step S3: using the extracted feature data and the corresponding liquid labels to perform semi-supervised learning training on the visual neural hybrid model, and using an incremental learning method to optimize the trained visual neural hybrid model to obtain an optimized visual neural hybrid model; Step S4: input the real-time liquid perception image into the optimized visual neural hybrid model for liquid recognition, output the liquid recognition result, and make a preliminary judgment on the recognition result to determine whether it is consistent with the preset result. If it is not consistent, a correction algorithm is introduced to correct the recognition result; Step S5: Perform intelligent analysis on the corrected recognition results. At the same time, introduce a real-time feedback mechanism to fine-tune the optimized visual neural hybrid model based on the intelligent analysis results and the differences between the recognition results and the preset results.
[0023] The specific steps of step S3 include: S3.1: Obtain feature data of the liquid sensing image, collect liquid labels corresponding to the feature data, and divide them into training set and validation set; Furthermore, the specific steps of S3.1 include: (1) Obtaining a feature data set of the liquid sensing image in step S2, and assigning one or more labels to each feature data according to the information of the liquid. These labels may be discrete, such as the type of liquid, or continuous, such as the concentration value; (2) Divide the feature data set into a training set and a validation set. Usually, the training set is used to train the model, while the validation set is used to evaluate the performance of the model. The division ratio can be determined according to the specific task and data set size. In the present invention, the division ratio of the training set and the validation set is set to 7:3.
[0024] S3.2: Initialize the visual neural hybrid model and train it using labeled data and unlabeled data in a ratio of 2:8. At the same time, build a generative model to learn the generative distribution of feature data. If there is new labeled data or unlabeled data, use the generative model to evaluate the new data and generate pseudo labels. The pseudo label generation formula is: ; in, represents the generated pseudo-label, Y represents the label data set, x Represents new labeled data or unlabeled data, Indicates that the generated model is given a label y The reconstructed data is Representation Tags y The uncertainty function of represents the feature importance function, represents the regularization term, represents the L2 norm, , , , represents the weight coefficient, Indicates that in the domain The value of the independent variable that corresponds to the minimum value within .
[0025] It should be noted that the formula in the present invention not only enhances the logic and flexibility of the formula, but also improves its accuracy and robustness in processing complex data and classification tasks by introducing multiple parameters and variables, including weight coefficients, category uncertainty, feature importance and regularization terms.
[0026] Furthermore, the specific steps of S3.2 include: (1) Collect feature data to ensure that the data covers the required feature space and has sufficient diversity and representativeness; (2) Select a generative model based on the characteristics of the data and the task requirements. In the present invention, a generative adversarial network is selected, and the number of network layers, the number of neurons, and the activation function parameters are designed based on the selected generative model. The generative adversarial network is a prior art in the art and is not an inventive solution of the present application, and is not described in detail herein. (3) According to the goal of the generated model, an adversarial loss function is set, wherein the adversarial loss function should be able to reflect the difference between the generated data and the real data and guide the model to optimize in the right direction. The adversarial loss function is the prior art content in this field and is not the inventive solution of the present application, and is not elaborated here; (4) selecting a stochastic gradient descent optimization algorithm to optimize the parameters of the generated model, wherein the stochastic gradient descent optimization algorithm is a prior art in the art and is not an inventive solution of the present application, and is not described in detail herein; (5) Use the training data to train the generative model and update the parameters of the generative model by iteratively optimizing the loss function. During the training process, use the validation set to monitor the performance of the generative model, such as the quality and diversity of the generated data and the stability of the training process. (6) Use the test set to evaluate the trained model and check the quality, diversity, and accuracy of the generated data. Based on the evaluation results, optimize the generated model, such as adjusting the network structure, adding data enhancement methods, and improving the loss function. (7) Using the trained generative model, new data with similar characteristics to the training data can be generated. The new data can be used for tasks such as data enhancement, data simulation, and anomaly detection. (8) For unlabeled data, a generative model can be used to generate pseudo labels for it to improve the generalization ability of the model.
[0027] S3.3: Merge the new data with pseudo labels with the training set of the original feature data to form a new training set; S3.4: Use the incremental learning algorithm to train the new training set, and update the parameters of the visual neural hybrid model trained in S3.2 according to the training results. The formula is: ; in, represents the parameters of the visual neural hybrid model after incremental learning, represents the parameters of the visual neural hybrid model before incremental learning, represents the learning rate, represents the coefficient of the regularization term, represents the coefficient of the momentum term, represents the difference of the previous parameter update, Represents the loss function Adding new data The gradient on Represents the coefficients of the influencing terms of multiple data sets, Indicates the new training set i The weight of the data, Indicates the new training set iNew data, N represents the number of data in the new training set, represents the parameters of the visual neural hybrid model; S3.5: Use the validation set to evaluate the visual neural hybrid model after incremental learning. If the performance of the adjusted visual neural hybrid model is improved, update the parameters of the visual neural hybrid model. Otherwise, return to S3.2 to continue training the visual neural hybrid model.
[0028] Furthermore, the specific steps of S3.5 include: (1) Ensure that the validation set is an independent dataset that does not participate in the training of the visual neural hybrid model; (2) Loading the incrementally learned visual neural hybrid model into the evaluation environment, and inputting the data in the validation set into the incrementally learned visual neural hybrid model for prediction; (3) Record the prediction results of the visual neural hybrid model after incremental learning for each sample in the validation set, including the predicted category and probability; (4) Based on the model’s prediction results and the true labels of the validation set, calculate the accuracy evaluation index to quantify the performance of the visual neural hybrid model after incremental learning; (5) Compare the calculated evaluation index with the previous visual neural hybrid model performance to determine whether incremental learning is effective. If the evaluation index improves, it means that the model performance after incremental learning is better. If the evaluation index does not improve or decreases, it is necessary to further analyze the reasons and consider whether to return to S3.2 to continue training the visual neural hybrid model.
[0029] The specific steps in step S4 include: S4.1: Obtain the optimized visual neural hybrid model, set liquid type judgment rules according to the extracted feature data and combined with the physical and chemical properties of the liquid, and build a liquid type judgment logic library based on the liquid type judgment rules; Among them, the liquid type judgment rules include feature data matching, physical property analysis, chemical property comparison, and multi-attribute comprehensive judgment to meet the liquid identification needs in different scenarios.
[0030] Furthermore, the specific steps of S4.1 include: (1) Obtain feature data extraction results; (2) Analyze the physical and chemical properties of liquids: Physical property analysis: Consider the physical properties of the liquid, such as density, refractive index, surface tension, and fluidity. These properties can be obtained through experimental measurement or theoretical calculation and used to assist in determining the type of liquid; Chemical property analysis: Analyze the chemical properties of liquids, such as pH value, solubility, and chemical reactivity. These properties can be determined through chemical analysis or chemical reaction experiments and used to build more sophisticated liquid type judgment rules; (3) Setting judgment rules: Threshold judgment: Set a threshold for a feature, such as color brightness, transparency level, and when the extracted feature data exceeds or falls below the set threshold, the type of liquid can be preliminarily judged; Pattern matching: Match the extracted feature data with the feature database of known liquid types to find the most similar pattern. If the match is high, it can be considered that the liquid belongs to the known liquid type. Machine learning algorithm: Use machine learning algorithms, such as support vector machines, to train and learn feature data to build a classification model that can automatically determine the type of liquid based on input feature data; (4) Build a logic library: Integrate judgment rules: Integrate the judgment rules set above to form a complete set of liquid type judgment logic library, which should include a variety of advanced judgment strategies to meet the liquid identification needs in different scenarios; Priority setting: Set priorities for different judgment rules so that when conflicts occur, judgments can be made in a predetermined order; Update and Maintenance: As new liquid types and characteristic data emerge, the logic library is regularly updated and maintained to ensure its accuracy and applicability.
[0031] S4.2: Input the real-time liquid perception image into the optimized visual neural hybrid model to obtain the preliminary recognition result of the liquid; Furthermore, the specific steps of S4.2 include: (1) Image acquisition: Real-time acquisition of liquid perception images through cameras or sensors; (2) Preprocessing: Preprocess the collected images to improve image quality; (3) Model input: input the preprocessed image into the optimized visual neural hybrid model; (4) Feature extraction: The model extracts features from the image and obtains key information; (5) Classification and recognition: The model performs classification and recognition based on the feature data and outputs the preliminary recognition results of the liquid; (6) Result output: The preliminary recognition results are output to the user or integrated into the automation system for subsequent processing.
[0032] S4.3: According to the preliminary recognition result, the liquid type judgment rule in the liquid type judgment logic library is automatically triggered to perform intelligent verification; S4.4: Output the liquid type after intelligent verification and correction as the final recognition result.
[0033] The specific steps of S4.3 include: S4.31: Obtain preliminary liquid recognition results from the optimized visual neural hybrid model; S4.32: Based on the preliminary recognition results, automatically trigger the corresponding judgment rules in the liquid type judgment logic library for intelligent verification to evaluate the confidence of the preliminary recognition results ,in, Indicates the category with the highest probability in the preliminary recognition results, Indicates the category with the second highest probability in the preliminary recognition result, g represents the normalization factor; S4.33: Compare the preliminary recognition result with the expected result in the liquid type judgment logic library, wherein the expected result in the liquid type judgment logic library refers to the expected output of liquid type recognition set based on the physical and chemical properties of the known liquids, as well as expert knowledge and experience; The specific process of comparison includes: (1) Data preprocessing: Ensure that the preliminary recognition results and the expected results in the logic library are properly preprocessed for accurate comparison. Preprocessing may include data cleaning, format conversion, standardization, etc. (2) Feature matching: matching the feature data in the preliminary recognition results with the expected result features in the logic library. The features may include the physical and chemical properties of the liquid, such as color, transparency, odor, density, viscosity, etc. (3) Logical operation: Perform logical operations on the preliminary recognition results according to the judgment rules and strategies in the logic library; (4) Compare the similarity between the result of the logic operation and the expected result in the logic library; (5) Decision making: Make the final decision based on the comparison results.
[0034] If the confidence of the preliminary recognition result is higher than the preset matching threshold and is consistent with the expected result in the liquid type judgment logic library, the recognition result is directly confirmed without further correction; Specifically, the confidence comparison process of the preliminary recognition results includes: (1) Obtaining the confidence of the preliminary recognition results; (2) Setting a matching threshold, which is used to determine whether the confidence level of the initial recognition result is high enough to determine whether further correction is needed; (3) Compare the preliminary recognition results with the expected results in the logic library: Compare the preliminary recognition results with the expected results in the liquid type judgment logic library, including matching of feature data and comparison of classification labels; (4) Determine the relationship between confidence and threshold: Check whether the confidence of the preliminary recognition result is higher than the preset matching threshold. If the confidence is higher than the threshold, proceed to the next step to determine the consistency between the preliminary recognition result and the expected result. If the preliminary recognition result is consistent with the expected result in the logic library, directly confirm the recognition result.
[0035] If the preliminary recognition result does not match the expected result in the liquid type judgment logic library, or the confidence level is lower than the preset matching threshold, the advanced judgment strategy in the logic library is triggered, using the advanced judgment strategy based on the multi-feature fusion method. Perform in-depth analysis on the preliminary recognition results, and judge whether the preliminary recognition results are wrong based on the analysis results of the advanced judgment strategy, where F represents the final classification result. Represents the rule engine function, Indicates n feature data, s Indicates the physical state information of the liquid. Represents actual measurements over time; If the preliminary recognition result is judged to be wrong according to the advanced judgment strategy, the error recognition is performed, and the preliminary recognition result is corrected according to the liquid type judgment rule.
[0036] Example 2 See also Figure 4 Another embodiment provided by the present invention is a liquid identification system based on visual nerves, comprising: Image processing module, model building module, model optimization module, liquid recognition module, fine-tuning module; An image processing module is used to collect liquid images and environment perception images, and perform adaptive preprocessing to generate liquid perception images; A model building module builds a visual neural hybrid model based on the features of the extracted liquid perception image; A model optimization module is used to perform semi-supervised learning training on the constructed visual neural hybrid model and optimize the visual neural hybrid model using an incremental learning method; Liquid recognition module, used to input the real-time liquid perception image into the optimized visual neural hybrid model for liquid recognition, and to make preliminary judgments and corrections on the recognition results; The fine-tuning module is used to perform intelligent analysis on the corrected recognition results, and to fine-tune the visual neural hybrid model according to the intelligent analysis results and the differences between the recognition results and the preset results.
[0037] The liquid identification module includes: an identification unit, a judgment unit, and a correction unit; A recognition unit, used for inputting the real-time liquid perception image into the visual neural hybrid model for recognition and outputting the recognition result; A judgment unit, used to make a preliminary judgment on the recognition result and compare it with the preset result; The correction unit uses a correction algorithm to correct the recognition results that do not match the preset results.
[0038] The fine-tuning module includes: an analysis unit, a feedback unit, and a fine-tuning unit; An analysis unit, used for intelligently analyzing the corrected recognition result; The feedback unit introduces a real-time feedback mechanism to provide feedback to the fine-tuning unit based on the analysis results and the differences between the recognition results and the preset results; The fine-tuning unit fine-tunes the optimized visual neural hybrid model based on the feedback to improve the accuracy and stability of the model.
[0039] The embodiments of the present invention are described above in conjunction with the accompanying drawings, but the present invention is not limited to the above-mentioned specific implementation modes, which are merely illustrative rather than restrictive. Under the guidance of the present invention, ordinary technicians in the field may also change, modify, replace and modify the above-mentioned embodiments without departing from the purpose and scope of protection of the present invention, and all of these are within the protection of the present invention.
Claims
1. A liquid identification method based on visual nerves, characterized in that: include: Step S1: collecting liquid images and environment perception images, and performing adaptive preprocessing to generate liquid perception images; Step S2: extracting features from the liquid perception image, and constructing a visual neural hybrid model based on the extracted features; Step S3: using the extracted feature data and the corresponding liquid labels to perform semi-supervised learning training on the visual neural hybrid model, and using an incremental learning method to optimize the trained visual neural hybrid model to obtain an optimized visual neural hybrid model; Step S4: input the real-time liquid perception image into the optimized visual neural hybrid model for liquid recognition, output the liquid recognition result, and make a preliminary judgment on the recognition result to determine whether it is consistent with the preset result. If it is not consistent, a correction algorithm is introduced to correct the recognition result; Step S5: Perform intelligent analysis on the corrected recognition results. At the same time, introduce a real-time feedback mechanism to fine-tune the optimized visual neural hybrid model based on the intelligent analysis results and the differences between the recognition results and the preset results.
2. A liquid identification method based on visual nerves as claimed in claim 1, characterized in that: The specific steps of step S3 include: S3.1: Obtain feature data of the liquid sensing image, collect liquid labels corresponding to the feature data, and divide them into training set and validation set; S3.2: Initialize the visual neural hybrid model and train it using labeled data and unlabeled data in a ratio of 2:
8. At the same time, build a generative model to learn the generative distribution of feature data. If there is new labeled data or unlabeled data, use the generative model to evaluate the new data and generate pseudo labels. The pseudo label generation formula is: ; in, represents the generated pseudo-label, Y represents the label data set, x Represents new labeled data or unlabeled data, Indicates that the generated model is given a label y The reconstructed data is Representation Tags y The uncertainty function of represents the feature importance function, represents the regularization term, represents the L2 norm, , , , represents the weight coefficient, Indicates that in the domain The value of the independent variable that corresponds to the minimum value within .
3. A liquid identification method based on visual nerves as claimed in claim 2, characterized in that: The specific steps of step S3 also include: S3.3: Merge the new data with pseudo labels with the training set of the original feature data to form a new training set; S3.4: Use the incremental learning algorithm to train the new training set, and update the parameters of the visual neural hybrid model trained in S3.2 according to the training results; S3.5: Use the validation set to evaluate the visual neural hybrid model after incremental learning. If the performance of the adjusted visual neural hybrid model is improved, update the parameters of the visual neural hybrid model. Otherwise, return to S3.2 to continue training the visual neural hybrid model.
4. A liquid identification method based on visual nerves as claimed in claim 3, characterized in that: The visual neural hybrid model parameter update formula in S3.4 is: ; in, represents the parameters of the visual neural hybrid model after incremental learning, represents the parameters of the visual neural hybrid model before incremental learning, represents the learning rate, represents the coefficient of the regularization term, represents the coefficient of the momentum term, represents the difference of the previous parameter update, Represents the loss function Adding new data The gradient on Represents the coefficients of the influencing terms of multiple data sets, Indicates the new training set i The weight of the data, Indicates the new training set i New data, N represents the number of data in the new training set, Represents the parameters of the visual neural mixture model.
5. A liquid identification method based on visual nerves as claimed in claim 4, characterized in that: The specific steps in step S4 include: S4.1: Obtain the optimized visual neural hybrid model, set liquid type judgment rules according to the extracted feature data and combined with the physical and chemical properties of the liquid, and build a liquid type judgment logic library based on the liquid type judgment rules; S4.2: Input the real-time liquid perception image into the optimized visual neural hybrid model to obtain the preliminary recognition result of the liquid; S4.3: According to the preliminary recognition result, the liquid type judgment rule in the liquid type judgment logic library is automatically triggered to perform intelligent verification; S4.4: Output the liquid type after intelligent verification and correction as the final recognition result.
6. A liquid identification method based on visual nerves as claimed in claim 5, characterized in that: The specific steps of S4.3 include: S4.31: Obtain preliminary liquid recognition results from the optimized visual neural hybrid model; S4.32: Based on the preliminary recognition results, automatically trigger the corresponding judgment rules in the liquid type judgment logic library for intelligent verification to evaluate the confidence of the preliminary recognition results ,in, Indicates the category with the highest probability in the preliminary recognition results, Indicates the category with the second highest probability in the preliminary recognition result, g represents the normalization factor; S4.33: Compare the preliminary identification result with the expected result in the liquid type judgment logic library; If the confidence of the preliminary recognition result is higher than the preset matching threshold and is consistent with the expected result in the liquid type judgment logic library, the recognition result is directly confirmed without further correction; If the preliminary recognition result does not match the expected result in the liquid type judgment logic library, or the confidence level is lower than the preset matching threshold, the advanced judgment strategy in the logic library is triggered, using the advanced judgment strategy based on the multi-feature fusion method. Perform in-depth analysis on the preliminary recognition results, and judge whether the preliminary recognition results are wrong based on the analysis results of the advanced judgment strategy, where F represents the final classification result. Represents the rule engine function, Indicates n feature data, s Indicates the physical state information of the liquid. Represents actual measurements over time; If the preliminary recognition result is judged to be wrong according to the advanced judgment strategy, the error recognition is performed, and the preliminary recognition result is corrected according to the liquid type judgment rule.
7. A liquid identification method based on visual nerves as claimed in claim 6, characterized in that: The liquid type judgment rules in S4.1 include feature data matching, physical property analysis, chemical property comparison, and multi-property comprehensive judgment.
8. A liquid identification system based on visual nerves, used to implement a liquid identification method based on visual nerves as claimed in any one of claims 1 to 7, characterized in that: include: Image processing module, model building module, model optimization module, liquid recognition module, fine-tuning module; The image processing module is used to collect liquid images and environment perception images, and perform adaptive preprocessing to generate liquid perception images; The model building module builds a visual neural hybrid model based on the features of the extracted liquid perception image; The model optimization module is used to perform semi-supervised learning training on the constructed visual neural hybrid model and optimize the visual neural hybrid model using an incremental learning method; The liquid recognition module is used to input the real-time liquid perception image into the optimized visual neural hybrid model to perform liquid recognition, and to make a preliminary judgment and correction on the recognition result; The fine-tuning module is used to perform intelligent analysis on the corrected recognition result, and to fine-tune the visual neural hybrid model according to the intelligent analysis result and the difference between the recognition result and the preset result.
9. A liquid identification system based on visual nerves as claimed in claim 8, characterized in that: The liquid identification module includes: an identification unit, a judgment unit, and a correction unit; The recognition unit is used to input the real-time liquid perception image into the visual neural hybrid model for recognition and output the recognition result; The judgment unit is used to make a preliminary judgment on the recognition result and compare it with the preset result; The correction unit uses a correction algorithm to correct the recognition result that does not match the preset result.
Citation Information
Patent Citations
Face image recognition method and system based on computer vision
CN117690178A
Neural tumor image analysis and identification method
CN119107507A
Image recognition system based on machine vision
CN119399534A
Person re-identification system and method integrating multi-scale GAN and label learning
US20220374630A1
Deep-learning-based surface defect detection method for mobile phone battery
WO2023155069A1
Cited By
Method for identifying types of liquid in pouring process based on event camera
CN121883964A