Drainage system detection method based on image processing
By constructing a drainage network model and pipe endoscopy device for the drainage system, a visual detection interface is generated to identify and eliminate blockages, solving the problem of difficulty in comprehensively evaluating the drainage system in existing technologies and achieving efficient and accurate pipe detection and blockage cleaning.
Patent Information
- Application Number
- CN202510633727.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-16
- Publication Date
- 2025-10-03
- Estimated Expiration
- 2045-05-16
AI Technical Summary
Existing drainage system detection technology makes it difficult to achieve a comprehensive assessment of pipeline status. It is unable to identify and locate blockages, mixed connections in pipeline systems, combined rainwater and sewage, structural and functional defects in pipelines in real time, and lacks a comprehensive analysis of pipeline status.
Construct a drainage network model of the drainage system, use a pipe endoscope device to obtain pipe images and location information, generate a drainage detection interface, identify the blockage area, and use automatic obstacle avoidance strategies and blockage attribute judgments to eliminate blockages using through-cleaning or grasping cleaning strategies, and generate a twin model to display the blockage location.
It improves the accuracy and efficiency of drainage system inspection, realizes the timely identification and positioning of blockages, generates a visual inspection interface, intelligently identifies and clears blockages, and ensures the smooth passage and inspection safety of the pipeline endoscope device.
Smart Images

