Sewage purification treatment agent dosage control system based on machine learning and image recognition

Through the sewage purification and treatment dose control system based on machine learning and image recognition, the problems of inflexible and wasteful traditional Chinese medicine dose control in the prior art are solved, and the automatic adjustment and efficient use of traditional Chinese medicine dose are realized.

CN119080087AActive Publication Date: 2024-12-06SI CHUAN YUN GAN ZHI REN GONG ZHI NENG KE JI YOU XIAN GONG SI
View PDF 10 Cites 0 Cited by

Patent Information

Application Number
CN202311325979.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-10-13
Publication Date
2024-12-06
Estimated Expiration
2043-10-13

AI Technical Summary

Technical Problem

The existing sewage treatment technology is not flexible enough in the control of Chinese medicine dose, which leads to the problem of waste of medicine.

Method used

The dosage control system for sewage purification treatment based on machine learning and image recognition is adopted. By obtaining the target underwater image and water quality information in the sewage tank, the characteristic values ​​are extracted and inputted to the prediction model, and the predicted frequency of the dosing pump is obtained, based on this frequency control Dosing the medicine can realize automatic adjustment of the dose.

Benefits of technology

It improves the flexibility of the dosage, reduces the waste of drugs, realizes automatic control between the dosage and the underwater characteristic value and water quality information, and improves the efficiency of sewage purification.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119080087A_ABST
    Figure CN119080087A_ABST
Patent Text Reader

Abstract

The invention relates to a sewage purification treatment agent dosage control system based on machine learning and image recognition. A target underwater image in a sewage pool and water quality information in the sewage pool are obtained through a first obtaining module; a first feature extraction module extracts feature values of the target underwater image; the first quantitative module inputs the water quality information and the characteristic value into a pre-established prediction model to obtain the predicted frequency of the dosing pump, and the frequency of the dosing pump is in direct proportion to the dosing amount per unit time; and the first control module controls the dosing pump to execute dosing action based on the predicted frequency. According to the application, the prediction model is established to obtain the relationship between the dosing amount and the underwater characteristic value and the water quality information, so that the prediction frequency of the dosing pump is determined through the extracted characteristic value of the underwater image and the water quality information, and the dosing amount is automatically controlled.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of automatic control technology, and in particular to a sewage purification treatment dosage control system based on machine learning and image recognition. Background Art

[0002] Sewage treatment (wastewater treatment) is the process of purifying sewage to meet the water quality requirements for discharge into a water body or reuse. Sewage treatment is widely used in various fields such as construction, agriculture, transportation, energy, petrochemicals, environmental protection, urban landscape, medical treatment, catering, etc., and is increasingly entering the daily lives of ordinary people.

[0003] In the prior art, the dosage of the medicine is mainly controlled based on human experience during sewage treatment, and then the medicine is added according to the dosage. This method is not flexible enough, especially for some large sewage treatment plants, where the dosage of the medicine is mainly controlled by adjusting the flow rate at regular intervals, which will cause waste of medicine. Summary of the invention

[0004] In view of this, the purpose of the present invention is to provide a sewage purification treatment drug dosage control system based on machine learning and image recognition, so as to solve the problem that the drug dosage control in the prior art is not flexible enough and easily causes drug waste.

[0005] In order to achieve the above object, the present invention adopts the following technical solutions:

[0006] The sewage purification treatment dosage control system based on machine learning and image recognition of the present invention comprises:

[0007] A first acquisition module is used to acquire a target underwater image in the sewage pool and water quality information in the sewage pool;

[0008] A first feature extraction module, used to extract feature values ​​of the target underwater image;

[0009] A first quantitative module is used to input the water quality information and the characteristic value into a pre-established prediction model to obtain a predicted frequency of a dosing pump, wherein the frequency of the dosing pump is proportional to the dosing amount per unit time;

[0010] The first control module is used to control the dosing pump to perform a dosing action based on the predicted frequency.

[0011] In one embodiment of the present application, obtaining an underwater image of a target in a sewage pool includes:

[0012] Acquire multiple underwater images P of the sewage pool taken continuously i ;

