Two-dimensional drawing and three-dimensional model mapping method and system based on named feature analysis

CN123012524APending Publication Date: 2026-10-30POWERCHINA JIANGXI ELECTRIC POWER ENGINEERING CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611118266.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-07-27
Publication Date
2026-10-30

AI Technical Summary

Technical Problem

人工挂接方式耗时费力,面对大规模工程数据时人力成本高且一致性难以保障

Benefits of technology

本发明通过构建可配置的命名规范解析模板,替代传统硬编码正则匹配方式,因此能够快速适配不同设计主体的差异化命名规则,显著降低多源图纸接入的配置维护成本。由于仅以文件完整存储路径作为特征提取的唯一信息来源,无需解析图纸内部图文内容,故而规避了光学字符识别受画质、字体、图层干扰导致的稳定性问题,提升了特征提取的可靠性与执行效率。通过图纸与模型复用同一套标准化算子构建统一语义度量空间,配合四级层级递进对齐机制自上而下逐级压缩匹配范围,因此有效解决了两端语义异构与全局匹配效率低的问题,大幅提升匹配准确率与处理速度。结合来源加权置信度分级判定与双向索引增量更新机制,进一步兼顾了自动匹配效率与结果可信度,同时支持图模双向追溯查询,降低设计变更场景下的映射维护开销,整体提升工程图模关联的自动化水平与工程应用价值。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123012524A_ABST
    Figure CN123012524A_ABST
Patent Text Reader

Abstract

The application discloses a kind of based on naming feature analysis two-dimensional drawing and three-dimensional model mapping method and system, it is related to data processing technical field.The method includes: constructing naming specification analysis template, defining field dimension, separator enumeration, cleaning logic and synonymous mapping relationship;Two-dimensional drawing is executed full-path semantic feature extraction, and the missing field of filename is completed by multistage directory backtracking, and standard feature information on drawing side is generated after unified standardization processing;Iterate three-dimensional power grid information model tree structure and extract component attribute, reuse the same set of standardized operator processing on drawing side, generate model side standard feature information in the same semantic metric space;Using four-level hierarchical progressive alignment mechanism, from top to bottom compression matching space;Combined with source weighted confidence model, complete hierarchical determination, build bidirectional index repository and support incremental dynamic maintenance.The application improves drawing and model mapping efficiency and accuracy, reduces adaptation and change maintenance cost.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of data processing technology, specifically to a method and system for mapping two-dimensional drawings to three-dimensional models based on named feature parsing. Background Technology

[0002] With the continuous expansion of power grid construction and the deepening of digital transformation, three-dimensional power grid information models are widely used in the design phase of power transmission and transformation projects, forming a technical data system where two-dimensional engineering drawings and three-dimensional digital models coexist. Establishing the correspondence between two-dimensional drawings and three-dimensional models is a crucial foundation for achieving collaborative mapping and data retrieval in engineering design, construction handover, and operation and maintenance management. A single substation or line project typically involves thousands of professional drawings and tens of thousands of three-dimensional components. The mapping and association between these two types of drawings is labor-intensive and highly repetitive; therefore, the efficiency and accuracy of this association directly impact the quality of engineering design delivery and the effectiveness of subsequent digital applications.

[0003] Currently, the mapping and association between 2D drawings and 3D models mainly relies on two technical approaches. One is the manual method, where designers identify the corresponding 3D components on each drawing, manually establish the binding relationship between the two, and enter it into the management system. The other is the automatic recognition method, which uses optical character recognition (OCR) technology to read the text information in the drawing's title block, extract identification fields such as drawing name and drawing number, and then compare and match them with the attributes of the 3D components. Some solutions use fixed rules to parse the drawing file name, extract key fields such as pole / tower number and professional category, and then perform string matching with the model attributes to complete the association. The mapping relationship is mostly stored in a one-way list format, supporting querying related drawings from the model. When the design changes, the matching process is fully re-executed to update the mapping relationship.

[0004] Existing technical solutions have several limitations in practical engineering applications. Manual data linking is time-consuming and labor-intensive, leading to high manpower costs and difficulty in ensuring consistency when dealing with large-scale engineering data. Solutions based on drawing label text recognition are susceptible to interference from factors such as overlapping drawing layers, differences in scanned image quality, and diverse font styles, resulting in insufficient recognition stability and limited adaptability to engineering implementation. Solutions using fixed rules to parse filenames have weak adaptability to the differentiated naming conventions of different design entities, requiring frequent adjustments to matching rules when switching design sources, leading to high maintenance costs. Furthermore, global pairwise matching methods have low computational efficiency, the lack of standardized semantic alignment mechanisms limits matching accuracy, and unidirectional storage mapping relationships are insufficient to meet the engineering requirements of bidirectional traceability queries. Summary of the Invention

[0005] In view of the shortcomings of the prior art, the purpose of this invention is to provide a method and system for mapping two-dimensional drawings and three-dimensional models based on naming feature parsing, in order to solve the above-mentioned problems described in the prior art.

[0006] The first aspect of the present invention is to provide a method for mapping two-dimensional drawings to three-dimensional models based on naming feature parsing, the method comprising: Construct a naming convention parsing template, which defines field dimensions, delimiter enumeration, cleaning logic, and synonym mapping relationships; Full-path semantic feature extraction is performed on 2D drawings. Missing fields in file names are filled by tracing back through multi-level directories. After unified standardization processing, standard feature information on the drawing side is generated. Feature extraction uses the complete storage path of the file as the only source of information. Extract component attributes by traversing the tree-like spatial structure of the 3D power grid information model, reuse the same set of standardized operators from the drawing side to process model attributes, and generate standard feature information from the model side. A four-level hierarchical alignment mechanism (engineering, line, tower, and professional) is adopted to compare standard feature information between the drawing side and the model side, and the candidate set is filtered from top to bottom. By combining the source-weighted confidence model to perform hierarchical determination of graph model mapping, a bidirectional index repository is constructed and incremental dynamic maintenance is performed on design changes.