Figure CN120472145B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to data processing technology, and in particular to a drainage system detection method based on image processing. Background Art
[0002] The drainage system is an engineering facility system that treats and removes urban sewage and rainwater. It is an integral part of urban public facilities. The drainage system planning is an integral part of the city's overall planning. The drainage system is usually composed of drainage pipes and sewage treatment plants. When the sewage and rainwater diversion system is implemented, sewage is collected by drainage pipes, sent to sewage treatment, and then discharged into water bodies or recycled. Rainwater runoff is collected by drainage pipes and discharged into nearby water bodies. Therefore, it is very important to test the drainage system to ensure the correct operation of the urban drainage system.
[0003] Existing drainage system inspection technologies typically rely on manual inspections or simple monitoring equipment, making it difficult to achieve a comprehensive assessment of pipeline status. Existing technologies have limited processing capabilities for pipeline images and are unable to identify and locate blockages, misconnected pipe systems, combined rainwater and sewage systems, structural and functional defects in pipes in real time. Furthermore, they generally lack a comprehensive analysis of pipeline status. Furthermore, existing systems struggle to accurately generate clear inspection interfaces when faced with complex pipe structures, making subsequent operational and maintenance decisions difficult.
[0004] Therefore, how to conduct actual inspections of drainage pipes, timely identify and locate blockages, combined pipe sections, misconnections of rainwater and sewage, and pipeline defects, and improve the accuracy and efficiency of drainage system inspections has become an urgent problem that needs to be solved. Summary of the Invention
[0005] The present invention provides a drainage system detection method based on image processing, which can perform actual detection of drainage pipes, timely identify and locate blockages, and improve the accuracy and efficiency of drainage system detection.
[0006] A first aspect of the present invention provides a drainage system detection method based on image processing, comprising:
[0007] Constructing a drainage network model for each sub-area of the drainage system, controlling a pipe endoscope device to obtain a pipe image of the drainage pipe in the sub-area, retrieving position information of the pipe endoscope device, and generating a drainage detection interface based on the pipe image, the drainage network model, and the position information;
[0008] When it is determined that the pipeline image in the drainage detection interface has a blockage, a blockage area corresponding to the blockage is identified, and a conditional area of the pipeline endoscopy device is determined based on an automatic obstacle avoidance strategy and the blockage area;
[0009] Comparing the conditional area with the preset restricted area to obtain an area comparison result, and when it is determined that the area comparison result is an area prohibition result, eliminating the congestion area according to the congestion elimination strategy to obtain a passable area;
[0010] The pipeline endoscope device is controlled to pass through the passage area, and the blockage position of the blockage is recorded, the blockage position is updated to the position display model in the drainage detection interface, and a drainage feedback model is generated and sent to the management end.
[0011] Optionally, in a possible implementation of the first aspect, constructing a drainage network model for each sub-area in the drainage system, controlling a pipe endoscopy device to obtain a pipe image of the drainage pipe in the sub-area, retrieving position information of the pipe endoscopy device, and generating a drainage detection interface based on the pipe image, the drainage network model, and the position information, includes:
[0012] Acquire multiple sub-areas corresponding to the drainage system, each of which has a corresponding drainage network pipe, and construct a twin model corresponding to the drainage network pipe as a drainage network pipe model of the sub-area;
[0013] controlling the pipeline endoscope device to obtain a pipeline image of the drainage pipeline in the sub-area, retrieving position information of the pipeline endoscope device as a detection position, and determining the corresponding sub-area as a detection area based on the detection position;
[0014] Determine a drainage network management model corresponding to the detection area as the detection network management model, update the detection position to the detection network management model, generate a position display model, and call the virtual pipe at the detection position in the position display model as the detection pipe;
[0015] Retrieving an initial display interface, connecting the midpoints of the upper and lower boundary lines of the initial display interface to obtain an interface dividing line, and dividing the initial display interface based on the interface dividing line to obtain an endoscopy display area on the left and a position display area on the right;
[0016] The position display area is divided into three areas from top to bottom, with the upper area being the area display area, the middle area being the detection display area, and the lower area being the pipeline display area;
[0017] The pipeline image is updated to the endoscopy display area, the detection area is updated to the area display area, the position display model is updated to the detection display area, and the detection pipeline is updated to the pipeline display area to generate a drainage detection interface.
[0018] Optionally, in a possible implementation of the first aspect, when determining that the pipeline image in the drainage detection interface has a blockage, identifying a blockage area corresponding to the blockage, and determining a conditional area of the pipeline endoscopy device based on an automatic obstacle avoidance strategy and the blockage area, includes:
[0019] When it is determined that the pipe image in the drainage detection interface has a blockage, identifying a blockage area corresponding to the blockage;
[0020] Obtaining a horizontal transverse diameter of a circular pipe area corresponding to the pipe image as a cut-off diameter, and dividing the circular pipe area according to the cut-off diameter to obtain a walking area located on the lower side;
[0021] Determine a lower congestion area according to the intersection of the walking area and the congestion area, obtain an area to be selected based on a difference set between the walking area and the lower congestion area, and obtain the number of areas in the area to be selected;
[0022] When it is determined that the number of regions is equal to 1, the corresponding region to be selected is used as a conditional region of the pipeline endoscopy device;
[0023] When it is determined that the number of regions is greater than 1, the conditional region of the pipeline endoscopy device is obtained according to the selection coordinates of the regions to be selected and the number of regions to be selected.
[0024] Optionally, in a possible implementation of the first aspect, when determining that the number of regions is greater than 1, obtaining the conditional region of the pipeline endoscopy device according to the selection coordinates and the number of regions to be selected includes:
[0025] When it is determined that the number of regions is greater than 1, the center point of the circular pipe region is used as the coordinate origin, a horizontal axis of the coordinate system is constructed at the intercepted diameter, and a vertical axis of the coordinate system is constructed perpendicular to the horizontal axis of the coordinate system to generate a selected coordinate system, and coordinate processing is performed on the pipe image based on the selected coordinate system;
[0026] Obtaining the minimum vertical coordinate of the walking area in the selected coordinate system as the longitudinal center of gravity value, and obtaining the horizontal coordinate corresponding to the coordinate origin in the selected coordinate system as the transverse center of gravity value;
[0027] Determine the coordinates of the center point of the area corresponding to the to-be-selected area as the selection coordinates, use the abscissa in the selection coordinates as the selection horizontal value, and use the ordinate in the selection coordinates as the selection vertical value;
[0028] obtaining a lateral center of gravity deviation value based on an absolute value of a difference between the selected lateral value and the lateral center of gravity value, and obtaining a longitudinal center of gravity deviation value based on a difference between the selected longitudinal value and the longitudinal center of gravity value;
[0029] Obtaining a device deviation value based on the sum of the horizontal center-of-gravity deviation value and the longitudinal center-of-gravity deviation value, and counting the number of pixels in the corresponding area to be selected as the number to be selected;
[0030] Calculating according to the device deviation value and the number to be selected, to obtain a condition coefficient corresponding to the area to be selected;
[0031] The to-be-selected area corresponding to the largest condition coefficient is selected as the condition area of the pipeline endoscopy device.
[0032] Optionally, in a possible implementation of the first aspect, the comparing the conditional area with a preset restricted area to obtain an area comparison result, and when it is determined that the area comparison result is an area prohibition result, eliminating the congested area according to a congestion elimination strategy to obtain a passable area, includes:
[0033] Retrieving a preset restricted area, and aligning the area center point of the preset restricted area with the area center point of the conditional area;
[0034] Obtaining an intersection area according to the intersection of the preset restricted area and the conditional area, and obtaining an area pass result when it is determined that the intersection area is consistent with the preset restricted area, and using the conditional area as the pass area;
[0035] When it is determined that the intersection area is inconsistent with the preset restricted area, a regional prohibition result is obtained, and a regional comparison result is obtained based on the regional passage result and the regional prohibition result;
[0036] When it is determined that the area comparison result is a no-travel result, obtaining the blocking attribute of the blocking object, the blocking attribute including a soft attribute and a solid attribute;
[0037] When it is determined that the congestion attribute is a soft attribute, the congestion area is cleared according to a clearing strategy to obtain a passable area;
[0038] When the congestion attribute is determined to be a solid attribute, the congestion area is subjected to a grabbing and eliminating process according to a grabbing and clearing strategy to obtain a passable area. The congestion elimination strategy includes a through-clearing strategy and the grabbing and clearing strategy.
[0039] Optionally, in a possible implementation of the first aspect, when determining that the congestion attribute is a soft attribute, performing a through-clearing process on the congested area according to a through-clearing strategy to obtain a passable area includes:
[0040] When it is determined that the congestion attribute is a soft attribute, a plurality of to-be-penetrated areas corresponding to the congestion area are obtained according to a difference set between the preset restricted area and the intersection area;
[0041] Taking the areas to be penetrated as selected areas in turn, deleting the selected areas from the blocked areas respectively, to obtain a simulated walking area;
[0042] Aligning the center point of the preset restricted area with the center point of the simulated walking area, and obtaining a simulated intersection area according to the intersection of the preset restricted area and the simulated walking area;
[0043] Based on the difference set between the preset restricted area and the simulated intersection area, a plurality of simulated areas to be penetrated corresponding to the selected area are obtained, and the areas of the plurality of simulated areas to be penetrated are counted to obtain a selection area corresponding to each of the selected areas;
[0044] Selecting a selected area corresponding to the smallest selected area as a penetration area, controlling the pipeline endoscopy device to perform a penetration elimination process on the penetration area, and obtaining a current conditional area;
[0045] Align the area center point of the preset restricted area with the area center point of the current conditional area, obtain the current intersection area based on the intersection of the preset restricted area and the current conditional area, repeat the above steps until the current intersection area is consistent with the preset restricted area, and use the current conditional area as the pass area.
[0046] Optionally, in a possible implementation of the first aspect, when determining that the congestion attribute is a solid attribute, performing a grabbing and clearing process on the congested area according to a grabbing and clearing strategy to obtain a passable area includes:
[0047] When the blockage attribute is determined to be a solid attribute, a blockage contour of the blockage is identified based on OpenCV, and coordinates of contour pixels in the blockage contour are obtained as contour coordinates;
[0048] Obtaining a horizontal distance based on a difference between a maximum horizontal coordinate and a minimum horizontal coordinate in the contour coordinates, and obtaining a vertical distance based on a difference between a maximum vertical coordinate and a minimum vertical coordinate in the contour coordinates;
[0049] Obtaining a direction difference value based on an absolute value of a difference between the horizontal distance and the longitudinal distance;
[0050] When it is determined that the directional difference value is greater than a preset difference value, the corresponding blockage contour is used as a strip blockage contour, an edge grabbing position of the pipeline endoscope device is determined based on the strip blockage contour, and the pipeline endoscope device is controlled to perform a grabbing and clearing process on the edge grabbing position to obtain a passage area;
[0051] When it is determined that the directional gap value is less than or equal to the preset gap value, the corresponding blockage contour is used as a block blockage contour, and the intermediate grabbing position of the pipeline endoscopy device is determined based on the block blockage contour. The pipeline endoscopy device is controlled to grab and clear the intermediate grabbing position to obtain a pass area.
[0052] Optionally, in a possible implementation of the first aspect, when determining that the directional difference value is greater than a preset difference value, taking the corresponding blockage profile as a strip blockage profile, determining an edge grabbing position of a pipeline endoscope device based on the strip blockage profile, and controlling the pipeline endoscope device to perform a grabbing and clearing process on the edge grabbing position to obtain a passage area, including:
[0053] When it is determined that the directional difference value is greater than the preset difference value, the corresponding blockage profile is used as a strip blockage profile;
[0054] Acquire multiple contact contour lines between the strip-shaped blockage contour and the circular pipe area, count the number of pixel points corresponding to contour pixels of each contact contour line, and obtain the number of contacts corresponding to each contact contour line;
[0055] Selecting a contact contour line corresponding to the minimum number of contacts as a grasping position contour line, and using the position of the grasping position contour line as the edge grasping position of the pipeline endoscope device;
[0056] The pipeline endoscope device is controlled to perform a grabbing and clearing process on the edge grabbing position to obtain a passage area.
[0057] Optionally, in a possible implementation of the first aspect, when determining that the directional difference value is less than or equal to a preset difference value, taking the corresponding blockage contour as a block blockage contour, determining an intermediate grabbing position of the pipeline endoscopy device based on the block blockage contour, and controlling the pipeline endoscopy device to perform a grabbing and clearing process on the intermediate grabbing position to obtain a passage area, including:
[0058] When it is determined that the directional difference value is less than or equal to the preset difference value, the corresponding blocking contour is used as a block blocking contour;
[0059] Acquire multiple contact contour lines between the block-shaped blockage contour and the circular pipe area, and delete the contact contour lines in the block-shaped blockage contour to obtain multiple remaining contour lines;
[0060] Counting the number of contour pixels corresponding to each of the remaining contour lines to obtain the number of remaining pixels corresponding to each of the remaining contour lines;
[0061] Select the remaining contour lines whose number of remaining pixel points is greater than the preset capture number as contour lines to be processed, obtain the straight line segments in each of the contour lines to be processed, use the contour pixel points corresponding to the straight line segments as straight line contour points, and obtain the number of straight line contour points corresponding to each of the straight line segments as the number of straight line pixel points;
[0062] A straight line segment with a number of straight line pixels greater than or equal to a preset grab number is used as a grabbable line segment, endpoints on both sides of the grabbable line segment are obtained as construction endpoints, and an intercept perpendicular line perpendicular to the grabbable line segment is constructed based on the construction endpoints;
[0063] intercepting the contour line to be processed according to the intercepted vertical lines to obtain a grabbing screening line located between the intercepted vertical lines, and counting the number of straight contour points in the grabbing screening line as the actual grabbing number;
[0064] Selecting a grabbing screening line corresponding to the largest actual grabbing quantity as an actual grabbing line, and using the position of the actual grabbing line as the middle grabbing position of the pipeline endoscopy device;
[0065] The pipeline endoscope device is controlled to perform a grabbing and clearing process on the intermediate grabbing position to obtain a passage area.
[0066] Optionally, in a possible implementation of the first aspect, the method further includes:
[0067] When it is determined that the pipeline image has water accumulation anomaly, retrieving water accumulation pixel values, and marking the water level of the pipeline image based on the water accumulation pixel values to obtain a water accumulation mark line;
[0068] Obtaining the center point of the pipeline image based on OpenCV, and performing coordinate processing on the pipeline image using the center point as the coordinate origin;
[0069] Obtaining the midpoint of the water accumulation mark line as the midpoint of the water accumulation line, and drawing a perpendicular line perpendicular to the water accumulation mark line based on the midpoint of the water accumulation line to obtain a water accumulation perpendicular line;
[0070] The intersection of the vertical line of accumulated water and the upper boundary of the circular pipe area is defined as the pipe vertex, and the intersection of the vertical line of accumulated water and the lower boundary of the circular pipe area is defined as the pipe base point;
[0071] Connect the pipeline base point and the midpoint of the accumulated water to obtain a water depth line, and obtain the accumulated water depth based on the water depth line;
[0072] When it is determined that the accumulated water depth is greater than the acquisition height, obtaining a difference between the accumulated water depth and the acquisition height to obtain a diving height;
[0073] According to the sum of the diving height and the standard collection height, the corresponding adjustment height of the collection device on the pipeline endoscopy device is obtained, and the collection device is controlled to be vertically raised based on the adjustment height.
[0074] According to a third aspect of the present invention, an electronic device is provided, comprising: a memory, a processor, and a computer program, wherein the computer program is stored in the memory, and the processor runs the computer program to execute the first aspect of the present invention and various methods that may be involved in the first aspect.
[0075] According to a fourth aspect of the present invention, a storage medium is provided, in which a computer program is stored. When the computer program is executed by a processor, it is used to implement the first aspect of the present invention and various methods that may be involved in the first aspect.
[0076] The beneficial effects of the present invention are as follows:
[0077] 1. The present invention can conduct actual inspections on urban drainage pipes, identify and locate blockages in a timely manner, and improve the accuracy of drainage system inspections. At the same time, it can generate a corresponding twin model, mark and display the blockage location, facilitate intuitive viewing by personnel, and improve pipeline inspection efficiency. First, the present invention can construct a drainage network model of the corresponding sub-area based on the drainage system, and control the pipeline endoscope device to detect the drainage pipe and collect pipeline images, thereby generating a drainage inspection interface so that relevant personnel can view the corresponding pipeline inspection information in a timely manner. Secondly, when determining that there is a blockage in the pipeline image, the present invention can extract the blockage area corresponding to the blockage, and analyze the conditional area that the pipeline endoscope device can clear. Then, the blockage area can be eliminated to obtain the passage area, so that the pipeline endoscope device passes through the passage area, thereby improving pipeline inspection efficiency, and recording the blockage location and updating it in the position display model to obtain a drainage feedback model for intuitive viewing by management personnel.
[0078] 2. The present invention can generate a visual drainage system detection interface, and intelligently identify and clean blockages, thereby improving personnel's review of detection results and ensuring the detection efficiency of the device in the pipeline. The present invention generates a visual drainage detection interface by constructing a digital twin model of the drainage system, combining the real-time images and position information collected by the pipeline endoscopy device, wherein the endoscopy display area displays the collected images inside the pipeline in real time, and the position display area can intuitively present the regional location, model information and detailed structure of the detection pipeline through multi-level information display of the regional display area, detection display area and pipeline display area. Through this multi-dimensional visual interface, management personnel can quickly locate the detection area, clarify the detection status and problem location of the pipeline, and greatly improve the readability and management efficiency of the detection information. In addition, after the present invention detects the presence of blockages in the drainage pipeline, Through image recognition technology, the blocked area is accurately divided and the properties of the blockage (soft or solid) are determined. For soft blockages, a through-clearing strategy is adopted. By simulating the analysis of the walking area and the area to be penetrated, the through-clearing path with the lowest cleaning cost is dynamically planned to achieve rapid cleaning. For solid blockages, OpenCV technology is used to identify the blockage outline, and a reasonable grasping position is determined through a grasping and cleaning strategy, such as the edge grasping position or the middle grasping position. The pipeline endoscope device is intelligently controlled to complete the grasping and clearing. The intelligent identification and targeted cleaning strategy effectively improve the efficiency and flexibility of pipeline blockage cleaning, avoid ineffective cleaning operations, and ensure the smooth passage of the pipeline endoscope device.
[0079] 3. The present invention can adjust the height of the device in real time when abnormal water accumulation occurs in the pipeline to ensure that the pipeline endoscope device can safely detect the drainage pipeline. Among them, when determining the abnormal water accumulation in the pipeline, the present invention accurately calculates the water depth by coordinate processing of the pipeline image and marking the water depth, combined with the geometric characteristics of the circular pipeline area. When the water depth exceeds the height of the acquisition device, the system automatically calculates the required height adjustment and controls the acquisition device to increase and adjust it so that it safely avoids the water accumulation area and continues to complete the detection task. This not only ensures the normal operation of the pipeline endoscope device, but also enhances the system's adaptability in complex water accumulation environments, further improving the detection efficiency and reliability of water accumulation problems in drainage pipes. BRIEF DESCRIPTION OF THE DRAWINGS
[0080] Figure 1 This is a flow chart of a drainage system detection method based on image processing provided by the present invention;
[0081] Figure 2 A schematic diagram of the distribution of drainage network pipes provided by the present invention;
[0082] Figure 3-4 A schematic diagram of a walking area provided by the present invention;
[0083] Figure 5-6 A schematic diagram of a preset restricted area provided by the present invention;
[0084] Figure 7-8 A schematic diagram of an area to be penetrated provided by the present invention;
[0085] Figure 9 This is a schematic diagram of the drainage network distribution after transformation provided by the present invention;
[0086] Figure 10 This is a schematic diagram of the hardware structure of an electronic device provided by the present invention. DETAILED DESCRIPTION
[0087] To make the objectives, technical solutions, and advantages of the embodiments of the present invention more clear, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the accompanying 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 making creative efforts shall fall within the scope of protection of the present invention.
[0088] The following specific embodiments are used to describe the technical solution of the present invention in detail. 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.
[0089] like Figure 1 As shown, the present invention provides a drainage system detection method based on image processing, comprising:
[0090] S1, construct a drainage network model for each sub-area in the drainage system, control the pipe endoscopy device to obtain the pipe image of the drainage pipe in the sub-area, and retrieve the position information of the pipe endoscopy device, and generate a drainage detection interface based on the pipe image, drainage network model and the position information.
[0091] It should be noted that due to the large area of urban areas, the layout of the corresponding drainage pipes is intricate. In order to facilitate personnel to intuitively view the detection information of the urban drainage system, a drainage network management model corresponding to each sub-area of the drainage system can be constructed, so that the collected information can be displayed in the drainage detection interface for personnel to view.
[0092] Among them, the sub-area is the corresponding divided area in the city. For example, it can be multiple administrative areas divided in the urban area, such as area A, area B, etc. The drainage network management model is the twin model corresponding to the drainage pipe network, the pipe endoscopy device is a peeping device for detecting the inside of the pipe, the pipe image is the corresponding collected image inside the drainage pipe, the position information is the positioning information corresponding to the movable pipe endoscopy device, and the drainage detection interface is the information display interface for detecting the pipes in the drainage system.
[0093] It is not difficult to understand that the pipeline endoscope device has a positioning device, such as a GPS, so that the corresponding position information can be obtained in real time according to the movement of the pipeline endoscope device.
[0094] In some embodiments, a specific implementation of step S1 (constructing a drainage network model for each sub-area in the drainage system, controlling a pipe endoscopy device to obtain a pipe image of the drainage pipe in the sub-area, retrieving position information of the pipe endoscopy device, and generating a drainage detection interface based on the pipe image, the drainage network model, and the position information) includes:
[0095] S11, obtaining multiple sub-areas corresponding to the drainage system, each of which has a corresponding drainage network pipe, and constructing a twin model corresponding to the drainage network pipe as a drainage network pipe model of the sub-area.
[0096] It is understandable that the drainage system covers a wide area. In order to discharge rainwater and sewage in a timely manner, it is necessary to divide the total area corresponding to the drainage system into sub-areas so that each pipeline can control the corresponding sub-areas. For example, Figure 2 As shown, the distribution diagram corresponding to the drainage network pipe is obtained. Therefore, the drainage network pipes corresponding to multiple sub-areas can be obtained to generate a twin model corresponding to the drainage network pipe, and obtain the drainage network pipe model of the sub-area. This is convenient for the subsequent one-by-one inspection of the drainage pipes in the sub-areas, which can be displayed in the corresponding drainage network pipe model, and the implementation method of each sub-area is the same, so that the drainage network pipes of each sub-area can be inspected and processed one by one.
[0097] S12, controlling the pipeline endoscopy device to obtain a pipeline image of the drainage pipeline in the sub-area, and retrieving the position information of the pipeline endoscopy device as a detection position, and determining the corresponding sub-area as a detection area based on the detection position.
[0098] It can be understood that when the pipe endoscope device enters the drainage pipe, the pipe endoscope device can be controlled to take images of the drainage pipe in the sub-area, so that the pipe image can be obtained and the detection can be obtained at the same time, so as to determine the detection area based on the detection, which is convenient for subsequent information update and display of the drainage network model.
[0099] Among them, the detection position is the position of the pipe endoscope device corresponding to the detection of the drainage pipe, that is, the position information of the pipe endoscope device in the drainage pipe, and the detection area is the sub-area corresponding to the detection position. For example, when the current pipe endoscope device is detecting the pipe in plot one, the corresponding detection area is plot one.
[0100] S13, determining the drainage network management model corresponding to the detection area as the detection network management model, updating the detection position to the detection network management model, generating a position display model, and retrieving the virtual pipe at the detection position in the position display model as the detection pipe.
[0101] It can be understood that the detection network management model is the drainage network management model corresponding to the detection area, the location display model is the detection network management model with detection location information, the virtual pipeline is the pipeline in the location display model, and the detection pipeline is the virtual pipeline where the detection location is located in the location display model.
[0102] Through the above-mentioned implementation manner, the present invention can determine the detection pipeline, so that the determined detection pipeline can be updated and displayed in the corresponding display area later, which is convenient for personnel to intuitively view.
[0103] S14, calling the initial display interface, connecting the midpoints of the upper and lower boundary lines in the initial display interface to obtain an interface dividing line, and dividing the initial display interface based on the interface dividing line to obtain an endoscopy display area on the left and a position display area on the right.
[0104] It can be understood that the initial display interface is a pre-set blank display interface, which can be an interface pre-set by humans and is used to display detection information. The interface dividing line is the line segment that divides the interface, that is, the line segment obtained by connecting the midpoints of the upper and lower boundary lines corresponding to the initial display interface. The endoscope display area is the area for displaying the image collected by the pipeline endoscope device, that is, the area located on the left after the initial display interface is divided. The position display area is the area for displaying the position information, that is, the area located on the right after the initial display interface is divided.
[0105] Through the above implementation, the present invention can preliminarily divide the initial display interface so that corresponding information content can be filled and displayed later.
[0106] S15, dividing the position display area into three areas from top to bottom, using the area on the upper side as the area display area, the area in the middle as the detection display area, and the area on the lower side as the pipeline display area.
[0107] It is understandable that since the information of the detection pipeline includes multiple, such as the location and model of the detection pipeline, in order to facilitate personnel to intuitively and quickly view the location of the detection location in the drainage network model, the location display area can be further divided into 3 areas, so that more detailed location information can be filled in and displayed later.
[0108] Among them, the regional display area is the area for displaying the regional position of the detection pipeline, that is, the position display area is divided into three areas, which is the upper area; the detection display area is the area for displaying the position model of the detection pipeline in the drainage network model, that is, the position display area is divided into three areas, which is the middle area; the pipeline display area is the area for displaying a single pipeline model, that is, the position display area is divided into three areas, which is the lower area.
[0109] Through the above implementation, the present invention can divide the location display area into three parts, which is convenient for subsequent filling and display of corresponding location information, so that personnel can quickly view and promptly determine the currently detected drainage pipe location.
[0110] S16, updating the pipeline image to the endoscopy display area, updating the detection area to the area display area, updating the position display model to the detection display area, and updating the detection pipeline to the pipeline display area to generate a drainage detection interface.
[0111] It can be understood that the corresponding content information is updated to the corresponding area, that is, the pipeline image is updated in the endoscope display area, the detection area is filled in the area display area, the position display model is updated in the detection display area, and finally the detection pipeline is updated in the pipeline display area, thereby obtaining the drainage detection interface of the pipeline that the current pipeline endoscope device is detecting, and displaying multiple information in the same interface for easy viewing by personnel, so that multiple information can be obtained in a timely manner through the same interface.
[0112] S2, when it is determined that the pipeline image in the drainage detection interface has a blockage, identifying the blockage area corresponding to the blockage, and determining the conditional area of the pipeline endoscopy device according to the automatic obstacle avoidance strategy and the blockage area.
[0113] It should be noted that since obstacles such as silt, branches, plastic bags, etc. may flow into the drainage pipe, causing blockage in the drainage pipe and affecting the detection of the pipe endoscope device, when it is determined that the pipe image in the drainage detection interface has a blockage, the blocked area of the blockage can be identified so that the area where the device can pass can be found later, allowing the pipe endoscope device to pass smoothly and complete the detection of the drainage pipe.
[0114] Among them, the blockage can be the misconnection of rainwater and sewage, the combination of rainwater and sewage, and structural or functional defects in the pipeline.
[0115] It can be understood that the blocked area is the area with blockage in the pipeline image, and the conditional area is the area selected from multiple unblocked areas so that the conditional area can be cleaned up later to allow the pipeline endoscopy device to pass through the inspection area smoothly.
[0116] Through the above-mentioned implementation manner, the present invention can determine the conditional area so as to subsequently clear the blockage in the conditional area, facilitate the smooth passage of the pipeline endoscope device, and improve the detection efficiency of the drainage pipe.
[0117] In some embodiments, a specific implementation of step S2 (determining that the pipe image in the drainage detection interface has a blockage, identifying a blockage area corresponding to the blockage, and determining a conditional area of the pipe endoscopy device based on the automatic obstacle avoidance strategy and the blockage area) includes:
[0118] S21 , when it is determined that the pipeline image in the drainage detection interface has a blockage, identifying a blockage area corresponding to the blockage.
[0119] It is understandable that when it is determined that the pipe image in the drainage detection interface has a blockage, for example, Figure 3 As shown, image recognition can be performed on the pipeline image to determine the blockage area corresponding to the blockage, so that the conditional area where the pipeline endoscopy device can pass can be judged based on the blockage area.
[0120] S22, obtaining a horizontal transverse diameter of the circular pipe area corresponding to the pipe image as a cut diameter, and dividing the circular pipe area according to the cut diameter to obtain a walking area on the lower side.
[0121] It should be noted that if Figure 3As shown, the drainage pipe is usually a cylindrical pipe. Therefore, the corresponding circle in the pipe image is the area inside the pipe. Therefore, the horizontal transverse diameter of the circular pipe area can be used as the interception diameter, and then the circular pipe area can be divided to obtain the walking area located below the interception diameter. It is not difficult to understand that since the slope of the pipe endoscope device is limited, that is, it cannot be too steep, the pipe endoscope device can climb to a maximum of half the height of the pipe when walking in the pipe. Therefore, by dividing the circular pipe area into upper and lower parts, the area where the pipe endoscope device can walk in the pipe can be obtained. Subsequently, the blockage situation in the walking area can be judged, and the amount of data analyzed and processed for all circular pipe areas can be reduced, so that only the walking area can be analyzed and processed later, so that the pipe endoscope device can complete the pipe detection in time. Similarly, it can also be a rectangular pipe. When it is a rectangular pipe, the center points of the left and right sides of the rectangle are obtained and connected to obtain the transverse width to obtain the area where the blockage can walk. See. Figure 4 , when the upper and lower center points of the blocked area can be connected to obtain the vertical height and the horizontal width on both sides, the walking area that is convenient for the robot to walk is determined.
[0122] It can be understood that the intercepting diameter is the horizontal transverse diameter of the circular pipeline area, and the walking area is the area where the pipeline endoscopy device can pass, that is, the area located below the intercepting diameter.
[0123] When it is a rectangular pipe, the following method can be used:
[0124] The horizontal length of the rectangular pipe area corresponding to the pipe image is obtained as the horizontal width, and the vertical length is obtained as the vertical height. The rectangular pipe area is divided according to the horizontal width and vertical height to obtain the walking area on the lower side. After obtaining the walking area on the lower side, the subsequent processing method is the same as that of the circle.
[0125] S23 , determining a lower congestion area according to the intersection of the walking area and the congestion area, obtaining an area to be selected based on a difference set between the walking area and the lower congestion area, and acquiring the number of areas in the area to be selected.
[0126] It can be understood that the lower congestion area is the congestion area located in the walking area on the lower side, and the area to be selected is the location area waiting to be selected as the conditional area, that is, the unblocked hole area, and the number of areas is the number of areas to be selected. For example, when the number of unblocked holes is 3, the corresponding number of areas is 3.
[0127] Through the above-mentioned embodiments, the present invention can determine the areas to be selected and the number of areas, so as to subsequently determine the conditional areas, thereby facilitating the detection of the pipeline endoscopy device.
[0128] S24: When it is determined that the number of regions is equal to 1, the corresponding region to be selected is used as a conditional region of the pipeline endoscopy device.
[0129] It can be understood that when the number of areas is equal to 1, it can be said that there is only one unblocked hole area in the walking area. Furthermore, for the subsequent passage detection of the pipeline endoscope device, the corresponding area to be selected can be used as the conditional area of the pipeline endoscope device. When the conditional area cannot allow the device to pass smoothly, the pipeline of the conditional area can be cleaned and expanded subsequently so that the pipeline endoscope device can pass through the detection.
[0130] S25 , when it is determined that the number of regions is greater than 1, obtaining the conditional region of the pipeline endoscopy device according to the selection coordinates of the regions to be selected and the number of regions to be selected.
[0131] It can be understood that when it is determined that the number of areas is greater than 1, it means that there are multiple unblocked areas to be selected in the walking area on the lower side. Therefore, the conditions for facilitating the passage of the pipeline endoscope, such as the position and area size of the area to be selected, can be combined to determine the conditional area based on the selection coordinates of the area to be selected and the number of areas to be selected.
[0132] The selection coordinates are the center coordinates of the area to be selected, and the number to be selected is the size of the pixels in the area to be selected, that is, it is used to determine the area size of the area to be selected.
[0133] Through the above-mentioned implementation, the present invention can determine the conditional area so as to subsequently analyze and process the conditional area, thereby allowing the pipeline endoscope device to pass smoothly to inspect the pipeline.
[0134] In some embodiments, a specific implementation of step S25 (obtaining the conditional region of the pipeline endoscopy device based on the selection coordinates and the number of regions to be selected when determining that the number of regions is greater than 1) includes:
[0135] S251: When it is determined that the number of areas is greater than 1, the center point of the circular pipe area is used as the coordinate origin, the horizontal axis of the coordinate system is constructed at the interception diameter, and the vertical axis of the coordinate system is constructed perpendicular to the horizontal axis of the coordinate system to generate a selected coordinate system, and the pipe image is coordinate-processed based on the selected coordinate system.
[0136] It can be understood that in order to facilitate the selection of suitable condition areas from multiple areas to be selected, the pipeline image can be coordinate-processed to facilitate the determination of the position of each area to be selected and the unblocked area. Furthermore, the center point of the circular pipeline area can be used as the coordinate origin, and the horizontal axis of the coordinate system can be constructed by intercepting the diameter, and the vertical axis of the coordinate system perpendicular to the horizontal axis of the coordinate system can be constructed to obtain the selected coordinate system.
[0137] The selected coordinate system is a coordinate system for coordinate processing of the pipeline image, that is, a coordinate system for selecting the conditional area.
[0138] When it is a rectangular pipe, it can be processed in the following way:
[0139] When it is determined that the number of areas is greater than 1, the center point of the rectangular pipe area is used as the coordinate origin, the horizontal axis of the coordinate system is constructed at the horizontal width, and the vertical axis of the coordinate system is constructed perpendicular to the horizontal axis of the coordinate system to generate a selected coordinate system. The pipe image is coordinate-processed based on the selected coordinate system, and the subsequent processing method is consistent with the circular processing method.
[0140] S252: Acquire the minimum vertical coordinate of the walking area in the selected coordinate system as the longitudinal center of gravity value, and take the horizontal coordinate corresponding to the coordinate origin in the selected coordinate system as the transverse center of gravity value.
[0141] It can be understood that the longitudinal center of gravity value is the minimum longitudinal coordinate in the selected coordinate system within the walking area, and the transverse center of gravity value is the transverse coordinate corresponding to the coordinate origin in the selected coordinate system.
[0142] It is not difficult to understand that when the pipeline endoscopy device is inspecting the pipeline, the corresponding walking position is usually on the lower side of the pipeline. Since the center of gravity is low, it is convenient for the device to pass through. Therefore, the longitudinal center of gravity value and the transverse center of gravity value can be determined, so as to subsequently judge the center of gravity position of each area to be selected, thereby determining the conditional area.
[0143] S253, determining the coordinates of the center point of the area to be selected as the selection coordinates, using the horizontal coordinates in the selection coordinates as the selection horizontal value, and using the vertical coordinates in the selection coordinates as the selection vertical value.
[0144] It can be understood that the area center point is the center position point of the area to be selected, the selection coordinates are the coordinates of the area center point corresponding to the area to be selected, the selection horizontal value is the horizontal coordinate in the selection coordinates, and the selection vertical value is the vertical coordinate in the selection coordinates.
[0145] It is not difficult to understand that the maximum horizontal coordinate and the minimum horizontal coordinate corresponding to the area to be selected can be obtained for average calculation to obtain the central horizontal coordinate, and the maximum vertical coordinate and the minimum vertical coordinate can be obtained for average calculation to obtain the central vertical coordinate. According to the central horizontal coordinate and the central vertical coordinate, the coordinates of the center point of the area are determined as the selection coordinates.
[0146] Through the above implementation, the present invention can determine the selected transverse value and the selected longitudinal value, so as to subsequently determine the center of gravity deviation of each area to be selected, thereby determining the conditional area.
[0147] S254: Obtain a lateral center of gravity deviation value based on the absolute value of the difference between the selected lateral value and the lateral center of gravity value, and obtain a longitudinal center of gravity deviation value based on the difference between the selected longitudinal value and the longitudinal center of gravity value.
[0148] It can be understood that the lateral center of gravity deviation value is the deviation value of the center of gravity in the horizontal direction, that is, the absolute value of the difference between the lateral value and the lateral center of gravity value is selected, and the longitudinal center of gravity deviation value is the deviation value of the center in the vertical direction, that is, the difference between the longitudinal value and the longitudinal center of gravity value is selected.
[0149] Through the above implementation, the present invention can obtain the lateral center of gravity deviation value and the longitudinal center of gravity deviation value corresponding to the area to be selected, so as to subsequently determine the condition coefficient of the area to be selected, thereby determining a suitable condition area.
[0150] S255: Obtain a device deviation value based on the sum of the horizontal center-of-gravity deviation value and the longitudinal center-of-gravity deviation value, and count the number of pixels in the corresponding area to be selected as the number to be selected.
[0151] It can be understood that the device deviation value is the total center of gravity deviation value, that is, the sum of the horizontal center of gravity deviation value and the longitudinal center of gravity deviation value, the number of pixels is the number of pixels located in the area to be selected, and the number to be selected is the number of pixels in the area to be selected.
[0152] S256: Calculate according to the device deviation value and the number of areas to be selected to obtain a condition coefficient corresponding to the area to be selected.
[0153] It can be understood that the condition coefficient is a numerical coefficient for determining whether the area to be selected is a conditional area.
[0154] Through the above implementation, the present invention can obtain the condition coefficient corresponding to the area to be selected, so that the area to be selected corresponding to the largest coefficient can be used as the condition area later.
[0155] The condition coefficient corresponding to the area to be selected can be calculated by the following formula:
[0156] C_con=A / N_def *k_n+P_sel*k_p
[0157] Among them, C_con is the condition coefficient, A is the constant value, N_def is the device deviation value, k_n is the deviation weight, P_sel is the number to be selected, and k_p is the quantity weight.
[0158] It can be understood that when the device deviation value N_def is smaller, the corresponding A / N_def is larger, which means that the corresponding area to be selected is closer to the bottom center of the pipeline, and it is easier for the pipeline endoscopy device to pass through. At the same time, when the number to be selected is larger, it can be said that the area of the corresponding area to be selected is larger, and thus, the obtained condition coefficient will be larger. Conversely, when the device deviation value N_def is larger, the corresponding A / N_def is smaller, which means that the corresponding area to be selected is farther away from the bottom center of the pipeline, and it is more difficult for the pipeline endoscopy device to pass through, and the pipeline endoscopy device is more likely to fall and be unable to pass. At the same time, when the number to be selected is smaller, it can be said that the area of the corresponding area to be selected is smaller, and thus, the obtained condition coefficient will be smaller.
[0159] Among them, the constant value is pre-set, the deviation weight is the important proportion of the device deviation value in the calculation condition coefficient, which can be pre-set manually, and the quantity weight is the proportion of the area size of the area to be selected in the calculation condition coefficient, which can be pre-set manually.
[0160] S257, selecting the to-be-selected area corresponding to the largest condition coefficient as the condition area of the pipeline endoscopy device.
[0161] It can be understood that the conditional area is the area to be selected corresponding to the maximum conditional coefficient.
[0162] S3, comparing the conditional area with a preset restricted area to obtain an area comparison result. When it is determined that the area comparison result is an area prohibited from traveling, eliminating the congested area according to a congestion elimination strategy to obtain a passable area.
[0163] It can be understood that after the conditional area is determined, the pipeline endoscope device needs to be compared with the current conditional area to determine whether the unblocked conditional area can allow the pipeline endoscope device to pass through normally. When the area comparison result is a prohibited area result, the blocked area needs to be eliminated so that the pipeline endoscope device can pass smoothly. When it is determined that the conditional area allows the pipeline endoscope device to pass, the pipeline endoscope device can be directly controlled to continue walking and detecting.
[0164] Among them, the preset restricted area is the shape area corresponding to the pipeline endoscopy device, which is determined by the actual pipeline endoscopy device. The area comparison result is the judgment result after comparing the conditional area with the preset restricted area. The area prohibition result is the result of determining that the conditional area cannot allow the pipeline endoscopy device to pass through. The pass area is the area that allows the pipeline endoscopy device to pass through for detection.
[0165] Through the above-mentioned implementation manner, the present invention can obtain a passage area, so that the pipeline endoscope device can pass smoothly and continue to inspect the pipeline.
[0166] In some embodiments, the specific implementation of step S3 (comparing the conditional area with the preset restricted area to obtain an area comparison result, and when determining that the area comparison result is an area prohibited result, eliminating the congested area according to the congestion elimination strategy to obtain a passable area) includes:
[0167] S31, retrieve a preset restricted area, and align a center point of the preset restricted area with a center point of the conditional area.
[0168] It can be understood that in order to determine whether the conditional area can allow the pipeline endoscopy device to pass smoothly, the preset restricted area can be retrieved, and the center point of the preset restricted area can be aligned with the area center point of the conditional area, so as to facilitate the determination of the shape and size of the conditional area and the preset restricted area, thereby facilitating the subsequent area comparison results.
[0169] S32, obtaining an intersection area according to the intersection of the preset restricted area and the conditional area, and obtaining an area pass result when it is determined that the intersection area is consistent with the preset restricted area, and using the conditional area as the pass area.
[0170] It is understandable that, for example, Figure 5 As shown, the black area is the intersection of the preset restricted area and the selected white conditional area, and the intersection area is obtained. The intersection area is the area where the preset restricted area and the conditional area intersect. When the intersection area is consistent with the preset restricted area, it means that the conditional area is greater than or equal to the preset restricted area, that is, the pipeline endoscopy device can pass smoothly. Therefore, the regional passage result can be obtained, and thus, the conditional area can be used as the passage area. The preset restricted area, that is, the area passed by the robot, can be set according to the actual situation. Similarly, the conditional area is also determined according to the actual situation. See Figure 6 , is the area corresponding to the rectangular pipe.
[0171] Among them, the regional access result is the result that the area can allow the device to pass smoothly, and the access area is the area where the pipeline endoscopy device can pass.
[0172] S33, when it is determined that the intersection area is inconsistent with the preset restricted area, an area prohibition result is obtained, and an area comparison result is obtained according to the area passage result and the area prohibition result.
[0173] It can be understood that when it is determined that the intersection area is inconsistent with the preset restricted area, it means that the pipeline endoscopy device corresponding to the preset restricted area cannot pass through the unblocked conditional area. Therefore, a regional prohibition result is obtained so that the corresponding area can be cleared subsequently.
[0174] Among them, the regional comparison results include regional traffic results and regional traffic prohibition results.
[0175] S34: When it is determined that the area comparison result is a no-travel result, the blocking attribute of the blocking object is obtained, where the blocking attribute includes a soft attribute and a firm attribute.
[0176] It is understandable that since the obstacles that may block the drainage pipes may be diverse, such as silt, branches, etc., blockages of different materials require corresponding cleaning methods so that the pipes can be cleaned quickly and the pipe endoscopy device can continue to pass through the inspection. Therefore, when the area comparison result is a prohibited area result, the blockage properties of the blockage can be obtained so that the appropriate cleaning method can be selected to clear the blockage from the pipe.
[0177] The blocking attribute is a material attribute of the blocking object, including a soft attribute and a firm attribute. The soft attribute is an attribute corresponding to the softness of the blocking object's material, and the firm attribute is an attribute corresponding to the firmness of the blocking object.
[0178] The blockage can be a blockage, misconnection, confluence, or defect attributed to mixed and misconnected connections, rainwater and sewage confluence, or pipeline defects. The misconnection attribute includes rainwater misconnected to sewage and sewage misconnected to rainwater. The confluence attribute includes the attribute of rainwater removal requirements that meet the design rainfall conditions and the attribute of rainwater removal requirements that do not meet the design rainfall conditions. The pipeline defect attribute includes structural defect attributes and functional defect attributes.
[0179] S35 , when it is determined that the congestion attribute is a soft attribute, a through-clearing process is performed on the congested area according to a through-clearing strategy to obtain a passable area.
[0180] It is understandable that when it is determined that the blockage attribute is a soft attribute, a through-clearing strategy can be selected to perform through-clearing processing on the blocked area so as to obtain a passable area, which is convenient for subsequent pass detection of the pipeline endoscope device.
[0181] In some embodiments, the specific implementation of step S35 (when determining that the congestion attribute is a soft attribute, performing a through-clearing process on the congested area according to a through-clearing strategy to obtain a passable area) includes:
[0182] S351 : When it is determined that the congestion attribute is a soft attribute, a plurality of to-be-penetrated areas corresponding to the congestion area are obtained according to a difference set between the preset restricted area and the intersection area.
[0183] It is understandable that when it is determined that the blocking attribute is a soft attribute, a difference set comparison can be performed between the preset restricted area and the intersection area to obtain the area to be penetrated, for example, Figure 7As shown, two areas to be penetrated are obtained, so that the blockage in the area to be penetrated can be cleared later, making the area to be penetrated unobstructed and facilitating the passage of the pipeline endoscope device. Figure 8 , when it is a rectangular pipe, it corresponds to an area to be penetrated.
[0184] The area to be penetrated is a blocked area of the difference set of the preset restricted area and the intersection area.
[0185] S352 , taking the areas to be penetrated as selected areas in turn, and deleting the selected areas from the blocked areas respectively, to obtain a simulated walking area.
[0186] It should be noted that since there may be multiple areas to be penetrated, the order in which the areas to be penetrated are cleared and penetrated may affect the passage speed of the pipeline endoscopy device. For example, some areas to be penetrated have other unblocked space areas adjacent to the left and right. Therefore, when the area to be penetrated is cleared first, the passage area obtained is larger, which may allow the device to pass directly. There is no need to clean the area to be penetrated, which will greatly save the penetration time. Therefore, the areas to be penetrated are selected as the selected areas in turn to simulate the passage conditions after the areas to be penetrated are cleared, so as to determine the order of cleaning positions and improve the cleaning efficiency.
[0187] It can be understood that the selected area is the selected area for simulation clearing, that is, the currently selected area to be penetrated, and the simulated walking area is the walkable area after deleting the selected area in the blocked area.
[0188] S353: Align the center point of the preset restricted area with the center point of the simulated walking area, and obtain a simulated intersection area according to the intersection of the preset restricted area and the simulated walking area.
[0189] It is understandable that after the model walking area is determined, the preset restricted area can be retrieved and aligned with the simulated walking area to determine whether the simulated walking area obtained after clearing the current selected area can allow the pipeline endoscopy device to pass through.
[0190] The model intersection area is the intersection area of the preset restricted area and the simulated walking area.
[0191] Through the above implementation, the present invention can obtain a simulated intersection area, so as to subsequently judge the similarity between the simulated intersection area and the preset restricted area, and facilitate the subsequent determination of the actual cleaning area sequence.
[0192] S354, based on the difference set of the preset restricted area and the simulated intersection area, a plurality of simulated areas to be penetrated corresponding to the selected area are obtained, and the areas of the plurality of simulated areas to be penetrated are counted to obtain the selection area corresponding to each of the selected areas.
[0193] It should be noted that, when the simulation clears and penetrates the currently selected area, the obtained simulated intersection area still has a difference with the preset restricted area, which means that the pipeline endoscopy device cannot pass through after the current penetration. Then, the selection area corresponding to the selected area can be obtained based on the statistical area of the simulated area to be penetrated, so that the selected area corresponding to the smallest selection area can be selected as the penetration area in the future. This makes it easier to determine the cleaning sequence that allows the device to pass after clearing the minimum area, saving cleaning time and improving the passage speed of the pipeline endoscopy device.
[0194] It can be understood that the simulated area to be penetrated is the area of the difference between the preset restricted area and the simulated intersection area, that is, the area to be penetrated obtained after clearing the model corresponding to the selected area, and the selected area is the sum of the areas of all simulated areas to be penetrated.
[0195] S355 , selecting the selected area corresponding to the smallest selected area as the through-going area, and controlling the pipeline endoscopy device to perform through-going elimination processing on the through-going area to obtain the current conditional area.
[0196] It can be understood that the penetration area is the selected area corresponding to the smallest selection area. For example, when there are three areas to be penetrated, area No. 1 to be penetrated is selected as the selected area, and the selection area obtained after simulation of penetration is 1. If area No. 2 to be penetrated is selected as the selected area, the selection area obtained after simulation of penetration is 5. If area No. 3 to be penetrated is selected as the selected area, and the selection area obtained after simulation of penetration is 3, the selected area with a selection area of 1 will be selected as the penetration area, so as to control the robotic arm on the pipeline endoscopy device to penetrate and eliminate the area, so as to obtain the current conditional area.
[0197] S356, align the area center point of the preset restricted area with the area center point of the current conditional area, obtain the current intersection area based on the intersection of the preset restricted area and the current conditional area, repeat the above steps until the current intersection area is consistent with the preset restricted area, and use the current conditional area as the pass area.
[0198] It can be understood that after completing the clearance of an area to be penetrated, the preset restricted area can be aligned and compared with the current conditional area again to determine the current intersection area, and the above-mentioned implementation steps of obtaining the penetration area are repeated until the current intersection area is consistent with the preset restricted area. It means that the current penetrated area can allow the pipeline endoscopy device to pass through and continue detection, so that the current conditional area can be used as a pass area.
[0199] S36, when it is determined that the congestion attribute is a solid attribute, performing a grabbing and eliminating process on the congested area according to a grabbing and clearing strategy to obtain a passable area, wherein the congestion eliminating strategy includes a through-clearing strategy and the grabbing and clearing strategy.
[0200] It is understandable that when it is determined that the blockage attribute is a solid attribute, the blocked area can be cleared and eliminated by grabbing to obtain a pass area, so that the subsequent pipeline endoscope device can pass through and continue to detect the pipeline.
[0201] In some embodiments, the specific implementation of step S36 (when determining that the congestion attribute is a solid attribute, performing a grabbing and clearing process on the congested area according to a grabbing and clearing strategy to obtain a passable area) includes:
[0202] S361: When it is determined that the blockage attribute is a solid attribute, a blockage contour of the blockage is identified based on OpenCV, and coordinates of contour pixels in the blockage contour are obtained as contour coordinates.
[0203] It is understandable that when the blockage attribute is determined to be a solid attribute, the pipeline cannot be cleared by pushing and poking. Therefore, OpenCV can be used to identify the blockage outline of the blockage so that the corresponding blockage can be cleared by crawling.
[0204] The blockage contour is the image contour corresponding to the blockage, and the contour coordinates are the coordinates of the contour pixels in the blockage contour.
[0205] S362: Obtain a horizontal distance based on a difference between a maximum horizontal coordinate and a minimum horizontal coordinate in the contour coordinates, and obtain a vertical distance based on a difference between a maximum vertical coordinate and a minimum vertical coordinate in the contour coordinates.
[0206] It can be understood that the horizontal distance is the difference between the maximum horizontal coordinate and the minimum horizontal coordinate in the contour coordinates, and the longitudinal distance is the distance difference in the vertical direction, that is, the difference between the maximum vertical coordinate and the minimum vertical coordinate in the contour coordinates.
[0207] S363: Obtain a direction difference value based on the absolute value of the difference between the lateral distance and the longitudinal distance.
[0208] It can be understood that the direction difference value is the absolute value of the difference between the horizontal distance and the vertical distance.
[0209] S364, when it is determined that the direction difference value is greater than the preset difference value, the corresponding blockage contour is used as a strip blockage contour, and the edge grabbing position of the pipeline endoscopy device is determined based on the strip blockage contour, and the pipeline endoscopy device is controlled to grab and clear the edge grabbing position to obtain a passage area.
[0210] It can be understood that when the directional gap value is greater than the preset gap value, it means that the current blockage has a large distance difference in the horizontal and vertical directions, and the blockage is in the shape of a strip. Therefore, the blockage can be cleared by grabbing. Furthermore, the edge grabbing position of the pipeline endoscopy device can be determined according to the strip blockage contour so as to perform grabbing and clearing processing to obtain the pass area.
[0211] The preset gap value is a preset reference distance difference, the strip-shaped congestion profile is a congestion profile whose direction gap value is greater than the preset gap value, and the edge grabbing position is an edge position for grabbing and clearing.
[0212] In some embodiments, a specific implementation of step S364 (when determining that the directional difference value is greater than a preset difference value, using the corresponding blockage profile as a strip blockage profile, determining an edge grabbing position of the pipeline endoscopy device based on the strip blockage profile, and controlling the pipeline endoscopy device to perform a grabbing and clearing process on the edge grabbing position to obtain a passable area) includes:
[0213] S3641: When it is determined that the direction difference value is greater than the preset difference value, the corresponding congestion profile is used as a strip congestion profile.
[0214] It can be understood that when the directional difference value is greater than the preset difference value, the corresponding blockage profile is used as a strip-shaped blockage profile.
[0215] S3642, obtaining multiple contact contour lines between the strip-shaped blockage contour and the circular pipe area, counting the number of pixel points corresponding to contour pixels of each contact contour line, and obtaining the number of contacts corresponding to each contact contour line.
[0216] It should be noted that since the strip-shaped blockage may be irregular, the strip-shaped blockage contour has multiple contact contour lines after contacting the circular pipe area. Moreover, when the contact contour is smaller, it is easier to remove the blockage during subsequent grabbing and removal. Therefore, the number of contacts corresponding to the contact contour line can be obtained, so that a more suitable grabbing position can be selected later.
[0217] It can be understood that the contact contour line is the contour line where the strip-shaped blockage contour contacts the circular pipe area, and the contact number is the number of pixel points corresponding to the contour pixel points of the contact contour line.
[0218] S3643: Select the contact contour line corresponding to the minimum number of contacts as the grasping position contour line, and use the position of the grasping position contour line as the edge grasping position of the pipeline endoscopy device.
[0219] It can be understood that the gripping position contour line is the contact contour line corresponding to the minimum number of contacts, and the edge gripping position is the position where the gripping position contour line is located.
[0220] S3644, controlling the pipeline endoscopy device to perform a grabbing and clearing process on the edge grabbing position to obtain a passage area.
[0221] It can be understood that the pipeline endoscope device is controlled to perform a grabbing and clearing process on the edge grabbing position to obtain a passage area.
[0222] S365, when it is determined that the directional gap value is less than or equal to the preset gap value, the corresponding blockage contour is used as a block blockage contour, and the middle grabbing position of the pipeline endoscopy device is determined based on the block blockage contour, and the pipeline endoscopy device is controlled to grab and clear the middle grabbing position to obtain a passage area.
[0223] It can be understood that when it is determined that the directional difference value is less than or equal to the preset difference value, it can be explained that the horizontal and vertical length distances of the corresponding blockage are relatively close, so that the shape of the corresponding blockage is classified as block-shaped, and then, the corresponding blockage contour can be used as a block blockage contour. Therefore, the middle grabbing position of the pipeline endoscopy device can be determined according to the block blockage contour, so as to grab and clear it and obtain the pass area.
[0224] It is not difficult to understand that when the blockage contour is a block-shaped blockage contour, it means that the blockage cannot be removed by grabbing the edge. Therefore, the middle position can be selected to clear the blockage in order to obtain a pass area.
[0225] In some embodiments, a specific implementation of step S365 (when determining that the directional difference value is less than or equal to a preset difference value, using the corresponding blockage contour as a block blockage contour, determining an intermediate grabbing position of the pipeline endoscopy device based on the block blockage contour, and controlling the pipeline endoscopy device to perform a grabbing and clearing process on the intermediate grabbing position to obtain a passable area) includes:
[0226] S3651: When it is determined that the direction difference value is less than or equal to the preset difference value, the corresponding congestion contour is used as a block congestion contour.
[0227] It can be understood that when it is determined that the direction difference value is less than or equal to the preset difference value, the corresponding congestion profile is used as a block congestion profile.
[0228] Through the above-mentioned embodiment, the present invention can determine the type of blockage so as to subsequently determine the corresponding grabbing position, thereby successfully clearing the blockage.
[0229] S3652: Acquire multiple contact contour lines between the block-shaped blockage contour and the circular pipe area, delete the contact contour lines in the block-shaped blockage contour, and obtain multiple remaining contour lines.
[0230] It can be understood that since the blockage can be irregular, the contact between the block block contour and the circular pipe area is discontinuous, and thus, multiple contact contour lines can be obtained. At the same time, the gripper of the robotic arm must grab the blockage before it can be cleaned. Therefore, in order to determine the grabbing position of the corresponding gripper of the robotic arm, the area position that does not contact the circular pipe area can be used as the grabbing position.
[0231] The remaining contour line is the contour line remaining after deleting the contact contour line from the block-shaped blocking contour, so that the grasping position can be determined in the remaining contour line later.
[0232] S3653: Count the number of contour pixels corresponding to each of the remaining contour lines to obtain the number of remaining pixels corresponding to each of the remaining contour lines.
[0233] It can be understood that the number of remaining pixels is the total number of contour pixels corresponding to the remaining contour lines.
[0234] Through the above implementation, the present invention can obtain the number of remaining pixels, so as to subsequently determine the capture position according to the number of remaining pixels.
[0235] S3654, select the remaining contour lines whose number of remaining pixel points is greater than the preset capture number as the contour lines to be processed, obtain the straight line segments in each of the contour lines to be processed, use the contour pixel points corresponding to the straight line segments as the straight line contour points, and obtain the number of straight line contour points corresponding to each of the straight line segments as the number of straight line pixel points.
[0236] It can be understood that the preset grasping number is the number of pixel points corresponding to the pre-set grasping position, which can be a number determined manually according to the position required by the grasping part of the robotic arm. The contour line to be processed is the remaining contour line whose remaining number of pixel points is greater than the preset grasping number. The straight line contour point is the contour pixel point corresponding to the straight line segment in the contour line to be processed, and the number of straight line pixel points is the number of straight line contour points corresponding to the straight line segment.
[0237] Through the above-mentioned implementation, the present invention can determine the number of straight line pixel points, so as to subsequently select a grabbing position for grabbing the blockage for cleaning according to the number of straight line pixel points.
[0238] S3655: Take the straight line segment whose number of straight line pixel points is greater than or equal to the preset grabbing number as a grabbable line segment, obtain the endpoints on both sides of the grabbable line segment as construction endpoints, and construct an intercept perpendicular line perpendicular to the grabbable line segment based on the construction endpoints.
[0239] It can be understood that when the number of corresponding straight line pixel points is greater than or equal to the preset grab number, it can be said that the current straight line segment has enough space to allow the gripper of the robotic arm to be placed at the corresponding position so as to grab the blockage for pipeline cleaning.
[0240] Among them, the grabbable line segment is a line segment with the number of straight line pixels greater than or equal to the preset grab number, the construction endpoints are the endpoints on both sides of the grabbable line segment, and the intercepted perpendicular line is a perpendicular line passing through the construction endpoints and perpendicular to the grabbable line segment.
[0241] S3656: intercept the contour line to be processed according to the intercepted vertical lines to obtain a capture filter line located between the intercepted vertical lines, and count the number of straight contour points in the capture filter line as the actual capture number.
[0242] It can be understood that the grabbing screening line is the position line segment corresponding to the grabbing blockage, that is, the grabbing screening line located between the intercepting vertical lines, and the actual grabbing quantity is the number of straight line contour points in the grabbing screening line.
[0243] Through the above-mentioned implementation, the present invention can obtain the actual grasping quantity so as to subsequently determine the intermediate grasping position.
[0244] S3657: Select the grabbing screening line corresponding to the largest actual grabbing quantity as the actual grabbing line, and use the position of the actual grabbing line as the middle grabbing position of the pipeline endoscopy device.
[0245] It can be understood that the actual grabbing line is the grabbing screening line corresponding to the maximum actual grabbing quantity, and the middle grabbing position is the middle position for grabbing blockages for cleaning, that is, the position of the actual grabbing line.
[0246] Through the above-mentioned embodiment, the present invention can determine the middle grabbing position, so as to subsequently control the grabbing part of the pipeline endoscope device to move to the middle grabbing position, thereby achieving the grabbing and clearing treatment of the blockage.
[0247] S3658, controlling the pipeline endoscopy device to perform grabbing and clearing processing on the intermediate grabbing position to obtain a passage area.
[0248] It can be understood that the pipeline endoscopy device is controlled to grab and clear the middle grabbing position to obtain a passage area, which is convenient for subsequent passage to continue to detect the pipeline.
[0249] If the misconnection is rainwater misconnected to sewage, it can be solved in the following ways:
[0250] When it is determined that the misconnection attribute is the misconnection of rainwater to sewage, the misconnected rainwater is connected to the rainwater system nearby according to the rainwater and sewage mixed misconnection reconstruction strategy to obtain a pass area.
[0251] When it is determined that the misconnection attribute is sewage misconnected to rainwater, the misconnected sewage is connected to the nearest sewage system according to the rainwater and sewage mixed misconnection reconstruction strategy to obtain a pass area.
[0252] When it is determined that the combined flow attribute meets the rainwater removal demand attribute under the design rainfall conditions, the combined pipe is transformed into a rainwater pipe according to the rainwater and sewage diversion strategy, and the sewage pipe is re-laid to achieve rainwater and sewage diversion and obtain a traffic area.
[0253] When it is judged that the combined pipe attribute does not meet the rainwater discharge demand attribute under the design rainfall conditions, the combined pipe is transformed into a sewage pipe according to the rainwater and sewage mixed connection transformation strategy, and the rainwater pipe that meets the design rainfall conditions is re-laid to achieve rainwater and sewage separation and obtain a traffic area.
[0254] When it is determined that the pipeline defect attribute is a structural defect attribute, problems such as concealed connection, deformation, misalignment, foreign body penetration, corrosion, rupture, undulation, leakage, disconnection, and interface material shedding of pipeline branches are repaired according to the pipeline defect repair strategy to obtain a pass area.
[0255] When it is determined that the pipeline defect attribute is a functional defect attribute, pipeline deposits, obstacles, scaling, tree roots, residual walls, dam roots, slag and other problems are repaired according to the pipeline defect repair strategy to obtain a passable area.
[0256] The pipeline defect repair strategy is to use trenchless repair technology as the first choice. When the trenchless repair technology cannot repair the pipeline defect, the drainage pipeline is rebuilt in situ to obtain a passable area.
[0257] S4, controlling the pipeline endoscopy device to pass through the passage area, and recording the blockage position of the blockage, updating the blockage position to the position display model in the drainage detection interface, generating a drainage feedback model and sending it to the management end.
[0258] It can be understood that the blockage position is the location of the blockage in the drainage pipe. The drainage feedback model is to update the twin model with the blockage position in the position display model so that personnel can visually view the blockage position through the drainage feedback model. The management end is the information terminal of the personnel who manage the pipeline inspection. Finally, the personnel can improve the rainwater system and sewage system according to the frequently blocked or abnormal locations. For example, see Figure 6 , rainwater and sewage can be collected through separate pipes and discharged into different areas.
[0259] It should be noted that there may be accumulated water at the corresponding position in the drainage pipe during the detection process. When the accumulated water exceeds the height of the acquisition camera corresponding to the pipeline endoscope device, since the acquisition camera cannot be immersed in the accumulated water for a long time, the height of the camera needs to be adjusted according to the depth of the accumulated water so that the pipeline endoscope device can perform real-time detection of the drainage pipe. Therefore, in some embodiments, the following is further included:
[0260] When it is determined that the pipeline image has water accumulation anomaly, the water accumulation pixel value is retrieved, and the water level of the pipeline image is marked based on the water accumulation pixel value to obtain a water accumulation mark line.
[0261] It can be understood that when it is determined that the pipeline image has water accumulation abnormality, it means that the water accumulation in the pipeline exceeds the camera device on the pipeline endoscope device. Therefore, the water accumulation pixel value can be retrieved to mark the water level of the pipeline image and obtain the water accumulation mark line, so as to subsequently determine the adjustment height of the acquisition device on the pipeline endoscope device to enable safe pipeline inspection.
[0262] The water accumulation pixel value is the pixel value corresponding to the water accumulation in the pipe, and the water accumulation marking line is the line segment marking the height of the water accumulation.
[0263] It is not difficult to understand that the corresponding water accumulation pixel points can be connected according to the water accumulation pixel values, so as to select the straight line segment in the connecting line as the water accumulation marking line.
[0264] The center point of the pipeline image is obtained based on OpenCV, and the center point is used as the coordinate origin to perform coordinate processing on the pipeline image.
[0265] It is understandable that in order to facilitate the subsequent determination of the depth of accumulated water inside the pipeline, the pipeline image may be subjected to coordinate processing.
[0266] The midpoint of the water accumulation marking line is obtained as the midpoint of the water accumulation line, and a perpendicular line perpendicular to the water accumulation marking line is drawn based on the midpoint of the water accumulation line to obtain the water accumulation perpendicular line.
[0267] It can be understood that the midpoint of the water accumulation line is the midpoint of the water accumulation marking line, and the water accumulation vertical line is the vertical line segment perpendicular to the water accumulation marking line.
[0268] Through the above embodiment, the present invention can obtain the water accumulation vertical line, so as to subsequently determine the pipeline vertex and pipeline base point, and then facilitate the subsequent acquisition of the water accumulation depth, thereby determining the adjustment height of the collection device on the pipeline endoscopy device.
[0269] The intersection of the water accumulation vertical line and the upper boundary of the circular pipe area is taken as the pipe vertex, and the intersection of the water accumulation vertical line and the lower boundary of the circular pipe area is taken as the pipe base point.
[0270] It can be understood that the pipe vertex is the top vertex of the circular pipe, that is, the intersection of the vertical line of water accumulation and the upper boundary of the circular pipe area, and the pipe base point is the lowest point of the circular pipe, that is, the intersection of the vertical line of water accumulation and the lower boundary of the circular pipe area.
[0271] The pipeline base point and the midpoint of the accumulated water are connected to obtain a water depth line, and the accumulated water depth is obtained based on the water depth line.
[0272] It can be understood that the water depth line is a line segment representing the depth of water, that is, the connecting line between the pipeline base point and the midpoint of the water accumulation. The water depth is the depth of water accumulation in the pipeline, that is, the length distance corresponding to the water depth line.
[0273] It is not difficult to understand that the length of the water depth line can be obtained based on the difference between the vertical coordinate of the middle point of the water accumulation and the vertical coordinate of the pipeline base point.
[0274] When it is determined that the accumulated water depth is greater than the acquisition height, the difference between the accumulated water depth and the acquisition height is obtained to obtain the diving height.
[0275] It can be understood that when the depth of accumulated water is greater than the collection height, it means that the accumulated water can submerge the collection camera. Therefore, the depth distance of the accumulated water above the camera can be determined based on the difference between the depth of accumulated water and the collection height, so that the height of the camera can be adjusted subsequently.
[0276] Among them, the collection height is the height of the collection camera on the pipeline endoscopy device, and the diving height is the height difference of the collection device on the pipeline endoscopy device submerged in the accumulated water, that is, the difference between the accumulated water depth and the collection height.
[0277] According to the sum of the diving height and the standard collection height, the corresponding adjustment height of the collection device on the pipeline endoscopy device is obtained, and the collection device is controlled to be vertically raised based on the adjustment height.
[0278] It can be understood that the acquisition device is a device for image acquisition on the pipeline endoscopy device, such as a camera. The standard acquisition height is the height distance of the standard acquisition device above the accumulated water, which can be pre-set. The height adjustment is to adjust the height of the acquisition device, that is, the sum of the diving height and the standard acquisition height.
[0279] Through the above implementation, the present invention can obtain the adjusted height, and then control the value of the collection device to increase the distance corresponding to the adjusted height, so that the pipes with accumulated water can continue to be inspected, thereby improving the inspection efficiency of the drainage pipes.
[0280] See also Figure 10 , is a schematic diagram of the hardware structure of an electronic device provided by an embodiment of the present invention, the electronic device 60 includes: a processor 61, a memory 62 and a computer program; wherein
[0281] The memory 62 is used to store the computer program, which may also be a flash memory. The computer program is, for example, an application program or a functional module for implementing the above method.
[0282] The processor 61 is configured to execute the computer program stored in the memory to implement the various steps performed by the device in the above method. For details, please refer to the relevant description in the above method embodiment.
[0283] Optionally, the memory 62 may be independent or integrated with the processor 61 .
[0284] When the memory 62 is a device independent of the processor 61, the device may further include:
[0285] The bus 63 is used to connect the memory 62 and the processor 61 .
[0286] The present invention also provides a readable storage medium, in which a computer program is stored. When the computer program is executed by a processor, it is used to implement the methods provided in the various embodiments described above.
[0287] The readable storage medium may be a computer storage medium or a communication medium. Communication media include any medium that facilitates the transfer of computer programs from one location to another. Computer storage media may be any available medium that can be accessed by a general-purpose or special-purpose computer. For example, a readable storage medium is coupled to a processor, enabling the processor to read information from and write information to the readable storage medium. Of course, the readable storage medium may also be an integral part of the processor. The processor and the readable storage medium may be located in an application-specific integrated circuit (ASIC). In addition, the ASIC may be located in a user device. Of course, the processor and the readable storage medium may also exist as discrete components in a communication device. The readable storage medium may be a read-only memory (ROM), a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, and the like.
[0288] The present invention also provides a program product, which includes execution instructions stored in a readable storage medium. At least one processor of a device can read the execution instructions from the readable storage medium, and at least one processor executes the execution instructions so that the device implements the methods provided in the various embodiments described above.
[0289] In the embodiments of the above-mentioned devices, it should be understood that the processor may be a central processing unit (CPU), other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASICs), etc. The general-purpose processor may be a microprocessor or any conventional processor. The steps of the method disclosed in the present invention may be directly executed by a hardware processor or by a combination of hardware and software modules within the processor.
[0290] 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 above embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the above 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 drainage system detection method based on image processing, characterized in that: include: Construct drainage network models for each sub-area in the drainage system, control the pipe endoscopy device to obtain pipe images of the drainage pipes in the sub-area, retrieve the position information of the pipe endoscopy device, and generate a drainage detection interface based on the pipe images, drainage network model, and position information; When it is determined that the pipe image in the drainage detection interface has a blockage, the blockage area corresponding to the blockage is identified, and the conditional area of the pipe endoscopy device is determined based on the automatic obstacle avoidance strategy and the blockage area; Compare the conditional area with the preset restricted area to obtain an area comparison result. When the area comparison result is determined to be a prohibited area, eliminate the congestion area according to the congestion elimination strategy to obtain a passable area. Control the pipeline endoscopy device to pass through the passage area and record the blockage position of the blockage, update the blockage position to the position display model in the drainage detection interface, generate a drainage feedback model and send it to the management end.
2. The method according to claim 1, characterized in that The method comprises: constructing a drainage network model for each sub-area in the drainage system, controlling a pipe endoscopy device to obtain a pipe image of the drainage pipe in the sub-area, retrieving position information of the pipe endoscopy device, and generating a drainage detection interface based on the pipe image, the drainage network model, and the position information, including: Acquire multiple sub-areas corresponding to the drainage system, each sub-area having a corresponding drainage network pipe, and construct a twin model corresponding to the drainage network pipe as a drainage network pipe model of the sub-area; Controlling the pipeline endoscope device to obtain a pipeline image of the drainage pipeline in the sub-area, retrieving position information of the pipeline endoscope device as a detection position, and determining a corresponding sub-area as a detection area based on the detection position; Determine the drainage network management model corresponding to the detection area as the detection network management model, update the detection position to the detection network management model, generate a position display model, and call the virtual pipe at the detection position in the position display model as the detection pipe; Retrieving the initial display interface, connecting the midpoints of the upper and lower boundary lines of the initial display interface to obtain an interface dividing line, and dividing the initial display interface based on the interface dividing line to obtain an endoscope display area on the left and a position display area on the right; The location display area is divided into three equal areas from top to bottom. The upper area is used as the regional display area, the middle area is used as the detection display area, and the lower area is used as the pipeline display area. Update the pipeline image to the endoscopy display area, update the inspection area to the area display area, update the location display model to the inspection display area, and update the inspection pipeline to the pipeline display area to generate a drainage inspection interface.
3. The method according to claim 2, characterized in that When determining that the pipe image in the drainage detection interface has a blockage, identifying a blockage area corresponding to the blockage, and determining a conditional area of the pipe endoscopy device based on an automatic obstacle avoidance strategy and the blockage area, includes: When it is determined that the pipe image in the drainage detection interface has a blockage, the blockage area corresponding to the blockage is identified; The horizontal diameter of the circular pipe area corresponding to the pipe image is obtained as the interception diameter, and the circular pipe area is divided according to the interception diameter to obtain the walking area on the lower side; Determine the lower congestion area based on the intersection of the walking area and the congestion area, obtain the area to be selected based on the difference set of the walking area and the lower congestion area, and obtain the number of areas to be selected; When it is determined that the number of regions is equal to 1, the corresponding region to be selected is used as a conditional region of the pipeline endoscopy device; When it is determined that the number of regions is greater than 1, the conditional region of the pipeline endoscopy device is obtained according to the selection coordinates of the regions to be selected and the number of regions to be selected.
4. The method according to claim 3, characterized in that When it is determined that the number of regions is greater than 1, obtaining the conditional region of the pipeline endoscopy device according to the selection coordinates and the number of regions to be selected includes: When the number of regions is determined to be greater than 1, the center point of the circular pipe region is used as the coordinate origin, the horizontal axis of the coordinate system is constructed at the intercepted diameter, and the vertical axis of the coordinate system is constructed perpendicular to the horizontal axis of the coordinate system to generate a selected coordinate system, and the pipe image is coordinate-processed based on the selected coordinate system; Obtain the minimum vertical coordinate of the walking area in the selected coordinate system as the longitudinal center of gravity value, and the horizontal coordinate corresponding to the coordinate origin in the selected coordinate system as the horizontal center of gravity value; Determine the coordinates of the center point of the area to be selected as the selection coordinates, use the horizontal coordinate in the selection coordinates as the selection horizontal value, and use the vertical coordinate in the selection coordinates as the selection vertical value; The lateral center of gravity deviation value is obtained based on the absolute value of the difference between the selected lateral value and the lateral center of gravity value, and the longitudinal center of gravity deviation value is obtained based on the difference between the selected longitudinal value and the longitudinal center of gravity value; Based on the sum of the horizontal center of gravity deviation value and the longitudinal center of gravity deviation value, the device deviation value is obtained, and the number of pixels in the corresponding area to be selected is counted as the number to be selected; Calculate the condition coefficient corresponding to the area to be selected based on the device deviation value and the number of areas to be selected; The area to be selected corresponding to the largest condition coefficient is selected as the condition area of the pipeline endoscopy device.
5. The method according to claim 4, characterized in that The step of comparing the conditional area with the preset restricted area to obtain an area comparison result, and when determining that the area comparison result is an area prohibited result, eliminating the congested area according to a congestion elimination strategy to obtain a passable area, includes: Retrieve the preset restricted area and align the area center point of the preset restricted area with the area center point of the conditional area; According to the intersection of the preset restricted area and the conditional area, an intersection area is obtained. When it is determined that the intersection area is consistent with the preset restricted area, a regional pass result is obtained, and the conditional area is used as the pass area; When it is determined that the intersection area is inconsistent with the preset restricted area, the regional prohibition result is obtained, and the regional comparison result is obtained based on the regional passage result and the regional prohibition result; When the area comparison result is determined to be a prohibited area, the blocking attribute of the blocking object is obtained, and the blocking attribute includes a soft attribute and a solid attribute; When the congestion attribute is determined to be soft, the congestion area is cleared according to the through-clearing strategy to obtain the passable area; When the congestion attribute is determined to be a solid attribute, the congestion area is subjected to a grabbing and eliminating process according to the grabbing and clearing strategy to obtain a passable area. The congestion elimination strategy includes a through-clearing strategy and a grabbing and clearing strategy.
6. The method according to claim 5, characterized in that When the blocking attribute is determined to be a soft attribute, performing a through-clearing process on the blocking area according to a through-clearing strategy to obtain a passable area includes: When the congestion attribute is determined to be a soft attribute, multiple areas to be penetrated corresponding to the congestion area are obtained according to the difference set of the preset restricted area and the intersection area; Each area to be penetrated is selected as a selected area in turn, and the selected area is deleted from the blocked area to obtain a simulated walking area; Aligning the center point of the preset restricted area with the center point of the simulated walking area, and obtaining a simulated intersection area according to the intersection of the preset restricted area and the simulated walking area; Based on the difference set of the preset restricted area and the simulated intersection area, a plurality of simulated areas to be penetrated corresponding to the selected area are obtained, and the areas of the plurality of simulated areas to be penetrated are counted to obtain the selected area corresponding to each selected area; The selected area corresponding to the smallest selection area is selected as the penetration area, and the pipeline endoscopy device is controlled to perform a penetration elimination process on the penetration area to obtain the current condition area; Align the area center point of the preset restricted area with the area center point of the current conditional area, and obtain the current intersection area based on the intersection of the preset restricted area and the current conditional area. Repeat the above steps until the current intersection area is consistent with the preset restricted area, and then use the current conditional area as the pass area.
7. The method according to claim 5, characterized in that When the blocking attribute is determined to be a solid attribute, the blocking area is subjected to a grabbing and clearing process according to a grabbing and clearing strategy to obtain a passable area, including: When the blockage attribute is determined to be a solid attribute, the blockage contour of the blockage is identified based on OpenCV, and the coordinates of the contour pixels in the blockage contour are obtained as contour coordinates; The horizontal distance is obtained based on the difference between the maximum horizontal coordinate and the minimum horizontal coordinate in the contour coordinates, and the vertical distance is obtained based on the difference between the maximum vertical coordinate and the minimum vertical coordinate in the contour coordinates; Based on the absolute value of the difference between the horizontal distance and the vertical distance, the direction difference value is obtained; When it is determined that the directional difference value is greater than the preset difference value, the corresponding blockage contour is used as a strip blockage contour, an edge grabbing position of the pipeline endoscope device is determined based on the strip blockage contour, and the pipeline endoscope device is controlled to grab and clear the edge grabbing position to obtain a passage area; When it is determined that the directional gap value is less than or equal to the preset gap value, the corresponding blockage contour is used as the block blockage contour, and the middle grabbing position of the pipeline endoscopy device is determined based on the block blockage contour. The pipeline endoscopy device is controlled to grab and clear the middle grabbing position to obtain the pass area.
8. The method according to claim 7, characterized in that When it is determined that the directional difference value is greater than a preset difference value, the corresponding blockage contour is used as a strip blockage contour, an edge grabbing position of a pipeline endoscope device is determined based on the strip blockage contour, and the pipeline endoscope device is controlled to perform a grabbing and clearing process on the edge grabbing position to obtain a passage area, including: When it is determined that the direction difference value is greater than the preset difference value, the corresponding blockage profile is used as a strip blockage profile; Obtain multiple contact contour lines between the strip-shaped blockage contour and the circular pipe area, count the number of pixel points corresponding to the contour pixel points of each contact contour line, and obtain the number of contacts corresponding to each contact contour line; Selecting the contact contour line corresponding to the minimum number of contacts as the grasping position contour line, and using the position of the grasping position contour line as the edge grasping position of the pipeline endoscope device; The pipeline endoscope device is controlled to perform grabbing and clearing processing on the edge grabbing position to obtain the passage area.
9. The method according to claim 7, characterized in that When it is determined that the directional difference value is less than or equal to a preset difference value, the corresponding blockage contour is used as a block blockage contour, an intermediate grabbing position of the pipeline endoscope device is determined based on the block blockage contour, and the pipeline endoscope device is controlled to perform a grabbing and clearing process on the intermediate grabbing position to obtain a passage area, including: When it is determined that the directional difference value is less than or equal to the preset difference value, the corresponding blocking contour is used as a block blocking contour; Acquire multiple contact contour lines between the block-shaped blockage contour and the circular pipe area, delete the contact contour lines in the block-shaped blockage contour, and obtain multiple remaining contour lines; Counting the number of contour pixels corresponding to each remaining contour line to obtain the number of remaining pixels corresponding to each remaining contour line; Select the remaining contour lines whose number of remaining pixels is greater than the preset capture number as contour lines to be processed, obtain the straight line segments in each contour line to be processed, use the contour pixel points corresponding to the straight line segments as straight line contour points, and obtain the number of straight line contour points corresponding to each straight line segment as the number of straight line pixel points; A line segment with a number of straight line pixels greater than or equal to a preset number of grab points is regarded as a grabbable line segment, and the endpoints on both sides of the grabbable line segment are obtained as construction endpoints. A vertical intercept perpendicular to the grabbable line segment is constructed based on the construction endpoints. The contour line to be processed is intercepted according to the intercepted vertical line to obtain the grabbing screening line located between the intercepted vertical lines, and the number of straight contour points in the grabbing screening line is counted as the actual grabbing number; The grabbing screening line corresponding to the maximum actual grabbing quantity is selected as the actual grabbing line, and the position of the actual grabbing line is used as the middle grabbing position of the pipeline endoscope device; The pipeline endoscope device is controlled to perform grabbing and clearing processing on the middle grabbing position to obtain the pass area.
10. The method according to claim 9, characterized in that Also includes: When it is determined that the pipeline image has water accumulation anomaly, the water accumulation pixel value is retrieved, and the water level of the pipeline image is marked based on the water accumulation pixel value to obtain a water accumulation mark line; Get the center point of the pipeline image based on OpenCV, and use the center point as the coordinate origin to coordinate the pipeline image; Obtain the midpoint of the water accumulation mark line as the midpoint of the water accumulation line, and draw a perpendicular line perpendicular to the water accumulation mark line based on the midpoint of the water accumulation line to obtain the water accumulation perpendicular line; The intersection of the vertical line of accumulated water and the upper boundary of the circular pipe area is the pipe vertex, and the intersection of the vertical line of accumulated water and the lower boundary of the circular pipe area is the pipe base point; Connect the pipeline base point and the midpoint of the water accumulation to obtain the water accumulation depth line, and obtain the water accumulation depth based on the water accumulation depth line; When it is determined that the accumulated water depth is greater than the acquisition height, the difference between the accumulated water depth and the acquisition height is obtained to obtain the diving height; According to the sum of the diving height and the standard collection height, the corresponding upward adjustment height of the collection device on the pipeline endoscopy device is obtained, and the collection device is controlled to rise vertically based on the upward adjustment height.
Citation Information
Patent Citations
Automatic navigation walking method, system, medium and equipment for pipeline inspection robot
CN118732685A