[0013] Calculate each underwater image P i The clarity D(P i );

[0014] Determine the multiple underwater images P i The highest value of clarity D max (P i ), and the highest definition value D max (P i ) is used as the target underwater image.

[0015] In one embodiment of the present application, each underwater image P is calculated i The clarity D(P i ),include:

[0016] Each underwater image P i Convert to grayscale image G i ;

[0017] Based on the segmentation grid, each grayscale image G i Divide into multiple areas;

[0018] Randomly select the target area from the multiple areas and calculate each grayscale image G i The variance of the pixel grayscale values ​​in the target area

[0019] The variance of the pixel gray value As the corresponding grayscale image G i The clarity D(P i ), where the variance of the pixel grayscale value The larger the value, the higher the clarity.

[0020] In one embodiment of the present application, extracting the feature value of the target underwater image includes:

[0021] Performing centering processing on the target underwater image to obtain a first intermediate image;

[0022] Convert the first intermediate image into a grayscale image G t ;

[0023] For the grayscale image G t Performing median filtering to obtain a second intermediate image;

[0024] adjusting the brightness of the second intermediate image to obtain a third intermediate image, so that the outlines of the suspended particles in the third intermediate image are clearer;

[0025] Determining the distribution uniformity of the suspended particles in the third intermediate image, and when the distribution uniformity of the suspended particles in the third intermediate image is greater than a preset first threshold, extracting the size and number of the suspended particles in the third intermediate image;

[0026] The characteristic value of the target underwater image is constructed based on the size and quantity of the suspended particles.

[0027] In an embodiment of the present application, determining the distribution uniformity of suspended particles in the third intermediate image includes:

[0028] extracting contour features in the third intermediate image;

[0029] When any contour feature meets the target conditions, the contour feature is used as the contour of the suspended particle, and the target conditions include: (1) the contour feature forms a closed figure; (2) the pixel value of the pixel point in the closed figure is within a preset pixel value range;

[0030] The third intermediate image is divided into a plurality of regions, and the number of suspended particles C in each region is determined. n and the average size of the suspended particles S n , wherein the number of suspended particles is the number of outlines of suspended particles, and the size of suspended particles is the number of pixel points within the outline of suspended particles;

[0031] Based on the number of suspended particles C in each area n and the average size of the suspended particles S n The distribution uniformity U of the suspended particles in the third intermediate image is calculated. The mathematical expression of the distribution uniformity U is:

[0032]

[0033] In the formula, α is the first weight factor, β is the second weight factor, C is the average value of the number of suspended particles in multiple regions, and S is the average value of the average size of suspended particles in multiple regions.

[0034] In one embodiment of the present application, the number of suspended particles C in each area is determined. n and the average size of the suspended particles S n ,include:

[0035] Determine whether the outline of each suspended particle is located in only one area. If so, increase the number of suspended particles in the corresponding area by one, and associate the outline of the suspended particle with the corresponding area; if not, increase the number of the proportion of the outline of the suspended particle in the corresponding multiple areas, and associate the outline of the suspended particle with the corresponding multiple areas;

[0036] The number of suspended particles in each area is accumulated to obtain the number of suspended particles C in each area. n ; The average number of pixels in the outline of the suspended particles associated with each region is calculated to obtain the average size S of the suspended particles n .

[0037] In one embodiment of the present application, constructing a feature value of the target underwater image based on the size and quantity of the suspended particles includes:

[0038] Calculating the average value A and standard deviation σ of the suspended particle size in the third intermediate image;

[0039] Constructing a distribution range [(A-σ), (A+σ)] of the suspended particle size in the third intermediate image based on the average value A and the standard deviation σ;

[0040] The characteristic value of the target underwater image is constructed based on the distribution range of the suspended particle size [(A-σ), (A+σ)] and the number of suspended particles.

[0041] In one embodiment of the present application, the following method is also included to establish a prediction model:

[0042] Acquire water quality sample information and a sample image containing suspended particles, wherein the sample image is an underwater image collected in the previous control cycle;

[0043] Manually labeling the water quality sample information and the sample image to obtain a data label, wherein the data label is the frequency information of the dosing pump;

