Automatic drawing feature recognition method and device, electronic equipment and storage medium

Through the automated feature recognition method, whether the Creo drawings are crossed out of boundaries and repaired positions, the reading difficulties and information loss caused by the crossing of boundaries is solved, and efficient and accurate automatic identification and repair of drawings is achieved.

CN119649395APending Publication Date: 2025-03-18LCFC HEFEI ELECTRONICS TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411538372.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-30
Publication Date
2025-03-18

AI Technical Summary

Technical Problem

In the field of engineering design, when the views, notes and table position information on Creo drawings exceed the boundary, it leads to difficult reading of drawings, missing information when exporting PDF or 2D drawings, and low manual recognition efficiency and poor accuracy, making automation and batch processing impossible.

Method used

It provides an automated drawing feature recognition method. By obtaining the feature information of the drawing to be identified, analyzing whether it is crossed, and performing position repair when it is crossed, and finally exporting and storing the feature information of the drawing and the repaired drawing information.

Benefits of technology

It realizes automatic identification and location repair of drawing views, sizes, Tables, Notes and other information, improves identification efficiency and accuracy, supports automation and batch processing, and reduces labor costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119649395A_ABST
    Figure CN119649395A_ABST
Patent Text Reader

Abstract

The invention discloses an automatic drawing feature recognition method and device, electronic equipment and a storage medium. The method comprises the steps of obtaining feature information of a to-be-recognized drawing; analyzing the drawing according to the feature information of the to-be-identified drawing, and judging whether the drawing crosses a boundary or not; when the drawing crosses the boundary, the position of the drawing is repaired; and exporting and storing the feature information of the drawing and the drawing information after position restoration. According to the method and the device, the Creo drawing can be automatically identified, and the Creo drawing crossing the boundary can be repaired.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to the technical field of engineering design, and in particular to a method and device for automatic feature recognition of Creo drawings, an electronic device, and a storage medium. Background Art

[0002] In the field of engineering design, Creo software is one of the widely used 3D modeling tools. Designers will mark key dimensions, modification records, modifiers, modification reasons, and other information on the design drawings. When this information needs to be entered into the system and transmitted to downstream systems or other teams, engineers are required to manually identify the important information marked on the Creo drawings and enter it into Excel and databases. If the location information of views, annotations, and tables on Creo drawings exceeds the boundaries, it will not only affect the reading of the drawings, but also cause information leakage when exporting PDF or 2D drawings. In order to avoid this problem, professionals are required to check the drawings one by one, collect the information marked on the drawings, and confirm whether there is any situation that exceeds the boundaries. When the drawing module exceeds the boundaries, the module that exceeds the boundaries needs to be manually typeset.

[0003] Manual recognition is easily affected by subjective factors, has poor accuracy, and has a certain error rate, making it difficult to be completely accurate; manually checking various modules in Creo drawings one by one requires a lot of time and energy, and is inefficient; each recognition requires the participation of professionals, and automation and batch processing cannot be achieved, and the repeatability and consistency of recognition results cannot be guaranteed; professionals are required for manual recognition, which has high labor costs and is difficult to promote and apply on a large scale; manual recognition is slow and cannot meet some application scenarios that require real-time processing. Summary of the invention

[0004] In view of this, the embodiments of the present application provide a method and device for automatic feature recognition of drawings, an electronic device, and a storage medium, which can at least solve the aforementioned technical problems.

[0005] According to a first aspect of an embodiment of the present application, a method for automatic feature recognition of drawings is provided, the method comprising:

[0006] Obtain feature information of the drawing to be identified;

[0007] Analyze the drawing according to the characteristic information of the drawing to be identified to determine whether the drawing is out of bounds;

[0008] When the drawing is out of bounds, the position of the drawing is repaired;

[0009] Export and store the feature information of the drawing and the drawing information after position repair.

[0010] In some exemplary embodiments, obtaining feature information of the drawing to be identified includes:

[0011] Get the number of sheets of the drawing to be identified, as well as the views and tables of all pages.

[0012] In some exemplary embodiments, obtaining the number of pages of the drawing to be identified and the views and detail lists of all pages includes:

[0013] Obtain the number of pages of the drawing to be identified through the secondary development interface for obtaining the number of sketches, and traverse the drawings to be identified according to the number of pages; set the active page value of the current drawing as the traversal value;

[0014] Get all the view information of the current page through the secondary development to obtain the sketch view interface;

[0015] Get all the detail list information of the current page through secondary development to obtain the sketch detail list interface.

[0016] In some exemplary embodiments, the obtaining of all view information of the current page through the secondary development of the sketch view interface includes:

[0017] Traverse all pages to get the view collection of the page;

[0018] Get the dimension information of the current view annotation through the sketch annotation dimension acquisition interface;

[0019] Get the dimension information marked on the current entity through the Get Entity Dimension API;

[0020] Traverse the acquired dimension information and obtain the dimension string array information through the Get Annotation Dimension Information interface;

[0021] According to the string array information, the size information, remark information, number information, business information, and modification information marked by the engineer of the current page are obtained.

[0022] In some exemplary embodiments, obtaining the size information, remark information, number information, business information, and modification information marked by the engineer of the current page according to the string array information includes:

[0023] When the length of the string array information is 1, the string is obtained by splitting it by colon;

[0024] When the length of the split string is 1, only the size information is available.

[0025] When the length of the string after segmentation is 2, determine whether the size information is in the first or second position. When the size information is in the first position, the second position is the remark information; when the size information is in the second position, the first position is the number information and business information.

[0026] When the length of the string after segmentation is 3, the first digit is the number information and business information, the second digit is the size information, and the third digit is the remarks information;

[0027] Get the size information, remarks information, number information, and business information of the current page;

[0028] When the length of the string array information is 2, the size information, remark information, number information, business information, and modification information marked by the engineer of the current page are obtained.

[0029] In some exemplary embodiments, the obtaining of all the detail list information of the current page through the secondary development of the sketch detail list interface includes:

[0030] Traverse all pages to obtain the page detail list collection;

[0031] Get the number of rows and columns of the current detail list by accessing the detail list row number interface and the detail list column number interface;

[0032] According to the row number and column number, access the detail table cell value interface through secondary development to obtain the value of each cell.

[0033] In some exemplary embodiments, analyzing the drawing according to the feature information of the drawing to be identified to determine whether the drawing is out of bounds includes:

[0034] Traverse all views of the current page;

[0035] Get the screen transformation matrix of the current page through the transformation matrix interface of the sketch obtained through secondary development;

[0036] Obtain the outline coordinates of the current traversal view through secondary development to obtain the outline interface of the view in the sketch;

[0037] Convert the screen transformation matrix of the page into an inverse matrix;

[0038] The contour coordinates and the inverse matrix are converted into sketch coordinates through the secondary development specified transformation matrix conversion coordinate interface, and the three-dimensional coordinates are obtained;

[0039] Get the width and height of the current page through the secondary development interface to obtain the sketch size interface;

[0040] Whether the drawing is out of bounds is determined according to the three-dimensional coordinates and the width and height of the current page.

[0041] In some exemplary embodiments, when the drawing is out of bounds, repairing the position of the drawing includes:

[0042] Mark the current view with a frame;

[0043] Traverse all views of the current page;

[0044] Get the width and height of each view, calculate the view area based on the width and height of the view, and sort the views from large to small by view area;

[0045] Traverse the sorted views and place them in the current page in descending order.

[0046] In some exemplary embodiments, placing the sorted views in the current page in descending order includes:

[0047] Step 1: Place the first view in the first row of the current page and update the placement position of the first view;

[0048] Step 2: Determine whether the remaining width of the first row is greater than the width of the second view. When the remaining width of the first row is greater than the width of the second view, place the second view in the first row of the current page, after the first view; when the remaining width of the first row is not greater than the width of the second view, place the second view in the second row of the current page; and update the placement position of the second view;

[0049] Step 3: Determine whether the remaining width of the first row is greater than the width of the third view. When the remaining width of the first row is greater than the width of the third view, place the third view in the first row of the current page; when the remaining width of the first row is not greater than the width of the third view, determine whether the remaining width of the second row is greater than the width of the third view. When the remaining width of the second row is greater than the width of the third view, place the third view in the second row of the current page; when the remaining width of the second row is not greater than the width of the third view, place the second view in the third row of the current page; and update the placement position of the third view;

[0050] Repeat steps 1 to 3 until all views are placed.

[0051] In some exemplary embodiments, the method further includes: determining whether the placed view is out of bounds, and when the placed view is not out of bounds, updating the placement position of the view.

[0052] In some exemplary embodiments, exporting and storing the feature information of the drawing and the drawing information after the position repair includes:

[0053] The drawing's dimension information, remark information, number information, business information, engineer-annotated modification information, and repaired drawing information are exported and stored.

[0054] According to a second aspect of an embodiment of the present application, a drawing automatic feature recognition device is provided, the device comprising:

[0055] An information acquisition module, used to acquire characteristic information of all the drawings to be identified;

[0056] A feature analysis module is used to analyze the drawing according to the feature information of the drawing to be identified, and determine whether the drawing is out of bounds;

[0057] The position repair module is used to repair the position of the drawing when it goes out of bounds;

[0058] The information storage module is used to export and store the feature information of the drawing and the drawing information after position repair.

[0059] According to a third aspect of an embodiment of the present application, there is provided an electronic device comprising a processor and a memory for storing processor executable instructions, wherein the processor is configured to execute the steps of the above-mentioned method for automatic feature recognition of drawings when calling the executable instructions in the memory.

[0060] According to a fourth aspect of an embodiment of the present application, it is provided that a computer program is stored in the computer-readable storage medium, and when the computer program is executed by a processor, the steps of the above-mentioned method for automatic feature recognition of drawings are implemented.

[0061] In the embodiment of the present application, the drawings are analyzed to determine whether they are out of bounds. When the drawings are out of bounds, the drawings are repaired and the repaired drawings are stored. The drawing views, dimensions, tables, notes and other information are automatically identified and editable record information is formed; the positions of the various views of the drawings can be automatically detected, the views that are out of bounds are marked, and the out-of-bounds views are rearranged; the automatic identification and repair functions of the drawings are integrated with the database to achieve seamless connection between drawings and data. BRIEF DESCRIPTION OF THE DRAWINGS

[0062] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the drawings required for use in the embodiments or the prior art description are briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention, and for ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0063] Figure 1 A schematic diagram showing a flow chart of a method for automatic feature recognition of drawings according to an embodiment of the present application is shown;

[0064] Figure 2 A schematic diagram showing the dimensions of a drawing and business information marking in an embodiment of the present application is shown;

[0065] Figure 3 A schematic diagram of view selection results in an embodiment of the present application is shown;

[0066] Figure 4 A schematic diagram of a drawing showing an embodiment of the present application after position repair is performed;

[0067] Figure 5 A schematic diagram showing a flow chart of a method for automatic feature recognition of drawings according to a second embodiment of the present application is shown;

[0068] Figure 6 A schematic diagram showing the structure of a drawing automatic feature recognition device according to an embodiment of the present application is shown;

[0069] Figure 7 A schematic diagram of the structure of an electronic device according to an embodiment of the present application is shown. DETAILED DESCRIPTION

[0070] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present disclosure. Instead, they are merely examples of devices and methods consistent with some aspects of the present disclosure as detailed in the appended claims.

[0071] The essence of the technical solution of the embodiment of the present application is explained in detail below with reference to the accompanying drawings.

[0072] Figure 1 A schematic diagram showing a process flow of a method for automatic feature recognition of drawings according to an embodiment of the present application is shown. Figure 1 As shown, the automatic feature recognition method for drawings in the embodiment of the present application includes the following steps:

[0073] Step 101: Acquire feature information of the drawing to be identified;

[0074] In the exemplary embodiment, the engineer first uploads the Creo drawing to be analyzed. After receiving the analysis request, the Creo drawing analysis tool module checks the drawing to be analyzed and the attachments. If the drawing does not meet the regulations or the attachment content does not meet the standards, it is returned to the engineer and an email reminder is sent. The engineer rechecks and re-uploads the drawing. When the uploaded drawing meets all standards, the analysis request is initiated again, the drawing is opened, and the analysis command is activated.

[0075] In an exemplary embodiment, the step of obtaining characteristic information of the drawing to be identified includes: obtaining the number of sheets of the drawing to be identified and the views and tables of all pages. Specifically, the step includes steps 101A to 101D:

[0076] Step 101A: Obtain the number of sheets of the drawings to be identified through the secondary development ProDrawingSheetsCount interface, and traverse the drawings to be identified according to the number of sheets;

[0077] Step 101B: Set the active Sheet value of the current drawing to the traversal value Sheet No.;

[0078] Step 101C: Obtain all view information of the current page through the secondary development of the sketch view interface (ProDrawingViewVisit);

[0079] In the embodiment of the present application, the acquisition of all Views information of the current Sheet through the secondary development of the ProDrawingViewVisit interface includes steps 101C1 to 101C5:

[0080] Step 101C1: traverse all pages to obtain the Views collection of the page;

[0081] Step 101C2: Obtain the dimension information of the current view annotation through the ProDrawingDimensionVisit interface; obtain the dimension information of the current entity annotation through the ProSolidDimensionVisit interface;

[0082] Step 101C3: traverse the acquired dimension information, and obtain the dimension string array information Str[] through the ProDimensionTextWstringsGet interface;

[0083] According to the string array information, the size information, remark information, number information, business information, and modification information marked by the engineer of the current page are obtained. Figure 2 This is a schematic diagram of the dimensions and business information of the drawings of the embodiment of the present application.

[0084] Wherein, the obtaining of the size information, remark information, number information, business information, and modification information marked by the engineer of the current page according to the string array information includes:

[0085] Step 101C4: When the length of the string array information is 1, the string Str[0] is obtained by splitting according to the colon;

[0086] When the length of the split string Str[0] is 1, it means that the current string only has size information;

[0087] When the length of the segmented string Str[0] is 2, it is further determined whether the size information is in the first position or the second position; when the size information is in the first position, the second position is the remark information; when the size information is in the second position, the first position is the number information and other business information;

[0088] When the length of the string after segmentation is 3, the first digit is the number information and business information, the second digit is the size information, and the third digit is the remark information; get the size information, remark information, number information, and business information of the current page;

[0089] Step 101C5: When the length of the string array information Str[] is 2, the size information, remark information, number information, and business information of the current page are obtained through the above rules, and then the modification information marked by the engineer is obtained through Str[1]. The modification information includes addition, deletion, modification, and other information.

[0090] Step 101D: Obtain all the detail table information of the current page through the secondary development ProDrawingTablesCollect interface.

[0091] In the embodiment of the present application, the acquisition of all Tables information of the current Sheet through the secondary development of the ProDrawingTablesCollect interface includes steps 101D1 to 101D3:

[0092] Step 101D1: traverse all pages to obtain the Tables collection of the page;

[0093] Step 101D2: Get the number of rows and columns of the current Table by accessing the ProDwgtableColumnsCount interface and the ProDwgtableRowsCount interface;

[0094] Step 101D3: According to the row number and column number, access the detail table cell value (ProDwgtableCelltextGet) interface through secondary development to obtain the value of each cell.

[0095] Step 102: Analyze the drawing according to the characteristic information of the drawing to be identified to determine whether the drawing is out of bounds;

[0096] In an exemplary embodiment, the step of analyzing the drawing according to the characteristic information of the drawing to be identified and determining whether the drawing is out of bounds includes steps 102A to 102K:

[0097] Step 102A: Traverse all Views of the current Sheet;

[0098] Step 102B: Get the screen transformation matrix (ScreenMatrix) of the current Sheet through the secondary development to obtain the transformation matrix (ProDrawingSheetTrfGet) interface of the sketch;

[0099] Step 102C: Obtain the outline coordinates Point3d[2] of the current traversed View through the secondary development ProDrawingViewOutlineGet interface; in this step, the currently obtained outline coordinates are screen coordinates. If you need to compare with the Sheet outline, you also need to convert the sketch (Drawing) coordinates;

[0100] Step 102D: Convert the screen conversion matrix ScreenMatrix of Sheet into an inverse matrix, specifically including steps 102D1 to 102D5:

[0101] Step 102D1: The function obtains the scaling factor of the input matrix m;

[0102] In the embodiment of the present application, three components x, y, and z are extracted from the first row of the input matrix m and stored in the vec array; the sum of the squares of the three components in the vec array is calculated to obtain the square of the scaling factor scale_sq.

[0103] Step 102D2: Check whether the scaling factor is large enough to ensure that the matrix is ​​invertible;

[0104] In the embodiment of the present application, if scale_sq is less than (1e-9)^2, it means that the matrix is ​​not invertible and the function returns 0.

[0105] Step 102D3: Calculate the square inverse of the scaling factor inv_sq_scale; the square inverse of the scaling factor will be used to calculate the rotation and translation parts of the output matrix.

[0106] Step 102D4: Calculate the rotation part of the output matrix; including:

[0107] Iterate over the first 3x3 part of the output matrix; for each element, divide the corresponding input matrix element by the square of the scaling factor and store in the output matrix; set the 4th column to 0.0.

[0108] Step 102D5: Calculate the translation part of the output matrix; including:

[0109] Traverse the last row of the output matrix; for each element, subtract the element of the corresponding row and column of the input matrix multiplied by the square inverse of the scaling factor, and store it in the output matrix; the last element is set to 1.0.

[0110] Step 102E: Convert the outline coordinates and the inverse matrix into Drawing coordinates through the secondary development specified transformation matrix conversion coordinate (ProPntTrfEval) interface, and obtain the three-dimensional coordinate drawPoint3d[2];

[0111] Step 102F: Get the width and height of the current Sheet through the secondary development interface ProDrawingSheetSizeGet interface;

[0112] Determine whether the drawing is out of bounds based on the three-dimensional coordinates and the width and height of the current Sheet; including:

[0113] Step 102G: If drawPoint3d[0][0]–width>0 or drawPoint3d[0][1]–height>0, the view is out of bounds;

[0114] Step 102H: If drawPoint3d[1][0]<0 or drawPoint3d[1][1]<0, the view is out of bounds;

[0115] Step 102I: If drawPoint3d[1][0]–width>0 or drawPoint3d[1][1]–height>0, the view is partially out of bounds;

[0116] Step 102J: If drawPoint3d[0][0]<0 or drawPoint3d[0][1]<0, the view is partially out of bounds;

[0117] Step 102K: Other cases mean that the view is within the outline of the Sheet and does not cross the boundary.

[0118] Step 103: When the drawing is out of bounds, the position of the drawing is repaired;

[0119] In an exemplary embodiment, when the drawing is out of bounds, repairing the drawing includes steps 103A to 103E:

[0120] Step 103A: Mark the current view with a frame;

