Drinking water quality monitoring method and system
By setting up sampling points in a multi-level drinking water pipeline network, combining microscope and spectrometer detection, and weight assignment, the problem of difficulty in monitoring the drinking water transport process in the existing technology is solved, and the comprehensive and accurate water quality of drinking water is achieved Evaluate.
Patent Information
- Application Number
- CN202411353429.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-26
- Publication Date
- 2024-12-31
AI Technical Summary
The prior art is difficult to monitor the delivery process of drinking water in all aspects, making it difficult to obtain all-round water quality monitoring data.
Multiple sampling points are set up in the multi-stage pipeline network of drinking water, and the detection is carried out through a microscope and spectrometer, combined with weight assignment, and comprehensive monitoring and scoring are carried out to improve the objectivity and accuracy of monitoring.
It realizes comprehensive monitoring of the drinking water transportation process, can objectively describe the impact of water quality at each stage, and improves the accuracy and comprehensiveness of water quality monitoring.
Smart Images

Figure CN119223676A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of water quality monitoring, and in particular to a drinking water quality monitoring method and system. Background Art
[0002] In the process of drinking water quality monitoring, drinking water is usually sampled regularly to detect whether the harmful substances in it exceed the standard. However, the sampling process in related technologies usually only involves sampling at the water outlet, and there may also be pollution in the multi-level pipe network that transports drinking water. This sampling method is difficult to fully monitor the drinking water transportation process and it is also difficult to obtain comprehensive monitoring data.
[0003] The information disclosed in the background technology section of this application is only intended to deepen the understanding of the general background technology of this application, and should not be regarded as an admission or any form of suggestion that the information constitutes the prior art already known to those skilled in the art. Summary of the invention
[0004] The present invention provides a drinking water quality monitoring method and system, which can solve the technical problem that the related technology is difficult to monitor the drinking water transportation process in an all-round way.
[0005] According to a first aspect of the present invention, there is provided a method for monitoring drinking water quality, comprising:
[0006] Set up multiple sampling points in the multi-level drinking water pipe network, and collect drinking water samples through the sampling points in each level of the pipe network;
[0007] Determine a first weight of the drinking water sample according to the level of the pipe network to which the sampling point corresponding to the drinking water sample belongs;
[0008] Sampling each of the drinking water samples to obtain a plurality of microscope samples corresponding to each drinking water sample;
[0009] observing a plurality of microscope samples of each drinking water sample through a microscope of a preset magnification, and obtaining a microscopic image of each microscope sample;
[0010] According to the microscopic image, obtaining an image detection score for each microscopic sample;
[0011] Obtaining a visual inspection score for drinking water quality according to the image inspection score of each microscope sample and the first weight;
[0012] According to the image detection score of each microscope sample, a target drinking water sample that has passed the image detection is determined from multiple drinking water samples, and the content information of multiple harmful substances in the target drinking water sample is detected by a spectrometer;
[0013] Obtaining a drinking water quality spectrum detection score according to the harmful substance content information and the first weight;
[0014] A drinking water quality score is obtained based on the quantitative proportion of the target drinking water samples in the drinking water samples, the drinking water quality visual detection score and the drinking water quality spectral detection score.
[0015] According to a second aspect of the present invention, there is provided a drinking water quality monitoring system, comprising:
[0016] The sampling point module is used to set multiple sampling points in the multi-level pipe network of drinking water, and collect drinking water samples through the sampling points in each level of the pipe network;
[0017] A first weight module, used to determine a first weight of the drinking water sample according to the level of the pipe network to which the sampling point corresponding to the drinking water sample belongs;
[0018] A sampling module, used for sampling each of the drinking water samples to obtain a plurality of microscope samples corresponding to each drinking water sample;
[0019] An observation module, used to observe multiple microscope samples of each drinking water sample through a microscope with a preset magnification, and obtain a microscopic image of each microscope sample;
[0020] An image detection and scoring module, used to obtain an image detection score for each microscope sample based on the microscope image;
[0021] A drinking water quality visual detection scoring module, used to obtain a drinking water quality visual detection score based on the image detection score of each microscope sample and the first weight;
[0022] A content information module is used to determine a target drinking water sample that has passed the image detection among multiple drinking water samples according to the image detection score of each microscope sample, and detect the content information of multiple harmful substances in the target drinking water sample through a spectrometer;
[0023] A drinking water quality spectrum detection scoring module, used to obtain a drinking water quality spectrum detection score according to the harmful substance content information and the first weight;
[0024] The drinking water quality scoring module is used to obtain a drinking water quality score based on the quantitative proportion of the target drinking water sample in the drinking water sample, the drinking water quality visual detection score and the drinking water quality spectral detection score.
[0025] According to a third aspect of the present invention, there is provided a drinking water quality monitoring device, comprising: a processor; a memory for storing processor executable instructions; wherein the processor is configured to call the instructions stored in the memory to execute the drinking water quality monitoring method.
[0026] Technical effect: According to the present invention, multiple sampling points can be set in a multi-level pipe network for drinking water, and the first weight of the drinking water samples obtained at each sampling point can be set based on the level of the pipe network, so that in the process of drinking water quality monitoring, the transportation process of drinking water can be monitored in all directions, and the impact of each stage of the transportation process on the quality of drinking water can be objectively described. In addition, the water quality of drinking water can be comprehensively and accurately evaluated through the visual detection score of drinking water quality and the spectral detection score of drinking water quality, thereby improving the objectivity and accuracy of drinking water quality monitoring. When determining the first weight, the first weight of the drinking water sample can be determined by the impact of the level of the pipe network where the sampling point corresponding to the drinking water sample is located on the entire drinking water delivery system, and the impact of the flow rate of the pipe network where the sampling point corresponding to the drinking water sample is located on the entire drinking water delivery system. This allows the first weight to accurately reflect the impact of water quality pollution in the drinking water sample collected at the sampling point on the drinking water delivery system, thereby improving the accuracy and objectivity of the first weight. When determining the image detection score, the set of intersections between the test line and the edge of the range where the pollutant is located can be obtained by the gradient of the pixel values of the pixels on the test line in the direction described by the direction vector of the test line, and then the maximum relative size of the pollutant crossed by the test line can be determined based on the intersections in the set, and the number ratio of all the pixels on the test line that are in the range to all the pixels on the test line can be obtained, so as to determine the image detection score that can describe both the size and the number of pollutants, thereby improving the accuracy and objectivity of the image detection score. When determining the visual detection score of drinking water quality, the visual detection score of drinking water quality that can accurately describe the water quality status of the visual detection of the entire drinking water delivery system can be obtained by the influence of the pollutants in each drinking water sample on the entire drinking water delivery system and the microscope detection results of each drinking water sample itself, thereby improving the accuracy and objectivity of the visual detection score of drinking water quality. When determining the spectral detection score of drinking water quality, the spectral detection score of drinking water quality that can accurately describe the water quality status of the spectral detection of the entire drinking water delivery system can be obtained by the influence of the harmful substances in each target drinking water sample on the entire drinking water delivery system and the spectral detection results of each drinking water sample itself, thereby improving the accuracy and objectivity of the spectral detection score of drinking water quality. When determining the drinking water quality score, the drinking water quality spectral detection score obtained for the target drinking water sample can be first converted into a drinking water quality spectral detection score based on all drinking water samples, so that the data basis of the drinking water quality visual detection score and the drinking water quality spectral detection score are consistent and horizontally comparable, thereby improving the accuracy and scientific nature of the drinking water quality score. In addition, the water quality status of the entire drinking water delivery system can be comprehensively evaluated from two aspects: visual detection and spectral detection, thereby improving the objectivity and comprehensiveness of the drinking water quality score.
[0027] It should be understood that the above general description and the following detailed description are exemplary and explanatory only and do not limit the present invention. Other features and aspects of the present invention will become more apparent from the following detailed description of exemplary embodiments with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present invention. For those of ordinary skill in the art, other embodiments can be obtained based on these drawings without creative work.
[0029] Figure 1 A schematic diagram of a process of monitoring drinking water quality according to an embodiment of the present invention is exemplarily shown;
[0030] Figure 2 A block diagram of a drinking water quality monitoring system according to an embodiment of the present invention is exemplarily shown. DETAILED DESCRIPTION
[0031] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0032] The technical solution of the present invention is described in detail with specific embodiments below. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described in detail in some embodiments.
[0033] Figure 1 A schematic flow chart of a method for monitoring drinking water quality according to an embodiment of the present invention is exemplarily shown, the method comprising:
[0034] Step S101, setting a plurality of sampling points in a multi-level pipe network for drinking water, and collecting drinking water samples through the sampling points in each level of the pipe network;
[0035] Step S102, determining a first weight of the drinking water sample according to the level of the pipe network to which the sampling point corresponding to the drinking water sample belongs;
[0036] Step S103, sampling each of the drinking water samples to obtain a plurality of microscope samples corresponding to each drinking water sample;
[0037] Step S104, observing multiple microscope samples of each drinking water sample through a microscope with a preset magnification, and obtaining a microscopic image of each microscope sample;
[0038] Step S105, obtaining an image detection score for each microscope sample according to the microscope image;
[0039] Step S106, obtaining a visual inspection score of drinking water quality according to the image inspection score of each microscope sample and the first weight;
[0040] Step S107, determining a target drinking water sample that has passed the image detection from among the multiple drinking water samples according to the image detection score of each microscope sample, and detecting content information of multiple harmful substances in the target drinking water sample by a spectrometer;
[0041] Step S108, obtaining a drinking water quality spectrum detection score according to the harmful substance content information and the first weight;
[0042] Step S109, obtaining a drinking water quality score according to the proportion of the target drinking water sample in the drinking water sample, the drinking water quality visual detection score and the drinking water quality spectral detection score.
[0043] According to the drinking water quality monitoring method of the embodiment of the present invention, multiple sampling points can be set in the multi-level pipe network of drinking water, and the first weight of the drinking water samples obtained at each sampling point can be set based on the level of the pipe network, so that in the process of drinking water quality monitoring, the drinking water transportation process can be fully monitored, and the impact of each stage of the transportation process on the drinking water quality can be objectively described. In addition, the water quality of drinking water can be comprehensively and accurately evaluated through the visual detection score of drinking water quality and the spectral detection score of drinking water quality, thereby improving the objectivity and accuracy of drinking water quality monitoring.
[0044] According to one embodiment of the present invention, in step S101, the pipe network for transporting drinking water may be a multi-level pipe network. For example, the pipe network for outputting drinking water from a drinking water station may be used as a primary pipe network. The primary pipe network may have multiple branch pipe networks, which may be connected to multiple communities respectively. Each branch pipe network of the primary pipe network may be used as a secondary pipe network. The secondary pipe network may also have multiple branch pipe networks, which may be connected to multiple streets respectively. Each branch pipe network of the secondary pipe network may be used as a tertiary pipe network. The tertiary pipe network may have multiple branch pipe networks, which may be connected to multiple communities respectively. Each branch pipe network of the tertiary pipe network may be used as a quaternary pipe network. The lower the level of the pipe network, the closer it is to the drinking water station. The higher the level of the pipe network, the closer it is to the user's water outlet. The present invention does not limit the division of pipe network levels and the number of pipe network levels.
[0045] According to one embodiment of the present invention, multiple sampling points can be set in a multi-level pipe network. For example, a sampling point is set in a primary pipe network. The primary pipe network may have a secondary pipe network with multiple branches. A sampling point can be set in each secondary pipe network. The secondary pipe network may have a tertiary pipe network with multiple branches. A sampling point can be set in each tertiary pipe network. A faucet for sampling can be set at each sampling point, which can be used to make the drinking water in the pipe network flow out, so as to obtain drinking water samples. The present invention does not limit the setting method of the sampling points. A certain amount of drinking water samples can be taken from each sampling point in each monitoring cycle.
[0046] According to one embodiment of the present invention, in step S102, as described above, the lower the level of the pipe network, the closer it is to the drinking water station, that is, the closer it is to the source, and the higher the level of the pipe network, the closer it is to the user's water outlet, that is, the closer it is to the end of the pipe network. Therefore, a higher weight can be assigned to the sampling points set in the pipe network with a lower level, and a lower weight can be assigned to the sampling points set in the pipe network with a higher level, so as to accurately and objectively describe the impact of the water pollution detected at each sampling point on the entire drinking water delivery process.
[0047] According to one embodiment of the present invention, a first weight of a drinking water sample is determined according to the level of a pipe network to which a sampling point corresponding to the drinking water sample belongs, including: obtaining design parameters of pipe networks of multiple levels; determining a flow ratio between a pipe network where each sampling point is located and a primary pipe network according to the design parameters of the pipe networks of multiple levels; and determining the first weight of the drinking water sample according to the flow ratio and the level of the pipe network to which the sampling point corresponding to the drinking water sample belongs.
[0048] According to one embodiment of the present invention, the pipeline network design parameters can record parameters such as the design diameter of each level of the pipeline network, so as to determine the flow data of each level of the pipeline network when transporting drinking water (for example, when the pipeline networks at all levels transport drinking water at the maximum flow rate), and then determine the flow ratio between the pipeline network where each sampling point is located and the first-level pipeline network.
[0049] According to one embodiment of the present invention, the first weight of the drinking water sample is determined according to the flow ratio and the level of the pipe network to which the sampling point corresponding to the drinking water sample belongs, including: determining the first weight W of the i-th drinking water sample according to formula (1): i ,
[0050]
[0051] Among them, P i is the flow ratio between the pipe network where the sampling point corresponding to the i-th drinking water sample is located and the primary pipe network, N is the maximum value of the pipe network level, L i is the level of the pipe network to which the sampling point corresponding to the i-th drinking water sample belongs, L i≤N, and L i and N are both positive integers.
[0052] According to one embodiment of the present invention, in formula (1), It can be used as the level weight of the pipe network where the sampling point corresponding to the drinking water sample is located. In this level weight, the lower the level of the pipe network, the closer it is to the source. If water pollution occurs in the drinking water sample collected at the sampling point in the pipe network, it will have a greater impact on the entire drinking water delivery system. Therefore, the lower the level of the pipe network, the higher the level weight. Conversely, the higher the level of the pipe network, the closer to the end of the pipe network, the fewer users are affected, and the smaller the impact on the entire drinking water delivery system. Therefore, the higher the level of the pipe network, the lower the level weight. The flow ratio of the pipe network where the sampling point corresponding to the drinking water sample is located to the first-level pipe network can be used as the flow weight of the pipe network where the sampling point corresponding to the drinking water sample is located. The larger the flow of the pipe network, the greater the proportion of the amount of drinking water affected to the total amount of drinking water, and the greater the impact on the entire drinking water delivery system. Therefore, the above-mentioned level weight and flow weight can be multiplied to obtain the first weight of the drinking water sample.
[0053] In this way, the first weight of the drinking water sample can be determined by two aspects: the impact of the level of the pipeline network where the sampling point corresponding to the drinking water sample is located on the entire drinking water delivery system, and the impact of the flow rate of the pipeline network where the sampling point corresponding to the drinking water sample is located on the entire drinking water delivery system. The first weight can accurately reflect the impact of water quality pollution in the drinking water sample collected at the sampling point on the drinking water delivery system, thereby improving the accuracy and objectivity of the first weight.
[0054] According to one embodiment of the present invention, in step S103, each drinking water sample may include a certain amount of drinking water, and therefore, multiple microscope samples may be obtained from each drinking water sample. The amount of water in each drinking water sample is 1 liter, and samples may be taken from multiple points in the container of the drinking water sample. Each time a sample is taken, 0.1 ml of water sample may be taken to prepare a microscope sample. For example, 10 water samples may be taken from the drinking water sample, and 10 microscope samples may be prepared.
[0055] According to an embodiment of the present invention, in step S104, each microscope sample of each drinking water sample may be placed under a microscope with a preset magnification for observation, and a microscopic image under the field of view of the microscope may be captured.
[0056] According to an embodiment of the present invention, in step S105, the microscopic image may be processed to determine whether the microscopic image includes pollutants, such as suspended particles, microorganisms, etc.
[0057] According to one embodiment of the present invention, an image detection score for each microscope sample is obtained based on the microscope image, including: grayscale processing is performed on the microscope image to obtain a grayscale microscope image; a plurality of test lines are evenly set along the horizontal direction of the grayscale microscope image; and the image detection score for each microscope sample is determined based on the pixel values of the grayscale microscope image on the test lines and the test lines.
[0058] According to one embodiment of the present invention, the microscopic image can be grayed to obtain a grayscale microscopic image, thereby reducing the algorithm consumption required for image processing and making the edges of pollutants such as suspended particles and microorganisms more obvious, which is convenient for judging whether pollutants exist. Further, multiple test lines can be evenly set on the grayscale microscopic image, for example, each test line is parallel to the horizontal direction of the microscopic image, and the distance between adjacent test lines is ten pixels. The present invention does not limit the distance between adjacent test lines.
[0059] According to one embodiment of the present invention, the image detection score of each microscope sample is determined according to the pixel value of the grayscale microscopic image on the test line and the test line, including: for the sth test line of the jth microscopic image of the ith drinking water sample, according to formula (2), the gradient condition C is set g ,
[0060]
[0061] Among them, (x i,j,s,t ,y i,j,s,t ) is the t-th pixel point on the s-th test line of the j-th microscopic image of the ith drinking water sample, p(x i,j,s,t ,y i,j,s,t ) is the pixel value of the t-th pixel on the s-th test line of the j-th microscopic image of the ith drinking water sample, is the direction vector of the sth test line of the jth microscopic image of the ith drinking water sample, is the pixel value of the t-th pixel point on the s-th test line of the j-th microscopic image of the i-th drinking water sample along the direction vector The gradient of for The model, K p is a preset change rate threshold; among the multiple pixel points on the sth test line of the jth microscopic image of the i-th drinking water sample, determine the pixel points that meet the gradient condition C g The set of pixels Ω i,j,s According to formula (3), determine the image detection score S of the microscope sample of the jth microscopic image of the i-th drinking water sample D,i,j ,
[0062]
[0063]
[0064] Among them, p p is the preset pixel value threshold, P p is the preset ratio threshold, n is the number of pixels on each test line, t k For the set Ω i,j,s The kth pixel in is the number of the multiple pixels on the sth test line of the jth microscopic image of the i-th drinking water sample, t k+1 For the set Ω i,j,s The k+1th pixel in is the number of the multiple pixels on the sth test line of the jth microscopic image of the ith drinking water sample, and p(c) is the tth pixel on the sth test line of the jth microscopic image of the ith drinking water sample. k To t k+1 The pixel value of the cth pixel between pixels, For the set Ω i,j,s The number of pixels in, m is the number of test lines in each microscopic image, i, j, s, t, n, m, c, t k ,t k+1 and All are positive integers, if is the conditional function, and max is the maximum value function.
[0065] According to an embodiment of the present invention, the modulus of the gradient of the direction vector of the pixel point on the test line along the test line can represent the rate of change of the pixel value at the position of the pixel point along the direction described by the direction vector of the test line. Therefore, when the rate of change of the pixel value of a certain pixel point on the test line along the direction described by the direction vector of the test line is greater than or equal to a preset rate of change threshold, it can be indicated that the pixel value at the position of the pixel point on the test line and the pixel value of the next adjacent pixel point on the test line have changed significantly. Therefore, the position of the pixel point can be located at the edge of the pollutant, that is, each time a contaminant meeting the gradient condition C is detected on the test line, g , it means that the test line has crossed the edge of the pollutant once. Based on the above analysis, the set Ω i,j,s The pixel point in is the intersection of the sth test line of the jth microscopic image of the ith drinking water sample and the edges of multiple pollutants.
[0066] According to one embodiment of the present invention, in formula (3), the set Ω i,j,s The kth pixel point in the sth test line of the jth microscopic image of the ith drinking water sample is numbered t k , set Ω i,j,sThe k+1th pixel point in the sth test line of the jth microscopic image of the ith drinking water sample is numbered t k+1 , therefore, the tth line on the sth test line of the jth microscopic image of the ith drinking water sample k pixels and the tth k+1 Each pixel is the intersection of the sth test line of the jth microscopic image of the ith drinking water sample and the edge of the pollutant. The function value satisfies the condition In the case of t k+1 -t k , otherwise it is 0, where the conditional function if[p(c)≥p p ,1,0] when the function value satisfies the condition p(c)≥p p , otherwise it is 0, and p(c) is the tth value on the sth test line of the jth microscopic image of the ith drinking water sample. k pixels and the tth k+1 The pixel value of the cth pixel point between the pixels. If the pixel value is greater than or equal to the preset pixel value threshold, it indicates that the pixel point is within the range where the pollutant is located. Otherwise, it indicates that the pixel point is within the background range. Therefore, The value of is the tth test line on the jth microscopic image of the i-th drinking water sample. k pixels and the tth k+1 The number of pixels between pixels, the number of pixels within the range where the pollutants are located, It means the tth test line on the jth microscopic image of the ith drinking water sample k pixels and the tth k+1 The pixel points between the tth pixel points and the pixel points within the range where the pollutant is located are k pixels and the tth k+1 The ratio of the number of all pixels between the t pixels. If the ratio is greater than or equal to the preset ratio threshold, it indicates that the tth pixel k pixels and the tth k+1 The area between the pixels belongs to the range where the pollutant is located. At this time, the conditional function value t k+1 -t k represents the width of the pollutant detected by the sth test line of the jth microscopic image of the i-th drinking water sample. Therefore, The maximum value of the width of the pollutant detected by the sth test line of the jth microscopic image of the i-th drinking water sample can be used to represent the maximum size of the pollutant detected by the test line. It represents the ratio of the maximum size of the pollutant detected by the test line to the length of the test line, which can be used as the maximum relative size of the pollutant detected by the test line. The larger the maximum relative size value is, the larger the maximum size of the pollutant passed by the test line is, which also indicates that the pollution condition is more serious.
[0067] According to one embodiment of the present invention, in formula (3), the conditional function if[p(x i,j,s,t ,y i,j,s,t )≥p p ,1,0] when the function value satisfies the condition p(x i,j,s,t, yi ,j,s,t )≥p p 1 if , otherwise 0, so is the number of all pixels within the range of the sth test line of the jth microscopic image of the ith drinking water sample, It represents the ratio of all pixel points within the range on the sth test line of the jth microscopic image of the ith drinking water sample to all pixel points on the test line. The larger the ratio, the greater the number of pollutants passing through the test line, and the more serious the pollution condition.
[0068] According to one embodiment of the present invention, the maximum relative size of the pollutants detected by the above-mentioned test line can be multiplied by the proportion of all pixels on the test line that are within the range where the pollutants are located to all pixels on the test line, and a test line score that can describe both the size of the pollutants detected by the test line and the number of pollutants can be obtained. By summing up the scores of each test line, an image detection score that can describe both the size of the pollutants and the number of pollutants can be obtained.
[0069] In this way, the set of intersection points of the test line and the edge of the range where the pollutants are located can be obtained through the gradient of the pixel values of the pixels on the test line in the direction described by the direction vector of the test line, and then the maximum relative size of the pollutants crossed by the test line can be determined based on the intersection points in the set, and the proportion of all pixel points on the test line within the range to all pixel points on the test line can be obtained, thereby determining the image detection score that can describe both the pollutant size and the pollutant quantity, thereby improving the accuracy and objectivity of the image detection score.
[0070] According to one embodiment of the present invention, in step S106, the image detection score of each microscope sample can be obtained as above, but the weights of the drinking water samples to which each microscope sample belongs are different. Therefore, based on the image detection score of each microscope sample and the first weight, a drinking water quality visual detection score that can describe the water quality status of the visual detection aspect of the entire drinking water delivery system (i.e., detecting the pollutant content through a microscope) can be obtained.
[0071] According to one embodiment of the present invention, the visual detection score of drinking water quality is obtained according to the image detection score of each microscope sample and the first weight, including: according to formula (4), the visual detection score of drinking water quality S is obtained. v ,
[0072]
[0073] Among them, S D,i,j is the image detection score of the microscopic sample of the jth microscopic image of the i-th drinking water sample, n i is the number of microscopic images corresponding to the i-th drinking water sample, W i is the first weight of the i-th drinking water sample, N S is the number of sampling points, i≤N S , and i and N S All are positive integers.
[0074] According to one embodiment of the present invention, The average value of the image detection scores of multiple microscope samples of the ith drinking water sample can represent the visual detection score of the ith drinking water sample. The visual detection score of each drinking water sample can be weighted averaged by the first weight to obtain the visual detection score of drinking water quality. Therefore, based on the impact of pollutants in each drinking water sample on the entire drinking water delivery system and the microscope detection results of each drinking water sample itself, a visual detection score of drinking water quality that can accurately describe the water quality status of the visual detection of the entire drinking water delivery system can be obtained. The higher the visual detection score of drinking water quality, the more serious the pollution status in the entire drinking water delivery system.
[0075] In this way, a visual inspection score for drinking water quality can be obtained that can accurately describe the water quality status of the visual inspection of the entire drinking water delivery system through the impact of pollutants in each drinking water sample on the entire drinking water delivery system and the microscopic inspection results of each drinking water sample itself, thereby improving the accuracy and objectivity of the visual inspection score for drinking water quality.
[0076] According to one embodiment of the present invention, in step S107, a target drinking water sample that has passed the image detection may be determined from a plurality of drinking water samples based on the image detection score of each microscope sample. For example, a drinking water sample whose average value of the image detection scores of a plurality of microscope samples is lower than or equal to a set threshold may be selected as a target drinking water sample, or a drinking water sample whose number of microscope samples whose image detection scores are lower than or equal to a set threshold in a plurality of microscope samples of drinking water samples is higher than a set ratio threshold may be selected as a target drinking water sample. The present invention does not limit the specific method of screening the target drinking water sample. After the target drinking water sample is determined, the number ratio of the target drinking water sample in the drinking water sample may be determined.
[0077] According to one embodiment of the present invention, after determining that a target drinking water sample has passed image detection (i.e., fewer or no pollutants are detected under a microscope), a spectrometer can be used to detect whether the target drinking water sample contains dissolved pollutants, i.e., to detect content information of multiple harmful substances in the target drinking water sample.
[0078] According to one embodiment of the present invention, in step S108, the impact of each target drinking water sample on the entire drinking water delivery system is also different. Therefore, based on the first weight of each target drinking water sample and the content information of multiple harmful substances in the target drinking water sample, a drinking water quality spectral detection score that can accurately describe the water quality status of the spectral detection of the entire drinking water delivery system can be obtained.
[0079] According to one embodiment of the present invention, according to the content information of the harmful substance and the first weight, obtaining the drinking water quality spectrum detection score includes: determining the upper limit information of the content of various harmful substances; according to formula (5), obtaining the drinking water quality spectrum detection score S s ,
[0080]
[0081] Among them, C u,l is the content information of the lth harmful substance in the uth target drinking water sample, C l,p is the upper limit information of the content of the first type of harmful substance, W u is the first weight of the u-th target drinking water sample, N T is the number of target drinking water samples, n c is the number of types of hazardous substances, u≤N T , l≤n c , and i, l, n c and N T All are positive integers.
[0082] According to one embodiment of the present invention, in formula (5), the conditional function The function value satisfies the condition C u,l ≥C l,p In the case of Otherwise it is 0, that is, if the content information of the lth harmful substance in the uth target drinking water sample exceeds the upper limit information of the content of the lth harmful substance, the relative difference between the content information of the lth harmful substance and the upper limit information of the content of the lth harmful substance is taken as the conditional function value. In this case, the higher the content information of the lth harmful substance, the greater the conditional function value. Conversely, if the content information of the lth harmful substance is lower than the upper limit information of the content of the lth harmful substance, the conditional function value is 0. Indicates that the maximum value of the conditional function values corresponding to multiple harmful substances is taken as the spectral detection score of the u-th target drinking water sample, so as to be used to indicate the pollution status of the most serious one of the multiple harmful substances that pollutes drinking water. Furthermore, the spectral detection scores of each target drinking water sample can be weighted averaged by the first weight to obtain the drinking water quality spectral detection score, so that based on the impact of the harmful substances in each target drinking water sample on the entire drinking water delivery system and the spectral detection results of each drinking water sample itself, a drinking water quality spectral detection score that can accurately describe the water quality status of the spectral detection of the entire drinking water delivery system can be obtained. The higher the drinking water quality spectral detection score, the more serious the pollution status of the harmful substances in the entire drinking water delivery system.
[0083] In this way, the drinking water quality spectral detection score can be obtained by considering the impact of harmful substances in each target drinking water sample on the entire drinking water delivery system and the spectral detection results of each drinking water sample itself, which can accurately describe the water quality status of the entire drinking water delivery system in terms of spectral detection, thereby improving the accuracy and objectivity of the drinking water quality spectral detection score.
[0084] According to one embodiment of the present invention, in step S109, a drinking water quality score is obtained according to the proportion of the target drinking water sample in the drinking water sample, the drinking water quality visual detection score and the drinking water quality spectral detection score, including: obtaining a drinking water quality score S according to formula (6),
[0085]
[0086] Among them, S v S is the visual inspection score of the drinking water quality, S s is the drinking water quality spectrum detection score, P s is the proportion of target drinking water samples in drinking water samples, and α and β are preset weights.
[0087] According to one embodiment of the present invention, in formula (6), since the drinking water quality spectral detection score is a score obtained for multiple target drinking water samples, not a score obtained for all drinking water samples, and since the non-target drinking water samples are drinking water samples that fail the image detection, in this case, it can be assumed that the spectral detection of the non-target drinking water samples also fails. Therefore, As the drinking water quality spectral detection score obtained based on all drinking water samples. Further, the drinking water quality visual detection score and the drinking water quality spectral detection score obtained based on all drinking water samples can be weighted and summed to obtain the drinking water quality score, so as to comprehensively evaluate the water quality status of the entire drinking water delivery system from the two aspects of visual detection and spectral detection. The higher the drinking water quality score, the worse the water quality status and the more serious the pollution.
[0088] In this way, the drinking water quality spectral detection score obtained for the target drinking water sample can be first converted into a drinking water quality spectral detection score obtained based on all drinking water samples, so that the data basis of the drinking water quality visual detection score and the drinking water quality spectral detection score are consistent and horizontally comparable, thereby improving the accuracy and scientificity of the drinking water quality score. In addition, the water quality status of the entire drinking water delivery system can be comprehensively evaluated from two aspects: visual detection and spectral detection, thereby improving the objectivity and comprehensiveness of the drinking water quality score.
[0089] According to the drinking water quality monitoring method of the embodiment of the present invention, multiple sampling points can be set in the multi-level pipe network of drinking water, and the first weight of the drinking water samples obtained at each sampling point can be set based on the level of the pipe network, so that in the process of drinking water quality monitoring, the transportation process of drinking water can be monitored in all directions, and the influence of each stage of the transportation process on the drinking water quality can be objectively described. In addition, the water quality of drinking water can be comprehensively and accurately evaluated through the visual detection score of drinking water quality and the spectral detection score of drinking water quality, thereby improving the objectivity and accuracy of drinking water quality monitoring. When determining the first weight, the first weight of the drinking water sample can be determined by the influence of the level of the pipe network where the sampling point corresponding to the drinking water sample is located on the entire drinking water delivery system, and the influence of the flow rate of the pipe network where the sampling point corresponding to the drinking water sample is located on the entire drinking water delivery system, so that the first weight can accurately reflect the influence of water quality pollution in the drinking water sample collected at the sampling point on the drinking water delivery system, thereby improving the accuracy and objectivity of the first weight. When determining the image detection score, the set of intersections between the test line and the edge of the range where the pollutant is located can be obtained by the gradient of the pixel values of the pixels on the test line in the direction described by the direction vector of the test line, and then the maximum relative size of the pollutant crossed by the test line can be determined based on the intersections in the set, and the number ratio of all the pixels on the test line that are in the range to all the pixels on the test line can be obtained, so as to determine the image detection score that can describe both the size and the number of pollutants, thereby improving the accuracy and objectivity of the image detection score. When determining the visual detection score of drinking water quality, the visual detection score of drinking water quality that can accurately describe the water quality status of the visual detection of the entire drinking water delivery system can be obtained by the influence of the pollutants in each drinking water sample on the entire drinking water delivery system and the microscope detection results of each drinking water sample itself, thereby improving the accuracy and objectivity of the visual detection score of drinking water quality. When determining the spectral detection score of drinking water quality, the spectral detection score of drinking water quality that can accurately describe the water quality status of the spectral detection of the entire drinking water delivery system can be obtained by the influence of the harmful substances in each target drinking water sample on the entire drinking water delivery system and the spectral detection results of each drinking water sample itself, thereby improving the accuracy and objectivity of the spectral detection score of drinking water quality. When determining the drinking water quality score, the drinking water quality spectral detection score obtained for the target drinking water sample can be first converted into a drinking water quality spectral detection score based on all drinking water samples, so that the data basis of the drinking water quality visual detection score and the drinking water quality spectral detection score are consistent and horizontally comparable, thereby improving the accuracy and scientific nature of the drinking water quality score. In addition, the water quality status of the entire drinking water delivery system can be comprehensively evaluated from two aspects: visual detection and spectral detection, thereby improving the objectivity and comprehensiveness of the drinking water quality score.
[0090] Figure 2 A block diagram of a drinking water quality monitoring system according to an embodiment of the present invention is exemplarily shown, the system comprising:
[0091] The sampling point module is used to set multiple sampling points in the multi-level pipe network of drinking water, and collect drinking water samples through the sampling points in each level of the pipe network;
[0092] A first weight module, used to determine a first weight of the drinking water sample according to the level of the pipe network to which the sampling point corresponding to the drinking water sample belongs;
[0093] A sampling module, used for sampling each of the drinking water samples to obtain a plurality of microscope samples corresponding to each drinking water sample;
[0094] An observation module, used to observe multiple microscope samples of each drinking water sample through a microscope with a preset magnification, and obtain a microscopic image of each microscope sample;
[0095] An image detection and scoring module, used to obtain an image detection score for each microscope sample based on the microscope image;
[0096] A drinking water quality visual detection scoring module, used to obtain a drinking water quality visual detection score based on the image detection score of each microscope sample and the first weight;
[0097] A content information module is used to determine a target drinking water sample that has passed the image detection among multiple drinking water samples according to the image detection score of each microscope sample, and detect the content information of multiple harmful substances in the target drinking water sample through a spectrometer;
[0098] A drinking water quality spectrum detection scoring module, used to obtain a drinking water quality spectrum detection score according to the harmful substance content information and the first weight;
[0099] The drinking water quality scoring module is used to obtain a drinking water quality score based on the quantitative proportion of the target drinking water sample in the drinking water sample, the drinking water quality visual detection score and the drinking water quality spectral detection score.
[0100] According to one embodiment of the present invention, there is provided a drinking water quality monitoring device, comprising: a processor; a memory for storing instructions executable by the processor; wherein the processor is configured to call the instructions stored in the memory to execute the drinking water quality monitoring method.
[0101] According to one embodiment of the present invention, there is provided a computer-readable storage medium having computer program instructions stored thereon, wherein the computer program instructions implement the drinking water quality monitoring method when executed by a processor.
[0102] The present invention may be a method, an apparatus, a system and / or a computer program product. The computer program product may include a computer-readable storage medium carrying computer-readable program instructions for executing various aspects of the present invention.
[0103] It should be understood by those skilled in the art that the embodiments of the present invention described above and shown in the accompanying drawings are only examples and do not limit the present invention. The purpose of the present invention has been fully and effectively achieved. The functional and structural principles of the present invention have been demonstrated and explained in the embodiments, and the embodiments of the present invention may be deformed or modified in any way without departing from the principles.
[0104] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein with equivalents. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for monitoring drinking water quality, characterized in that: include: Set up multiple sampling points in the multi-level drinking water pipe network, and collect drinking water samples through the sampling points in each level of the pipe network; Determine a first weight of the drinking water sample according to the level of the pipe network to which the sampling point corresponding to the drinking water sample belongs; Sampling each of the drinking water samples to obtain a plurality of microscope samples corresponding to each drinking water sample; observing a plurality of microscope samples of each drinking water sample through a microscope of a preset magnification, and obtaining a microscopic image of each microscope sample; According to the microscopic image, obtaining an image detection score for each microscopic sample; Obtaining a visual inspection score for drinking water quality according to the image inspection score of each microscope sample and the first weight; According to the image detection score of each microscope sample, a target drinking water sample that has passed the image detection is determined from multiple drinking water samples, and the content information of multiple harmful substances in the target drinking water sample is detected by a spectrometer; Obtaining a drinking water quality spectrum detection score according to the harmful substance content information and the first weight; A drinking water quality score is obtained based on the quantitative proportion of the target drinking water samples in the drinking water samples, the drinking water quality visual detection score and the drinking water quality spectral detection score.
2. The drinking water quality monitoring method according to claim 1, characterized in that: According to the level of the pipe network to which the sampling point corresponding to the drinking water sample belongs, the first weight of the drinking water sample is determined, including: Obtain design parameters for multiple levels of pipe networks; According to the design parameters of multiple levels of pipe networks, the flow ratio between the pipe network where each sampling point is located and the primary pipe network is determined; The first weight of the drinking water sample is determined according to the flow ratio and the level of the pipe network to which the sampling point corresponding to the drinking water sample belongs.
3. The drinking water quality monitoring method according to claim 2, characterized in that: Determining a first weight of the drinking water sample according to the flow ratio and the level of the pipe network to which the sampling point corresponding to the drinking water sample belongs includes: According to the formula Determine the first weight W of the i-th drinking water sample i , where P i is the flow ratio between the pipe network where the sampling point corresponding to the i-th drinking water sample is located and the primary pipe network, N is the maximum value of the pipe network level, L i is the level of the pipe network to which the sampling point corresponding to the i-th drinking water sample belongs, L i ≤N, and L i and N are both positive integers.
4. The drinking water quality monitoring method according to claim 1, characterized in that: According to the microscopic image, an image detection score of each microscopic sample is obtained, including: grayscale processing is performed on the microscopic image to obtain a grayscale microscopic image; A plurality of test lines are evenly arranged along the lateral direction of the grayscale microscopic image; An image detection score for each microscope sample is determined based on the pixel value of the grayscale microscopic image on the test line and the test line.
5. The drinking water quality monitoring method according to claim 4, characterized in that: Determining an image detection score for each microscope sample according to the pixel value of the grayscale microscope image on the test line and the test line, including: For the sth test line of the jth microscopic image of the ith drinking water sample, according to the formula Set the gradient condition C g , where (x i,j,s,t ,y i,j,s,t ) is the t-th pixel point on the s-th test line of the j-th microscopic image of the ith drinking water sample, p(x i,j,s,t ,y i,j,s,t ) is the pixel value of the t-th pixel on the s-th test line of the j-th microscopic image of the ith drinking water sample, is the direction vector of the sth test line of the jth microscopic image of the ith drinking water sample, is the pixel value of the t-th pixel point on the s-th test line of the j-th microscopic image of the ith drinking water sample along the direction vector The gradient of for The model, K p is a preset change rate threshold; Among the multiple pixel points on the sth test line of the jth microscopic image of the i-th drinking water sample, determine the pixel points that meet the gradient condition C g The set of pixels Ω i,j,s ; According to the formula Determine the image detection score S of the microscope sample for the jth microscopic image of the i-th drinking water sample D,i,j , where p p is the preset pixel value threshold, P p is the preset ratio threshold, n is the number of pixels on each test line, t k For the set Ω i,j,s The kth pixel in is the number of the multiple pixels on the sth test line of the jth microscopic image of the i-th drinking water sample, t k+1 For the set Ω i,j,s The k+1th pixel in is the number of the multiple pixels on the sth test line of the jth microscopic image of the ith drinking water sample, and p(c) is the tth pixel on the sth test line of the jth microscopic image of the ith drinking water sample. k To t k+1 The pixel value of the cth pixel between pixels, For the set Ω i,j,s The number of pixels in, m is the number of test lines in each microscopic image, i, j, s, t, n, m, c, t k ,t k+1 and All are positive integers, if is the conditional function, and max is the maximum value function.
6. The drinking water quality monitoring method according to claim 1, characterized in that: According to the image detection score of each microscope sample and the first weight, a visual detection score of drinking water quality is obtained, including: According to the formula Obtain drinking water quality visual inspection score S v , where S D,i,j is the image detection score of the microscopic sample of the jth microscopic image of the i-th drinking water sample, n i is the number of microscopic images corresponding to the i-th drinking water sample, W i is the first weight of the i-th drinking water sample, N S is the number of sampling points, i≤N S , and i and N S All are positive integers.
7. The drinking water quality monitoring method according to claim 1, characterized in that: Obtaining a drinking water quality spectrum detection score according to the harmful substance content information and the first weight, including: Determine the upper limit information of various harmful substances; According to the formula Obtain drinking water quality spectrum detection score S s , where C u,l is the content information of the lth harmful substance in the uth target drinking water sample, C l,p is the upper limit of the content of the first type of harmful substance, W u is the first weight of the u-th target drinking water sample, N T is the number of target drinking water samples, n c is the number of types of hazardous substances, u≤N T , l≤n c , and i, l, n c and N T All are positive integers.
8. The method for monitoring drinking water quality according to claim 1, characterized in that: The drinking water quality score is obtained according to the proportion of the target drinking water sample in the drinking water sample, the visual detection score of the drinking water quality and the spectral detection score of the drinking water quality, including: According to the formula Get the drinking water quality score S, where S v S is the visual inspection score of the drinking water quality, S s is the spectrum detection score of the drinking water quality, P s is the proportion of target drinking water samples in drinking water samples, and α and β are preset weights.
9. A drinking water quality monitoring system, characterized in that: include: The sampling point module is used to set multiple sampling points in the multi-level pipe network of drinking water, and collect drinking water samples through the sampling points in each level of the pipe network; A first weight module, used to determine a first weight of the drinking water sample according to the level of the pipe network to which the sampling point corresponding to the drinking water sample belongs; A sampling module, used for sampling each of the drinking water samples to obtain a plurality of microscope samples corresponding to each drinking water sample; An observation module, used to observe multiple microscope samples of each drinking water sample through a microscope with a preset magnification, and obtain a microscopic image of each microscope sample; An image detection and scoring module, used to obtain an image detection score for each microscope sample based on the microscope image; A drinking water quality visual detection scoring module, used to obtain a drinking water quality visual detection score based on the image detection score of each microscope sample and the first weight; A content information module is used to determine a target drinking water sample that has passed the image detection among multiple drinking water samples according to the image detection score of each microscope sample, and detect the content information of multiple harmful substances in the target drinking water sample through a spectrometer; A drinking water quality spectrum detection scoring module, used to obtain a drinking water quality spectrum detection score according to the harmful substance content information and the first weight; The drinking water quality scoring module is used to obtain a drinking water quality score based on the quantitative proportion of the target drinking water sample in the drinking water sample, the drinking water quality visual detection score and the drinking water quality spectral detection score.
10. A drinking water quality monitoring device, characterized in that: include: processor; A memory for storing processor-executable instructions; wherein the processor is configured to call the instructions stored in the memory to execute the method according to any one of claims 1-8.
Citation Information
Cited By
Water environment detection method based on photoelectrons
CN120028256A