[0044] Extracting feature values ​​of the sample image, and constructing a training data set based on the feature values ​​of the sample image, the water quality sample information and the data label;

[0045] The artificial neural network is trained based on the training data set to obtain a prediction model.

[0046] In one embodiment of the present application, it also includes:

[0047] The second acquisition module is used to acquire an underwater feedback image of the purified sewage pool;

[0048] A second feature extraction module, used to extract feature values ​​of the underwater feedback image;

[0049] A first comparison module, used for comparing the characteristic value of the underwater feedback image with a preset characteristic reference value;

[0050] The adjustment module is used to adjust the operating frequency of the dosing pump when the difference between the characteristic value of the underwater feedback image and the preset characteristic reference value exceeds a preset second threshold value, so that the difference between the characteristic value of the underwater feedback image and the preset characteristic reference value does not exceed the preset second threshold value.

[0051] In one embodiment of the present application, it also includes:

[0052] The third acquisition module is used to obtain the actual operating frequency of the dosing pump;

[0053] A second comparison module, used for comparing the actual operating frequency with the predicted frequency;

[0054] A feedback and adjustment module is used to feed back the predicted frequency and the actual operating frequency to the front-end module when the difference between the actual operating frequency and the predicted frequency is greater than a preset third threshold value, and send the predicted frequency to the controller through a preset process control data interface to adjust the actual operating frequency of the dosing pump to the predicted frequency.

[0055] The beneficial effects of the present invention are as follows: the sewage purification treatment dosage control system based on machine learning and image recognition of the present invention obtains the target underwater image in the sewage pool and the water quality information in the sewage pool through the first acquisition module; the first feature extraction module extracts the characteristic value of the target underwater image; the first quantitative module inputs the water quality information and the characteristic value into a pre-established prediction model to obtain the predicted frequency of the dosing pump, wherein the frequency of the dosing pump is proportional to the dosage per unit time; the first control module controls the dosing pump to perform the dosing action based on the predicted frequency. The present application establishes a prediction model to obtain the relationship between the dosage and the underwater characteristic value and water quality information, thereby determining the predicted frequency of the dosing pump through the extracted characteristic value of the underwater image and the water quality information, thereby automatically controlling the dosage. BRIEF DESCRIPTION OF THE DRAWINGS

[0056] The present invention will be further described below in conjunction with the accompanying drawings and embodiments:

[0057] Figure 1 It is a structural diagram of a sewage purification treatment dosage control system based on machine learning and image recognition in one embodiment of the present invention;

[0058] Figure 2 The present invention is a flowchart of a method for controlling dosage of sewage purification treatment agents based on machine learning and image recognition in one embodiment of the present invention. DETAILED DESCRIPTION

[0059] The following describes the embodiments of the present invention by specific examples, and those skilled in the art can easily understand other advantages and effects of the present invention from the contents disclosed in this specification. The present invention can also be implemented or applied through other different specific embodiments, and the details in this specification can also be modified or changed in various ways based on different viewpoints and applications without departing from the spirit of the present invention. It should be noted that the following embodiments and features in the embodiments can be combined with each other without conflict.

[0060] It should be noted that the illustrations provided in the following embodiments are only schematic illustrations of the basic concept of the present invention, and thus the drawings only show the layers related to the present invention rather than being drawn according to the number, shape and size of the layers in actual implementation. In actual implementation, the type, quantity and proportion of each layer may be changed arbitrarily, and the layer layout may also be more complicated.

[0061] In the following description, numerous details are discussed to provide a more thorough explanation of embodiments of the present invention; however, it is apparent to one skilled in the art that embodiments of the present invention may be practiced without these specific details.

[0062] Figure 1 FIG. 1 is a structural diagram of a sewage purification treatment drug dosage control system based on machine learning and image recognition in one embodiment of the present application. Figure 1 Shown: Included:

[0063] The first acquisition module is used to obtain the target underwater image in the sewage pool and the water quality information in the sewage pool. The multiple underwater images are obtained by the camera preset in the sewage pool. The camera transmits the underwater images to the computer host in the computer room through the data cable for storage; the computer host screens the multiple underwater images to obtain the target underwater image with the highest definition. The water quality information includes pH value, water temperature, turbidity, total nitrogen, total phosphorus, inlet flow and outlet flow.

[0064] Specifically, the target underwater image is obtained through the following process:

[0065] Acquire multiple underwater images P of the sewage pool taken continuously i ;

[0066] Calculate each underwater image P i The clarity D(P i );

[0067] Determine the multiple underwater images P i The highest value of clarity D max (P i ), and the highest definition value D max (P i) is used as the target underwater image.

[0068] In one embodiment of the present application, each underwater image P is calculated i The clarity D(P i ),include:

[0069] Each underwater image P i Convert to grayscale image G i ;

[0070] Based on the segmentation grid, each grayscale image G i Divide into multiple areas;

[0071] Randomly select the target area from the multiple areas and calculate each grayscale image G i The variance of the pixel grayscale values ​​in the target area

[0072] The variance of the pixel gray value As the corresponding grayscale image G i The clarity D(P i ), where the variance of the pixel grayscale value The larger the value, the higher the clarity.

[0073] This application uses the continuous shooting function of the camera to take multiple images each time, and then calculates the clarity of each image after converting it into a grayscale image.

[0074] This application determines the clarity by calculating the variance of the grayscale values ​​of pixels. In general, the larger the grayscale value variance, the clearer the image as a whole. In order to increase the calculation speed, this application divides the image into 9 3*3 areas and calculates the grayscale value variance of the middle area, thereby simplifying the calculation process.

[0075] The first feature extraction module is used to extract the feature values ​​of the target underwater image. The feature values ​​in the present application include the number of suspended particles and the size of the suspended particles. The size of the suspended particles is represented by the average size and the standard deviation. The average size reflects the overall size of the suspended particles, and the standard deviation reflects the uniformity of the size of the suspended particles.

[0076] Specifically, extracting the characteristic value of the target underwater image includes:

[0077] Performing centering processing on the target underwater image to obtain a first intermediate image;

[0078] Convert the first intermediate image into a grayscale image G t ;

[0079] For the grayscale image G tPerforming median filtering to obtain a second intermediate image;

[0080] adjusting the brightness of the second intermediate image to obtain a third intermediate image, so that the outlines of the suspended particles in the third intermediate image are clearer;

[0081] Determining the distribution uniformity of the suspended particles in the third intermediate image, and when the distribution uniformity of the suspended particles in the third intermediate image is greater than a preset first threshold, extracting the size and number of the suspended particles in the third intermediate image;

[0082] The characteristic value of the target underwater image is constructed based on the size and quantity of the suspended particles.

[0083] This application uses a series of image preprocessing to make subsequent feature extraction more accurate and faster. The preprocessing methods include centering, grayscale conversion, median filtering and brightness adjustment.

[0084] In order to eliminate the influence of water flow on the morphology of suspended particles, the present application also calculates the distribution uniformity of the suspended particles in the preprocessed image. After ensuring that the suspended particles are evenly distributed in the image, feature extraction is performed to ensure that the extracted feature values ​​can accurately reflect the reaction between sewage and water purification agents.

[0085] In an embodiment of the present application, determining the distribution uniformity of suspended particles in the third intermediate image includes:

[0086] extracting contour features in the third intermediate image;

[0087] When any contour feature meets the target conditions, the contour feature is used as the contour of the suspended particle, and the target conditions include: (1) the contour feature forms a closed figure; (2) the pixel value of the pixel point in the closed figure is within a preset pixel value range;

[0088] The third intermediate image is divided into a plurality of regions, and the number of suspended particles C in each region is determined. n and the average size of the suspended particles S n , wherein the number of suspended particles is the number of outlines of suspended particles, and the size of suspended particles is the number of pixel points within the outline of suspended particles;

[0089] Based on the number of suspended particles C in each area n and the average size of the suspended particles S n The distribution uniformity U of the suspended particles in the third intermediate image is calculated. The mathematical expression of the distribution uniformity U is:

[0090]

[0091] In the formula, α is the first weight factor, β is the second weight factor, C is the average value of the number of suspended particles in multiple regions, and S is the average value of the average size of suspended particles in multiple regions.

[0092] This application sets target conditions to screen out suspended particles, then divides the image into multiple regions, calculates the number of suspended particles in each region and the average size of the suspended particles, and finally obtains the overall distribution uniformity U of the suspended particles through variance calculation.

[0093] Specifically, determine the number of suspended particles C in each area n and the average size of the suspended particles S n ,include:

[0094] Determine whether the outline of each suspended particle is located in only one area. If so, increase the number of suspended particles in the corresponding area by one, and associate the outline of the suspended particle with the corresponding area; if not, increase the number of the proportion of the outline of the suspended particle in the corresponding multiple areas, and associate the outline of the suspended particle with the corresponding multiple areas;

[0095] The number of suspended particles in each area is accumulated to obtain the number of suspended particles C in each area. n ; The average number of pixels in the contour of the suspended particles associated with each area is calculated to obtain the average size Sn of the suspended particles.

[0096] In this application, the number of suspended particles in each area is determined based on the actual distribution of the suspended particles. For example, suspended particle A is distributed in both area 1 and area 2, where area 1 accounts for 0.4 and area 2 accounts for 0.6. When counting, the number of area 1 is accumulated by 0.4 and the number of area 2 is accumulated by 0.6. The average size of the suspended particles is determined based on the complete area of ​​the suspended particle contour. For example, if the area of ​​suspended particle A is S, then when calculating the average area of ​​suspended particles in area 1, the area corresponding to suspended particle A is S, and when calculating the average area of ​​suspended particles in area 2, the area corresponding to suspended particle A is also S.

[0097] If the distribution uniformity of the suspended particles in the image meets the preset requirements, the feature value of the target underwater image can be further extracted. Specifically, the feature value of the target underwater image is constructed based on the size and number of the suspended particles, including:

[0098] Calculating the average value A and standard deviation σ of the suspended particle size in the third intermediate image;

[0099] Constructing a distribution range [(A-σ), (A+σ)] of the suspended particle size in the third intermediate image based on the average value A and the standard deviation σ;

[0100] The characteristic value of the target underwater image is constructed based on the distribution range of the suspended particle size [(A-σ), (A+σ)] and the number of suspended particles.

[0101] The more fully the particles in the sewage react with the reagent, the larger the suspended particles are, the fewer they are, and the more uniform their size is. The average value A and standard deviation σ of the suspended particle size are used to characterize the band and uniformity of the suspended particles. Combined with the number of suspended particles, a characteristic value that can reflect the degree of reaction between sewage and the reagent can be constructed.

[0102] A first quantitative module is used to input the water quality information and the characteristic value into a pre-established prediction model to obtain a predicted frequency of a dosing pump, wherein the frequency of the dosing pump is proportional to the dosing amount per unit time;

[0103] The first control module is used to control the dosing pump to perform a dosing action based on the predicted frequency.

[0104] In one embodiment of the present application, the following method is also included to establish a prediction model:

[0105] Acquire water quality sample information and a sample image containing suspended particles, wherein the sample image is an underwater image collected in the previous control cycle;

[0106] Manually labeling the water quality sample information and the sample image to obtain a data label, wherein the data label is the frequency information of the dosing pump;

[0107] Extracting feature values ​​of the sample image, and constructing a training data set based on the feature values ​​of the sample image, the water quality sample information and the data label;

[0108] The artificial neural network is trained based on the training data set to obtain a prediction model.

[0109] The present application utilizes an artificial neural network to train a prediction model, thereby obtaining the corresponding relationship between water quality information, characteristic values ​​and dosage.

[0110] In one embodiment of the present application, it also includes:

[0111] The second acquisition module is used to acquire an underwater feedback image of the purified sewage pool;

[0112] A second feature extraction module, used to extract feature values ​​of the underwater feedback image;

[0113] A first comparison module, used for comparing the characteristic value of the underwater feedback image with a preset characteristic reference value;

[0114] The adjustment module is used to adjust the operating frequency of the dosing pump when the difference between the characteristic value of the underwater feedback image and the preset characteristic reference value exceeds a preset second threshold value, so that the difference between the characteristic value of the underwater feedback image and the preset characteristic reference value does not exceed the preset second threshold value.

[0115] The present application can also provide feedback based on the above process and adjust the dosage in real time to ensure that the sewage can fully react with the agent.

[0116] In one embodiment of the present application, it also includes:

[0117] The third acquisition module is used to obtain the actual operating frequency of the dosing pump;

[0118] A second comparison module, used for comparing the actual operating frequency with the predicted frequency;

[0119] A feedback and adjustment module is used to feed back the predicted frequency and the actual operating frequency to the front-end module when the difference between the actual operating frequency and the predicted frequency is greater than a preset third threshold value, and send the predicted frequency to the controller through a preset process control data interface to adjust the actual operating frequency of the dosing pump to the predicted frequency.

[0120] The present application also uses a backup channel. When the actual operating frequency of the dosing pump differs greatly from the control frequency, it indicates that there may be a problem with the channel. At this time, the control frequency is sent to the controller through a preset process control data interface to correct the actual operating frequency of the dosing pump.

[0121] The sewage purification treatment dosage control system based on machine learning and image recognition of the present invention obtains the target underwater image in the sewage pool and the water quality information in the sewage pool through the first acquisition module; the first feature extraction module extracts the characteristic value of the target underwater image; the first quantitative module inputs the water quality information and the characteristic value into a pre-established prediction model to obtain the predicted frequency of the dosing pump, wherein the frequency of the dosing pump is proportional to the dosage per unit time; the first control module controls the dosing pump to perform the dosing action based on the predicted frequency. The present application establishes a prediction model to obtain the relationship between the dosage and the underwater characteristic value and water quality information, thereby determining the predicted frequency of the dosing pump through the extracted characteristic value of the underwater image and the water quality information, thereby automatically controlling the dosage.

[0122] like Figure 2 As shown, the present application also provides a sewage purification treatment dosage control method based on machine learning and image recognition, including:

[0123] S1, obtaining a target underwater image in a sewage pool and water quality information in the sewage pool;

[0124] S2, extracting feature values ​​of the target underwater image;

[0125] S3, inputting the water quality information and the characteristic value into a pre-established prediction model to obtain a predicted frequency of a dosing pump, wherein the frequency of the dosing pump is proportional to the dosing amount per unit time;

[0126] S4, controlling the dosing pump to perform a dosing action based on the predicted frequency.

[0127] The sewage purification treatment dosage control method based on machine learning and image recognition of the present invention obtains the target underwater image in the sewage pool and the water quality information in the sewage pool through the first acquisition module; the first feature extraction module extracts the characteristic value of the target underwater image; the first quantitative module inputs the water quality information and the characteristic value into a pre-established prediction model to obtain the predicted frequency of the dosing pump, wherein the frequency of the dosing pump is proportional to the dosage per unit time; the first control module controls the dosing pump to perform the dosing action based on the predicted frequency. The present application establishes a prediction model to obtain the relationship between the dosage and the underwater characteristic value and water quality information, thereby determining the predicted frequency of the dosing pump through the extracted characteristic value of the underwater image and the water quality information, thereby automatically controlling the dosage.

[0128] This embodiment further provides a computer-readable storage medium on which a computer program is stored. When the program is executed by a processor, any one of the methods in this embodiment is implemented, wherein the method is the execution logic of this system.

[0129] This embodiment also provides an electronic terminal, including: a processor and a memory;

[0130] The memory is used to store a computer program, and the processor is used to execute the computer program stored in the memory, so that the terminal executes any one of the methods in this embodiment.

[0131] The computer-readable storage medium in this embodiment can be understood by ordinary technicians in this field: all or part of the steps of implementing the above-mentioned method embodiments can be completed by hardware related to the computer program. The aforementioned computer program can be stored in a computer-readable storage medium. When the program is executed, the steps of the above-mentioned method embodiments are executed; and the aforementioned storage medium includes: ROM, RAM, magnetic disk or optical disk and other media that can store program codes.