[0007] According to one aspect of the above technical solution, the step of constructing the naming convention parsing template specifically includes: The naming convention parsing template is configured into four components: a semantic field set, a separator set, a field cleaning rule set, and a professional synonym lookup table. The semantic field set defines the semantic dimensions of the parsed project and their corresponding data types. The separator set covers all separator symbols used in the naming of the design subject. The field cleaning rule set defines exclusive standardized processing logic for each type of semantic field. The professional synonym lookup table stores the mapping relationship between multiple synonym expressions of the same project semantic and the unique standard value. When setting up a loosely coupled architecture between the template and the mapping engine, the core logic of feature extraction, standardization calculation, and matching determination of the mapping engine remains unchanged when a new design subject is connected or the naming convention is updated. Only the template configuration content is adjusted, and multiple naming templates are stored and called in parallel according to the project dimension.

[0008] According to one aspect of the above technical solution, the step of performing full-path semantic feature extraction on the two-dimensional drawing specifically includes: The complete storage path of the split drawing is divided into multi-level directory nodes and file name nodes. The semantic content of each node is parsed layer by layer in a bottom-up backtracking order. For missing engineering semantic fields in the file name, the backtracking process is completed by tracing back to each level of directory node in turn. The backtracking process is terminated when the root directory node is reached. Perform conflict detection on filenames and fields with the same name extracted from directories at all levels, and perform conflict resolution according to the priority rules of the field source level. Filename level fields have higher priority than directory level fields, and output the initial feature information of the drawing.

[0009] According to one aspect of the above technical solution, the step of generating standard feature information on the model side specifically includes: The three-dimensional power grid information model is traversed in depth according to the four-level tree structure of engineering, line, tower group, and component. The original attribute values ​​corresponding one-to-one with the template semantic fields are extracted at each level node to form a hierarchical attribute set covering the entire model. The same set of standardized operators is reused on both the drawing and model sides to perform cleaning processing. For numerical fields, unit removal and leading zero removal are performed for numerical normalization, and for text fields, synonym mapping and character normalization are performed for text normalization, thus unifying the heterogeneous expressions at both ends into standard values.

[0010] According to one aspect of the above technical solution, the step of using a four-level hierarchical progressive alignment mechanism to filter the candidate set from top to bottom specifically includes: The first-level engineering dimension performs batch grouping of all drawings and all model components through the voltage level field, splitting the global matching space into several independent voltage level groups; the second-level line dimension further subdivides the matching units within each group through line identifiers; the third-level tower dimension performs filtering within each line unit by matching tower type strings and comparing tower number values; the fourth-level professional dimension aligns the drawings and component categories through professional standard enumeration values. Each level of filtering outputs intermediate matching results, which are then used as the input set for the next level of filtering.

[0011] According to one aspect of the above technical solution, the step of performing graph-pattern mapping hierarchical determination by combining the source-weighted confidence model specifically includes: Differentiated weight coefficients are set for different semantic fields, with core fields having higher weights than auxiliary fields, and filename source fields having higher weights than directory source fields; the comprehensive matching score is calculated by normalizing the weighted sum of the matching status of each field and its corresponding weight. Two judgment thresholds are preset: a high judgment threshold and a low judgment threshold. Candidate mappings with a comprehensive matching score greater than or equal to the high judgment threshold are judged as valid mappings and automatically added to the database. Candidate mappings with a comprehensive matching score between the two thresholds are marked as pending manual review. Candidate mappings with a comprehensive matching score lower than the low judgment threshold are judged as matching failures and the corresponding reasons are recorded.

[0012] According to one aspect of the above technical solution, the step of constructing a bidirectional index repository and performing incremental dynamic maintenance on design changes specifically includes: Two types of bidirectional query indexes are established: forward index and reverse index. The forward index uses the unique identifier of the 3D component as the primary key to associate all drawing paths and mapping metadata corresponding to the component. The reverse index uses the complete drawing path as the primary key to associate all component identifiers and spatial positioning parameters bound to the drawing. Both types of indexes are updated synchronously. The system monitors two types of change events: changes in drawing file naming and updates to 3D model versions. When a change is detected, the change node is identified and feature extraction and matching calculations are re-executed. Components that have not undergone changes retain their existing mapping relationship with the drawings.

[0013] A second aspect of the present invention is to provide a two-dimensional drawing and three-dimensional model mapping system based on naming feature parsing, for performing the method described in the above technical solution, the system comprising: The naming template configuration module is used to build a naming convention parsing template, which defines field dimensions, delimiter enumeration, cleaning logic, and synonym mapping relationships. The drawing feature extraction module is used to perform full-path semantic feature extraction on two-dimensional drawings. It completes missing fields in the file name by tracing back through multi-level directories, and generates standard feature information on the drawing side after unified standardization processing. The feature extraction takes the complete storage path of the file as the only source of information. The dual-end attribute parsing module is used to traverse the tree-like spatial structure of the 3D power grid information model to extract component attributes, reuse the same set of standardized operators from the drawing side to process model attributes, and generate standard feature information from the model side. The hierarchical alignment matching module is used to compare the standard feature information of the drawing side and the model side using a four-level hierarchical alignment mechanism of engineering, line, tower and professional, and filter the candidate set from top to bottom. The bidirectional mapping management module is used to perform hierarchical determination of graph-model mapping by combining the source weighted confidence model, build a bidirectional index repository, and perform incremental dynamic maintenance on design changes.

[0014] A third aspect of the present invention is to provide a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the steps of the method described in the above-described technical solutions.

[0015] A fourth aspect of the present invention is to provide an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the method described in the above technical solutions.

