A method and system for analyzing sewage treatment quality based on image data
By using image recognition models and water quality data analysis, the wastewater treatment scheme is dynamically adjusted, solving the problem of ineffective operation after the water quality meets the standards, and achieving energy saving, consumption reduction and efficient treatment.
Patent Information
- Application Number
- CN202511453976.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-13
- Publication Date
- 2026-01-13
- Estimated Expiration
- 2045-10-13
AI Technical Summary
In existing wastewater treatment processes, even after the water quality meets the standards, aeration, mixing, and chemical dosing units still need to be operated, resulting in a waste of energy and materials.
A wastewater treatment quality analysis method based on image data is adopted. The similarity of wastewater surface images is judged by an image recognition model. Combined with water quality data analysis, the treatment plan is dynamically adjusted to avoid ineffective work.
Accurately capture moments of stable water quality, reduce testing frequency, lower testing costs, shorten treatment cycles, and avoid energy and material waste.
Smart Images

Figure CN120912835B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The application belongs to the technical field of sewage treatment, and particularly relates to a sewage treatment quality analysis method and system based on image data. BACKGROUND
[0002] In the existing sewage treatment process, accurately determining the treatment endpoint (i.e., the water quality has stabilized to reach the predetermined standard) is a key link to realize energy saving and efficiency improvement. At present, the industry generally relies on periodic sampling and analysis of water quality parameters (such as chemical oxygen demand COD, ammonia nitrogen, turbidity, etc.). The limitations of this method are obvious: the detection results are lagging, and cannot provide real-time feedback for process control. More importantly, in order to ensure that the water quality is stable and not accidentally up to standard, the system usually needs to continue running and wait for the data of the subsequent continuous multiple periods to be confirmed stable after detecting the first up-to-standard data, and then stop the treatment. This conservative strategy, although it guarantees reliability, is extremely prone to "over-treatment", that is, after the water quality has reached the standard, the aeration, stirring, and dosing units are still working invalidly, causing energy and material waste. SUMMARY
[0003] The application provides a sewage treatment quality analysis method and system based on image data, which is used to solve the technical problem that after the water quality has reached the standard, the aeration, stirring, and dosing units are still working invalidly, causing energy and material waste.
[0004] In a first aspect, the application provides a sewage treatment quality analysis method based on image data, comprising:
[0005] obtaining a first initial sewage surface image of a first sewage pool at an initial time and a first target sewage surface image at a first time, wherein the first sewage pool is the sewage pool with the highest water quality in a set of sewage pools at the initial time, the initial time is any time before sewage treatment, and the first time is any time after the initial time;
[0006] determining a first target image similarity between the first target sewage surface image and the first initial sewage surface image based on a preset image recognition model, and determining whether the first target image similarity is greater than a first preset threshold;
[0007] if the first target image similarity is not greater than the first preset threshold, a second target sewage surface image at a second time and each first target historical sewage surface image in a first historical time period are obtained, and a preset image analysis strategy is used to determine whether the first target sewage surface image is a first mutation sewage surface image according to the second target sewage surface image and the each first target historical sewage surface image, wherein the second time is a next collection time adjacent to the first time, and the first historical time period is a time period before the first time;
[0008] if the first target sewage surface image is the first mutation sewage surface image, second water quality data of the first sewage pool at the second time are obtained, and a first sewage treatment execution scheme of the first sewage pool is determined according to a water quality analysis result corresponding to the second water quality data;
[0009] other initial sewage surface images of other sewage pools at an initial time are obtained, and a preset time correction strategy is used to correct the first time according to an initial similarity between the other initial sewage surface images and the first initial sewage surface image, to obtain other mutation times;
[0010] other water quality data at the other mutation times are obtained, and other sewage treatment execution schemes of the other sewage pools are determined according to water quality analysis results corresponding to the other water quality data.
[0011] In a second aspect, the present application provides a sewage treatment quality analysis system based on image data, comprising:
[0012] an acquisition module configured to acquire a first initial sewage surface image of a first sewage pool at an initial time and a first target sewage surface image at a first time, wherein the first sewage pool is a sewage pool with the highest water quality in a sewage pool set at the initial time, the initial time is any time when sewage treatment is not performed, and the first time is any time after the initial time;
[0013] a first determination module configured to determine a first target image similarity between the first target sewage surface image and the first initial sewage surface image based on a preset image recognition model, and determine whether the first target image similarity is greater than a first preset threshold;
[0014] The second determining module is configured to, if the first target image similarity is not greater than the first preset threshold, acquire a second target sewage surface image at a second time and each first target historical sewage surface image in a first historical time period, and determine whether the first target sewage surface image is a first mutation sewage surface image according to the second target sewage surface image and the each first target historical sewage surface image by using a preset image analysis strategy, wherein the second time is a next acquisition time adjacent to the first time, and the first historical time period is a time period before the first time.
[0015] The first determining module is configured to, if the first target sewage surface image is the first mutation sewage surface image, acquire second water quality data of the first sewage pool at the second time, and determine a first sewage treatment execution scheme of the first sewage pool according to a water quality analysis result corresponding to the second water quality data.
[0016] The correcting module is configured to acquire other initial sewage surface images of other sewage pools at an initial time, and correct the first time to obtain other mutation times by using a preset time correction strategy according to an initial similarity between the other initial sewage surface images and the first initial sewage surface image.
[0017] The second determining module is configured to acquire other water quality data at the other mutation times, and determine other sewage treatment execution schemes of the other sewage pools according to water quality analysis results corresponding to the other water quality data.
[0018] In a third aspect, an electronic device is provided, which includes at least one processor and a memory connected with the at least one processor in communication, wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform steps of the image data-based sewage treatment quality analysis method of any of the embodiments.
[0019] In a fourth aspect, the present application further provides a computer readable storage medium having a computer program stored thereon, and the program instructions are executed by a processor to enable the processor to perform steps of the image data-based sewage treatment quality analysis method of any of the embodiments.
[0020] The image data-based sewage treatment quality analysis method and system provided by the application can more accurately capture the moment when the water quality tends to be stable in the sewage treatment process by judging whether the first target image similarity is greater than a first preset threshold, obtaining a second target sewage surface image at a second time and each first target historical sewage surface image in a first historical time period, and judging whether the first target sewage surface image is a first mutation sewage surface image according to the second target sewage surface image and the each first target historical sewage surface image by using a preset image analysis strategy. In addition, the first time is corrected by using a preset time correction strategy according to the initial similarity between the other initial sewage surface images and the first initial sewage surface image to obtain other mutation times. The mutation times of other sewage pools can be determined as quickly as possible on the premise of reducing the image data processing amount. Finally, only single-point water quality data is obtained after the predicted mutation time of each pool for verification analysis, and an execution scheme of shutdown or continuous treatment is formulated accordingly. On the premise of ensuring that the water quality meets the standard, the treatment cycle is shortened to the maximum extent, and the detection cost is reduced. BRIEF DESCRIPTION OF DRAWINGS
[0021] In order to more clearly illustrate the technical solutions of the embodiments of the application, the following will briefly introduce the drawings needed to be used in the embodiment description. Obviously, the drawings in the following description are some embodiments of the application, and other drawings can be obtained by those skilled in the art without creative labor.
[0022] Figure 1 A flow chart of an image data-based sewage treatment quality analysis method provided by an embodiment of the application;
[0023] Figure 2 A structural block diagram of an image data-based sewage treatment quality analysis system provided by an embodiment of the application;
[0024] Figure 3 A structural schematic diagram of an electronic device provided by an embodiment of the application. DETAILED DESCRIPTION
[0025] In order to make the objects, technical solutions and advantages of the embodiments of the application clearer, the following will combine the drawings in the embodiments of the application to clearly and completely describe the technical solutions in the embodiments of the application. Obviously, the described embodiments are some embodiments of the application, rather than all the embodiments of the application. Based on the embodiments in the application, all other embodiments obtained by those skilled in the art without creative labor are within the protection scope of the application.
[0026] Please refer to Figure 1 which shows a flow chart of an image data-based sewage treatment quality analysis method of the present application.
[0027] As shown in Figure 1 , the image data-based sewage treatment quality analysis method specifically comprises the following steps:
[0028] Step S101, acquiring a first initial sewage surface image of a first sewage pool at an initial time and a first target sewage surface image at a first time, wherein the first sewage pool is a sewage pool with the highest water quality in a sewage pool set at the initial time, the initial time is any time before sewage treatment, and the first time is any time after the initial time.
[0029] In this step, sewage from the same source is stored in multiple sewage pools to obtain a sewage pool set, and the same sewage treatment scheme is used for each sewage pool in the same sewage pool set. At this time, the water quality data of each sewage pool at any time before sewage treatment is acquired, and the first sewage pool with the highest water quality is determined according to the analysis result. A high-definition industrial camera deployed at a fixed point directly above the first sewage pool is used to acquire the first initial sewage surface image of the first sewage pool at the initial time and the first target sewage surface image at the first time.
[0030] Step S102, determining a first target image similarity between the first target sewage surface image and the first initial sewage surface image based on a preset image recognition model, and determining whether the first target image similarity is greater than a first preset threshold.
[0031] In this step, the image recognition model is obtained by iteratively training the deep convolutional neural network. The first target sewage surface image and the first initial sewage surface image will pass through the convolutional layer, the pooling layer, the activation function, etc. of the image recognition model in turn, and finally a fixed-length, high-dimensional feature vector will be obtained before the last fully connected layer or after the global average pooling layer.
[0032] The cosine similarity between the feature vector in the first target sewage surface image and the feature vector in the first initial sewage surface image is calculated to obtain the first target image similarity between the first target sewage surface image and the first initial sewage surface image.
[0033] In one specific embodiment, after determining whether the first target image similarity is greater than the first preset threshold, if the first target image similarity is greater than the first preset threshold, the second target image similarity between the second target sewage surface image and the first initial sewage surface image is determined based on the image recognition model, and it is further determined whether the second target image similarity is greater than the first preset threshold.
[0034] In step S103, if the first target image similarity is not greater than the first preset threshold, a second target sewage surface image at a second time and each first target historical sewage surface image in a first historical time period are obtained, and whether the first target sewage surface image is a first mutation sewage surface image is determined according to the second target sewage surface image and the each first target historical sewage surface image by using a preset image analysis strategy, wherein the second time is a next collection time adjacent to the first time, and the first historical time period is a time period before the first time.
[0035] In this step, the second target sewage surface image and the first target sewage surface image are input into an image recognition model, the image recognition model outputs an image similarity, and whether the target image similarity is greater than a second preset threshold is determined; if the target image similarity is not greater than the second preset threshold, the first target sewage surface image is not directly defined as the first mutation sewage surface image; if the target image similarity is greater than the second preset threshold, a historical image change rate between each first target historical sewage surface image and the first target sewage surface image is determined, and an average of each historical image change rate is taken to obtain a target historical image change rate, wherein a certain historical image change rate is a ratio of a certain historical similarity to a certain historical time interval, the certain historical similarity is a similarity between a certain first target historical sewage surface image and the first target sewage surface image, and the certain historical time interval is a time interval between a historical collection time corresponding to the certain first target historical sewage surface image and the first time; whether the target historical image change rate is greater than a preset change rate threshold is determined; if a sequence change rate of the first target historical sewage surface image sequence is not greater than the preset change rate threshold, the first target sewage surface image is defined as the first mutation sewage surface image; if the sequence change rate of the first target historical sewage surface image sequence is greater than the preset change rate threshold, the first target sewage surface image is not defined as the first mutation sewage surface image.
[0036] In the embodiment, when the target image similarity between the second target sewage surface image and the first target sewage surface image is not greater than the second preset threshold, it is indicated that the second target sewage surface image has changed compared with the first target sewage surface image, at this time, the sewage treatment has not tended to be stable, and therefore, the first time is not the critical time when the sewage treatment tends to be stable. When the target image similarity between the second target sewage surface image and the first target sewage surface image is greater than the second preset threshold, it is possible that the sewage treatment tends to be stable at this time, or it is also possible that the second target sewage surface image has temporary abnormality, and the cause of the temporary abnormality can be equipment failure or state locking (network transmission interruption or instability, resulting in repeated display of the last frame of picture before flow interruption at the receiving end) or environmental conditions entering a stable state (external environmental factors reach and maintain a constant state, resulting in stagnation of water surface visual performance, but biochemical reaction has not been completed). Therefore, whether the target historical image change rate is greater than the preset change rate threshold is judged to effectively distinguish the normal situation and the temporary abnormal situation.
[0037] In a specific embodiment, after it is judged by using the preset image analysis strategy whether the first target sewage surface image is the first mutated sewage surface image, if the first target sewage surface image is not the first mutated sewage surface image, it is judged whether the second target image similarity is greater than the first preset threshold; if the second target image similarity is not greater than the first preset threshold, a third target sewage surface image at a third time and each second target historical sewage surface image in a second historical time period are obtained, and whether the second target sewage surface image is the first mutated sewage surface image is judged by using the preset image analysis strategy according to the third target sewage surface image and each second target historical sewage surface image, wherein the third time is a next collection time adjacent to the second time, and the second historical time period is a time period before the second time.
[0038] In step S104, if the first target sewage surface image is the first mutated sewage surface image, second water quality data of the first sewage pool at the second time is obtained, and a first sewage treatment execution scheme of the first sewage pool is determined according to a water quality analysis result corresponding to the second water quality data.
[0039] In this step, the second time point is the next acquisition time after the first time point. Through the steps executed in steps S101-S103, the critical time when the wastewater quality tends to stabilize, i.e., the first time point, can be determined relatively accurately. At this time, by directly acquiring the stable water quality data at the second time point and analyzing this stable water quality data, if the stable water quality data meets the water quality requirements, the wastewater treatment of the first wastewater tank is directly stopped; if it does not meet the water quality requirements, the wastewater treatment of the first wastewater tank continues. Compared with the existing technology, which requires analyzing the water quality data at each acquisition time and terminating wastewater treatment only after obtaining multiple consecutive stable water quality data, this method can reduce frequent and unnecessary water quality testing and avoid the situation where wastewater treatment continues even when multiple consecutive stable water quality data are obtained, thus saving wastewater treatment costs as much as possible.
[0040] Step S105: Obtain other initial sewage surface images of other sewage tanks at the initial time, and correct the first time according to the initial similarity between the other initial sewage surface images and the first initial sewage surface image using a preset time correction strategy to obtain other abrupt change times.
[0041] In this step, a second mutation sewage surface image corresponding to the second sewage tank is acquired, and the time interval between the first time and the second mutation time is determined. The second mutation time is the acquisition time of the second mutation sewage surface image. The second sewage tank is any sewage tank in a certain sewage tank set after excluding the first sewage tank.
[0042] A second initial similarity is obtained between the second initial sewage surface image and the first initial sewage surface image. The difference between the preset similarity and the second initial similarity is calculated to obtain the second initial deviation. The preset similarity is 1. The second initial sewage surface image is the initial sewage surface image of the second sewage tank at the initial time.
[0043] The ratio of the time interval to the second initial deviation is defined as the target correction factor;
[0044] Obtain the third initial similarity between the third initial sewage surface image of the third sewage tank at the initial time and the first initial sewage surface image, and subtract the preset similarity from the third initial similarity to obtain the third initial deviation degree. Here, the third sewage tank is any sewage tank in a certain sewage tank set after removing the first sewage tank and the second sewage tank.
[0045] Multiply the third initial deviation by the target correction coefficient to obtain the correction time interval, and add the correction time interval to the first time to obtain the third abrupt change time.
[0046] In this embodiment, the identified abrupt change time (first moment) of the first sewage tank is used as a benchmark. By quantifying the image similarity difference between the other sewage tanks and the first sewage tank in the initial state (initial moment), the abrupt change time of each other sewage tank is dynamically predicted and calculated. This can avoid repeating the high-frequency image acquisition and calculation analysis process for each sewage tank as much as possible, and effectively reduce the amount of image data processing.
[0047] Step S106: Obtain other water quality data at the other abrupt change time, and determine other wastewater treatment implementation plans for the other wastewater ponds based on the water quality analysis results corresponding to the other water quality data.
[0048] In this step, the water quality analysis results can be obtained by inputting water quality data into a pre-built water quality identification model, from which the model outputs its results. The water quality identification model is trained using a neural network model from existing technologies.
[0049] In summary, the method of this application first utilizes an image acquisition device deployed on the initial optimal water quality pool (first sewage pool), combined with an image recognition model, to determine whether the similarity of the first target image is greater than a first preset threshold. If the similarity of the first target image is not greater than the first preset threshold, then the second target sewage surface image at the second time point and each first target historical sewage surface image within the first historical time period are acquired. Based on the second target sewage surface image and each first target historical sewage surface image, a preset image analysis strategy is used to determine whether the first target sewage surface image is a first abrupt change sewage surface image. This can accurately capture the moment when the water quality tends to stabilize during sewage treatment. Furthermore, based on the initial similarity between the other initial sewage surface images and the first initial sewage surface image, a preset time correction strategy is used to correct the first time point to obtain other abrupt change moments. This can determine the abrupt change moments of other sewage pools as quickly as possible while reducing the amount of image data processing. Finally, only after the predicted abrupt change moments of each pool are single-point water quality data acquired for verification analysis, and an execution plan for shutdown or continued treatment is formulated accordingly. This minimizes the processing cycle and reduces detection costs while ensuring that the water quality meets the standards.
[0050] Please see Figure 2 The diagram shows a structural block diagram of a wastewater treatment quality analysis system based on image data according to this application.
[0051] like Figure 2 As shown, the wastewater treatment quality analysis system 200 includes an acquisition module 210, a first judgment module 220, a second judgment module 230, a first determination module 240, a correction module 250, and a second determination module 260.
[0052] The acquisition module 210 is configured to acquire a first initial sewage surface image of a first sewage tank at an initial time, and a first target sewage surface image at a first time, wherein the first sewage tank is the sewage tank with the highest water quality in a set of sewage tanks at the initial time, the initial time is any time when no sewage treatment is carried out, and the first time is any time after the initial time; the first judgment module 220 is configured to determine the first target image similarity between the first target sewage surface image and the first initial sewage surface image based on a preset image recognition model, and determine whether the first target image similarity is greater than a first preset threshold; the second judgment module 230 is configured to acquire a second target sewage surface image at a second time and each first target historical sewage surface image within a first historical time period if the first target image similarity is not greater than the first preset threshold, and determine the first target sewage surface image using a preset image analysis strategy based on the second target sewage surface image and each first target historical sewage surface image. Whether the wastewater surface image is a first abrupt change wastewater surface image, wherein the second time moment is the next acquisition time adjacent to the first time moment, and the first historical time period is the time period before the first time moment; the first determining module 240 is configured to, if the first target wastewater surface image is a first abrupt change wastewater surface image, acquire the second water quality data of the first wastewater tank at the second time moment, and determine the first wastewater treatment execution plan of the first wastewater tank according to the water quality analysis results corresponding to the second water quality data; the correction module 250 is configured to acquire other initial wastewater surface images of other wastewater tanks at the initial time moment, and correct the first time moment according to the initial similarity between the other initial wastewater surface images and the first initial wastewater surface image using a preset time correction strategy to obtain other abrupt change times; the second determining module 260 is configured to acquire other water quality data at the other abrupt change times, and determine other wastewater treatment execution plans of other wastewater tanks according to the water quality analysis results corresponding to the other water quality data.
[0053] It should be understood that Figure 2 The modules and references described in the document Figure 1 The steps described in the text correspond to those in the method described above. Therefore, the operations, features, and corresponding technical effects described above also apply to the method described in the text. Figure 2 The various modules in the document will not be described in detail here.
[0054] In other embodiments, the present invention also provides a computer-readable storage medium having a computer program stored thereon, wherein when the program instructions are executed by a processor, the processor performs the wastewater treatment quality analysis method based on image data in any of the above method embodiments.
[0055] In one embodiment, the computer-readable storage medium of the present invention stores computer-executable instructions, which are configured as follows:
[0056] Acquire a first initial sewage surface image of a first sewage tank at an initial time, and a first target sewage surface image at a first time, wherein the first sewage tank is the sewage tank with the highest water quality in a certain sewage tank set at the initial time, the initial time is any time when no sewage treatment is carried out, and the first time is any time after the initial time.
[0057] The first target image similarity between the first target sewage surface image and the first initial sewage surface image is determined based on a preset image recognition model, and it is determined whether the first target image similarity is greater than a first preset threshold.
[0058] If the similarity of the first target image is not greater than the first preset threshold, then the second target sewage surface image at the second time and each first target historical sewage surface image within the first historical time period are acquired. Based on the second target sewage surface image and each first target historical sewage surface image, a preset image analysis strategy is used to determine whether the first target sewage surface image is a first abrupt sewage surface image. The second time is the next acquisition time adjacent to the first time, and the first historical time period is the time period before the first time.
[0059] If the first target sewage surface image is a first abrupt sewage surface image, then the second water quality data of the first sewage tank at the second time is obtained, and the first sewage treatment execution plan of the first sewage tank is determined according to the water quality analysis results corresponding to the second water quality data.
[0060] Acquire other initial sewage surface images of other sewage tanks at the initial time, and based on the initial similarity between the other initial sewage surface images and the first initial sewage surface image, use a preset time correction strategy to correct the first time to obtain other abrupt change times;
[0061] Obtain other water quality data at the other abrupt change times, and determine other wastewater treatment implementation plans for the other wastewater ponds based on the water quality analysis results corresponding to the other water quality data.
[0062] Computer-readable storage media may include a stored program area and a stored data area, wherein the stored program area may store an operating system and an application program required for at least one function; the stored data area may store data created based on the use of the image data-based wastewater treatment quality analysis system, etc. Furthermore, the computer-readable storage medium may include high-speed random access memory, and may also include memory, such as at least one disk storage device, flash memory device, or other non-volatile solid-state storage device. In some embodiments, the computer-readable storage medium may optionally include memory remotely configured relative to a processor, which can be connected to the image data-based wastewater treatment quality analysis system via a network. Examples of such networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.
[0063] Figure 3 This is a schematic diagram of the structure of the electronic device provided in the embodiment of the present invention, such as... Figure 3 As shown, the device includes a processor 310 and a memory 320. The electronic device may also include an input device 330 and an output device 340. The processor 310, memory 320, input device 330, and output device 340 can be connected via a bus or other means. Figure 3 Taking a bus connection as an example, the memory 320 is the computer-readable storage medium described above. The processor 310 executes various server functions and data processing by running non-volatile software programs, instructions, and modules stored in the memory 320, thereby implementing the wastewater treatment quality analysis method based on image data described in the above embodiment. The input device 330 can receive input digital or character information and generate key signal inputs related to user settings and function control of the image data-based wastewater treatment quality analysis system. The output device 340 may include a display screen or other display device.
[0064] The aforementioned electronic device can execute the method provided in the embodiments of the present invention, and has the corresponding functional modules and beneficial effects for executing the method. Technical details not described in detail in this embodiment can be found in the method provided in the embodiments of the present invention.
[0065] In one implementation, the above-described electronic device is applied in a wastewater treatment quality analysis system based on image data, for a client, and includes: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to:
[0066] Acquire a first initial sewage surface image of a first sewage tank at an initial time, and a first target sewage surface image at a first time, wherein the first sewage tank is the sewage tank with the highest water quality in a certain sewage tank set at the initial time, the initial time is any time when no sewage treatment is carried out, and the first time is any time after the initial time.
[0067] The first target image similarity between the first target sewage surface image and the first initial sewage surface image is determined based on a preset image recognition model, and it is determined whether the first target image similarity is greater than a first preset threshold.
[0068] If the similarity of the first target image is not greater than the first preset threshold, then the second target sewage surface image at the second time and each first target historical sewage surface image within the first historical time period are acquired. Based on the second target sewage surface image and each first target historical sewage surface image, a preset image analysis strategy is used to determine whether the first target sewage surface image is a first abrupt sewage surface image. The second time is the next acquisition time adjacent to the first time, and the first historical time period is the time period before the first time.
[0069] If the first target sewage surface image is a first abrupt sewage surface image, then the second water quality data of the first sewage tank at the second time is obtained, and the first sewage treatment execution plan of the first sewage tank is determined according to the water quality analysis results corresponding to the second water quality data.
[0070] Acquire other initial sewage surface images of other sewage tanks at the initial time, and based on the initial similarity between the other initial sewage surface images and the first initial sewage surface image, use a preset time correction strategy to correct the first time to obtain other abrupt change times;
[0071] Obtain other water quality data at the other abrupt change times, and determine other wastewater treatment implementation plans for the other wastewater ponds based on the water quality analysis results corresponding to the other water quality data.
[0072] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., including several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods of various embodiments or some parts of embodiments.
[0073] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method of wastewater treatment quality analysis based on image data, characterized by, The method comprises the following steps: acquiring a first initial sewage surface image of a first sewage pool at an initial time and a first target sewage surface image at a first time, wherein the first sewage pool is a sewage pool with the highest water quality in a set of sewage pools at the initial time, the initial time is any time before sewage treatment, and the first time is any time after the initial time; determining a first target image similarity between the first target sewage surface image and the first initial sewage surface image based on a preset image recognition model, and determining whether the first target image similarity is greater than a first preset threshold; if the first target image similarity is not greater than the first preset threshold, acquiring a second target sewage surface image at a second time and each first target historical sewage surface image in a first historical time period, and determining whether the first target sewage surface image is a first mutation sewage surface image based on the second target sewage surface image and the each first target historical sewage surface image using a preset image analysis strategy, wherein the second time is a next collection time adjacent to the first time, and the first historical time period is a time period before the first time; if the first target image similarity is greater than the first preset threshold, determining a second target image similarity between the second target sewage surface image and the first initial sewage surface image based on the image recognition model, and continuing to determine whether the second target image similarity is greater than the first preset threshold; if the first target sewage surface image is the first mutation sewage surface image, acquiring second water quality data of the first sewage pool at the second time, and determining a first sewage treatment execution scheme of the first sewage pool based on a water quality analysis result corresponding to the second water quality data; acquiring other initial sewage surface images of other sewage pools at the initial time, and correcting the first time to obtain other mutation times using a preset time correction strategy based on an initial similarity between the other initial sewage surface images and the first initial sewage surface image; acquiring other water quality data at the other mutation times, and determining other sewage treatment execution schemes of the other sewage pools based on water quality analysis results corresponding to the other water quality data.
2. The method of claim 1, wherein the method is characterized by, The method further comprises the following steps: inputting the second target sewage surface image and the first target sewage surface image into the image recognition model, and determining whether the target image similarity is greater than a second preset threshold based on an output image similarity of the image recognition model; if greater than the second preset threshold, determining a historical image change rate between each first target historical sewage surface image and the first target sewage surface image, and taking an average of each historical image change rate to obtain a target historical image change rate, wherein a certain historical image change rate is a ratio of a certain historical similarity and a certain historical time interval, the certain historical similarity is a similarity between a certain first target historical sewage surface image and the first target sewage surface image, and the certain historical time interval is a time interval between a historical collection time corresponding to the certain first target historical sewage surface image and the first time; determining whether the target historical image change rate is greater than a preset change rate threshold; if the sequence change rate of the first target historical sewage surface image sequence is not greater than the preset change rate threshold, defining the first target sewage surface image as a first mutation sewage surface image; if the sequence change rate of the first target historical sewage surface image sequence is greater than the preset change rate threshold, not defining the first target sewage surface image as a first mutation sewage surface image.
3. The method of claim 2, wherein the method further comprises: After determining whether the target image similarity is greater than the second preset threshold, the method further comprises: if not greater than the second preset threshold, directly not defining the first target sewage surface image as a first mutation sewage surface image.
4. The method of claim 1, wherein the method is characterized by: After the step of determining whether the first target sewage surface image is a first mutation sewage surface image by using the preset image analysis strategy, the method further comprises: if the first target sewage surface image is not a first mutation sewage surface image, determining whether the second target image similarity is greater than a first preset threshold; if the second target image similarity is not greater than the first preset threshold, obtaining a third target sewage surface image at a third time and each second target historical sewage surface image in a second historical time period, and determining whether the second target sewage surface image is a first mutation sewage surface image by using the preset image analysis strategy according to the third target sewage surface image and the each second target historical sewage surface image, wherein the third time is a next collection time adjacent to the second time, and the second historical time period is a time period before the second time.
5. The method of claim 1, wherein the method is characterized by: the first initial sewage surface image, and correcting the first time to obtain other mutation times by using a preset time correction strategy according to an initial similarity between the other initial sewage surface image and the first initial sewage surface image, comprising: obtaining a second mutation sewage surface image corresponding to a second sewage pool, and determining a time interval between the first time and the second mutation time, wherein the second mutation time is a collection time of the second mutation sewage surface image, and the second sewage pool is any sewage pool in the certain sewage pool set except the first sewage pool; obtaining a second initial similarity between a second initial sewage surface image and the first initial sewage surface image, and obtaining a second initial deviation degree by subtracting a preset similarity from the second initial similarity, wherein the preset similarity has a value of 1, and the second initial sewage surface image is an initial sewage surface image of the second sewage pool at the initial time; defining a target correction coefficient as a ratio between the time interval and the second initial deviation degree; obtaining a third initial similarity between a third initial sewage surface image of a third sewage pool at the initial time and the first initial sewage surface image, and obtaining a third initial deviation degree by subtracting a preset similarity from the third initial similarity, wherein the third sewage pool is any sewage pool in the set of sewage pools except the first sewage pool and the second sewage pool; multiplying the third initial deviation degree by the target correction coefficient to obtain a corrected time interval, and adding the corrected time interval to the first time to obtain a third mutation time.
6. An image data-based sewage treatment quality analysis system characterized by comprising: comprise: an obtaining module configured to obtain a first initial sewage surface image of a first sewage pool at an initial time, and a first target sewage surface image at a first time, wherein the first sewage pool is a sewage pool with the highest water quality in a set of sewage pools at the initial time, the initial time is any time before sewage treatment, and the first time is any time after the initial time; a first determining module configured to determine a first target image similarity between the first target sewage surface image and the first initial sewage surface image based on a preset image recognition model, and determine whether the first target image similarity is greater than a first preset threshold; a second determining module configured to, if the first target image similarity is not greater than the first preset threshold, obtain a second target sewage surface image at a second time and each first target historical sewage surface image in a first historical time period, and determine whether the first target sewage surface image is a first mutation sewage surface image according to the second target sewage surface image and the each first target historical sewage surface image using a preset image analysis strategy, wherein the second time is a next collection time adjacent to the first time, and the first historical time period is a time period before the first time; if the first target image similarity is greater than the first preset threshold, determining a second target image similarity between the second target sewage surface image and the first initial sewage surface image based on the image recognition model, and continuing to determine whether the second target image similarity is greater than the first preset threshold; a first determining module configured to, if the first target sewage surface image is the first mutation sewage surface image, obtain second water quality data of the first sewage pool at the second time, and determine a first sewage treatment execution scheme of the first sewage pool according to a water quality analysis result corresponding to the second water quality data. The correction module is configured to acquire an initial sewage surface image of another sewage pool at an initial time, and correct the first time according to an initial similarity between the initial sewage surface image and the first initial sewage surface image by using a preset time correction strategy, to obtain another mutation time. The second determination module is configured to acquire other water quality data at the other mutation time, and determine an other sewage treatment execution scheme of the other sewage pool according to a water quality analysis result corresponding to the other water quality data.
7. An electronic device, comprising: The method comprises the following steps: At least one processor and a memory connected in communication with the at least one processor, wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute the method of any one of claims 1 to 5.
8. A computer readable storage medium having stored thereon a computer program, characterized in that, The program is executed by the processor to implement the method of any one of claims 1 to 5.
Citation Information
Patent Citations
Automatic medicament adding management system
CN116835683A
Sewage treatment operation method and system based on AI algorithm
CN118135310A