Modern engineering, procurement, and construction (EPC) companies increasingly rely on digital piping and instrumentation diagram (P&ID) platforms to support chemical process design, monitoring, and control. These systems manage flow paths, equipment, and interconnections critical to plant operations. Compared to traditional paper-based formats, digital P&IDs offer advantages such as improved safety through predictive simulation, faster design validation, and better data sharing and version control across engineering teams.
However, image- and PDF-based P&IDs are still common in practice, especially during inter-organizational collaboration or when dealing with legacy systems. These unstructured formats are often shared due to confidentiality constraints, highlighting the need for technologies that can convert them into structured digital representations. This digitization process typically involves three steps: (1) detecting objects such as symbols, lines, and text, (2) identifying logical connections, and (3) assigning engineering attributes to create a usable digital diagram for simulation, validation, and smart plant applications.
P&IDs primarily comprise three types of graphical elements: symbols, text, and lines. As illustrated in Fig. 1, pipelines that represent process connectivity and fluid flow are typically depicted as thick continuous lines. Thinner continuous lines are also common, serving various engineering purposes such as annotation, dimensioning, and reference, and are classified into leader lines, dimension lines, and extension lines. Other line types include dotted, dashed, or slashed patterns, which represent signal transmission (e.g., electrical or pneumatic), and arrows that indicate flow direction or highlight critical components.
Among these components, line objects are the most difficult to interpret accurately due to their visual similarity and frequent overlap with other objects. First, line segments often intersect with symbols or text, making segmentation difficult. Additionally, some lines share similar geometric properties but serve different functions, complicating functional classification. For example, pipelines and leader lines may both appear as continuous straight segments but differ significantly in their process roles.
To address these challenges, this study proposes a hybrid method for the comprehensive recognition and functional classification of line objects in image-based P&IDs. The method comprises two primary stages: (1) identifying all line segments and classifying them into continuous lines and lines with special signs through a Deep Learning (DL) model, and (2) applying rule-based logic to further classify continuous lines into dimension, extension, and leader types.
The DL model incorporates arrow detection to infer signal or fluid flow direction, thereby supporting the reconstruction of flow and control pathways. This study makes several contributions to the domain of process diagram digitization and design automation. First, it introduces a method capable of recognizing and classifying nearly all types of line objects in high-density P&IDs. Second, it presents a high-accuracy recognition pipeline that combines DL, rule-based techniques, and classical image processing. Third, it defines a complete labeling schema for training deep neural networks specialized in line recognition. Fourth, it establishes a neutral structured output format suitable for downstream use in digital plant systems, including process simulation, control loop verification, and safety analysis.
The remainder of this paper is organized as follows. Section 2 reviews the related work. Section 3 describes the types of line objects in P&IDs and presents the proposed approach. Section 4 details the technical implementation of line classification, while Section 5 reports the experimental results and analysis. Finally, Section 6 concludes the paper.