DRC detection method, device and system for PCB and readable storage medium
By separating PCB images and identifying graphics and text, and DRC detection combined with AI models, the security risks caused by dependence on PCB source files in traditional methods are solved, and a more efficient and safe design rule check is achieved.
Patent Information
- Application Number
- CN202411568582.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-05
- Publication Date
- 2025-03-18
AI Technical Summary
The traditional PCB design rule checking (DRC) method relies on PCB source files, and there are problems of information leakage and security risks.
By obtaining PCB pictures, color separation and graphic recognition, PCB traces are generated, and DRC detection is used to generate detection reports.
Reduces dependence on PCB source files, reduces the risk of design errors and information leakage, and improves security and detection efficiency.
Smart Images

Figure CN119648623A_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the technical field of PCB detection, and in particular to a DRC detection method, device, system and readable storage medium for PCB. Background Art
[0002] In the process of circuit board design and manufacturing, design rule checking (DRC) is an important part of ensuring the performance and reliability of circuit boards. The traditional DRC detection process relies on PCB source files for design verification, but this method has a significant flaw, that is, it is highly dependent on PCB source files, which can easily lead to information leakage and security risks. Especially when working with external teams, the transmission and sharing of source files may expose design information to potential security threats. Summary of the invention
[0003] The embodiments of the present application provide a DRC detection method, device, system and readable storage medium for PCB, which can perform DRC detection based on PCB images, which is conducive to improving safety.
[0004] A first aspect of an embodiment of the present application provides a DRC detection method for a PCB, comprising:
[0005] Obtaining a PCB image, wherein the PCB image includes stacked layers and traces marked with different colors;
[0006] Performing color separation on the PCB image to obtain stacking and routing information;
[0007] Performing image and text recognition on the PCB image to obtain component placement and pin information;
[0008] Generate a PCB routing context according to the stacking and routing information and the component placement and pin information;
[0009] Perform DRC test on the PCB routing veins to obtain a DRC test report.
[0010] Optionally, performing DRC detection on the PCB routing veins to obtain a DRC detection report includes:
[0011] Obtain DRC inspection requirements;
[0012] Perform DRC inspection on the PCB routing veins according to the DRC inspection requirements to obtain a test result;
[0013] A DRC test report is generated according to the test result to obtain a DRC test report.
[0014] Optionally, performing DRC detection on the PCB routing veins according to the DRC inspection requirements to obtain the detection result includes:
[0015] Input the DRC inspection requirements and the PCB routing context into a pre-trained AI model for DRC detection;
[0016] The AI model is used to compare the DRC detection requirements with the PCB routing context to obtain a detection result.
[0017] Optionally, before inputting the DRC inspection requirement and the PCB routing context into an AI model for DRC detection, the method further includes:
[0018] Get the annotated PCB design files and DRC rule sets as training sets;
[0019] An untrained AI model for DRC detection is trained using the training set to obtain a trained AI model for DRC detection.
[0020] Optionally, obtaining a PCB image includes:
[0021] Sending a detection request to a holder of a PCB source file, so that the holder exports the PCB source file into a corresponding PCB image according to the detection request;
[0022] A detection response returned by the holder is received, where the detection response includes the PCB image.
[0023] Optionally, obtaining a PCB image includes:
[0024] Sending a detection request to a holder of a PCB source file, so that the holder exports the PCB source file into a corresponding PDF file according to the detection request;
[0025] receiving a detection response returned by the holder, wherein the detection response includes the PDF file;
[0026] Get the PCB image in the PDF file.
[0027] Optionally, performing image and text recognition on the PCB image to obtain component placement and pin information includes:
[0028] The PCB image is subjected to graphic recognition according to the unique codes and boundary lines of the components to obtain the placement positions and pin information of the components.
[0029] A second aspect of an embodiment of the present application provides a DRC detection device for a PCB, comprising:
[0030] An acquisition unit is used to acquire a PCB image, wherein the PCB image includes stacked layers and traces marked with different colors;
[0031] A separation unit, used for performing color separation on the PCB image to obtain stacking and routing information;
[0032] An identification unit, used to perform image and text recognition on the PCB image to obtain component placement and pin information;
[0033] A generating unit, used for generating a PCB routing context according to the stacking and routing information and the component placement and pin information;
[0034] The detection unit is used to perform DRC detection on the PCB routing veins to obtain a DRC detection report.
[0035] Optionally, the detection unit includes:
[0036] An acquisition module is used to obtain DRC inspection requirements;
[0037] A detection module, used to perform DRC detection on the PCB routing veins according to the DRC inspection requirements to obtain a detection result;
[0038] A generating module is used to generate a DRC test report according to the test result to obtain a DRC test report.
[0039] Optionally, the detection module is specifically used for:
[0040] Input the DRC inspection requirements and the PCB routing context into a pre-trained AI model for DRC detection;
[0041] The AI model is used to compare the DRC detection requirements with the PCB routing context to obtain a detection result.
[0042] Optionally, the device further comprises a training unit, wherein the training unit is used to:
[0043] Get the annotated PCB design files and DRC rule sets as training sets;
[0044] An untrained AI model for DRC detection is trained using the training set to obtain a trained AI model for DRC detection.
[0045] Optionally, the acquiring unit is specifically used for:
[0046] Sending a detection request to a holder of a PCB source file, so that the holder exports the PCB source file into a corresponding PCB image according to the detection request;
[0047] A detection response returned by the holder is received, where the detection response includes the PCB image.
[0048] Optionally, the acquiring unit is specifically used for:
[0049] Sending a detection request to a holder of a PCB source file, so that the holder exports the PCB source file into a corresponding PDF file according to the detection request;
[0050] receiving a detection response returned by the holder, wherein the detection response includes the PDF file;
[0051] Get the PCB image in the PDF file.
[0052] Optionally, the identification unit is specifically used for:
[0053] The PCB image is subjected to graphic recognition according to the unique codes and boundary lines of the components to obtain the placement positions and pin information of the components.
[0054] A third aspect of the embodiment of the present application provides a DRC detection system for a PCB, including:
[0055] Processor, memory, input-output unit, and bus;
[0056] The processor is connected to the memory, the input and output unit, and the bus;
[0057] A program is stored in the memory, and the processor calls the program to execute the method in the first aspect and any possible implementation manner of the first aspect.
[0058] A fourth aspect of an embodiment of the present application provides a computer-readable storage medium, on which a program is stored. When the program is executed on a computer, the computer executes the method in the first aspect and any possible implementation of the first aspect.
[0059] It can be seen from the above technical solutions that the embodiments of the present application have the following advantages:
[0060] In the embodiment of the present application, since all operations are performed based on image processing and automated algorithms, it is no longer necessary to rely on PCB source files during the verification process. This approach reduces potential design errors and information leakage risks, thereby avoiding the possibility of manual modification of source files and is conducive to improving security. BRIEF DESCRIPTION OF THE DRAWINGS
[0061] Figure 1 This is a flow chart of an embodiment of a DRC detection method for PCB in an embodiment of the present application;
[0062] Figure 2 A schematic diagram of a process for performing DRC detection on a PCB routing pattern in an embodiment of the present application;
[0063] Figure 3 A flowchart of an embodiment of training an AI model in an embodiment of the present application;
[0064] Figure 4 A schematic diagram of a process for obtaining a PCB image in an embodiment of the present application;
[0065] Figure 5 This is a flow chart of another embodiment of obtaining a PCB image in the embodiment of the present application;
[0066] Figure 6 This is a structural schematic diagram of an embodiment of a DRC detection device for PCB in an embodiment of the present application;
[0067] Figure 7 This is a structural schematic diagram of an embodiment of a DRC detection system for PCB in the embodiments of the present application. DETAILED DESCRIPTION
[0068] The embodiments of the present application provide a DRC detection method, device, system and readable storage medium for PCB, which are used to perform DRC detection based on PCB images, thereby improving safety.
[0069] The method of the present application can be applied to a server, a terminal or other devices with logic processing capabilities, and the present application does not limit this. For the convenience of description, the following description is made by taking the execution subject as a server as an example.
[0070] The embodiments of the present application will be described below in conjunction with the accompanying drawings.
[0071] See also Figure 1 In the embodiment of the present application, an embodiment of the DRC detection method for PCB includes:
[0072] 101. Obtain a PCB image, which includes stacking layers and traces marked with different colors;
[0073] First, the server needs to obtain images of the PCB (printed circuit board) from a specified database or file system. These images contain stacking and routing information marked in different colors. PCB is one of the core components of electronic devices, responsible for connecting electronic components and providing pathways for electrical signals. The server can use image processing libraries (such as OpenCV) to load and store these images to ensure that the details of each layer can be clearly captured, such as images generated by high-resolution scanners.
[0074] 102. Perform color separation on the PCB image to obtain stacking and routing information;
[0075] Next, the server performs color separation on the acquired PCB image. This process requires the use of image processing algorithms to extract different color areas in the image to obtain stacking and routing information. The server can use a color threshold segmentation algorithm combined with image processing tools such as color space conversion in OpenCV to identify and separate each color area. This operation can make information such as the power layer, ground layer, and signal layer clearly visible, providing the necessary data basis for the execution of subsequent steps.
[0076] 103. Perform image and text recognition on the PCB image to obtain the placement position and pin information of components;
[0077] After completing the color separation, the server will perform image and text recognition on the PCB image, mainly through OCR (optical character recognition) technology to extract the placement and pin information of components. The server can call the OCR library (such as Tesseract) to identify and extract text and symbol information in the image, such as the model of resistors and capacitors and how they are connected. Through this process, the server can generate a structured data set containing the exact location of each component and the connection information of its pins, laying the foundation for subsequent routing design.
[0078] 104. Generate PCB routing context according to stacking and routing information and component placement and pin information;
[0079] The server then uses the extracted stackup and routing information, as well as the component placement and pin information, to generate the routing pattern of the PCB. At this point, the server uses the API of the PCB design software (such as the interface of Altium Designer) to integrate this information into a logical diagram of electrical connections. The design of the routing pattern must not only follow the minimum routing width and spacing specifications, but also ensure signal integrity and electrical performance. Through this process, the server is able to generate a comprehensive circuit design diagram that reflects the paths of all electrical connections.
[0080] 105. Perform DRC test on the PCB routing veins and obtain the DRC test report.
[0081] Finally, the server performs DRC (design rule check) on the generated PCB routing context to ensure that the design meets various electrical and mechanical specifications. The server can call the design rule checking tool (such as KiCad's DRC function) for detection and generate a DRC test report. This report will list all potential problems, such as routing that is too close or inappropriate apertures, to ensure that these defects can be corrected before production. This process not only improves the accuracy of the design, but also effectively avoids potential failures in production.
[0082] In this embodiment, because all operations are performed based on image processing and automated algorithms, there is no need to rely on PCB source files during the verification process. This approach reduces potential design errors and information leakage risks, thereby avoiding the possibility of manual modification of source files and is conducive to improving security.
[0083] In addition, the process of automatically detecting and generating routing patterns can ensure that the design meets the standards, effectively reducing the failure rate and improving the reliability of the final product. At the same time, it reduces the dependence on source files, making the system safer and more stable during the processing.
[0084] Furthermore, in some embodiments of the present application, step 104 in the above embodiment generates a PCB routing context based on the stacking and routing information and the component placement and pin information, and may specifically include: performing graphic recognition on the PCB image based on the unique coding and boundary lines of the components to obtain the component placement and pin information.
[0085] Specifically, the server first uses the unique code of the components and the boundary lines of the PCB design to perform image and text recognition on the acquired PCB image. The unique code is usually an identifier printed on each component, which can effectively distinguish different components. By detecting the boundary lines, the server can accurately locate the layout of the entire circuit board, thereby extracting the position of each component and the corresponding pin information. The image and text recognition process usually uses computer vision technology and deep learning algorithms to ensure the accuracy and efficiency of recognition. The recognition results will provide an important data basis for subsequent DRC testing to ensure the compliance and reliability of the design.
[0086] In this embodiment, the process of using unique codes and boundary lines for image and text recognition not only improves the accuracy of component information extraction, but also reduces errors caused by human factors in traditional methods. The introduction of this method ensures the reliability of component placement and pin information, and further enhances the security and effectiveness of design verification.
[0087] See also Figure 2In some embodiments of the present application, step 105 in the above embodiment performs DRC detection on the PCB routing veins to obtain a DRC detection report, which may include the following steps 201 to 204:
[0088] 201. Obtain DRC inspection requirements;
[0089] The server first needs to obtain the DRC (design rule check) inspection requirements. These requirements usually come from the circuit board design standards, which define parameters such as trace width, spacing, and stacking order to ensure the functionality and reliability of the circuit board. These requirements can be obtained by querying the database or extracting them from the design documents. The server can use interface or document parsing technology to ensure that the requirements obtained are complete and meet the preset standards. For example, the design team may provide a set of DRC rules that meet industry standards, and the server needs to store and manage this information for use in subsequent inspection processes.
[0090] 202. Input the DRC inspection requirements and PCB routing context into the pre-trained AI model for DRC detection;
[0091] Next, the server inputs the acquired DRC inspection requirements and the previously generated PCB routing context into a pre-trained AI model. This AI model is usually trained with a large amount of circuit board design data and can automatically identify potential problems in the design. The server combines these two data sets and inputs them into the model through the API to ensure that the data format and content meet the input requirements of the model. The purpose of this is to take advantage of the efficiency and accuracy of AI to complete complex inspection tasks in a short time.
[0092] 203. Use the AI model to compare the DRC test requirements with the PCB routing context to obtain the test results;
[0093] The server then uses the AI model to compare the DRC detection requirements with the PCB routing context to obtain the detection results. This process involves deep learning and pattern recognition technology. The AI model analyzes the input data and identifies whether there are any parts that violate the design rules. Through machine learning algorithms, the model can process large amounts of data quickly and efficiently and automatically generate a list of potential problems. For example, if the routing width does not meet the design requirements, the model will mark the specific areas and problems, which allows designers to make timely adjustments.
[0094] 204. Generate a DRC test report according to the test result to obtain the DRC test report.
[0095] Finally, the server generates a DRC test report based on the test results. The report lists all detected problems and their corresponding descriptions and locations in detail, helping designers quickly locate and correct design defects. The server can automatically generate reports and format them into easy-to-read documents such as PDF or HTML, which is convenient for the design team to review and follow up. In addition, the report can include recommended modifications to improve the quality and safety of the design. This automated report generation process significantly improves work efficiency and reduces the time for manual review.
[0096] In this embodiment, by obtaining clear DRC inspection requirements, compliance with design specifications is ensured and the risk of potential failures is reduced. At the same time, the use of AI models to quickly identify problems in the design significantly improves detection efficiency and reduces the possibility of human error, thereby reducing correction costs and time. The automatically generated DRC test report provides designers with clear problem descriptions and suggestions, helping them take timely measures and further improving the safety of the design.
[0097] See also Figure 3 In some embodiments of the present application, step 202 in the above embodiment inputs the DRC inspection requirements and the PCB routing context into a pre-trained AI model for DRC detection. The DRC detection method for PCB may further include the following steps 301 to 302:
[0098] 301. Obtain the annotated PCB design file and DRC rule set as a training set;
[0099] The server first needs to obtain the annotated PCB design files and DRC (design rule check) rule sets as training sets. These design files contain the layout and connection information of various circuit boards, while the DRC rule sets define key parameters in the design, such as trace width, spacing, stacking order, etc. The annotated design files are usually reviewed by experts to ensure their accuracy and compliance. The server can extract these files from the database, or obtain the latest annotated files and corresponding rule sets through cooperation with the design team to ensure the quality and diversity of the training data.
[0100] 302. Train an untrained AI model for DRC detection using a training set to obtain a trained AI model for DRC detection.
[0101] Next, the server uses the acquired training set to train the untrained AI model to obtain a trained model for DRC detection. This process usually involves inputting the annotated PCB design file into the AI model and training the back-propagation algorithm in combination with the DRC rule set. During the training process, the model will learn how to identify defects in the design and improve its understanding of different circuit board designs. The server monitors the training process to ensure the convergence and accuracy of the model, and optimizes the performance of the model by adjusting hyperparameters and the number of training rounds.
[0102] In this embodiment, the annotated PCB design files and DRC rule sets are obtained as training sets, which provide a high-quality data foundation for the AI model, thereby enhancing the model's ability to understand the design rules. Through training, the model can effectively identify potential design defects, improve the accuracy and efficiency of DRC detection, and ultimately provide more reliable support for circuit board design.
[0103] See also Figure 4 In some embodiments of the present application, step 101 in the above embodiment, obtaining a PCB image, wherein the PCB image includes stacking layers and routings marked with different colors, may include the following steps 401 to 402:
[0104] 401. Sending a detection request to the holder of the PCB source file, so that the holder exports the PCB source file into a corresponding PCB image according to the detection request;
[0105] The server first sends a detection request to the holder of the PCB source file, asking it to export the PCB source file to the corresponding PCB image according to the request. This request should detail the layers and resolutions to be exported to ensure that the obtained images meet the requirements of subsequent processing. The server can send this request via email, API call or other communication methods to ensure that the holder can accurately understand and execute the export task, so as to obtain the required high-quality PCB images.
[0106] 402. Receive a detection response returned by the holder, where the detection response includes a PCB image.
[0107] Next, the server receives the detection response returned by the holder, which contains the requested PCB image. The server needs to verify the format and quality of the returned image to ensure that it meets the previously set standards. If the image meets the requirements, the server stores it for subsequent analysis and processing. If there is a problem in the response, the server may record the error information and resend the request to ensure that a valid PCB image is finally obtained.
[0108] In this embodiment, a test request is sent to the PCB source file holder and a response is received, which ensures that high-quality PCB images are obtained and provides necessary input for subsequent DRC testing. The automation of this process reduces the need for manual intervention, improves overall efficiency, and ensures the accuracy and timeliness of design verification.
[0109] See also Figure 5 In some embodiments of the present application, step 101 in the above embodiment, obtaining a PCB image, wherein the PCB image includes stacked layers and traces marked with different colors, may include the following steps 501 to 503:
[0110] 501. Sending a detection request to the holder of the PCB source file, so that the holder exports the PCB source file into a corresponding PDF file according to the detection request;
[0111] The server first sends a detection request to the holder of the PCB source file, asking it to export the PCB source file to the corresponding PDF file according to the request. When sending the request, the server should clearly indicate the specific content required, such as the layers and views that need to be included, to ensure that the returned PDF file meets the needs of subsequent processing. This request can be sent via email, API or other communication methods to ensure that the holder understands and can accurately perform the export operation to generate a suitable PDF file.
[0112] 502. Receive a detection response returned by the holder, where the detection response includes a PDF file;
[0113] Next, the server receives the detection response returned by the holder, which contains the requested PDF file. The server needs to verify whether the format of the returned PDF file is correct and ensure that the content meets the previously set standards. This verification process may include checking the file size, format, and content integrity. If the PDF file meets the requirements, the server stores it for subsequent analysis; if there is a problem, the server can record the error message and resend the request to ensure that a valid PDF file is obtained.
[0114] 503. Get the PCB image in the PDF file.
[0115] Finally, the server extracts the PCB image from the received PDF file. This process usually involves using a PDF parsing library or tool to convert the PDF content into a usable image format. The extracted PCB image will serve as input data for subsequent analysis and processing to ensure the consistency and accuracy of the entire process.
[0116] In this embodiment, the process of sending a test request to the PCB source file holder and receiving a response ensures the acquisition of a high-quality PDF file, which contains the necessary PCB images and provides a basis for subsequent DRC testing and analysis. The automation of this process improves efficiency, reduces the need for manual intervention, and ensures accurate information transmission.
[0117] See also Figure 6 In the embodiment of the present application, an embodiment of a DRC detection device for PCB includes:
[0118] An acquisition unit 601 is used to acquire a PCB image, where the PCB image includes stacked layers and traces marked with different colors;
[0119] The separation unit 602 is used to perform color separation on the PCB image to obtain stacking and routing information;
[0120] The recognition unit 603 is used to perform image and text recognition on the PCB image to obtain the placement position and pin information of components;
[0121] A generating unit 604 is used to generate a PCB routing context according to the stacking and routing information and the component placement and pin information;
[0122] The detection unit 605 is used to perform DRC detection on the PCB routing veins and obtain a DRC detection report.
[0123] In this embodiment, because all operations are performed based on image processing and automated algorithms, there is no need to rely on PCB source files during the verification process. This approach reduces potential design errors and information leakage risks, thereby avoiding the possibility of manual modification of source files and is conducive to improving security.
[0124] In addition, the process of automatically detecting and generating routing patterns can ensure that the design meets the standards, effectively reducing the failure rate and improving the reliability of the final product. At the same time, it reduces the dependence on source files, making the system safer and more stable during the processing.
[0125] Optionally, the detection unit 605 includes:
[0126] An acquisition module is used to obtain DRC inspection requirements;
[0127] The detection module is used to perform DRC detection on the PCB routing veins according to the DRC inspection requirements to obtain the detection results;
[0128] The generation module is used to generate a DRC test report according to the test results to obtain the DRC test report.
[0129] Optionally, the detection module is specifically used for:
[0130] Input the DRC inspection requirements and PCB routing context into the pre-trained AI model for DRC detection;
[0131] The AI model is used to compare the DRC detection requirements with the PCB routing context to obtain the detection results.
[0132] Optionally, the device further comprises a training unit, and the training unit is used for:
[0133] Get the annotated PCB design files and DRC rule sets as training sets;
[0134] An untrained AI model for DRC detection is trained using a training set to obtain a trained AI model for DRC detection.
[0135] Optionally, the acquiring unit 601 is specifically configured to:
[0136] Sending a detection request to the holder of the PCB source file, so that the holder exports the PCB source file into a corresponding PCB image according to the detection request;
[0137] Receive the detection response returned by the holder, which includes the PCB image.
[0138] Optionally, the acquiring unit 601 is specifically configured to:
[0139] Sending a test request to the holder of the PCB source file, so that the holder exports the PCB source file into a corresponding PDF file according to the test request;
[0140] Receive the detection response returned by the holder, which includes the PDF file;
[0141] Get the PCB image in the PDF file.
[0142] Optionally, the identification unit 603 is specifically configured to:
[0143] The PCB image is recognized based on the unique code and boundary line of the components to obtain the component placement and pin information.
[0144] In this implementation, the functions of each unit and module are the same as those described above. Figures 1 to 5 The steps in the illustrated embodiments correspond to each other and will not be described again here.
[0145] See also Figure 7 In the embodiment of the present application, an embodiment of a DRC detection system for PCB includes:
[0146] Processor 701, memory 702, input and output unit 703 and bus 704;
[0147] The processor 701 is connected to the memory 702, the input and output unit 703 and the bus 704;
[0148] The memory 702 stores a program, and the processor 701 calls the program to execute Figures 1 to 5 Steps in the illustrated embodiment.
[0149] In this embodiment, the function of the processor 701 is the same as that of the aforementioned Figures 1 to 5 The steps in the illustrated embodiments correspond to each other and will not be described again here.
[0150] The present application also provides a computer-readable storage medium having a program stored thereon, which, when executed on a computer, causes the computer to execute Figures 1 to 5 A method in any possible implementation manner in the illustrated embodiment.
[0151] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0152] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, 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 integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.
[0153] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0154] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0155] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, read-only memory), random access memory (RAM, random access memory), disk or optical disk and other media that can store program code.
Claims
1. A DRC detection method for PCB, characterized in that: include: Obtaining a PCB image, wherein the PCB image includes stacked layers and traces marked with different colors; Performing color separation on the PCB image to obtain stacking and routing information; Performing image and text recognition on the PCB image to obtain component placement and pin information; Generate a PCB routing context according to the stacking and routing information and the component placement and pin information; Perform DRC test on the PCB routing veins to obtain a DRC test report.
2. The method according to claim 1, characterized in that The DRC test is performed on the PCB routing veins to obtain a DRC test report including: Obtain DRC inspection requirements; Perform DRC inspection on the PCB routing veins according to the DRC inspection requirements to obtain a test result; A DRC test report is generated according to the test result to obtain a DRC test report.
3. The method according to claim 2, characterized in that The DRC test is performed on the PCB routing veins according to the DRC inspection requirements to obtain the test results, including: Input the DRC inspection requirements and the PCB routing context into a pre-trained AI model for DRC detection; The AI model is used to compare the DRC detection requirements with the PCB routing context to obtain a detection result.
4. The method according to claim 3, characterized in that: Before inputting the DRC inspection requirements and the PCB routing context into the AI model for DRC detection, the method further includes: Get the annotated PCB design files and DRC rule sets as training sets; An untrained AI model for DRC detection is trained using the training set to obtain a trained AI model for DRC detection.
5. The method according to any one of claims 1 to 4, characterized in that The obtaining of the PCB image comprises: Sending a detection request to a holder of a PCB source file, so that the holder exports the PCB source file into a corresponding PCB image according to the detection request; A detection response returned by the holder is received, where the detection response includes the PCB image.
6. The method according to any one of claims 1 to 4, characterized in that The obtaining of the PCB image comprises: Sending a detection request to a holder of a PCB source file, so that the holder exports the PCB source file into a corresponding PDF file according to the detection request; receiving a detection response returned by the holder, wherein the detection response includes the PDF file; Get the PCB image in the PDF file.
7. The method according to any one of claims 1 to 4, characterized in that The performing of image and text recognition on the PCB image to obtain component placement and pin information includes: The PCB image is subjected to graphic recognition according to the unique codes and boundary lines of the components to obtain the placement positions and pin information of the components.
8. A DRC detection device for PCB, characterized in that: include: An acquisition unit is used to acquire a PCB image, wherein the PCB image includes stacked layers and traces marked with different colors; A separation unit, used for performing color separation on the PCB image to obtain stacking and routing information; An identification unit, used to perform image and text recognition on the PCB image to obtain component placement and pin information; A generating unit, used for generating a PCB routing context according to the stacking and routing information and the component placement and pin information; The detection unit is used to perform DRC detection on the PCB routing veins to obtain a DRC detection report.
9. A DRC detection system for PCB, characterized in that: include: Processor, memory, input-output unit, and bus; The processor is connected to the memory, the input and output unit, and the bus; A program is stored in the memory, and the processor calls the program to execute the method according to any one of claims 1 to 7. 10 . A computer-readable storage medium having a program stored thereon, wherein when the program is executed on a computer, the computer is caused to execute the method according to claim 1 .