[0016] Compared with existing technologies, the advantages of the two-dimensional drawing and three-dimensional model mapping method and system based on naming feature parsing shown in this invention are as follows: This invention replaces the traditional hard-coded regular expression matching method by constructing a configurable naming convention parsing template, thus enabling rapid adaptation to the differentiated naming rules of different design entities and significantly reducing the configuration and maintenance costs of multi-source drawing access. Since only the complete file storage path is used as the sole source of information for feature extraction, there is no need to parse the internal text and graphics content of the drawing, thereby avoiding the stability issues caused by image quality, font, and layer interference in optical character recognition, and improving the reliability and execution efficiency of feature extraction. By reusing the same set of standardized operators to construct a unified semantic metric space for drawings and models, and using a four-level hierarchical progressive alignment mechanism to compress the matching range from top to bottom, the invention effectively solves the problems of semantic heterogeneity at both ends and low global matching efficiency, significantly improving matching accuracy and processing speed. Combined with source-weighted confidence grading and a bidirectional index incremental update mechanism, the invention further balances automatic matching efficiency and result reliability, while supporting bidirectional traceability queries between drawings and models, reducing mapping and maintenance overhead in design change scenarios, and comprehensively improving the automation level and engineering application value of engineering drawing-model association. Attached Figure Description

[0017] The above and / or additional aspects and advantages of the present invention will become apparent and readily understood from the description of the embodiments taken in conjunction with the following drawings, in which: Figure 1 A flowchart illustrating the method for mapping two-dimensional drawings to three-dimensional models based on naming feature parsing provided in an embodiment of the present invention; Figure 2 The structural block diagram of the two-dimensional drawing and three-dimensional model mapping system based on naming feature parsing provided in the embodiments of the present invention. Detailed Implementation

[0018] To make the objectives, features, and advantages of the present invention more apparent and understandable, specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings. Several embodiments of the present invention are shown in the drawings. However, the present invention can be implemented in many different forms and is not limited to the embodiments described herein. Rather, these embodiments are provided so that the disclosure of the present invention will be more thorough and complete.

[0019] It should be noted that when a component is said to be "fixed to" another component, it can be directly on the other component or there may be an intervening component. When a component is said to be "connected to" another component, it can be directly connected to the other component or there may be an intervening component. The terms "vertical," "horizontal," "left," "right," and similar expressions used in this document are for illustrative purposes only.

[0020] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention pertains. The terminology used herein in the description of the invention is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. The term "and / or" as used herein includes any and all combinations of one or more of the associated listed items.

[0021] Example 1 Please see Figure 1 The first embodiment of the present invention provides a method for mapping two-dimensional drawings to three-dimensional models based on naming feature parsing, the method comprising steps S10-S50: Step S10: Construct a naming convention parsing template, which defines field dimensions, delimiter enumeration, cleaning logic, and synonym mapping relationships.

[0022] Step S20: Perform full-path semantic feature extraction on the two-dimensional drawing. Complete the missing fields of the file name by tracing back through multi-level directories. After unified standardization processing, generate standard feature information on the drawing side. Feature extraction takes the complete storage path of the file as the only source of information.

[0023] Step S30: Traverse the tree-like spatial structure of the three-dimensional power grid information model to extract component attributes, reuse the same set of standardized operators from the drawing side to process model attributes, and generate standard feature information from the model side.

[0024] Step S40: A four-level hierarchical alignment mechanism (engineering, line, tower, and specialty) is used to compare the standard feature information between the drawing side and the model side, and the candidate set is filtered from top to bottom.

[0025] Step S50: Combine the source-weighted confidence model to perform graph-model mapping hierarchical determination, build a bidirectional index repository, and perform incremental dynamic maintenance on design changes.

[0026] The method for mapping 2D drawings to 3D models based on named feature parsing, as presented in this embodiment, relies on a computer program running on a computing device with file system access capabilities and 3D model parsing capabilities. The overall technical solution revolves around two main lines: named feature parsing and attribute alignment. Through a complete closed-loop process of template configuration, feature extraction, standardization processing, hierarchical matching, graded judgment, and index maintenance, it achieves automated mapping between 2D drawings and 3D power grid information models. This method is applicable to drawing-model association scenarios in the power grid engineering design phase and can handle batch mapping tasks of thousands of drawings and tens of thousands of components in a single project.

[0027] Specifically, the naming convention parsing template serves as the configuration hub for this mapping method, centrally defining four core configuration items: field dimensions, delimiter enumeration, cleaning logic, and synonym mapping relationships. Field dimensions define the engineering semantic boundaries that the method can recognize; delimiter enumeration supports filename splitting operations; cleaning logic standardizes the output format of various fields; and synonym mapping relationships unify the representation of synonyms from different sources. This template is persistently stored as a structured configuration file, allowing for on-demand loading and calling during subsequent feature extraction and standardization stages. Adjustments to the template content do not affect the main logic of the mapping engine, achieving separation of configuration and computation.

[0028] The extraction of semantic features from the entire path of 2D drawings relies solely on the complete storage path of the drawing file as the sole source of information, without reading or parsing any text or graphic content within the drawing file. The complete path is hierarchically split, separating the directory levels and filenames, and the semantic information carried by each level is parsed separately. For semantic fields not covered in the filename, a backtracking search is performed along the directory hierarchy from bottom to top to complete the information, ensuring that as much semantic information as possible is collected. After the extracted raw semantic fields undergo standardized processing, the output is a formatted standard feature information for the drawing side, serving as the data source for subsequent matching and comparison.

[0029] The attribute extraction and standardization of the 3D power grid information model involves traversing the model's tree-like spatial structure. In this embodiment, the original attribute values ​​of each component are extracted layer by layer, and the same set of standardized operators used on the drawing side are fully reused to process the model attributes. Reusing the same set of standardized operators on both ends ensures that the standard feature information output from the drawing side and the model side is under the same representation system, eliminating comparison barriers caused by the heterogeneity of semantic expressions at both ends. After the attribute extraction on the model side is completed, independent feature entries are formed on a component-by-component basis, corresponding one-to-one with the feature entries on the drawing side for subsequent matching.

[0030] The four-level hierarchical alignment mechanism is responsible for the core matching function. Specifically, it filters the candidate set from top to bottom according to four dimensions: engineering, line, tower, and specialty. Each level of filtering is based on the feature fields of the corresponding dimension to screen the candidate set. Candidate pairs that pass the screening proceed to the next level for further comparison, while candidate pairs that fail are directly removed from the candidate set.

[0031] After the four levels of filtering are executed sequentially, the size of the candidate set is significantly reduced, and the final output consists of candidate mapping pairs that satisfy all dimension matching conditions, which then proceed to the subsequent confidence determination stage. Compared to global pairwise comparison, the above-mentioned hierarchical filtering method has a significant computational efficiency advantage in scenarios with large data volumes.

[0032] When performing mapping classification and storage maintenance, each candidate mapping is quantitatively scored based on a source-weighted confidence model, and classification is performed based on the scoring results. Specifically, the approved mapping relationships are persistently stored by simultaneously building a repository with a bidirectional index structure.

[0033] In response to potential design changes, this embodiment uses an incremental update method to maintain the mapping relationship. Only the nodes that have changed are re-executed for feature extraction and matching calculation, while the nodes that have not changed retain the original mapping relationship without the need for full recalculation.

[0034] The method described above constructs a complete closed loop from configuration to matching to maintenance. It can be deployed and run independently or integrated into existing engineering design management platforms as the underlying capability for drawing and model association.

[0035] Compared with existing technologies, the method for mapping two-dimensional drawings and three-dimensional models based on naming feature parsing shown in this embodiment has the following advantages: This embodiment replaces the traditional hard-coded regular expression matching method by constructing a configurable naming convention parsing template, thus enabling rapid adaptation to the differentiated naming rules of different design entities and significantly reducing the configuration and maintenance costs of multi-source drawing access. Since only the complete file storage path is used as the sole source of information for feature extraction, there is no need to parse the internal text and graphics content of the drawings, thereby avoiding the stability issues caused by image quality, font, and layer interference in optical character recognition, and improving the reliability and execution efficiency of feature extraction. By reusing the same set of standardized operators to construct a unified semantic metric space for drawings and models, and using a four-level hierarchical progressive alignment mechanism to compress the matching range from top to bottom, the problem of semantic heterogeneity at both ends and low global matching efficiency is effectively solved, significantly improving matching accuracy and processing speed. Combined with source-weighted confidence grading and a bidirectional index incremental update mechanism, the automatic matching efficiency and result reliability are further balanced, while supporting bidirectional traceability queries between drawings and models, reducing mapping and maintenance overhead in design change scenarios, and overall improving the automation level and engineering application value of engineering drawing and model association.

[0036] Example 2 The second embodiment of the present invention also provides a method for mapping two-dimensional drawings to three-dimensional models based on naming feature parsing. The method shown in this embodiment is basically similar to the method shown in the first embodiment, except that: In this embodiment, the step of constructing the naming convention parsing template specifically includes: The naming convention parsing template is configured into four components: a semantic field set, a separator set, a field cleaning rule set, and a professional synonym lookup table. The semantic field set defines the semantic dimensions of the parsed project and their corresponding data types. The separator set covers all separator symbols used in the naming of the design subject. The field cleaning rule set defines exclusive standardized processing logic for each type of semantic field. The professional synonym lookup table stores the mapping relationship between multiple synonym expressions of the same project semantic and the unique standard value. When setting up a loosely coupled architecture between the template and the mapping engine, the core logic of feature extraction, standardization calculation, and matching determination of the mapping engine remains unchanged when a new design subject is connected or the naming convention is updated. Only the template configuration content is adjusted, and multiple naming templates are stored and called in parallel according to the project dimension.

[0037] Specifically, the semantic field set defines all engineering semantic dimensions supported by the method in an enumerated form. Each field is labeled with its corresponding data type, categorized into numeric and text types. This type label serves as the basis for selecting processing logic in subsequent standardization steps. The field set supports expansion; adding a new semantic dimension simply requires appending a field definition item to the set. This field definition item includes attributes such as field name, data type, whether it is required, and default value, meeting different levels of granular configuration requirements.

[0038] The delimiter set includes all delimiters used in drawing naming practices by the design team, covering common naming delimiters in engineering fields such as underscores, hyphens, slashes, and periods. The delimiter set supports filename splitting in scenarios with multiple delimiters, meaning that even when multiple delimiters are used interchangeably or in combination within the same filename, it can still correctly identify the splitting point and complete the string splitting, adapting to the diverse naming habits of different design teams. The symbols in the delimiter set are sorted by priority; when multiple symbols appear simultaneously, the primary delimiter is determined based on priority, avoiding overly fragmented splitting results.

[0039] The field cleaning rule set defines dedicated standardized processing logic for each type of semantic field, with different cleaning rule entries corresponding to numeric and text fields. Rules for numeric fields define numerical extraction methods, unit removal rules, and format conversion requirements, while rules for text fields define character filtering ranges, case sensitivity, and synonym mapping trigger conditions. A professional synonym lookup table stores the mapping relationship between multiple synonym expressions of the same engineering semantics and a unique standard value in key-value pairs. Table entries support dynamic addition and deletion, and can be queried during text normalization. The synonym lookup table supports multilingual entries and can simultaneously accommodate Chinese abbreviations, English abbreviations, and mixed expressions.

[0040] It's important to note that the templates exist as independent configuration files, and the mapping engine loads the template content by reading these configuration files. There is no hard binding between the two at the code level. When integrating a new design entity or updating the naming conventions of an existing design entity, only the corresponding template configuration file needs to be modified or added. The core logic code of the mapping engine, such as feature extraction, standardization calculation, and matching determination, remains unchanged.

[0041] Multiple naming templates are stored in parallel according to project dimensions. The corresponding template is automatically loaded based on the currently processed project identifier, enabling flexible switching of naming rules between different projects without the need to restart the service or redeploy the program. A built-in validation mechanism is included when loading templates to automatically detect the integrity and format validity of the configuration, avoiding matching anomalies caused by incorrect configurations.

[0042] In this embodiment, the step of performing full-path semantic feature extraction on the two-dimensional drawing specifically includes: The complete storage path of the split drawing is divided into multi-level directory nodes and file name nodes. The semantic content of each node is parsed layer by layer in a bottom-up backtracking order. For missing engineering semantic fields in the file name, the backtracking process is completed by tracing back to each level of directory node in turn. The backtracking process is terminated when the root directory node is reached. Perform conflict detection on filenames and fields with the same name extracted from directories at all levels, and perform conflict resolution according to the priority rules of the field source level. Filename level fields have higher priority than directory level fields, and output the initial feature information of the drawing.

[0043] Specifically, using the path separator defined in the operation as the cutting marker, the complete path string is split into an ordered array of nodes. The last element of the array corresponds to the filename node, and the remaining elements correspond to directory nodes at each level in ascending order. After splitting, starting from the filename node, the semantic content of each node is parsed layer by layer in a bottom-up backtracking order. During the parsing process, according to the field rules defined in the naming convention parsing template, the corresponding semantic fields in the node string are identified through pattern matching and their values ​​are extracted. The parsing result of each node is stored independently, recording two attributes: the field value and the source level.

[0044] After the filename node is parsed, the assignment status of all target semantic fields is checked. If any semantic fields remain unassigned, the process traces upwards through each directory node, attempting to extract the values ​​of the missing fields from the directory names to complete the process. This backtracking process continues upwards along the directory hierarchy until all target semantic fields have been assigned values, or until the root directory node of the path is reached. It should be noted that the root directory node serves as the termination boundary of the backtracking process; reaching this node terminates the backtracking process regardless of whether all fields are completed, thus avoiding infinite upward tracing. For required fields that still lack values ​​after the backtracking process, the drawing is marked as having a missing feature, the missing field name is recorded, and the process is transferred to the exception handling procedure, excluding them from subsequent automatic matching.

[0045] After backtracking and completion, the process proceeds to conflict detection and adjudication. Since filenames and multi-level directories may simultaneously contain the same semantic field value, and values ​​at different levels may differ, it is necessary to detect and identify such conflicts with the same name field. Conflict adjudication is performed according to the priority rules of the field's source hierarchy, where filename-level fields have higher priority than directory-level fields, with higher priority for directory levels closer to the filename. When a conflict is detected, the field value corresponding to the higher priority level is accepted, and the value from the lower priority level is discarded.

[0046] After conflict resolution is completed, the initial feature information of the drawing with unique values ​​for each field is output and passed to the subsequent standardization process. The resolution process synchronously records a conflict log, including conflict fields, values ​​at each level, and the final accepted result, which facilitates manual verification and rule optimization.

[0047] In this embodiment, the step of generating standard feature information on the model side specifically includes: The three-dimensional power grid information model is traversed in depth according to the four-level tree structure of engineering, line, tower group, and component. The original attribute values ​​corresponding one-to-one with the template semantic fields are extracted at each level node to form a hierarchical attribute set covering the entire model. The same set of standardized operators is reused on both the drawing and model sides to perform cleaning processing. For numerical fields, unit removal and leading zero removal are performed for numerical normalization, and for text fields, synonym mapping and character normalization are performed for text normalization, thus unifying the heterogeneous expressions at both ends into standard values.

[0048] Specifically, the 3D power grid information model is organized into a tree-like spatial structure based on four levels: engineering, lines, tower groups, and components. A depth-first traversal strategy is used to progressively traverse this tree structure. During the traversal, the complete attribute set of each node is read, and the semantic field definitions in the template are parsed according to naming conventions to filter out the original attribute values ​​that correspond one-to-one with the template fields. After the traversal is completed, a hierarchical attribute set covering all components of the entire model is obtained. This set fully preserves the original hierarchical relationships of the model, facilitating subsequent hierarchical matching operations. The traversal process supports breakpoint resumption; after an interruption, execution can continue from the interrupted node without starting from the beginning.

[0049] In the standardization process, the same set of standardization operators is reused on both the drawing and model sides, ensuring consistency and comparability of the output results from both ends. The standardization operators are divided into two categories: numerical normalization and text normalization, which handle semantic fields of different data types respectively. Numerical fields undergo two processes sequentially: unit removal and leading zero removal. The unit removal operation uses regular expression matching to identify and remove unit text appended to the numerical value, while the leading zero removal operation removes invalid zero characters at the beginning of the numeric string. After both processes, the data is uniformly converted to a pure numerical format for output, eliminating interference from unit and format differences on numerical comparison. The numerical normalization process simultaneously performs validity checks; fields that cannot be converted to valid numerical values ​​are marked as abnormal, and the reasons are recorded.

[0050] The synonym mapping process involves querying a professional synonym lookup table to uniformly replace all abbreviations, acronyms, uppercase and lowercase variants, and mixed Chinese and English expressions in the input text with predefined standard values ​​in the lookup table. The character normalization process sequentially performs three sub-operations: case unification, removal of leading and trailing spaces, and filtering of redundant special characters, to ensure the formatting regularity of the output text.

[0051] After the above normalization process, the heterogeneous representations at both ends of the drawing and the model are uniformly mapped to standard values ​​with a consistent format, eliminating semantic differences at the data level and providing a comparable data foundation for subsequent hierarchical alignment and matching. The standardization operator is encapsulated in a function library, and both ends execute the processing by calling the same interface, ensuring complete consistency in algorithm logic and avoiding comparison deviations caused by implementation differences.

[0052] In this embodiment, the step of using a four-level hierarchical progressive alignment mechanism to filter the candidate set from top to bottom specifically includes: The first-level engineering dimension performs batch grouping of all drawings and all model components through the voltage level field, splitting the global matching space into several independent voltage level groups; the second-level line dimension further subdivides the matching units within each group through line identifiers; the third-level tower dimension performs filtering within each line unit by matching tower type strings and comparing tower number values; the fourth-level professional dimension aligns the drawings and component categories through professional standard enumeration values. Each level of filtering outputs intermediate matching results, which are then used as the input set for the next level of filtering.

[0053] Specifically, the four-level hierarchical alignment mechanism executes the four-level filtering operations sequentially from coarse-grained to fine-grained during implementation.

[0054] The first level of filtering, based on the engineering dimension, uses the voltage level field as the grouping criterion. All drawings and model components are grouped into their respective voltage level groups, thus splitting the global matching space into several independent voltage level groups. No candidate matching relationships are generated between drawings and components of different voltage levels, significantly compressing the matching range from the source and reducing the computational load of subsequent levels. After the engineering dimension grouping is completed, each group executes subsequent filtering independently and in parallel, further improving overall processing efficiency.

[0055] Line-level filtering, as the second level, further subdivides the matching units within each voltage level group based on the line identification field, grouping drawings and components under the same voltage level into secondary groups according to line affiliation. After this secondary division by line dimension, the size of the matching unit is further reduced, with each matching unit containing only drawings and components from the same line.

[0056] As the third level, tower dimension filtering compares two core fields, tower type string and tower number, within each line unit. Candidate pairs that match both fields proceed to the next level of processing, while those that do not match either field are removed from the candidate set.

[0057] The professional dimension filtering, as the fourth level, performs final alignment of drawings and component categories using professional standard enumeration values, completing the matching and filtering across all four dimensions. Each level of filtering outputs a filtering log, recording details of entries entering and leaving the candidate set.

[0058] The above four-level filtering adopts a progressive architecture. After each level of filtering is completed, it outputs an intermediate matching result for that level, which is directly used as the input set for the next level of filtering. This step-by-step approach ensures that each level of filtering only processes a small-scale candidate set output by the previous level, rather than performing pairwise comparisons on the entire dataset. Through this four-level progressive filtering, the computational task that originally required global-scale pairwise comparisons is decomposed into multiple levels of small-scale local matching tasks. Each level of filtering progressively compresses the candidate set size, ultimately outputting candidate mapping pairs that satisfy all dimensional conditions, which then proceed to the confidence determination stage. Furthermore, this progressive architecture supports inserting custom filtering rules at any level, possessing good scalability and allowing for the addition of additional matching dimensions according to business needs.

[0059] In this embodiment, the step of performing graph-pattern mapping hierarchical determination by combining the source-weighted confidence model specifically includes: Differentiated weight coefficients are set for different semantic fields, with core fields having higher weights than auxiliary fields, and filename source fields having higher weights than directory source fields; the comprehensive matching score is calculated by normalizing the weighted sum of the matching status of each field and its corresponding weight. Two judgment thresholds are preset: a high judgment threshold and a low judgment threshold. Candidate mappings with a comprehensive matching score greater than or equal to the high judgment threshold are judged as valid mappings and automatically added to the database. Candidate mappings with a comprehensive matching score between the two thresholds are marked as pending manual review. Candidate mappings with a comprehensive matching score lower than the low judgment threshold are judged as matching failures and the corresponding reasons are recorded.

[0060] Specifically, the source-weighted confidence model, in its implementation, first involves configuring the weight coefficients. Different weight coefficients are assigned to different semantic fields, following two basic principles: First, core fields have higher weights than auxiliary fields. Key fields determining uniqueness, such as voltage level, tower number, and specialty, receive higher weights, while auxiliary fields used only for sorting, such as volume and sheet number, receive lower weights. Second, filename source fields have higher weights than directory source fields, and the same semantic field extracted from a filename has a higher weight than extracted from a directory, reflecting the difference in credibility between different information sources. These two principles combine to form a multi-level weight allocation system. The weight coefficients are stored as configuration items and can be optimized based on actual matching results.

[0061] Furthermore, the feature values ​​of the candidate mapping pairs on both the drawing and model sides are compared field by field, and the matching status of each field is recorded. A complete match is considered valid, while a difference is considered invalid. During calculation, the matching status of each field is multiplied by its corresponding weight coefficient, and the results are summed to obtain a weighted sum. This sum is then divided by the sum of all field weights to obtain a normalized comprehensive matching score. The score ranges from zero to one; a higher score indicates a higher degree of reliability in matching the candidate mappings. The score calculation retains four decimal places to avoid threshold boundary judgment deviations due to insufficient precision.

[0062] The tiered judgment process employs a dual-threshold mechanism. Candidate mappings with a comprehensive matching score greater than or equal to the higher judgment threshold are directly judged as valid mappings and automatically written into the mapping repository without manual intervention. Candidate mappings with a comprehensive matching score between the lower and higher judgment thresholds are marked as awaiting manual review and pushed to the manual review queue for confirmation by operators. Candidate mappings with a comprehensive matching score lower than the lower judgment threshold are judged as matching failures, and the reason for failure is recorded to facilitate subsequent investigation of rule defects and optimization of matching strategies.

[0063] The above three-tiered judgment mechanism ensures both automated processing efficiency and matching accuracy. The manual review stage provides detailed comparison information of candidate mappings, assisting operators in quickly making decisions to confirm or reject.

[0064] In this embodiment, the steps of building a bidirectional index repository and performing incremental dynamic maintenance on design changes specifically include: Two types of bidirectional query indexes are established: forward index and reverse index. The forward index uses the unique identifier of the 3D component as the primary key to associate all drawing paths and mapping metadata corresponding to the component. The reverse index uses the complete drawing path as the primary key to associate all component identifiers and spatial positioning parameters bound to the drawing. Both types of indexes are updated synchronously. The system monitors two types of change events: changes in drawing file naming and updates to 3D model versions. When a change is detected, the change node is identified and feature extraction and matching calculations are re-executed. Components that have not undergone changes retain their existing mapping relationship with the drawings.

[0065] Specifically, the forward index uses the unique identifier of each 3D component as its primary key. Each primary key corresponds to a complete set of paths to all drawings associated with that component, along with mapping metadata such as mapping creation time, comprehensive matching score, and mapping status. Furthermore, the forward index supports quick querying of all associated drawings starting from a model component, making it suitable for model-driven drawing retrieval and batch drawing export applications. Moreover, the forward index is stored in partitioned tables according to component type, allowing queries to directly locate the corresponding partitioned table, further improving retrieval efficiency.

[0066] The reverse index uses the complete path of the drawing as the primary key. Each primary key corresponds to a unique set of identifiers for all 3D components bound to that drawing, while also recording spatial positioning parameters, tower and line information, and other hierarchical information for each component. Furthermore, the reverse index supports quick lookup of corresponding 3D components starting from the drawing, making it suitable for drawing-driven model positioning, 3D scene navigation, and other application scenarios.

[0067] Both types of indexes perform update operations synchronously when the mapping relationship is written, updated, or deleted. A transaction mechanism ensures data consistency between the forward and reverse indexes, preventing one-sided data failures. The index storage supports both relational databases and key-value databases, allowing for flexible selection based on the deployment environment.

[0068] Furthermore, the method shown in this embodiment will continuously monitor two types of change events: one is the drawing file naming change event, which detects the renaming operation of the drawing file through a file monitoring mechanism; the other is the 3D model version update event, which detects changes in the model content by comparing the model file version number.

[0069] When a change event is detected, the specific node that has changed is first located. The feature extraction and matching calculation process is then re-executed only for the changed node to update the mapping relationship of the corresponding node. For components and drawings that have not changed, their existing mapping relationships are directly retained and do not need to be recalculated.

[0070] The above incremental update method avoids performing a full recalculation for every design change, effectively reducing the mapping maintenance overhead in change scenarios. Finally, a change report is generated after the change is processed, listing the number of components and drawings involved in the change, as well as details of changes in mapping relationships, so that managers can understand the scope of the change's impact.

[0071] Example 3 Please see Figure 2 A third embodiment of the present invention provides a two-dimensional drawing and three-dimensional model mapping system based on naming feature parsing, used to execute the method described in any of the above embodiments, the system comprising: Naming template configuration module 10 is used to construct a naming convention parsing template, wherein the naming convention parsing template defines field dimensions, delimiter enumeration, cleaning logic and synonym mapping relationship; The drawing feature extraction module 20 is used to perform full-path semantic feature extraction on two-dimensional drawings. It completes missing fields in the file name by tracing back through multi-level directories, and generates standard feature information on the drawing side after unified standardization. The feature extraction takes the complete storage path of the file as the only source of information. The dual-end attribute parsing module 30 is used to traverse the tree-like spatial structure of the three-dimensional power grid information model to extract component attributes, reuse the same set of standardized operators on the drawing side to process model attributes, and generate standard feature information on the model side. The hierarchical alignment matching module 40 is used to compare the standard feature information of the drawing side and the model side using a four-level hierarchical progressive alignment mechanism of engineering, line, tower and professional, and filter the candidate set from top to bottom. The bidirectional mapping management module 50 is used to perform hierarchical determination of graph-model mapping by combining the source weighted confidence model, build a bidirectional index repository, and perform incremental dynamic maintenance on design changes.

[0072] Compared with existing technologies, the advantages of using the naming feature-based mapping system for 2D drawings and 3D models shown in this embodiment are as follows: This embodiment replaces the traditional hard-coded regular expression matching method by constructing a configurable naming convention parsing template, thus enabling rapid adaptation to the differentiated naming rules of different design entities and significantly reducing the configuration and maintenance costs of multi-source drawing access. Since only the complete file storage path is used as the sole source of information for feature extraction, there is no need to parse the internal text and graphics content of the drawings, thereby avoiding the stability issues caused by image quality, font, and layer interference in optical character recognition, and improving the reliability and execution efficiency of feature extraction. By reusing the same set of standardized operators to construct a unified semantic metric space for drawings and models, and using a four-level hierarchical progressive alignment mechanism to compress the matching range from top to bottom, the problem of semantic heterogeneity at both ends and low global matching efficiency is effectively solved, significantly improving matching accuracy and processing speed. Combined with source-weighted confidence grading and a bidirectional index incremental update mechanism, the automatic matching efficiency and result reliability are further balanced, while supporting bidirectional traceability queries between drawings and models, reducing mapping and maintenance overhead in design change scenarios, and overall improving the automation level and engineering application value of engineering drawing and model association.

[0073] Example 4 A fourth embodiment of the present invention provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the steps of the methods described in the above embodiments. Example 5 A fifth embodiment of the present invention provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the steps of the methods described in the above embodiments.

[0074] In the description of this specification, references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of the invention. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples.

[0075] The embodiments described above are merely illustrative of several implementations of the present invention, and while the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the present invention. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of the present invention, and these all fall within the protection scope of the present invention. Therefore, the protection scope of this patent should be determined by the appended claims.

Claims

1. A method for mapping two-dimensional drawings to three-dimensional models based on named feature parsing, characterized in that, The method includes: Construct a naming convention parsing template, which defines field dimensions, delimiter enumeration, cleaning logic, and synonym mapping relationships; Full-path semantic feature extraction is performed on 2D drawings. Missing fields in file names are filled by tracing back through multi-level directories. After unified standardization processing, standard feature information on the drawing side is generated. Feature extraction uses the complete storage path of the file as the only source of information. Extract component attributes by traversing the tree-like spatial structure of the 3D power grid information model, reuse the same set of standardized operators from the drawing side to process model attributes, and generate standard feature information from the model side. A four-level hierarchical alignment mechanism (engineering, line, tower, and professional) is adopted to compare standard feature information between the drawing side and the model side, and the candidate set is filtered from top to bottom. By combining the source-weighted confidence model to perform hierarchical determination of graph model mapping, a bidirectional index repository is constructed and incremental dynamic maintenance is performed on design changes.