[0121] Includes: Get the current window status and refresh the window; define a set of 3D coordinate points, which are calculated based on the drawPoint3d array and the defined X and Y direction offsets. Define the connecting line as a highlight color; use the secondary development image polygon drawing (ProGraphicsPolylineDraw) interface to draw a polygonal figure with these coordinate points; Figure 3 This is a schematic diagram of the view selection result of an embodiment of the present application.

[0122] Step 103B: traverse all views of the current page;

[0123] Step 103C: Get the width view_width and height view_height of each view; where view_width = drawPoint3d[1][0]-drawPoint3d[0][0], view_height = drawPoint3d[1][1]-drawPoint3d[0][1]. Calculate the view area based on the view width view_width and the view height view_height, and sort the views from large to small by view area; to ensure that in the subsequent placement steps, the views with larger areas can be placed first. Because the larger the view, the harder it is to find a suitable position. If we place a view with a smaller area first, it may result in not being able to find a suitable position to place the view with a larger area later. In the embodiment of the present application, the view with the largest area is the first view, the view with the second largest area is the second view, and so on.

[0124] Step 103D: traverse the sorted views and place the sorted views in the current page in order from large to small.

[0125] Specifically, placing the sorted views in the current page in descending order includes steps 103D1 to 103D4:

[0126] 103D1: placing the first view in the first row of the current page and updating the placement position of the first view;

[0127] In this step, if it is the first placement, the moving point is defined as move[0]=10; move[1]=Height-10; move[2]=0; determine whether it is out of bounds based on the module position analysis function. If it is not out of bounds, it means that the current view can be placed, and update the view's position information to the placements list to record the view's position information; if it is out of bounds, continue to try to place the next view.

[0128] 103D2: Determine whether the remaining width of the first row is greater than the width of the second view. When the remaining width of the first row is greater than the width of the second view, place the second view in the first row of the current page, after the first view. When the remaining width of the first row is not greater than the width of the second view, place the second view in the second row of the current page. Update the placement position of the second view. Determine whether it is out of bounds according to the module position analysis function. If it is not out of bounds, it means that the current view can be placed. Update the view's position information to the placement list and record the view's position information. If it is out of bounds, continue to try to place the next view.

[0129] In this step, if it is not the first placement, determine whether width–fistst view_width>second viewwidth is established. When the above conditions are established, define the moving point as move[0]=fistst view_width+20; move[1]=Height-10; move[2]=0; otherwise, wrap and place, and define the moving point as move[0]=10; move[1]=Height–first view_height-10; move[2]=0.

[0130] 103D3: Determine whether the remaining width of the first row is greater than the width of the third view. When the remaining width of the first row is greater than the width of the third view, place the third view in the first row of the current page; when the remaining width of the first row is not greater than the width of the third view, determine whether the remaining width of the second row is greater than the width of the third view. When the remaining width of the second row is greater than the width of the third view, place the third view in the second row of the current page; when the remaining width of the second row is not greater than the width of the third view, place the second view in the third row of the current page; and update the placement position of the third view; determine whether it is out of bounds according to the module position analysis function. If it is not out of bounds, it means that the current view can be placed, and update the view's position information to the placement list to record the view's position information; if it is out of bounds, continue to try to place the next view.

[0131] Step 103D3 is a further analogous step of 103D2, and the moving point is defined in the same way as 103D2.

[0132] 103D4: Use the secondary development view move (ProDrawingViewMove) interface to move the view according to the points defined above, and repeat steps 103D1 to 103D3 until all views are placed.

[0133] In the above steps 1 to 3, after each view is placed, it is necessary to determine whether the placed view is out of bounds. If the placed view is not out of bounds, the placement position of the view is updated, thereby ensuring that the subsequently placed view will not overlap with the already placed view.

[0134] Figure 4 This is a schematic diagram of a drawing after position repair according to an embodiment of the present application.

[0135] Step 104: Export and store the feature information of the drawing and the drawing information after the position repair.

[0136] In an exemplary embodiment, the exporting and storing of the characteristic information of the drawing and the drawing information after the position is repaired includes: exporting the drawing's dimension information, remark information, numbering information, business information, modification information marked by the engineer, and the repaired drawing information to Excel and storing them in a database (DB, Data Base).

[0137] Figure 5 The flowchart of the automatic feature recognition method of drawings in the second embodiment of the present application is shown as follows: Figure 5 As shown, the automatic feature recognition method for drawings in the embodiment of the present application includes the following steps:

[0138] Step 501: Engineer uploads the Creo drawing to be analyzed

[0139] Step 502: Sample the Creo drawings uploaded by the engineer for analysis

[0140] Step 503: Determine whether the drawing meets the requirements; if the drawing meets the requirements, execute step 506, otherwise, execute step 504;

[0141] Step 504: Remind the engineer to re-upload the drawing;

[0142] Step 505: After the engineer checks and modifies the drawings, the process returns to step 501;