[0132] The electronic terminal provided in this embodiment includes a processor, a memory, a transceiver and a communication interface. The memory and the communication interface are connected to the processor and the transceiver and complete communication with each other. The memory is used to store computer programs, the communication interface is used to communicate, and the processor and the transceiver are used to run computer programs so that the electronic terminal executes each step of the above method.

[0133] In this embodiment, the memory may include a random access memory (RAM), and may also include a non-volatile memory (non-volatile memory), such as at least one disk memory.

[0134] The above-mentioned processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.

[0135] In the above-mentioned embodiments, although the present invention has been described in conjunction with the specific embodiments of the present invention, many replacements, modifications and variations of these embodiments will be apparent to those of ordinary skill in the art based on the foregoing description. The embodiments of the present invention are intended to cover all such replacements, modifications and variations falling within the broad scope of the appended claims.

[0136] The above embodiments are merely illustrative of the principles and effects of the present invention, and are not intended to limit the present invention. Anyone familiar with the art may modify or alter the above embodiments without departing from the spirit and scope of the present invention. Therefore, all equivalent modifications or alterations made by a person of ordinary skill in the art without departing from the spirit and technical ideas disclosed by the present invention shall still be covered by the claims of the present invention.

Claims

1. A sewage purification treatment dosage control system based on machine learning and image recognition, characterized in that: include: A first acquisition module is used to acquire a target underwater image in the sewage pool and water quality information in the sewage pool; A first feature extraction module, used to extract feature values ​​of the target underwater image; A first quantitative module is used to input the water quality information and the characteristic value into a pre-established prediction model to obtain a predicted frequency of a dosing pump, wherein the frequency of the dosing pump is proportional to the dosing amount per unit time; The first control module is used to control the dosing pump to perform a dosing action based on the predicted frequency.

2. The sewage purification treatment dosage control system based on machine learning and image recognition according to claim 1 is characterized in that: Acquire underwater images of targets in sewage pools, including: Acquire multiple underwater images P of the sewage pool taken continuously i ; Calculate each underwater image P i The clarity D(P i ); Determine the multiple underwater images P i The highest value of clarity D max (P i ), and the highest definition value D max (P i ) is used as the target underwater image.

3. The sewage purification treatment dosage control system based on machine learning and image recognition according to claim 2 is characterized in that: Calculate each underwater image P i The clarity D(P i ),include: Each underwater image P i Convert to grayscale image G i ; Based on the segmentation grid, each grayscale image G i Divide into multiple areas; Randomly select the target area from the multiple areas and calculate each grayscale image G i The variance of the pixel grayscale values ​​in the target area The variance of the pixel gray value As the corresponding grayscale image G i The clarity D(P i ), where the variance of the pixel grayscale value The larger it is, the higher the clarity.

4. The sewage purification treatment dosage control system based on machine learning and image recognition according to claim 1 is characterized in that: Extracting the characteristic value of the target underwater image includes: Performing centering processing on the target underwater image to obtain a first intermediate image; Convert the first intermediate image into a grayscale image G t ; For the grayscale image G t Performing median filtering to obtain a second intermediate image; adjusting the brightness of the second intermediate image to obtain a third intermediate image, so that the outlines of the suspended particles in the third intermediate image are clearer; Determining the distribution uniformity of the suspended particles in the third intermediate image, and when the distribution uniformity of the suspended particles in the third intermediate image is greater than a preset first threshold, extracting the size and number of the suspended particles in the third intermediate image; The characteristic value of the target underwater image is constructed based on the size and quantity of the suspended particles.