2. The method for mapping two-dimensional drawings to three-dimensional models based on named feature parsing according to claim 1, characterized in that, The steps for constructing the naming convention parsing template specifically include: The naming convention parsing template is configured into four components: a semantic field set, a separator set, a field cleaning rule set, and a professional synonym lookup table. The semantic field set defines the semantic dimensions of the parsed project and their corresponding data types. The separator set covers all separator symbols used in the naming of the design subject. The field cleaning rule set defines exclusive standardized processing logic for each type of semantic field. The professional synonym lookup table stores the mapping relationship between multiple synonym expressions of the same project semantic and the unique standard value. When setting up a loosely coupled architecture between the template and the mapping engine, the core logic of feature extraction, standardization calculation, and matching determination of the mapping engine remains unchanged when a new design subject is connected or the naming convention is updated. Only the template configuration content is adjusted, and multiple naming templates are stored and called in parallel according to the project dimension.

3. The method for mapping two-dimensional drawings to three-dimensional models based on named feature parsing according to claim 2, characterized in that, The steps for performing full-path semantic feature extraction on the two-dimensional drawing specifically include: The complete storage path of the split drawing is divided into multi-level directory nodes and file name nodes. The semantic content of each node is parsed layer by layer in a bottom-up backtracking order. For missing engineering semantic fields in the file name, the backtracking process is completed by tracing back to each level of directory node in turn. The backtracking process is terminated when the root directory node is reached. Perform conflict detection on filenames and fields with the same name extracted from directories at all levels, and perform conflict resolution according to the priority rules of the field source level. Filename level fields have higher priority than directory level fields, and output the initial feature information of the drawing.

4. The method for mapping two-dimensional drawings to three-dimensional models based on named feature parsing according to claim 3, characterized in that, The steps for generating standard feature information on the model side specifically include: The three-dimensional power grid information model is traversed in depth according to the four-level tree structure of engineering, line, tower group, and component. The original attribute values ​​corresponding one-to-one with the template semantic fields are extracted at each level node to form a hierarchical attribute set covering the entire model. The same set of standardized operators is reused on both the drawing and model sides to perform cleaning processing. For numerical fields, unit removal and leading zero removal are performed for numerical normalization, and for text fields, synonym mapping and character normalization are performed for text normalization, thus unifying the heterogeneous expressions at both ends into standard values.

5. The method for mapping two-dimensional drawings to three-dimensional models based on named feature parsing according to claim 4, characterized in that, The steps of filtering the candidate set from top to bottom using a four-level hierarchical progressive alignment mechanism specifically include: The first-level engineering dimension performs batch grouping of all drawings and all model components through the voltage level field, splitting the global matching space into several independent voltage level groups; the second-level line dimension further subdivides the matching units within each group through line identifiers; the third-level tower dimension performs filtering within each line unit by matching tower type strings and comparing tower number values; the fourth-level professional dimension aligns the drawings and component categories through professional standard enumeration values. Each level of filtering outputs intermediate matching results, which are then used as the input set for the next level of filtering.

6. The method for mapping two-dimensional drawings to three-dimensional models based on named feature parsing according to claim 5, characterized in that, The steps for performing graph-pattern mapping hierarchical determination using the source-weighted confidence model specifically include: Differentiated weight coefficients are set for different semantic fields, with core fields having higher weights than auxiliary fields, and filename source fields having higher weights than directory source fields; the comprehensive matching score is calculated by normalizing the weighted sum of the matching status of each field and its corresponding weight. Two judgment thresholds are preset: a high judgment threshold and a low judgment threshold. Candidate mappings with a comprehensive matching score greater than or equal to the high judgment threshold are judged as valid mappings and automatically added to the database. Candidate mappings with a comprehensive matching score between the two thresholds are marked as pending manual review. Candidate mappings with a comprehensive matching score lower than the low judgment threshold are judged as matching failures and the corresponding reasons are recorded.

7. The method for mapping two-dimensional drawings to three-dimensional models based on named feature parsing according to claim 6, characterized in that, The steps of building a bidirectional index repository and performing incremental dynamic maintenance on design changes specifically include: Two types of bidirectional query indexes are established: forward index and reverse index. The forward index uses the unique identifier of the 3D component as the primary key to associate all drawing paths and mapping metadata corresponding to the component. The reverse index uses the complete drawing path as the primary key to associate all component identifiers and spatial positioning parameters bound to the drawing. Both types of indexes are updated synchronously. The system monitors two types of change events: changes in drawing file naming and updates to 3D model versions. When a change is detected, the change node is identified and feature extraction and matching calculations are re-executed. Components that have not undergone changes retain their existing mapping relationship with the drawings.

8. A mapping system for two-dimensional drawings and three-dimensional models based on named feature parsing, characterized in that, The system for performing the method according to any one of claims 1 to 7, the system comprising: The naming template configuration module is used to build a naming convention parsing template, which defines field dimensions, delimiter enumeration, cleaning logic, and synonym mapping relationships. The drawing feature extraction module is used to perform full-path semantic feature extraction on two-dimensional drawings. It completes missing fields in the file name by tracing back through multi-level directories, and generates standard feature information on the drawing side after unified standardization processing. The feature extraction takes the complete storage path of the file as the only source of information. The dual-end attribute parsing module is used to traverse the tree-like spatial structure of the 3D power grid information model to extract component attributes, reuse the same set of standardized operators from the drawing side to process model attributes, and generate standard feature information from the model side. The hierarchical alignment matching module is used to compare the standard feature information of the drawing side and the model side using a four-level hierarchical alignment mechanism of engineering, line, tower and professional, and filter the candidate set from top to bottom. The bidirectional mapping management module is used to perform hierarchical determination of graph-model mapping by combining the source weighted confidence model, build a bidirectional index repository, and perform incremental dynamic maintenance on design changes.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 7.

10. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 7.