[0143] Step 506: traverse all Sheets of the drawing;

[0144] Step 507: ProDrawingViewVisit obtains Views;

[0145] Step 508: ProDrawingTablesCollect obtains Tables;

[0146] Step 509: ProDrawingDtlnotesCollect obtains Notes;

[0147] Step 510: traverse the Views of the current Sheet;

[0148] Step 511: Get the screen conversion matrix of the current Sheet;

[0149] Step 512: Get the width and height of the current Sheet;

[0150] Step 513: Obtain the outline coordinates of the current view;

[0151] Step 514: Convert the screen transformation matrix of the Sheet into an inverse matrix;

[0152] Step 515: Obtain Drawing coordinates through contour coordinates and inverse matrix;

[0153] Step 516: Obtain three-dimensional coordinates;

[0154] Step 517: Determine whether a boundary crossing occurs; if a boundary crossing occurs, execute step 520; if a boundary crossing does not occur, execute step 518;

[0155] Step 518: Determine whether all Sheets have been traversed; when all Sheets have been traversed, execute step 519; otherwise, return to step 510;

[0156] Step 519: If the test is normal, a report is generated;

[0157] Step 520: Get the defined x, y offsets;

[0158] Step 521: define the bounding point by three-dimensional coordinates and offset;

[0159] Step 522: ProGraphicsPolylineDraw selects the out-of-bounds view;

[0160] Step 523: Calculate the areas of all views and sort them from large to small;

[0161] Step 524: traverse the sorted view;

[0162] Step 525: Move the coordinate point to place the view;

[0163] Step 526: Determine whether the moved view crosses the border and overlaps; if the moved view does not cross the border and overlap, execute step 527; otherwise, return to step 524;

[0164] Step 527: Place the view;

[0165] Step 528: Update the placement list information.

[0166] The automatic feature recognition method for drawings described in the embodiment of the present application can realize automatic recognition of drawing views, dimensions, tables, notes and other information to form editable record information; realize automatic detection of the position of each view of the drawing, mark out-of-bounds views, and reformat the out-of-bounds views; integrate the automatic recognition and repair functions of the drawings with the database to realize seamless connection between drawings and data.

[0167] The present application also provides a drawing automatic feature recognition device, Figure 6 Schematic diagram of the structure of the drawing automatic feature recognition device according to the embodiment of the present application. Figure 6 As shown, the device comprises:

[0168] An information acquisition module 61 is used to acquire characteristic information of all the drawings to be identified;

[0169] The feature analysis module 62 is used to analyze the drawing according to the feature information of the drawing to be identified, and determine whether the drawing is out of bounds;

[0170] The position repair module 63 is used to repair the position of the drawing when the drawing is out of bounds;

[0171] The information storage module 64 is used to export and store the characteristic information of the drawing and the drawing information after the position is repaired.

[0172] In the embodiments of the present application, Figure 6 The specific manner in which each unit in the illustrated drawing automated feature recognition device performs operations has been described in detail in the embodiments of the method and will not be elaborated on here.

[0173] In an exemplary embodiment, the information acquisition module 61, the feature analysis module 62, the position repair module 63, the information storage module 64, etc. can be implemented by one or more central processing units (CPU), graphics processing units (GPU), application specific integrated circuits (ASIC), DSP, programmable logic devices (PLD), complex programmable logic devices (CPLD), field programmable gate arrays (FPGA), general-purpose processors, controllers, microcontrollers (MCU), microprocessors, or other electronic components.

[0174] In an exemplary embodiment, an electronic device is also provided, including a processor and a memory for storing processor executable instructions, wherein the processor is configured to execute the steps of the above-mentioned drawing automatic feature recognition method when calling the executable instructions in the memory.

[0175] Figure 7 Schematic diagram of the structure of the electronic device according to the embodiment of the present application. Figure 7 As shown, the electronic device 800 supports multi-screen output, and the electronic device 800 may include one or more of the following components: a processing component 802, a memory 804, a power component 806, a multimedia component 808, an audio component 810, an input / output (I / O) interface 812, a sensor component 814, and a communication component 816.

[0176] The processing component 802 generally controls the overall operation of the electronic device 800, such as operations associated with display, phone calls, data communications, camera operations, and recording operations. The processing component 802 may include one or more processors 820 to execute instructions to complete all or part of the steps of the above-mentioned method. In addition, the processing component 802 may include one or more modules to facilitate the interaction between the processing component 802 and other components. For example, the processing component 802 may include a multimedia module to facilitate the interaction between the multimedia component 808 and the processing component 802.

[0177] The memory 804 is configured to store various types of data to support operations on the device 800. Examples of such data include instructions for any application or method operating on the electronic device 800, contact data, phone book data, messages, pictures, videos, etc. The memory 804 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.

[0178] The power component 806 provides power to the various components of the electronic device 800. The power component 806 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the electronic device 800.