5. The sewage purification treatment dosage control system based on machine learning and image recognition according to claim 4 is characterized in that: Determining the distribution uniformity of the suspended particles in the third intermediate image includes: extracting contour features in the third intermediate image; When any contour feature meets the target conditions, the contour feature is used as the contour of the suspended particle, and the target conditions include: (1) the contour feature forms a closed figure; (2) the pixel value of the pixel point in the closed figure is within a preset pixel value range; The third intermediate image is divided into a plurality of regions, and the number of suspended particles C in each region is determined. n and the average size of the suspended particles S n , wherein the number of suspended particles is the number of outlines of suspended particles, and the size of suspended particles is the number of pixel points within the outline of suspended particles; Based on the number of suspended particles C in each area n and the average size of the suspended particles S n The distribution uniformity U of the suspended particles in the third intermediate image is calculated. The mathematical expression of the distribution uniformity U is: In the formula, α is the first weight factor, β is the second weight factor, C is the average value of the number of suspended particles in multiple regions, and S is the average value of the average size of the suspended particles in multiple regions.

6. The sewage purification treatment dosage control system based on machine learning and image recognition according to claim 5 is characterized in that: Determine the number of suspended particles C in each area n and the average size of the suspended particles S n ,include: Determine whether the outline of each suspended particle is located in only one area. If so, increase the number of suspended particles in the corresponding area by one, and associate the outline of the suspended particle with the corresponding area; if not, increase the number of the proportion of the outline of the suspended particle in the corresponding multiple areas, and associate the outline of the suspended particle with the corresponding multiple areas; The number of suspended particles in each area is accumulated to obtain the number of suspended particles C in each area. n ; The average number of pixels in the outline of the suspended particles associated with each region is calculated to obtain the average size S of the suspended particles n .

7. The sewage purification treatment dosage control system based on machine learning and image recognition according to claim 4 is characterized in that: Constructing a characteristic value of the target underwater image based on the size and quantity of the suspended particles includes: Calculating the average value A and standard deviation σ of the suspended particle size in the third intermediate image; Constructing a distribution range [(A-σ), (A+σ)] of the suspended particle size in the third intermediate image based on the average value A and the standard deviation σ; The characteristic value of the target underwater image is constructed based on the distribution range of the suspended particle size [(A-σ), (A+σ)] and the number of suspended particles.

8. The sewage purification treatment dosage control system based on machine learning and image recognition according to claim 1 is characterized in that: The following methods are also included to establish a prediction model: Acquire water quality sample information and a sample image containing suspended particles, wherein the sample image is an underwater image collected in the previous control cycle; Manually labeling the water quality sample information and the sample image to obtain a data label, wherein the data label is the frequency information of the dosing pump; Extracting feature values ​​of the sample image, and constructing a training data set based on the feature values ​​of the sample image, the water quality sample information and the data label; The artificial neural network is trained based on the training data set to obtain a prediction model.

9. The sewage purification treatment dosage control system based on machine learning and image recognition according to claim 1 is characterized in that: Also includes: The second acquisition module is used to acquire an underwater feedback image of the purified sewage pool; A second feature extraction module, used to extract feature values ​​of the underwater feedback image; A first comparison module, used for comparing the characteristic value of the underwater feedback image with a preset characteristic reference value; The adjustment module is used to adjust the operating frequency of the dosing pump when the difference between the characteristic value of the underwater feedback image and the preset characteristic reference value exceeds a preset second threshold value, so that the difference between the characteristic value of the underwater feedback image and the preset characteristic reference value does not exceed the preset second threshold value.

10. The sewage purification treatment dosage control system based on machine learning and image recognition according to claim 1, characterized in that: Also includes: The third acquisition module is used to obtain the actual operating frequency of the dosing pump; A second comparison module, used for comparing the actual operating frequency with the predicted frequency; A feedback and adjustment module is used to feed back the predicted frequency and the actual operating frequency to the front-end module when the difference between the actual operating frequency and the predicted frequency is greater than a preset third threshold value, and send the predicted frequency to the controller through a preset process control data interface to adjust the actual operating frequency of the dosing pump to the predicted frequency.

Citation Information

Patent Citations

  • Method for analyzing and evaluating micro-nano particle dispersion and distribution

    CN103903266A

  • Drinking spring water suspended matter detection method

    CN110726720A

  • Alum blossom image processing method and system, electronic equipment and medium

    CN111294516A

  • Device and method for measuring the concentration of marine suspended particles

    CN112098289A

  • Sewage purification treatment agent dosage control system based on big data learning and image recognition

    CN115367823A