A logic analysis method for a circuit system block diagram
By combining the YOLOv1 object detection model and the visual language large model, fine-tuning is performed using component numbering and masking mechanisms, and random numbering data augmentation method is adopted to solve the problem of automated parsing of circuit system block diagrams. This achieves accurate identification and structured representation of component positions and connection relationships, and improves the automation and intelligence level of circuit system block diagrams.
Patent Information
- Application Number
- CN202611166511.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-03
- Publication Date
- 2026-11-20
AI Technical Summary
Existing technologies struggle to efficiently convert visual information in circuit system block diagrams into structured design data automatically. Furthermore, multimodal large models lack structural constraints and visual guidance in circuit system block diagrams, leading to incomplete recognition, logical confusion, or structural inconsistencies.
By combining the YOLOv1 object detection model with a large visual language model, and fine-tuning it through component numbering and masking mechanisms, visual guidance images are generated. Then, by using random numbering data augmentation methods, automatic recognition and structured analysis of circuit system block diagrams are achieved.
It enables accurate identification and structured parsing of component positions and their connections in circuit system block diagrams, generating structured data in standardized JSON format, thus improving the automation and intelligence level of circuit system block diagram parsing.
Smart Images

Figure CN123139879A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of electronic design automation technology, and specifically to a logical analysis method for circuit system block diagrams. Background Technology
[0002] With the increasing complexity of integrated circuit design, electronic design automation (EDA) technology plays a crucial role in chip architecture design, system modeling, and functional verification. In the circuit system-level design process, system block diagrams, as an important carrier for expressing module division, signal flow, and functional relationships, are widely used in academic papers, technical reports, and patent documents. System block diagrams are usually presented in graphical form, containing numerous functional modules, text annotations, and directional connections, carrying important structural and logical information.
[0003] However, existing circuit system block diagrams are mostly stored as unstructured images, and their analysis and utilization still mainly rely on manual reading and annotation, which is not only inefficient but also prone to misunderstandings. With the rapid increase in the number of technical documents, how to automatically convert the visual information in block diagrams into structured design data has become an urgent problem to be solved in the field of electronic design automation.
[0004] In existing technologies, some methods employ traditional computer vision algorithms to detect and recognize graphic elements in images. However, these methods typically rely on rule-based design, making it difficult to handle complex topological structures, line intersections, and occlusions, resulting in limited generalization capabilities. On the other hand, while pure vision models can identify target regions in images, they struggle to accurately understand the logical semantic relationships between modules. In recent years, multimodal large models have made some progress in the field of image and text understanding. However, in specialized scenarios such as circuit system block diagrams, due to the lack of structural constraints and visual guidance mechanisms, these models still suffer from incomplete recognition, logical confusion, or structural inconsistencies in connection relationship reasoning and topology reconstruction.
[0005] Furthermore, existing technologies generally fail to achieve unified structured modeling from component detection and port count to connection relationship extraction, making it difficult to generate standardized data formats that meet engineering application requirements and unable to directly serve downstream applications such as design verification, automatic report generation, or knowledge retrieval.
[0006] Therefore, it is necessary to propose an automatic circuit block diagram parsing method that integrates visual detection and multimodal semantic reasoning capabilities to accurately identify component information, port structure and connection topology, and generate structured data results, thereby improving the automation and intelligence level of circuit system block diagram parsing. Summary of the Invention
[0007] In order to overcome the above-mentioned shortcomings and deficiencies of the prior art, the purpose of this invention is to provide a logical analysis method for circuit system block diagrams.
[0008] The objective of this invention is achieved through the following technical solution:
[0009] A logical analysis method for circuit system block diagrams includes the following:
[0010] S1 acquires the block diagram image of the circuit system to be parsed and preprocesses the image;
[0011] S2 inputs the preprocessed image into the object detection model to detect the components in the image and outputs the bounding box coordinates and confidence information for each component.
[0012] S3 uses a fine-tuning strategy based on component numbering and masking mechanism to process the image after component detection, and obtains the image after numbering and labeling.
[0013] S4 uses the numbered and labeled images as visual input, and constructs structured prompt text as language input. The visual input and language input are input into the visual language large model. The loss is calculated based on the connection relationship prediction results and the real labels, and the model parameters are updated to obtain the fine-tuned visual language large model.
[0014] S5 uses a finely tuned visual language model to identify the connection relationships in the circuit system block diagram. Then, it matches the connection relationships with the component numbers and parses the obtained component location information, component numbers, and connection relationships between components.
[0015] Furthermore, a fine-tuning strategy based on component numbering and masking mechanism is adopted, specifically including a data augmentation method with randomized numbering and a component region masking annotation method.
[0016] Furthermore, this includes two types:
[0017] The first method is the center mask numbering method, which masks the component bounding box area and fills the component area with a uniform color, thereby eliminating the internal texture information of the component and only retaining the spatial position of the component. At the same time, a unique number is drawn at the center of each bounding box to represent the unique identifier of the component. The original name of the component is hidden in this view.
[0018] The second method is corner numbering, which involves marking the number near the upper left corner of the component's bounding box while ensuring that the component name and original structural information are not obscured.
[0019] Furthermore, the numbering adopts an adaptive font size calculation method based on component size.
[0020] Furthermore, the structured prompt text is used to limit the output format of the visual language large model and define the rules for determining connection relationships.
[0021] Furthermore, the defined rules for determining connection relationships are as follows:
[0022] Output connections are defined as the components that the arrow emitted by the current component directly points to; only direct connections are considered, and indirect path relationships are not inferred.
[0023] Disconnected branch structure and feedback loop.
[0024] Furthermore, the parsed component location information, component IDs, and connection relationships between components are integrated into structured data and output in a standardized JSON format. In the output data, each component includes its component ID, component name, component location, and a set of corresponding output connection component IDs, thus forming a complete description of the system topology.
[0025] Furthermore, the preprocessing includes size normalization, noise suppression and enhancement, and color space conversion.
[0026] Furthermore, the target detection model adopts the YOLOv11 target detection network.
[0027] Furthermore, it also includes validating the output results, specifically checking the validity of the number, filtering duplicate connections, and correcting abnormal connections.
[0028] Compared with the prior art, the present invention has the following advantages and beneficial effects:
[0029] (1) By integrating the target detection model and the visual language big data model, the automatic identification and structured analysis of the component positions and their connection relationships in the circuit system block diagram are realized. First, the present invention uses the YOLOv11 model to automatically detect and locate the components in the system block diagram, thereby obtaining the spatial position information of each component and providing basic data for subsequent topology analysis.
[0030] (2) This invention proposes a visual guidance strategy based on numbering and masking. By introducing numbering labels in the component area and combining them with masking to generate visual guidance images, the multimodal model can use the numbering as the unique identifier of the component, thereby reducing the interference of image text information on the identification of connection relationships and enhancing the model's ability to focus on the structural relationships between components.
[0031] (3) In view of the problem of limited system block diagram data scale, the present invention proposes a random numbering data augmentation method. By randomly shuffling the component numbers and updating the connection relationship synchronously, new training samples are generated while keeping the system topology unchanged, thereby effectively expanding the training data scale and improving the generalization ability of the model in different system block diagram scenarios.
[0032] (4) This invention makes targeted fine-tuning to the large visual language model, enabling the model to combine visual information and structured prompts to complete the automatic reasoning of component connection relationships, and transform the complex topological structure in the system block diagram into a standardized structured data representation.
[0033] (5) The present invention can organize the parsed component information and connection relationship in a unified manner and output it in JSON format, realizing the automatic conversion of circuit system block diagram to structured topology data, providing a data foundation for subsequent circuit system analysis, design verification and intelligent modeling and other applications. Attached Figure Description
[0034] Figure 1 This is a flowchart of the workflow of the present invention.
[0035] Figure 2 This is a circuit system block diagram used in an embodiment of the present invention. Detailed Implementation
[0036] The present invention will be further described in detail below with reference to the embodiments, but the implementation of the present invention is not limited thereto.
[0037] Example
[0038] like Figure 1 As shown, a logic analysis method for a circuit system block diagram includes the following steps:
[0039] S1 obtains the block diagram image of the circuit system to be analyzed and preprocesses the image, specifically:
[0040] The block diagram image of the circuit system to be analyzed is obtained and preprocessed. The preprocessing includes image size normalization, scaling the image proportionally when the resolution exceeds a preset threshold to reduce computational complexity, noise suppression and enhancement to improve image clarity and structural recognizability, and color space conversion when necessary. These preprocessing steps ensure the image meets the input requirements for subsequent model processing.
[0041] The circuit system block diagram primarily uses functional modules and arrows to describe how test signals are generated. In this invention, the circuit system block diagram refers to a system-level block diagram image that uses functional modules, connecting lines, and arrows to represent the circuit system composition and signal transmission relationships. The circuit system block diagram image includes multiple components with independent functions, component names located within or near the components, connecting lines linking different components, arrows indicating the signal transmission direction, and signal attribute labels located near the connecting lines; wherein, the components include a signal generation module, a signal processing module, a signal conversion module, and a signal distribution module. The circuit system block diagram image is used to describe the generation, transmission, conversion, processing, distribution, and measurement processes of signals between different components, and reflects the directed topological connections between the components.
[0042] S2 Component Detection and Positioning
[0043] After preprocessing, the image is input into a YOLO object detection model to detect and identify components in the block diagram. In a preferred embodiment, the object detection model uses the YOLOv11 object detection network, leveraging its end-to-end detection capabilities to locate functional modules in the circuit block diagram and output the bounding box coordinates and confidence information for each component. Through this detection process, the spatial distribution and basic category information of all components in the image can be obtained.
[0044] S3 employs a fine-tuning strategy based on component numbering and a masking mechanism to process the image after component detection, resulting in an image with numbered labels.
[0045] To address the challenges of limited available datasets and the difficulty of existing multimodal large models in accurately understanding the topological relationships between modules in an image, this invention proposes a model fine-tuning strategy based on component numbering and a masking mechanism.
[0046] Specifically, by introducing unique numbers into each component region in the circuit block diagram and masking these regions, the model can focus more on the connection structure information between modules, thereby enhancing its ability to understand topological relationships. Simultaneously, to further improve the model's generalization performance and robustness, this invention designs a data augmentation method based on the aforementioned numbering strategy, which randomly shuffles the component numbers to generate multiple training samples. This effectively expands the scale of the training data and enables the fine-tuned model to accurately identify the connection relationships between modules even under different numbering arrangements, thus significantly improving its ability to resolve complex topological structures.
[0047] The specific process is as follows:
[0048] First, an object detection model is used to detect each component in the circuit block diagram, obtaining the bounding box positions of the components. Let the normalized bounding boxes of the detected components be:
[0049] (1)
[0050] in, , Indicates the first Normalized coordinates of the center point of each component; , This represents the width and height of the component's bounding box, with coordinates ranging from [0,1].
[0051] When the image size is At this time, the component bounding box can be converted to absolute pixel coordinates:
[0052] (2)
[0053] (3)
[0054] (4)
[0055] (5)
[0056] This yields the rectangular region of the component in the image. After obtaining the component's position, this invention proposes two numbering and masking strategies:
[0057] The first method is the center-mask numbering method. In this method, the component's bounding box area is masked and filled with a uniform color (e.g., white), thus eliminating internal texture information and retaining only the component's spatial position. Simultaneously, a unique number is drawn at the center of each bounding box to represent the component's unique identifier. The original component name is hidden from this perspective, allowing the model to focus on the connections between the numbers.
[0058] The second method is corner numbering. In this method, the component area is not masked; instead, a number is marked near the top left corner of the component's bounding box, ensuring that the component name and original structural information are not obscured. This method allows for semantic recognition using the component name information simultaneously.
[0059] Further explanation: Original structural information refers to the fact that the components in this circuit block diagram are actually labeled with names or some parameters and formulas. If the first option is selected, all the information within the component will be obscured. If the second option is used, some information will be retained. The dataset in the fine-tuning process contains data from both methods, but in the actual reasoning process, you can choose either method arbitrarily.
[0060] To ensure good readability of the numbering across components of different sizes, this invention employs an adaptive font size calculation method based on component size. Let the component bounding box width be... The height is The font scaling factor It can be represented as:
[0061] (6)
[0062] in, The scaling factor for the font used to indicate numbering. This represents the minimum side length of the component's bounding box. For experience, The adjustment coefficient is used to control the scale.
[0063] The above method allows the font size of the numbering to automatically adjust according to the component size, thus maintaining a stable visual effect across components of different scales. After component numbering, the original component position is no longer directly used as the component identifier; instead, the number serves as the new unique ID for the component, and the connection relationships between components are established based on this number. Through this numbering mechanism, the large-scale visual model can more stably establish the mapping between component nodes and connection relationships, thereby improving the ability to resolve the topology of the circuit system block diagram.
[0064] S4 uses the labeled images as visual input and constructs structured prompt text as language input. The visual and language inputs are then input into the visual large model for pre-training. The loss is calculated based on the connection relationship prediction results and the real labels, and the model parameters are updated to obtain the fine-tuned visual-language large model (VLM large model).
[0065] After automatically locating and labeling the components in the system block diagram, it is necessary to further analyze the connection relationships and topological structure between the components. While traditional large-scale visual models can detect component positions, their ability to understand the logical relationships between components is weak. To address this issue, this invention employs a large-scale visual language model for fine-tuning and training, enabling the model to combine image information with labeling information to automatically identify the connection relationships between components in the system block diagram.
[0066] The specific process is as follows:
[0067] During the input phase, the image after component detection and numbering is used as visual input, while structured prompt text is constructed as linguistic input. Let the set of detected components in the system block diagram be:
[0068] (7)
[0069] in, Indicates the first There are N components, where N is the total number of components. Each component contains the following information:
[0070] (8)
[0071] in, Assign component number, For component bounding box, This is the text name of the component.
[0072] After numbering and labeling, the model only needs to focus on the relationships between the numbers, without having to directly identify complex component names, thus reducing the difficulty of visual recognition.
[0073] The final input data to the model can be represented as:
[0074] (9)
[0075] in, The image is processed using a numbered mask, and P represents a structured cue word.
[0076] The connection relationships in the system block diagram can be abstracted into a directed graph structure:
[0077] (10)
[0078] in, For the component number collection, This is a collection of connection relationships between components.
[0079] The input and output of the model can be represented as:
[0080] (11)
[0081] (12)
[0082] in, Indicates the component number. Representation Component The output connection combination can transform the complex topological structure in the system block diagram into a structured numbering relationship, which facilitates model learning and reasoning.
[0083] Due to the limited size of the system block diagram dataset, this invention proposes a random numbering data augmentation method to improve the model's generalization ability to topological relationships. For the original numbering set: :
[0084] By generating a random permutation function and randomly mapping the component numbers, the corresponding connection relationships are updated:
[0085] (13)
[0086] (14)
[0087] (15)
[0088] In this way, new training samples can be generated while keeping the topology unchanged, thereby effectively expanding the scale of training data.
[0089] The training samples after random numbering can be represented as:
[0090] (16)
[0091] This strategy avoids the model memorizing the correspondence between fixed numbers and component categories, allowing the model to focus more on the connection relationships and topology between components.
[0092] S5 uses a finely tuned visual language model to identify the connection relationships in the circuit system block diagram. Then, it matches the connection relationships with the component numbers and parses the obtained component location information, component numbers, and connection relationships between components.
[0093] The numbered images generated in step S3, along with preset prompts, are input into the fine-tuned visual language model for connection relationship inference. The prompts define the model's output format and connection relationship determination rules. Output connections are defined as the components directly pointed to by the arrows emitted by the current component; only direct connections are judged, without inferring indirect path relationships. The model also supports the recognition of broken branch structures and feedback loops. The visual language model performs cross-modal semantic inference based on visual and prompt information, outputting the number of each component and its corresponding list of output connection numbers.
[0094] To further explain, the branch refers to the fact that the output of a component may point to multiple components, and the feedback loop usually refers to the output signal of a downstream module being connected back to the upstream module or its own input.
[0095] After the model inference is completed, the identified connections are matched with the component numbers to obtain the complete topology of the system block diagram. To ensure the validity of the output results, this invention further parses and verifies the model output results, including steps such as number validity checking, duplicate connection filtering, and abnormal connection correction, to improve the accuracy of topology parsing.
[0096] Finally, the parsed component location information, component numbers, and connection relationships between components are integrated into structured data and output in a standardized JSON format. Each component in the output data includes its component number, component name, component location, and a set of corresponding output connection component numbers, thus forming a complete description of the system topology. This method enables the automatic conversion of system block diagrams into structured topology data, providing a reliable data foundation for subsequent circuit analysis, system modeling, and automated design.
[0097] This method is used to perform structural analysis on the circuit system block diagram. For example... Figure 2 As shown, this figure is a block diagram of a radio frequency transceiver system. It is not a circuit schematic diagram used to represent electronic components such as transistors, resistors, and capacitors and their specific electrical connections. Instead, it uses functional modules, module numbers, and directional connection arrows to represent the processing of radio frequency signals in the transmit and receive links.
[0098] Task requirements: Detect and locate module regions with independent functions from the circuit system block diagram image, obtain the bounding box, component name and unique number of each component, and provide node information for subsequent connection relationship analysis.
[0099] Using this method according to Figure 2 The rectangular function box in the image identifies 9 components, as shown in Table 1:
[0100] Table 1
[0101]
[0102] Those skilled in the art will readily understand that the above description is merely an embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.
Claims
1. A logical analysis method for a circuit system block diagram, characterized in that, Including the following: S1 acquires the block diagram image of the circuit system to be parsed and preprocesses the image; S2 inputs the preprocessed image into the object detection model to detect the components in the image and outputs the bounding box coordinates and confidence information for each component. S3 uses a fine-tuning strategy based on component numbering and masking mechanism to process the image after component detection, and obtains the image after numbering and labeling. S4 uses the numbered and labeled images as visual input, and constructs structured prompt text as language input. The visual input and language input are input into the visual language large model. The prediction results and the real labels are used to calculate the loss and update the model parameters to obtain the fine-tuned visual language large model. S5 uses a finely tuned visual language model to identify the connection relationships in the circuit system block diagram. Then, it matches the connection relationships with the component numbers and parses the obtained component location information, component numbers, and connection relationships between components.
2. The logic parsing method according to claim 1, characterized in that, A fine-tuning strategy based on component numbering and masking mechanism is adopted, including a data augmentation method with random number shuffling and a component region masking annotation method.
3. The logic parsing method according to claim 2, characterized in that, There are two types: The first method is the center mask numbering method, which masks the component bounding box area and fills the component area with a uniform color, thereby eliminating the internal texture information of the component and only retaining the spatial position of the component. At the same time, a unique number is drawn at the center of each bounding box to represent the unique identifier of the component. The original name of the component is hidden in this view. The second method is corner numbering, which involves marking the number near the upper left corner of the component's bounding box while ensuring that the component name and original structural information are not obscured.
4. The logic parsing method according to claim 3, characterized in that, The numbering uses an adaptive font size calculation method based on component size.
5. The logic parsing method according to claim 1, characterized in that, The structured prompt text is used to limit the output format of the large visual language model and define the rules for determining connection relationships.
6. The logic parsing method according to claim 5, characterized in that, The defined rules for determining connection relationships are as follows: Output connections are defined as the components that the arrow emitted by the current component directly points to; only direct connections are considered, and indirect path relationships are not inferred. Disconnected branch structure and feedback loop.
7. The logic parsing method according to claim 1, characterized in that, The parsed component location information, component number, and connection relationships between components are integrated into structured data and output in a standardized JSON format. In the output data, each component includes a component number, component name, component location, and its corresponding set of output connection component numbers, thus forming a complete description of the system topology.
8. The logic parsing method according to claim 1, characterized in that, The preprocessing includes size normalization, noise suppression and enhancement, and color space conversion.
9. The logic parsing method according to claim 1, characterized in that, The target detection model uses the YOLOv11 target detection network.
10. The logic parsing method according to any one of claims 1-9, characterized in that, It also includes validating the output results, specifically checking the validity of the number, filtering duplicate connections, and correcting abnormal connections.