[0179] The multimedia component 808 includes a screen that provides an output interface between the electronic device 800 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundaries of the touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 808 includes a front camera and / or a rear camera. When the device 800 is in an operating mode, such as a shooting mode or a video mode, the front camera and / or the rear camera may receive external multimedia data. Each front camera and the rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.

[0180] The audio component 810 is configured to output and / or input audio signals. For example, the audio component 810 includes a microphone (MIC), and when the electronic device 800 is in an operating mode, such as a call mode, a recording mode, and a voice recognition mode, the microphone is configured to receive an external audio signal. The received audio signal can be further stored in the memory 804 or sent via the communication component 816. In some embodiments, the audio component 810 also includes a speaker for outputting audio signals.

[0181] I / O interface 812 provides an interface between processing component 802 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include but are not limited to: a home button, a volume button, a start button, and a lock button.

[0182] The sensor assembly 814 includes one or more sensors for providing various aspects of status assessment for the electronic device 800. For example, the sensor assembly 814 can detect the open / closed state of the device 800, the relative positioning of components, such as the display and keypad of the electronic device 800, and the sensor assembly 814 can also detect the position change of the electronic device 800 or a component of the electronic device 800, the presence or absence of contact between the user and the electronic device 800, the orientation or acceleration / deceleration of the electronic device 800, and the temperature change of the electronic device 800. The sensor assembly 814 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. The sensor assembly 814 may also include an optical sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 814 may also include an accelerometer, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.

[0183] The communication component 816 is configured to facilitate wired or wireless communication between the electronic device 800 and other devices. The electronic device 800 can access a wireless network based on a communication standard, such as Wi-Fi, 2G or 3G, or a combination thereof. In an exemplary embodiment, the communication component 816 receives a broadcast signal or broadcast-related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 816 also includes a near field communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on radio frequency identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technologies.

[0184] In an exemplary embodiment, the electronic device 800 can be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors or other electronic components to execute the steps of the drawing automatic feature recognition method of the above-mentioned embodiment.

[0185] In an exemplary embodiment, a non-transitory computer-readable storage medium including instructions is also provided, wherein a computer program is stored in the computer-readable storage medium, and when the computer program is executed by a processor, the steps of the above-mentioned automatic feature recognition method for drawings are implemented. For example, the non-transitory computer-readable storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.

[0186] It should be understood that "one embodiment" or "an embodiment" mentioned throughout the specification means that specific features, structures or characteristics related to the embodiment are included in at least one embodiment of the present invention. Therefore, "in one embodiment" or "in an embodiment" appearing throughout the specification does not necessarily refer to the same embodiment. In addition, these specific features, structures or characteristics can be combined in one or more embodiments in any suitable manner. It should be understood that in various embodiments of the present invention, the size of the sequence number of the above-mentioned processes does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiment of the present application. The above-mentioned sequence numbers of the embodiments of the present application are for description only and do not represent the advantages and disadvantages of the embodiments.

[0187] It should be noted that, in this article, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the existence of other identical elements in the process, method, article or device including the element.

[0188] In the several embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. The device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as: multiple units or components can be combined, or can be integrated into another system, or some features can be ignored or do not exist.

[0189] The units described above as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units; some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.

[0190] The above is only an embodiment of the present invention, but the protection scope of the present invention is not limited thereto. Any person skilled in the art can easily think of changes or substitutions within the technical scope disclosed by the present invention, which should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention should be based on the protection scope of the claims.

Claims

1. A method for automatic feature recognition of drawings, characterized in that: The method comprises: Obtain feature information of the drawing to be identified; Analyze the drawing according to the characteristic information of the drawing to be identified to determine whether the drawing is out of bounds; When the drawing is out of bounds, the position of the drawing is repaired; Export and store the feature information of the drawing and the drawing information after position repair.

2. The method for automatic feature recognition of drawings according to claim 1, characterized in that: The step of obtaining the characteristic information of the drawing to be identified includes: Get the number of sheets of the drawing to be identified, as well as the views and tables of all pages.

3. The method for automatic feature recognition of drawings according to claim 2, characterized in that: The method of obtaining the number of pages of the drawing to be identified and the views and lists of all pages includes: Obtain the number of pages of the drawing to be identified through the secondary development interface for obtaining the number of sketches, and traverse the drawings to be identified according to the number of pages; set the active page value of the current drawing as the traversal value; Get all the view information of the current page through the secondary development to obtain the sketch view interface; Get all the detail list information of the current page through secondary development to obtain the sketch detail list interface.

4. The method for automatic feature recognition of drawings according to claim 3, characterized in that: The method of obtaining all view information of the current page through the secondary development of the sketch view interface includes: Traverse all pages to get the view collection of the page; Get the dimension information of the current view annotation through the sketch annotation dimension acquisition interface; Get the dimension information marked on the current entity through the Get Entity Dimension API; Traverse the acquired dimension information and obtain the dimension string array information through the Get Annotation Dimension Information interface; According to the string array information, the size information, remark information, number information, business information, and modification information marked by the engineer of the current page are obtained.

5. The method for automatic feature recognition of drawings according to claim 4, characterized in that: The acquisition of the size information, remark information, number information, business information, and modification information marked by the engineer of the current page according to the string array information includes: When the length of the string array information is 1, the string is obtained by splitting it by colon; When the length of the split string is 1, only the size information is available. When the length of the string after segmentation is 2, determine whether the size information is in the first or second position. When the size information is in the first position, the second position is the remark information; when the size information is in the second position, the first position is the number information and business information. When the length of the string after segmentation is 3, the first digit is the number information and business information, the second digit is the size information, and the third digit is the remarks information; Get the size information, remarks information, number information, and business information of the current page; When the length of the string array information is 2, the size information, remark information, number information, business information, and modification information marked by the engineer of the current page are obtained.

6. The method for automatic feature recognition of drawings according to claim 3, characterized in that: The method of obtaining all the detail list information of the current page through the secondary development of the sketch detail list interface includes: Traverse all pages to obtain the page's detail list collection; Get the number of rows and columns of the current detail list by accessing the detail list row number interface and the detail list column number interface; According to the row number and column number, access the detail table cell value interface through secondary development to obtain the value of each cell.

7. The method for automatic feature recognition of drawings according to claim 1, characterized in that: Analyzing the drawing according to the characteristic information of the drawing to be identified to determine whether the drawing is out of bounds includes: Traverse all views of the current page; Get the screen transformation matrix of the current page through the transformation matrix interface of the sketch obtained through secondary development; Obtain the outline coordinates of the current traversal view through secondary development to obtain the outline interface of the view in the sketch; Convert the screen transformation matrix of the page into an inverse matrix; The contour coordinates and the inverse matrix are converted into sketch coordinates through the secondary development specified transformation matrix conversion coordinate interface, and the three-dimensional coordinates are obtained; Get the width and height of the current page through the secondary development interface to obtain the sketch size interface; Whether the drawing is out of bounds is determined according to the three-dimensional coordinates and the width and height of the current page.

8. The method for automatic feature recognition of drawings according to claim 1, characterized in that: When the drawing is out of bounds, repairing the position of the drawing includes: Mark the current view with a frame; Traverse all views of the current page; Get the width and height of each view, calculate the view area based on the width and height of the view, and sort the views from large to small by view area; Traverse the sorted views and place them in the current page in descending order.

9. The method for automatic feature recognition of drawings according to claim 8, characterized in that: Placing the sorted views in the current page in descending order includes: Step 1: Place the first view in the first row of the current page and update the placement position of the first view; Step 2: Determine whether the remaining width of the first row is greater than the width of the second view. When the remaining width of the first row is greater than the width of the second view, place the second view in the first row of the current page, after the first view; when the remaining width of the first row is not greater than the width of the second view, place the second view in the second row of the current page; and update the placement position of the second view; Step 3: Determine whether the remaining width of the first row is greater than the width of the third view. When the remaining width of the first row is greater than the width of the third view, place the third view in the first row of the current page; when the remaining width of the first row is not greater than the width of the third view, determine whether the remaining width of the second row is greater than the width of the third view. When the remaining width of the second row is greater than the width of the third view, place the third view in the second row of the current page; when the remaining width of the second row is not greater than the width of the third view, place the second view in the third row of the current page; and update the placement position of the third view; Repeat steps 1 to 3 until all views are placed.

10. The method for automatic feature recognition of drawings according to claim 9, characterized in that: The method further includes: determining whether the placed view is out of bounds, and updating the placement position of the view when the placed view is not out of bounds.

11. The method for automatic feature recognition of drawings according to claim 1, characterized in that: The exporting and storing of the feature information of the drawing and the drawing information after the position repair includes: The drawing's dimension information, remark information, number information, business information, engineer-annotated modification information, and repaired drawing information are exported and stored.

12. A drawing automatic feature recognition device, characterized in that: The device comprises: An information acquisition module, used to acquire characteristic information of all the drawings to be identified; A feature analysis module is used to analyze the drawing according to the feature information of the drawing to be identified, and determine whether the drawing is out of bounds; The position repair module is used to repair the position of the drawing when it goes out of bounds; The information storage module is used to export and store the feature information of the drawing and the drawing information after position repair.

13. An electronic device comprising a processor and a memory for storing instructions executable by the processor, characterized in that: The processor is configured to execute the steps of the method for automatic feature recognition of drawings as claimed in any one of claims 1 to 11 when calling the executable instructions in the memory.

14. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the method for automatic feature recognition of drawings according to any one of claims 1 to 11 are implemented.