CN114429639B - Pipeline annotation recognition method and device - Google Patents

Pipeline annotation recognition method and device Download PDF

Info

Publication number
CN114429639B
CN114429639B CN202210102815.5A CN202210102815A CN114429639B CN 114429639 B CN114429639 B CN 114429639B CN 202210102815 A CN202210102815 A CN 202210102815A CN 114429639 B CN114429639 B CN 114429639B
Authority
CN
China
Prior art keywords
pipeline
pipe
length
pipe length
mark
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202210102815.5A
Other languages
Chinese (zh)
Other versions
CN114429639A (en
Inventor
王金璐
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Glodon Co Ltd
Original Assignee
Glodon Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Glodon Co Ltd filed Critical Glodon Co Ltd
Priority to CN202210102815.5A priority Critical patent/CN114429639B/en
Publication of CN114429639A publication Critical patent/CN114429639A/en
Application granted granted Critical
Publication of CN114429639B publication Critical patent/CN114429639B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/60Analysis of geometric attributes
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/60Analysis of geometric attributes
    • G06T7/66Analysis of geometric attributes of image moments or centre of gravity
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10004Still image; Photographic image

Landscapes

  • Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Geometry (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Image Analysis (AREA)

Abstract

The invention provides a pipeline annotation recognition method and device, wherein the method comprises the following steps: acquiring a pipe length mark in a region to be identified of a target building engineering drawing; respectively calculating the distance from each pipe length mark to each pipeline in the area to be identified; determining a first pipeline corresponding to each pipe length mark based on the distance from each pipe length mark to each pipeline in the area to be identified; extracting a pipeline set meeting the pipe length marking information along the connection direction of the first pipeline based on the pipe length marking information of the first pipe length marking corresponding to the first pipeline; the first pipe length label is matched to the set of pipes. Therefore, a pipeline belonging to the pipeline length mark is determined by utilizing the distance between the pipeline length mark and the pipeline, and then pipeline collection is extracted along the connection direction of the pipeline according to the pipeline length value of the pipeline length mark, so that automatic identification of the pipeline length mark is realized, the identification efficiency of the pipeline mark is improved, false identification is avoided, the accuracy of the pipeline mark identification is improved, and the user experience is improved.

Description

Pipeline annotation recognition method and device
Technical Field
The invention relates to the technical field of computer aided design, in particular to a pipeline marking and identifying method and a device,
Background
In the existing construction engineering software, many support users to construct a three-dimensional model according to drawings after CAD drawings are imported, and most of the realization modes are that users manually draw the three-dimensional model according to the pipelines of the drawings according to the drawings, but the three-dimensional model takes a lot of time for users, and in order to save the operation time of the users, some software provides a scheme capable of quickly generating pipe member primitives such as drain pipes, and when the pipe member primitives are generated, the corresponding relations between the pipe length and the pipe diameter of each pipeline marking information in the CAD drawings and the pipelines need to be identified.
In the prior art, users are often required to manually identify the pipeline corresponding to each pipeline label. However, because the drawing scene is complex, the pipeline marking information may be under the same layer or not, the connection direction of the pipeline marking information and the pipeline may not correspond, and one pipeline marking may correspond to a plurality of pipelines and the like, so that the conventional manual pipeline marking identification mode is long in time consumption, low in identification efficiency and easy to identify errors.
Disclosure of Invention
In view of the above, the embodiment of the invention provides a method and a device for identifying pipeline labels, which are used for solving the problems that the efficiency is low and the accuracy cannot be ensured by manually identifying the pipeline labels in the prior art.
According to a first aspect, an embodiment of the present invention provides a pipeline annotation identifying method, including:
acquiring a pipe length mark in a region to be identified of a target building engineering drawing;
respectively calculating the distance from each pipe length mark to each pipeline in the area to be identified;
Determining a first pipeline corresponding to each pipe length mark based on the distance from each pipe length mark to each pipeline in the area to be identified;
Extracting a pipeline set meeting the pipe length marking information along the connection direction of the first pipeline based on the pipe length marking information of the first pipe length marking corresponding to the first pipeline;
the first pipe length label is matched to the set of pipes.
Optionally, the calculating the distance of each pipe length label to each pipeline in the area to be identified includes:
acquiring a center point of each pipe length mark;
the distance from each tube length label to each pipeline is determined based on the distance from the center point of each tube length label to each pipeline.
Optionally, the determining, based on the distance from each pipe length label to each pipeline in the area to be identified, a first pipeline corresponding to each pipe length label includes:
Obtaining the distance from each pipe length mark to the current pipeline and the pipe length value of each pipe length mark;
The distance from each pipe length mark to the current pipeline is respectively input into a pipeline identification model to obtain a prediction score corresponding to each pipe length mark;
and determining the pipe length label with the highest prediction score as the current pipe length label corresponding to the current pipe line.
Optionally, the extracting, based on the pipe length labeling information of the first pipe length label corresponding to the first pipe, the pipe set that meets the pipe length labeling information along the connection direction of the first pipe includes:
Sequentially extracting connecting pipelines from the first pipeline along the connecting direction of the first pipeline to form a pipeline set;
determining the actual length of each pipeline set based on the total length of each pipeline set in the target building engineering drawing and the corresponding scale of the target building engineering drawing;
And screening the pipeline sets with the actual length equal to the pipe length value marked by the first pipe length based on the actual length of each pipeline set.
Optionally, before extracting the pipeline set that satisfies the pipe length labeling information along the connection direction of the first pipeline based on the pipe length labeling information of the first pipe length labeling corresponding to the first pipeline, the method further includes:
Acquiring a first length of the first pipeline in the target building engineering drawing and a scale corresponding to the target building engineering drawing;
Determining a first actual length of the first pipeline based on the first length and the scale;
judging whether the first actual length is smaller than a tube length value marked by the first tube length;
When the first actual length is smaller than the first pipe length marked pipe length value, extracting a pipeline set meeting the first pipe length marked information along the connection direction of the first pipeline based on the first pipe length marked information corresponding to the first pipeline;
And when the actual length is equal to the pipe length value of the first pipe length mark, matching the first pipe length mark with the first pipeline.
Optionally, the method further comprises:
Obtaining all pipe diameter labels in a region to be identified of a target building engineering drawing;
Respectively calculating the distance from each pipe diameter mark to each pipeline in the area to be identified;
Determining a second pipeline corresponding to each pipe diameter mark based on the distance from each pipe diameter mark to each pipeline in the area to be identified;
Acquiring a first pipe diameter label corresponding to any pipe in the pipe set based on the second pipe corresponding to each pipe diameter label;
And matching the first pipe diameter label with the pipeline set.
Optionally, before each pipe diameter label in the area to be identified of the target building engineering drawing is acquired, the method further comprises:
Judging whether the first pipe length label contains pipe diameter label information or not;
And when the first pipe length label does not contain pipe diameter label information, acquiring all pipe diameter labels in the area to be identified of the target building engineering drawing.
According to a second aspect, an embodiment of the present invention provides a pipeline annotation recognition apparatus, including:
The acquisition module is used for acquiring the pipe length label in the area to be identified of the target building engineering drawing;
the first processing module is used for respectively calculating the distance from each pipe length mark to each pipeline in the area to be identified;
The second processing module is used for determining a first pipeline corresponding to each pipe length mark based on the distance from each pipe length mark to each pipeline in the area to be identified;
the third processing module is used for extracting a pipeline set meeting the pipe length marking information along the connection direction of the first pipeline based on the pipe length marking information of the first pipe length marking corresponding to the first pipeline;
a fourth processing module for matching the first pipe length label with the set of pipes.
According to a third aspect, embodiments of the present invention provide a computer readable storage medium storing computer instructions which, when executed by a processor, implement a method according to the first aspect of the present invention and any one of its alternatives.
According to a fourth aspect, an embodiment of the present invention provides an electronic device, including: the system comprises a memory and a processor, wherein the memory and the processor are in communication connection, the memory stores computer instructions, and the processor executes the computer instructions, so as to execute the method according to the first aspect of the invention and any optional mode thereof.
The technical scheme of the invention has the following advantages:
The embodiment of the invention provides a pipeline marking identification method and a device, which are used for acquiring a pipeline length marking in a region to be identified of a target building engineering drawing; respectively calculating the distance from each pipe length mark to each pipeline in the area to be identified; determining a first pipeline corresponding to each pipe length mark based on the distance from each pipe length mark to each pipeline in the area to be identified; extracting a pipeline set meeting the pipe length marking information along the connection direction of the first pipeline based on the pipe length marking information of the first pipe length marking corresponding to the first pipeline; the first pipe length label is matched to the set of pipes. Therefore, a pipeline belonging to the pipeline length mark is determined by utilizing the distance between the pipeline length mark and the pipeline, and then pipeline collection is extracted along the connection direction of the pipeline according to the pipeline length value of the pipeline length mark, so that automatic identification of the pipeline corresponding to the pipeline length mark is realized, the identification efficiency of the pipeline mark is improved, the problem that false identification is easy to occur in manual identification is avoided, the accuracy of the pipeline mark identification result is improved, and the user experience is further improved.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings that are needed in the description of the embodiments or the prior art will be briefly described, and it is obvious that the drawings in the description below are some embodiments of the present invention, and other drawings can be obtained according to the drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flow chart of a pipeline annotation recognition method according to an embodiment of the invention;
FIG. 2 is a schematic diagram of a relationship between a target pipeline and a pipe length marking position in an embodiment of the invention;
FIG. 3 is a schematic diagram of a correspondence between a pipeline and a pipe length label in an embodiment of the present invention;
FIG. 4 is a schematic diagram of the positional relationship between the pipeline and the pipe length mark and the pipe diameter mark in the embodiment of the invention;
FIG. 5 is a schematic diagram of a main pipeline and a branch pipeline according to an embodiment of the present invention;
FIG. 6 is a schematic diagram of a pipeline label recognition device according to an embodiment of the present invention;
Fig. 7 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
The following description of the embodiments of the present invention will be made apparent and fully in view of the accompanying drawings, in which some, but not all embodiments of the invention are shown. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
In addition, the technical features of the different embodiments of the present invention described below may be combined with each other as long as they do not collide with each other.
First, technical terms used in the embodiments of the present invention will be described.
The primitives: the graphic primitive is an operable minimum display unit in graphic informatization engineering. Such as: a column, in the patterning software, is shown as a cuboid, which is described as a primitive; the length, width, height, steel bar information and other attributes of the graphic element can be adjusted.
A component: when the core characteristics of most of the primitives are the same, merging the primitives into a component and completing definition of the common characteristic data in the component in order to avoid repeated definition; such as: one set of 400 x 3000 square columns is the same member, and the other set of 500 radius, 3000 height columns is the other member.
Type of component: when a group of components belong to the same class from the service, the components are marked as one class, and the description is given by the component types. For example: columns, beams, walls, panels, are just different component types.
The same layer: the same layer, referred to herein, represents that the same type of primitive for CAD is below one layer. For example: all well primitives within the CAD drawing are under one layer.
In the existing construction engineering software, many support users to construct a three-dimensional model according to drawings after CAD drawings are imported, and most of the realization modes are that users manually draw the three-dimensional model according to the pipelines of the drawings according to the drawings, but the three-dimensional model takes a lot of time for users, and in order to save the operation time of the users, some software provides a scheme capable of quickly generating pipe member primitives such as drain pipes, and when the pipe member primitives are generated, the corresponding relations between the pipe length and the pipe diameter of each pipeline marking information in the CAD drawings and the pipelines need to be identified.
In the prior art, users are often required to manually identify the pipeline corresponding to each pipeline label. However, because the drawing scene is complex, the pipeline marking information may be under the same layer or not, the connection direction of the pipeline marking information and the pipeline may not correspond, and one pipeline marking may correspond to a plurality of pipelines and the like, so that the conventional manual pipeline marking identification mode is long in time consumption, low in identification efficiency and easy to identify errors.
Based on the above problems, an embodiment of the present invention provides a method for identifying a pipeline label, as shown in fig. 1, where the method specifically includes the following steps:
Step S101: and obtaining the pipe length label in the area to be identified of the target building engineering drawing.
In the embodiment of the present invention, the target building engineering drawing is taken as a CAD drawing for example, and in practical application, the target building engineering drawing may also be a building drawing with other formats. The region to be identified is a region corresponding to a user expected to generate a pipe member primitive on the CAD drawing. The pipe length is marked as a marking frame with a pipe length value on the CAD drawing, and only the pipe length value may be marked in the pipe length marking, and the pipe diameter value and the pipe length value are sometimes marked in one marking frame.
Step S102: and respectively calculating the distance from each pipe length mark to each pipeline in the area to be identified.
Specifically, step S102 is performed by obtaining a center point marked by each tube length; the distance from each tube length label to each pipeline is determined based on the distance from the center point of each tube length label to each pipeline. The distance between each tube length label and the different tube lines is thus determined from the point-to-line distance.
Step S103: and determining a first pipeline corresponding to each pipe length mark based on the distance from each pipe length mark to each pipeline in the area to be identified.
In the CAD drawing design, a tube length label is usually set near a corresponding tube, and one tube length label may be the total length of a plurality of tubes connected in sequence, and the closer the tube length label is to the tube, the greater the likelihood that the tube belongs to the label range of the tube length label, so that one tube belonging to the tube length label can be determined according to the distance between the tube length label and the tube.
Step S104: and extracting a pipeline set meeting the pipe length marking information along the connection direction of the first pipeline based on the pipe length marking information of the first pipe length marking corresponding to the first pipeline.
The pipeline set at least comprises a first pipeline or comprises the first pipeline and other pipelines which are connected with the first pipeline in sequence and belong to the first pipeline length label.
Step S105: the first pipe length label is matched to the set of pipes.
Specifically, by acquiring the numbers of all the pipelines in the pipeline set, a corresponding relation between the pipeline numbers and the first pipeline length mark is established, so that the automatic identification of the pipeline corresponding to the pipeline length mark is realized.
By executing the steps, the pipeline marking identification method provided by the embodiment of the invention determines the pipeline belonging to the pipeline marking by utilizing the distance between the pipeline marking and the pipeline, and then extracts the pipeline set for matching according to the pipeline length value of the pipeline marking along the connection direction of the pipeline, thereby realizing the automatic identification of the pipeline corresponding to the pipeline length marking, improving the identification efficiency of the pipeline marking, avoiding the problem that the manual identification is easy to cause false identification, improving the accuracy of the identification result of the pipeline marking, and further improving the user experience.
Specifically, in one embodiment, the step S103 specifically includes the following steps:
Step S301: and obtaining the distance from each pipe length mark to the current pipeline and the pipe length value of each pipe length mark.
The length values are recorded in one length label, l=24.35m and l=18.40m shown in fig. 2 are respectively a length label and a length label B, which are simply referred to as a length a and a length B, a line segment in the middle of the length a and the length B is a target line, and the length values corresponding to the length a and the length B are respectively 24.35m and 18.40m.
Step S302: and respectively inputting the distance from each pipe length mark to the current pipeline and the pipe length value of each pipe length mark into a pipeline identification model to obtain a prediction score corresponding to each pipe length mark.
Specifically, as shown in fig. 2, assuming that the shortest distance from the center point ptA of the pipe length a to the target line is MinA, the pipe length value is ALength; the shortest distance from the center point ptB of the pipe length B to the target line is MinB, and the pipe length value is BLength; the actual length of the target line is ActualLength; weight setting: pipeline distance weight wDis, pipeline length weight lDis, where the sum of wDis and lDis is equal to 1. The specific weight setting can be flexibly adjusted according to the design habit of the CAD drawing, and the invention is not limited to the design habit.
Wherein the pipeline recognition model is represented by the following formula:
M=MinN*wDis+(NLength-ActualLength)*lDis
Wherein M is a prediction score of the pipeline identification model, minN is the shortest distance from the Nth pipe length to the target pipeline, and NLength is the pipe length value of the Nth pipe length.
Predicted score for tube length a = MinA x wDis + (ALength-ActualLength) x lDis;
Predicted score for tube length B = MinB x wDis + (BLength-ActualLength) x lDis.
Step S303: and determining the pipe length label with the highest prediction score as the current pipe length label corresponding to the current pipeline.
Illustratively, assuming that the predictive score for tube length B in fig. 2 is greater than the predictive score for tube length a, tube length B is determined to be the tube length label corresponding to the target pipeline. Therefore, the pipeline distance weight wDis and the pipeline length weight lDis can be flexibly adjusted through the drawing habit of the CAD drawing, and the accuracy of the pipeline length labeling identification result is ensured. The embodiment of the invention can adapt to different CAD drawing habits, has wide application range and strong flexibility, and further improves the use experience of users.
Specifically, in an embodiment, the step S104 specifically includes the following steps:
Step S401: starting from the first pipeline, the connecting pipelines are sequentially extracted along the connecting direction of the first pipeline to form a pipeline set.
Illustratively, as shown in fig. 3, the numbers above the pipelines are the pipeline numbers corresponding to the pipelines, the numbers below the pipelines are the actual lengths of the pipelines corresponding to the pipelines, and assuming that the pipeline No. 3 is matched with the length label of the pipeline No. 6, the process is carried out from one direction of the pipeline No. 3 connection until the collection formed by all the pipelines with the small remainder equal to 6 is found.
Step S402: and determining the actual length of each pipeline set based on the total length of each pipeline set in the target building engineering drawing and the scale corresponding to the target building engineering drawing.
Specifically, on the CAD drawing, the actual length can be obtained by the dimension on the CAD drawing according to a fixed scale, and, for example, assuming that the scale is 1:5000, 1cm on the CAD drawing represents the actual 50m, and if the total length of all the lines in the line set on the CAD drawing is 10cm, the actual length of the line set is 500m, etc., the present invention is not limited to this.
Step S403: based on the actual length of each pipeline set, pipeline sets with the actual length equal to the pipe length value marked by the first pipe length are screened.
Illustratively, as shown in FIG. 3, from pipeline number 3, for example, find first left, find number 3, 2, overall length 5, then find in one direction of the other connection, find number 3, 4, 5, overall length 6. And judging that the right side is more in line with the actual value, so that the pipeline sets of No. 3, no. 4 and No. 5 are selected as the pipeline sets corresponding to the pipe length label L6.
Therefore, the actual length of the pipeline set is calculated by utilizing the scale and the total length of the pipeline set on the CAD drawing, and the matching relation between the pipe length mark and the pipeline set can be accurately matched by comparing the pipe length value of the pipe length mark with the actual length, so that the accuracy of the final pipe length mark identification result is further improved, and the user experience is improved.
Specifically, in an embodiment, before the step S104, the method for identifying a pipeline label specifically further includes the following steps:
Step S41: and acquiring a first length of the first pipeline in the target building engineering drawing and a scale corresponding to the target building engineering drawing.
The first length is the actual length of the first pipeline on the CAD drawing, such as 3 cm.
Step S42: a first actual length of the first pipeline is determined based on the first length and the scale.
Specifically, the actual length calculation manner of the first pipeline is similar to the total length calculation manner of the pipeline set, and will not be described herein.
Step S43: judging whether the first actual length is smaller than a tube length value marked by the first tube length; executing step S104 when the first actual length is smaller than the first pipe length marked pipe length value; and when the actual length is equal to the pipe length value of the first pipe length mark, matching the first pipe length mark with the first pipeline.
In practical application, a condition that one pipe length label corresponds to one pipe line may exist, so that the identification of the pipe length label of the independent pipe line can be directly realized by comparing whether the actual length of the independent pipe line is matched with the pipe length value of the pipe length label, and the subsequent steps are not required to be executed, so that the identification efficiency of the pipe length label is further improved.
Specifically, in an embodiment, the method for identifying a pipeline label specifically further includes the following steps:
Step S106: judging whether the first pipe length label contains pipe diameter label information or not; when the first pipe length label does not include pipe diameter label information, step S107 is performed. And when the pipe diameter marking information is not contained in the first pipe length marking, matching the pipe diameter marking information contained in the first pipe length marking with the pipeline set. . In practical application, the pipeline label comprises a pipe length label and a pipe diameter label, and through realizing automatic matching of the pipe diameter label and the pipeline, automatic matching of the complete pipeline label and the pipeline is realized, the efficiency of identifying the pipeline label is further improved, and the use experience of a user is improved.
Step S107: and obtaining all pipe diameter labels in the area to be identified of the target building engineering drawing.
In practical application, in some CAD drawings, the pipe length label and the pipe diameter label are in different label frames, so that the identification of the pipe diameter label is required to be completely realized, and the matching of the pipe diameter label and the pipe diameter is also required to be realized. And the independent pipe diameters are marked as a marking frame with pipe diameter values on the CAD drawing.
Step S108: and respectively calculating the distance from each pipe diameter mark to each pipeline in the area to be identified.
Specifically, the step S108 is performed by obtaining the center point of each pipe diameter mark; and determining the distance from each pipe diameter mark to each pipeline based on the distance from the central point of each pipe diameter mark to each pipeline. Thereby determining the distance between each pipe diameter label and different pipelines according to the distance from the point to the line.
Step S109: and determining a second pipeline corresponding to each pipe diameter mark based on the distance from each pipe diameter mark to each pipeline in the area to be identified.
In CAD drawing design, the pipe diameter label is usually arranged near the corresponding pipe, and the closer the pipe diameter label is to the pipe diameter, the greater the possibility that the pipe belongs to the label pipe diameter value of the pipe diameter label is, so that one pipe belonging to the pipe diameter label can be determined according to the distance between the pipe diameter label and the pipe.
Step S110: and acquiring a first pipe diameter label corresponding to any pipe in the pipe set based on the second pipe corresponding to each pipe diameter label.
Specifically, any one of the pipelines may have a pipe diameter label corresponding to the pipeline set, and since each pipeline in the pipeline set belongs to a pipe length label, and a plurality of pipelines which are sequentially connected and have the same pipe diameter in the CAD drawing are labeled with the same pipe length, the pipe diameter value of each pipeline in the whole pipeline set can be obtained through the pipe diameter label of any one of the pipelines in the pipeline set. Therefore, the identification efficiency of pipe diameter labeling is further improved, and the use experience of a user is improved.
Step S111: and matching the first pipe diameter label with the pipeline set.
Specifically, a matching relationship can be established between the pipe diameter value corresponding to the first pipe diameter mark and the serial number of each pipe in the pipe assembly, so that automatic identification of the pipe diameter mark is realized, the pipe identification efficiency is further improved, and the user experience is improved.
In addition, in practical application, a pipeline mark which is parallel to the pipeline and closest to the pipeline can be found through the current pipeline, whether the pipeline mark comprises a pipe diameter value and a pipe length value or not is judged, the pipe length value is consistent with the actual length of the current pipeline in the CAD drawing, and if the pipeline mark comprises the pipe diameter value and the pipe length value, and the pipe length value is consistent with the actual length of the current pipeline in the CAD drawing, the pipeline mark is directly matched with the current pipeline.
Illustratively, as shown in FIG. 4, it is assumed that the total pipe lengths of the 1,2, 3 pipes are 41m, the pipe diameters are 300mm, the total pipe lengths of the 4, 5 pipes are 35m, and the pipe diameters are 500mm. By adopting the modes from the step S301 to the step S303, the pipeline 2 can be matched with the pipe diameter DN300, the pipeline 3 is matched with the pipe length L41m, the pipeline 4 is matched with the pipe diameter DN500, and the pipeline 5 is matched with the pipe length L35m. And then finding all pipelines matched with the lengths of the pipelines, namely 3 and 4, finding the marked pipe length of the pipeline 3 to be 41m, finding the pipe length sum of other pipelines connected with the pipeline 3 (the pipelines marked with the pipe lengths) and the latest 41m pipe collection, namely finding the pipe lengths of the pipelines 1,2 and 3 to be closest to 41m, finding the pipeline marked with the pipe diameters from the found pipelines, and assigning the pipe diameters DN300 to the pipelines 1 and 3 without the pipe diameters if the pipeline 2 is matched with the pipe diameters.
In practical application, the pipeline can be matched with the independent pipe length, the independent pipe diameter and the pipe length plus pipe diameter, after the matching, the independent pipe diameter and the independent pipe length matched with the same pipeline are combined, then all pipeline marks matched with the pipeline can be obtained, an optimal pipeline path is searched through the values of the pipe length marks, the mark of the pipe length is considered to be given to the pipes, then the pipe mark matched with the pipe diameter is found on the pipes, and then the pipe diameter is given to the pipes without the pipe diameter, so that the pipe diameter of the pipeline is found. If the pipe with the pipe diameter mark is not found, adopting default pipe diameter and the like, and the invention is not limited to the default pipe diameter.
In addition, in practical application, since only the pipeline label corresponding to the main pipeline is required to be identified, and the branch pipeline does not need to be identified, the embodiment of the invention also provides a method for judging whether the pipeline is the main pipeline or the branch pipeline, which comprises the following specific processes:
Illustratively, as shown in FIG. 5, there are 4 lines, the main lines are 1,2, 3, and the branch lines are 1, 4. The method for judging whether the current pipeline is a branch pipeline comprises the steps of obtaining the starting point and the end point of the current pipeline, constructing a three-dimensional bounding box through a starting point position and then adding a fault tolerance, extracting all primitives intersected with the bounding box, judging the position relation between the point on the current pipeline and the primitives, and if other pipelines except the current pipeline can be found, indicating that the starting point of the current pipeline is connected with other pipelines. Similarly, it is determined whether the end position of the current pipeline is connected to other pipelines, and if both the start point and the end point are connected to the pipelines, the current pipeline is considered to be not a branch pipeline but a main pipeline.
By executing the steps, the pipeline marking identification method provided by the embodiment of the invention determines the pipeline belonging to the pipeline marking by utilizing the distance between the pipeline marking and the pipeline, and then extracts the pipeline set for matching according to the pipeline length value of the pipeline marking along the connection direction of the pipeline, thereby realizing the automatic identification of the pipeline corresponding to the pipeline length marking, improving the identification efficiency of the pipeline marking, avoiding the problem that the manual identification is easy to cause false identification, improving the accuracy of the identification result of the pipeline marking, and further improving the user experience.
The embodiment of the invention also provides a pipeline marking and identifying device, as shown in fig. 6, which specifically comprises:
The obtaining module 101 is configured to obtain a tube length label in a region to be identified of the target building engineering drawing. For details, refer to the related description of step S101 in the above method embodiment, and no further description is given here.
A first processing module 102 is configured to calculate a distance from each pipe length label to each pipeline in the area to be identified. For details, refer to the related description of step S102 in the above method embodiment, and no further description is given here.
And the second processing module 103 is used for determining a first pipeline corresponding to each pipe length label based on the distance from each pipe length label to each pipeline in the area to be identified. For details, see the description of step S103 in the above method embodiment, and the details are not repeated here.
The third processing module 104 is configured to extract, based on the pipe length labeling information of the first pipe length label corresponding to the first pipe, a pipe set that satisfies the pipe length labeling information along the connection direction of the first pipe. For details, refer to the related description of step S104 in the above method embodiment, and no further description is given here.
A fourth processing module 105 for matching the first pipe length label to the pipeline set. For details, see the description of step S105 in the above method embodiment, and the details are not repeated here.
Further functional descriptions of the above respective modules are the same as those of the above corresponding method embodiments, and are not repeated here.
Through the cooperation of the components, the pipeline marking and identifying device provided by the embodiment of the invention determines one pipeline belonging to the pipeline length marking by utilizing the distance between the pipeline length marking and the pipeline, and then extracts a pipeline set for matching along the connecting direction of the pipeline according to the pipeline length value of the pipeline length marking, thereby realizing the automatic identification of the pipeline corresponding to the pipeline length marking, improving the identification efficiency of the pipeline marking, avoiding the problem that the manual identification is easy to cause false identification, improving the accuracy of the pipeline marking and identifying result, and further improving the user experience.
The present invention also provides an electronic device, as shown in fig. 7, which may include a processor 901 and a memory 902, where the processor 901 and the memory 902 may be connected by a bus or other means, and in fig. 7, the connection is exemplified by a bus.
The processor 901 may be a central processing unit (Central Processing Unit, CPU). The Processor 901 may also be other general purpose processors, digital signal processors (DIGITAL SIGNAL processors, DSPs), application SPECIFIC INTEGRATED Circuits (ASICs), field-Programmable gate arrays (Field-Programmable GATE ARRAY, FPGA) or other Programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, or combinations thereof.
The memory 902 is used as a non-transitory computer readable storage medium for storing non-transitory software programs, non-transitory computer executable programs, and modules, such as program instructions/modules corresponding to the methods of the embodiments of the present invention. The processor 901 performs various functional applications of the processor and data processing, i.e., implements the above-described methods, by running non-transitory software programs, instructions, and modules stored in the memory 902.
The memory 902 may include a storage program area and a storage data area, wherein the storage program area may store an operating device, at least one application program required for a function; the storage data area may store data created by the processor 901, and the like. In addition, the memory 902 may include high-speed random access memory, and may also include non-transitory memory, such as at least one magnetic disk storage device, flash memory device, or other non-transitory solid state storage device. In some embodiments, memory 902 optionally includes memory remotely located relative to processor 901, which may be connected to processor 901 via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
One or more modules are stored in the memory 902 that, when executed by the processor 901, perform the methods described above.
The specific details of the electronic device may be correspondingly understood by referring to the corresponding related descriptions and effects in the above method embodiments, which are not repeated herein.
It will be appreciated by those skilled in the art that implementing all or part of the above-described methods in the embodiments may be implemented by a computer program for instructing relevant hardware, and the implemented program may be stored in a computer readable storage medium, and the program may include the steps of the embodiments of the above-described methods when executed. The storage medium may be a magnetic disk, an optical disk, a Read-Only Memory (ROM), a random access Memory (Random Access Memory, RAM), a Flash Memory (Flash Memory), a hard disk (HARD DISK DRIVE, abbreviated as HDD), a Solid state disk (Solid-STATE DRIVE, SSD), or the like; the storage medium may also comprise a combination of memories of the kind described above.
The above embodiments are only for illustrating the technical aspects of the present invention and not for limiting the same, and although the present invention has been described in detail with reference to the above embodiments, it should be understood by those of ordinary skill in the art that: modifications and equivalents may be made to the specific embodiments of the invention without departing from the spirit and scope of the invention, which is intended to be covered by the scope of the claims.

Claims (10)

1. A method for identifying pipeline labels, comprising:
acquiring a pipe length mark in a region to be identified of a target building engineering drawing;
respectively calculating the distance from each pipe length mark to each pipeline in the area to be identified;
Determining a first pipeline corresponding to each pipe length mark based on the distance from each pipe length mark to each pipeline in the area to be identified;
Extracting a pipeline set meeting the pipe length marking information along the connection direction of the first pipeline based on the pipe length marking information of the first pipe length marking corresponding to the first pipeline;
the first pipe length label is matched to the set of pipes.
2. The method of claim 1, wherein the separately calculating the distance each tube length is marked to each pipeline in the area to be identified comprises:
acquiring a center point of each pipe length mark;
the distance from each tube length label to each pipeline is determined based on the distance from the center point of each tube length label to each pipeline.
3. The method of claim 1, wherein determining a first pipeline corresponding to each tube length label based on a distance of each tube length label to each pipeline in the region to be identified, comprises:
Obtaining the distance from each pipe length mark to the current pipeline and the pipe length value of each pipe length mark;
The distance from each pipe length mark to the current pipeline is respectively input into a pipeline identification model to obtain a prediction score corresponding to each pipe length mark;
and determining the pipe length label with the highest prediction score as the current pipe length label corresponding to the current pipe line.
4. A method according to claim 3, wherein the extracting, along the connection direction of the first pipeline, the set of pipelines satisfying the pipe length labeling information based on the pipe length labeling information of the first pipe length label corresponding to the first pipeline includes:
Sequentially extracting connecting pipelines from the first pipeline along the connecting direction of the first pipeline to form a pipeline set;
determining the actual length of each pipeline set based on the total length of each pipeline set in the target building engineering drawing and the corresponding scale of the target building engineering drawing;
And screening the pipeline sets with the actual length equal to the pipe length value marked by the first pipe length based on the actual length of each pipeline set.
5. The method according to claim 1, wherein before extracting a set of pipes satisfying the pipe length labeling information in a connection direction of the first pipe based on the pipe length labeling information of the first pipe corresponding to the first pipe, the method further comprises:
Acquiring a first length of the first pipeline in the target building engineering drawing and a scale corresponding to the target building engineering drawing;
Determining a first actual length of the first pipeline based on the first length and the scale;
judging whether the first actual length is smaller than a tube length value marked by the first tube length;
When the first actual length is smaller than the first pipe length marked pipe length value, extracting a pipeline set meeting the first pipe length marked information along the connection direction of the first pipeline based on the first pipe length marked information corresponding to the first pipeline;
And when the actual length is equal to the pipe length value of the first pipe length mark, matching the first pipe length mark with the first pipeline.
6. The method as recited in claim 4, further comprising:
Obtaining all pipe diameter labels in a region to be identified of a target building engineering drawing;
Respectively calculating the distance from each pipe diameter mark to each pipeline in the area to be identified;
Determining a second pipeline corresponding to each pipe diameter mark based on the distance from each pipe diameter mark to each pipeline in the area to be identified;
Acquiring a first pipe diameter label corresponding to any pipe in the pipe set based on the second pipe corresponding to each pipe diameter label;
And matching the first pipe diameter label with the pipeline set.
7. The method of claim 6, wherein prior to obtaining each pipe diameter annotation within the area to be identified of the target construction engineering drawing, the method further comprises:
Judging whether the first pipe length label contains pipe diameter label information or not;
And when the first pipe length label does not contain pipe diameter label information, acquiring all pipe diameter labels in the area to be identified of the target building engineering drawing.
8. A pipeline marking identification device, comprising:
The acquisition module is used for acquiring the pipe length label in the area to be identified of the target building engineering drawing;
the first processing module is used for respectively calculating the distance from each pipe length mark to each pipeline in the area to be identified;
The second processing module is used for determining a first pipeline corresponding to each pipe length mark based on the distance from each pipe length mark to each pipeline in the area to be identified;
the third processing module is used for extracting a pipeline set meeting the pipe length marking information along the connection direction of the first pipeline based on the pipe length marking information of the first pipe length marking corresponding to the first pipeline;
a fourth processing module for matching the first pipe length label with the set of pipes.
9. A computer readable storage medium storing computer instructions which, when executed by a processor, implement the method of any one of claims 1-7.
10. An electronic device, comprising:
A memory and a processor, the memory and the processor being communicatively coupled to each other, the memory having stored therein computer instructions that, when executed, cause the processor to perform the method of any of claims 1-7.
CN202210102815.5A 2022-01-27 2022-01-27 Pipeline annotation recognition method and device Active CN114429639B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210102815.5A CN114429639B (en) 2022-01-27 2022-01-27 Pipeline annotation recognition method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210102815.5A CN114429639B (en) 2022-01-27 2022-01-27 Pipeline annotation recognition method and device

Publications (2)

Publication Number Publication Date
CN114429639A CN114429639A (en) 2022-05-03
CN114429639B true CN114429639B (en) 2024-05-03

Family

ID=81312831

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210102815.5A Active CN114429639B (en) 2022-01-27 2022-01-27 Pipeline annotation recognition method and device

Country Status (1)

Country Link
CN (1) CN114429639B (en)

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20130028393A (en) * 2011-09-09 2013-03-19 현대중공업 주식회사 Automatic output method for duct manufacturing drawing
CN107169203A (en) * 2017-05-17 2017-09-15 重庆尔安机电设备工程有限公司 A kind of plumbing system auto-discharing method
CN108121863A (en) * 2017-12-13 2018-06-05 机械工业第六设计研究院有限公司 Creation method, device, equipment and the computer readable storage medium of pipeline label
CN110717207A (en) * 2019-09-06 2020-01-21 景森设计股份有限公司 Labeling method, system and storage medium for pipeline design
CN110851956A (en) * 2019-10-11 2020-02-28 南昌大学 Automatic calculation, labeling and plotting method for construction engineering pipeline construction positioning information
CN111814664A (en) * 2020-07-07 2020-10-23 广联达科技股份有限公司 Method and device for identifying marks in drawing, computer equipment and storage medium
CN112149204A (en) * 2020-09-22 2020-12-29 合肥小龟快跑信息科技有限公司 Method for automatically searching position pointed by caption in CAD file
CN112257629A (en) * 2020-10-29 2021-01-22 广联达科技股份有限公司 Text information identification method and device for construction drawing
CN112446870A (en) * 2020-12-02 2021-03-05 平安科技(深圳)有限公司 Pipeline damage detection method, device, equipment and storage medium
CN112464903A (en) * 2020-12-16 2021-03-09 广联达科技股份有限公司 Primitive identification method and device of municipal construction drawing and electronic equipment

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20130028393A (en) * 2011-09-09 2013-03-19 현대중공업 주식회사 Automatic output method for duct manufacturing drawing
CN107169203A (en) * 2017-05-17 2017-09-15 重庆尔安机电设备工程有限公司 A kind of plumbing system auto-discharing method
CN108121863A (en) * 2017-12-13 2018-06-05 机械工业第六设计研究院有限公司 Creation method, device, equipment and the computer readable storage medium of pipeline label
CN110717207A (en) * 2019-09-06 2020-01-21 景森设计股份有限公司 Labeling method, system and storage medium for pipeline design
CN110851956A (en) * 2019-10-11 2020-02-28 南昌大学 Automatic calculation, labeling and plotting method for construction engineering pipeline construction positioning information
CN111814664A (en) * 2020-07-07 2020-10-23 广联达科技股份有限公司 Method and device for identifying marks in drawing, computer equipment and storage medium
CN112149204A (en) * 2020-09-22 2020-12-29 合肥小龟快跑信息科技有限公司 Method for automatically searching position pointed by caption in CAD file
CN112257629A (en) * 2020-10-29 2021-01-22 广联达科技股份有限公司 Text information identification method and device for construction drawing
CN112446870A (en) * 2020-12-02 2021-03-05 平安科技(深圳)有限公司 Pipeline damage detection method, device, equipment and storage medium
CN112464903A (en) * 2020-12-16 2021-03-09 广联达科技股份有限公司 Primitive identification method and device of municipal construction drawing and electronic equipment

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
Revit管线自动标注方法的实现;李昌华;李桐;周方晓;崔欢欢;;土木建筑工程信息技术;20160215(第01期);全文 *

Also Published As

Publication number Publication date
CN114429639A (en) 2022-05-03

Similar Documents

Publication Publication Date Title
CN112651373B (en) Method and device for identifying text information of building drawing
US20070165034A1 (en) Snap To Element Analytical Tool
JP2020038624A (en) Lane line processing method and device
CN102428491A (en) Location-based data service apparatus and method
CN105095617A (en) Method and device for constructing missing part of target movement track of object
CN108170807B (en) Map data processing method, map drawing method, map data processing device, map drawing device, map data processing equipment and storage medium
EP3633551A1 (en) Obstacle distribution simulation method, device and terminal based on a probability graph
CN114429639B (en) Pipeline annotation recognition method and device
CN114882719A (en) Control method, device, medium and electronic equipment for intelligent calling vehicle
CN113887043A (en) Method, device and equipment for determining breakpoint on steel bar primitive and storage medium
CN104899908A (en) Method and device for generating evolution diagram of event group
CN110728359B (en) Method, device, equipment and storage medium for searching model structure
US20140089234A1 (en) Interactive visualization of multi-objective optimization
CN106651803A (en) House type data identification method and device
CN113781569B (en) Loop detection method and device
US7844419B1 (en) Method of detecting potential topology problems in a network
CN112053116B (en) Method and device for identifying carpooling orders
CN113008249B (en) Avoidance point detection method and avoidance method of mobile robot and mobile robot
CN108920749B (en) Pipeline two-dimensional and three-dimensional data updating method and device and computer readable storage medium
CN113624245A (en) Navigation method and device, computer storage medium and electronic equipment
CN113538465A (en) Automatic dividing method and device for regular and irregular polygon areas and storage medium
CN109840609B (en) Goods picking point data verification method and device, storage medium and electronic equipment
CN110851896A (en) CAD (computer-aided design) outer wall body identification method and device based on local neighborhood information
CN112799404B (en) Global path planning method and device of AGV and computer readable storage medium
KR102156621B1 (en) Device and method for creating automatic device linear map of GIS

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant