EMI filter design method based on graph attention network

By converting EMI filter circuits into graph structures and using graph attention networks for modeling and optimization, the problems of low accuracy and efficiency in traditional EMI filter design are solved, achieving efficient and automated filter design, reducing reliance on computational resources and physical prototypes, and improving design accuracy and efficiency.

CN121052191APending Publication Date: 2025-12-02CHONGQING TSINGSHAN IND
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510942963.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-07-09
Publication Date
2025-12-02

AI Technical Summary

Technical Problem

Traditional EMI filter design methods struggle to accurately describe filter parasitic parameters and coupling effects between complex components under high-frequency operating conditions. They also consume significant computational resources and rely on iterative physical prototype development, resulting in long development cycles and high costs.

Method used

The filter circuit is converted into a graph structure, modeled and optimized using a graph attention network, and the circuit parameters are optimized through a backpropagation algorithm, thus realizing the automated design of the filter.

Benefits of technology

It improves the accuracy of filter insertion loss prediction, reduces computational resource requirements, reduces physical prototype experiments, shortens the R&D cycle and reduces costs, and improves design efficiency and accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121052191A_ABST
    Figure CN121052191A_ABST
Patent Text Reader

Abstract

The invention relates to the field of electromagnetic compatibility, in particular to an EMI (Electro-Magnetic Interference) filter design method based on a graph attention network, which can more accurately model and predict the insertion loss of a filter by converting a filter circuit into a graph structure and utilizing the graph attention network, and meanwhile, optimizes circuit parameters by utilizing back propagation so as to improve the design accuracy of the filter. Therefore, dependence on computing resources is remarkably reduced, the requirement for multiple iteration physical prototype experiments is effectively reduced, high cost and time consumption caused by repeated prototype manufacturing are avoided, the research and development cost is effectively reduced, the research and development period is greatly shortened, automatic design of the filter is achieved, and the research and development efficiency is improved. And the design accuracy and efficiency are effectively improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of electromagnetic compatibility, and more specifically to an EMI filter design method based on graph attention networks. Background Technology

[0002] With the development of modern society, the number of electronic devices continues to rise, and their internal structures are becoming increasingly complex, making electromagnetic interference (EMI) problems more and more prominent. In the field of power electronics systems, high-frequency switching operations are a key cause of EMI, which can significantly affect the normal operation of surrounding circuits and equipment, thereby threatening the stability and reliability of the entire system.

[0003] To effectively address this challenge, EMI filters (electromagnetic interference filters) have been widely used. These filters, with their superior performance in suppressing high-frequency noise, provide crucial assurance for achieving electromagnetic compatibility (EMC) in systems. In traditional design processes, EMI filter design is primarily based on equivalent circuit models. These models utilize a network of resistors, capacitors, and inductors to model the filter's impedance characteristics and the coupling between components. Simultaneously, electromagnetic simulation techniques are used to determine the filter's insertion loss, thereby guiding the filter design.

[0004] However, traditional electromagnetic interference (EMI) filter design methods have revealed several limitations, including:

[0005] ① Regarding model accuracy, the equivalent circuit-based modeling method struggles to accurately describe filter parasitic parameters and complex inter-component coupling effects under high-frequency operating conditions. This results in a significant discrepancy between the filter insertion loss predicted by the model and the filter's performance in real-world applications, greatly impacting the reliability of filter design.

[0006] ② From the perspective of computational resource consumption, electromagnetic simulation, as a crucial step in the traditional design process, faces enormous computational resource demands when handling filter designs involving complex circuit structures and multiple component combinations. As circuit complexity increases, simulation computation time increases significantly, not only extending the design cycle but also resulting in substantial resource waste.

[0007] ③ Furthermore, the over-reliance on physical prototypes in traditional design also severely restricts the efficiency and cost control of research and development. Every design change requires the creation of a new physical prototype and iterative adjustments through repeated experimental verification. This process is time-consuming and labor-intensive, significantly extending the research and development cycle and increasing the company's time and financial investment.

[0008] In conclusion, given the ever-increasing demands for electromagnetic compatibility in modern electronic systems, developing a more efficient and accurate EMI filter modeling and design method to promote the stable operation and continuous development of electronic systems in complex electromagnetic environments has become a crucial issue that urgently needs to be addressed in this field. Summary of the Invention

[0009] The purpose of this invention is to address the shortcomings of existing technologies by providing an EMI filter design method based on graph attention networks. By converting the filter circuit into a graph structure, the insertion loss of the filter can be modeled and predicted more accurately. At the same time, backpropagation is used to optimize circuit parameters, thereby realizing automated filter design and improving the accuracy and efficiency of the design.

[0010] The objective of this invention is achieved through the following approach:

[0011] An EMI filter design method based on graph neural networks, characterized by the following steps:

[0012] 1) Following the traditional EMI filter design scheme, design the equivalent circuit model of the EMI filter as needed;

[0013] 2) Based on the equivalent circuit model of the EMI filter, establish an insertion loss prediction model based on graph neural network to output the insertion loss prediction curve corresponding to the equivalent circuit model of the EMI filter.

[0014] 3) Based on the target insertion loss curve, perform reverse optimization design on the equivalent circuit model of the EMI filter to ensure that the error between the predicted insertion loss values ​​before and after optimization meets the accuracy requirements.

[0015] Preferably, in step 2), the establishment of the insertion loss prediction model includes the following steps:

[0016] 2-1) Take each component in the equivalent circuit model of the EMI filter as a node and establish an equivalent original graph. The edges between the nodes in the equivalent original graph are used to represent the relative positions between the components in the equivalent circuit model of the EMI filter.

[0017] 2-2) A coding network is used to map the features of all nodes in the equivalent original graph to a high-dimensional space to form an equivalent coded graph;

[0018] 2-3) Construct the adjacency matrix of the equivalent coding graph, and combine it with the edge coding in the equivalent coding graph to construct a coupling matrix to characterize the coupling effect between various components in the equivalent circuit model of the EMI filter.

[0019] 2-4) Calculate the attention coefficients between nodes in the equivalent coding graph, and combine them with the coupling matrix to calculate the sum of the coupling effects of all neighboring nodes on each node in the graph attention network, as the attention aggregation result;

[0020] 2-5) Based on the attention aggregation result, each node is updated layer by layer through the node update function, and information is transmitted. By calculating the error between the output value and the label value, the backpropagation algorithm is used to continuously update the model parameters until the error converges, and the insertion loss prediction curve of the EMI filter is output.

[0021] Preferably, in step 2), the nodes of the equivalent original graph include quadruple feature vectors, which consist of element type, element parameters, element coordinates, and element size, and the edge features of the equivalent original graph are binary tuples, which are used to represent the relative positions between the elements in the equivalent original graph.

[0022] Preferably, in step 2-2), the specific construction method of the equivalent coding map includes:

[0023] 2-2-1) By using an encoding network, all node features in the equivalent original graph are mapped to a high-dimensional space to obtain the node encoding of each node;

[0024] 2-2-2) Then, the edge features between two adjacent nodes in the equivalent original graph are concatenated with the node codes of these two nodes and input into the encoding network to obtain the edge code corresponding to the edge between the two adjacent nodes.

[0025] 2-2-3) Repeat step 2-2-2) until you get the edge codes of all edges in the equivalent original graph. Combine the node codes of each node to form an equivalent coded graph.

[0026] Preferably, in step 2-3), the specific method for constructing the coupling matrix includes:

[0027] 2-3-1) Based on the equivalent coding graph, define the adjacency matrix A = (a ij ) N×N And the matrix element a of the adjacency matrix A ij The rules for determining the value are as follows:

[0028]

[0029] In the formula, L is the maximum distance at which coupling effects can occur; Δl is the Euclidean distance between the i-th node and the j-th node; a ij Let be the element in the i-th row and j-th column of the adjacency matrix A;

[0030] 2-3-2) Based on the adjacency matrix A and the edge codes in the equivalent coding graph, the coupling matrix used to characterize the coupling effect between various components in the equivalent circuit model of the EMI filter is constructed as follows:

[0031]

[0032] In the formula, C is the coupling matrix. This represents the coupling effect between the i-th and j-th components in the k-th layer of the equivalent circuit model of an EMI filter.

[0033] Preferably, in steps 2-4), the specific method for obtaining the attention aggregation result includes:

[0034] 2-4-1) Define node-edge fusion features based on the equivalent coding graph;

[0035] 2-4-2) Based on the node-edge fusion features, the attention scores between nodes in the equivalent coding graph are obtained;

[0036] 2-4-3) Process the attention scores between nodes in the equivalent coding graph to obtain the attention coefficients;

[0037] 2-4-4) Using the attention coefficients between nodes in the equivalent encoding graph and the coupling matrix, the sum of the coupling effects of all neighboring nodes on each node in the graph attention network is calculated as the attention aggregation result.

[0038] Preferably, in steps 2-5), the specific method for obtaining the insertion loss prediction curve of the EMI filter includes:

[0039] 2-5-1) Based on the attention aggregation result and combined with the characteristics of each node, the nodes are updated and information is passed layer by layer through the node update function to obtain the global features of the equivalent coding graph.

[0040] 2-5-2) The global features of the equivalent coding map are used as input and fed into a fully connected network to calculate the error between the output value and the label value;

[0041] 2-5-3) Based on the error calculated in step 2-5-2), the backpropagation algorithm is used to calculate the gradient of each model parameter, and the calculated gradient is used to update the model parameters using an optimization algorithm.

[0042] 2-5-4) Repeat steps 2-5-2) to 2-5-3) until the error converges and output the insertion loss prediction curve of the EMI filter.

[0043] Preferably, in step 3), the specific method for reverse optimization design of the EMI filter includes:

[0044] 3-1) Obtain the insertion loss function based on the insertion loss prediction curve of the output EMI filter;

[0045] 3-2) Define the desired insertion loss function, and use the insertion loss function to define the optimization objective function;

[0046] 3-3) By adjusting the equivalent circuit model of the EMI filter, the optimization objective function is made to converge;

[0047] 3-4) Repeat step 3-3) until the optimization objective function converges to the minimum value, and then use the circuit design at this point as the final output scheme.

[0048] Preferably, in step 6-3), the model parameters include node encoding network weights, edge encoding network weights, attention network weights, and attention weight vectors.

[0049] The beneficial effects of this invention include:

[0050] ① By transforming the filter circuit into a graph structure, this invention enables more accurate modeling of the filter insertion loss, thereby greatly improving the accuracy of insertion loss prediction. Furthermore, by utilizing graph attention networks for modeling and optimization, the complex electromagnetic coupling effects in the filter can be efficiently processed, effectively achieving efficient, automated, and precise control of filter design.

[0051] ② This invention optimizes filter circuit parameters using a backpropagation algorithm. By continuously calculating the error between the output value and the label value and updating the model parameters, the insertion loss prediction curve of the EMI filter more accurately approximates the actual situation, effectively improving the model's accuracy in predicting insertion loss. Furthermore, in the reverse optimization design, the circuit layout is continuously adjusted using the optimization objective function to obtain a circuit design scheme that meets the requirements, achieving optimized design of the filter circuit so that its performance reaches or approaches the expected target.

[0052] ③ By using graph attention networks, this invention significantly reduces the dependence on computing resources, effectively reduces the need for multiple iterations of physical prototype experiments, and avoids the high costs and time consumption caused by repeatedly manufacturing prototypes. While effectively reducing R&D costs, it also greatly shortens the R&D cycle.

[0053] ④ This invention constructs an intelligent modeling mechanism that integrates circuit component attributes, spatial relationships, and electromagnetic coupling effects by acquiring attention aggregation results. This mechanism, centered on a graph attention network, transforms electromagnetic coupling effects into learnable attention weights, shifting the filter design process from an experience-based trial-and-error model to a data-driven intelligent optimization model. The constructed filter design model, with its clear physical meaning and excellent computational efficiency, effectively achieves a dual improvement in filter performance (such as insertion loss and electromagnetic compatibility) and design efficiency.

[0054] The advantages of this invention are:

[0055] This invention achieves high efficiency, automation, and precise control in filter design by converting the filter circuit into a graph structure and using graph attention networks for modeling and optimization. Compared to traditional high-frequency electromagnetic simulation methods, this invention significantly reduces computational resource requirements while greatly improving design efficiency and accuracy. Furthermore, the invention optimizes electrical and positional parameters using a backpropagation algorithm, effectively reducing parasitic coupling effects and enhancing electromagnetic compatibility. Its automated design process greatly reduces reliance on physical prototypes, shortening development costs and timelines, ultimately resulting in a high-efficiency, low-cost, and high-performance filter design solution. Attached Figure Description

[0056] Figure 1 This is a flowchart of the present invention;

[0057] Figure 2 This is a flowchart of the insertion loss curve of the forward predictive EMI filter in an embodiment of the present invention;

[0058] Figure 3 This is a flowchart illustrating the reverse optimization of the EMI filter circuit design in an embodiment of the present invention;

[0059] Figure 4 This is a schematic diagram of the model structure in an embodiment of the present invention;

[0060] Figure 5 This is the differential insertion loss curve in an embodiment of the present invention;

[0061] Figure 6 This is the common-mode insertion loss curve in an embodiment of the present invention;

[0062] Figure 7 This is a physical diagram of an EMI filter designed according to the traditional EMI filter design scheme in this embodiment of the invention (it needs optimization);

[0063] Figure 8 This is a schematic diagram of the optimized EMI filter model in an embodiment of the present invention;

[0064] Figure 9 This is a schematic diagram of the optimized EMI filter in an embodiment of the present invention;

[0065] Figure 10 This is a schematic diagram of the optimized filter circuit model according to an embodiment of the present invention;

[0066] Figure 11 This is a schematic diagram of the filter simulation results according to an embodiment of the present invention. Detailed Implementation

[0067] like Figures 1 to 11 As shown, an EMI filter design method based on graph neural networks includes the following steps:

[0068] 1) Following the traditional EMI filter design scheme, design the equivalent circuit model of the EMI filter as needed;

[0069] 2) such as Figure 2 As shown, based on the equivalent circuit model of the EMI filter, an insertion loss prediction model based on a graph neural network is established to output the insertion loss prediction curve corresponding to the equivalent circuit model of the EMI filter. The specific method is as follows:

[0070] 2-1) Using each component in the equivalent circuit model of the EMI filter as a node, an equivalent original graph is established. The nodes of the equivalent original graph include a quadruple feature vector ([C,L,R],NUM,p,l), that is, the characteristics of each node are described by a quadruple. Specifically, the quadruple feature vector consists of component type, component parameters, component coordinates, and component size. Among them, [C,L,R] represents the component type, i.e., capacitor, inductor, resistor; NUM represents the component specifications, such as the capacitance value of capacitors, the resistance value of resistors, etc.; p = (x,y) represents the position of the component in the circuit (i.e., component coordinates); and l represents the size of the component.

[0071] The edges between nodes in the equivalent original graph are used to represent the relative positions of the components in the EMI filter equivalent circuit model. In this embodiment, the edge features of the equivalent original graph are tuples (Δx, Δy), which represent the relative positions of the components in the equivalent original graph, thus representing the topological connectivity characteristics of the components in the EMI filter equivalent circuit model in terms of spatial distribution.

[0072] 2-2) By mapping all node features in the equivalent original graph to a high-dimensional space through an encoding network, the multi-dimensional attributes (electrical parameters, geometric positions) and potential relationships of components in the equivalent circuit model of the EMI filter are effectively integrated, thereby forming an equivalent encoded graph. The specific construction methods of the equivalent encoded graph include:

[0073] 2-2-1) By using an encoding network, the features of all nodes in the equivalent original graph are mapped to a high-dimensional space to obtain the node encoding h of each node. i The encoding network consists of a multilayer perceptron (MLP) and a LeakyReLU activation function. The node encoding process is formulated as follows:

[0074]

[0075] In the formula, W represents the encoding of node i at level k. n Represents the weights of a learnable node encoding network;

[0076] 2-2-2) Using the same method as node encoding, the edge features between two adjacent nodes in the equivalent original graph are concatenated with the node codes of these two nodes and then input into the encoding network to obtain the edge code corresponding to the edge between the two adjacent nodes. The edge encoding process is represented by the following formula:

[0077]

[0078] In the formula, The edge encoding for the edge between two adjacent nodes i and j at the k-th layer; W e These are the weights of a trainable edge-encoding network; This represents the node code of the i-th node at the k-th layer; This represents the node code of the j-th node at the k-th level; Represents edge characteristics.

[0079] 2-2-3) Repeat step 2-2-2) until you get the edge codes of all edges in the equivalent original graph. Combine the node codes of each node to form an equivalent coded graph.

[0080] 2-3) Construct the adjacency matrix of the equivalent coding graph, and combine it with the edge coding in the equivalent coding graph to construct a coupling matrix to characterize the coupling effect between various components in the equivalent circuit model of the EMI filter. This achieves the organic integration of the spatial positional relationship, connection topology, and electromagnetic coupling physical characteristics of circuit components in the equivalent circuit model of the EMI filter. The specific construction methods of the above coupling matrix include:

[0081] 2-3-1) Based on each node in the equivalent coding graph, define the adjacency matrix A = (a ij ) N×N ,Right now

[0082] And the matrix element a of the adjacency matrix A ij The rules for determining the value are as follows:

[0083]

[0084] Specifically, for the above matrix element a ij , the value thereof represents the probability of the occurrence of the coupling effect between circuit elements. In the formula, L is the maximum distance at which the coupling effect can occur; Δl is the Euclidean distance between the i-th node and the j-th node; a ij is the element in the i-th row and j-th column of the adjacency matrix A, and is used to represent the connection relationship between the i-th node and the j-th node in the equivalent coding graph.

[0085] That is to say, when i = j, a ii = 1.

[0086] When i ≠ j, a ij ∈(0, 1], and the matrix element a ij is determined by the relationship between the node distance and the maximum distance L at which the set coupling effect can occur, specifically:

[0087] ① When Δl < L, it is considered that there must be a coupling effect, that is, a ij = 1;

[0088] ② When Δl > L, a probability value between (0, 1] is assigned to it according to the distance, that is where relu(x) = max(0, x).

[0089] 2 - 3 - 2) According to the adjacency matrix A and the edge coding in the equivalent coding graph, construct a coupling matrix for characterizing the coupling effect between each component in the equivalent circuit model of the EMI filter, specifically as follows:

[0090]

[0091] In the formula, C is the coupling matrix; is the coupling effect between the i-th component and the j-th component in the k-th layer of the equivalent circuit model of the EMI filter.

[0092]

[0093] That is, in this embodiment, the coupling matrix C can be expressed by the matrix expression as:

[0094]

[0095] 2-4) Calculate the attention coefficients between nodes in the equivalent coding graph, and combine them with the coupling matrix to calculate the sum of the coupling effects of all neighboring nodes on each node in a graph attention network, as the attention aggregation result. Specifically, the specific methods for obtaining the above attention aggregation result include:

[0096] 2-4-1) Based on the equivalent coding graph, define the node-edge fusion feature. The node-edge fusion feature is: in, This is the encoding of the i-th node in the k-th layer. Let || be the edge feature between the i-th node and the j-th node in the k-th layer, and || denotes the vector concatenation operation.

[0097] 2-4-2) Based on the node-edge fusion features, obtain the attention scores between nodes in the equivalent coding graph. In this embodiment, the formula for calculating the attention score is:

[0098]

[0099] In the formula, The attention score between node i and node j in the equivalent encoding graph; Let F represent the learnable weight matrix, and F be the number of node features. F' represents the learnable weight vector, and F′ is the number of intermediate features generated after node-edge fusion features.

[0100] 2-4-3) Using the softmax function to calculate the attention scores between nodes in the equivalent coding graph After performing exponential normalization, the attention coefficient is obtained, and its specific formula is as follows:

[0101]

[0102] In the formula, Let be the attention coefficient between the i-th node and the j-th node in the k-th layer; N(i) represents all the neighbors of node i.

[0103] 2-4-4) Using the attention coefficients between nodes in the equivalent encoding graph and the coupling matrix, the sum of the coupling effects of all neighboring nodes on each node in the graph attention network is calculated as the attention aggregation result. In this embodiment, for node i in each layer, the attention coefficients obtained in step 5-3) above are used... And the coupling matrix C obtained in step 4-2) is used to calculate the sum of the coupling effects of all its neighboring nodes in the graph attention network. The calculation formula is as follows:

[0104]

[0105] In the formula, It is the sum of the coupling effects of all neighboring nodes on node i in the k-th layer; This refers to the coupling effect between component i and component j in the equivalent circuit model of the EMI filter on the k-th layer. Let be the attention coefficient between node i and node j in the k-th layer.

[0106] 2-5) Based on the attention aggregation result, each node is updated layer by layer through the node update function, and information is passed between them. By calculating the error between the output value and the label value, the model parameters are continuously updated using the backpropagation algorithm until the error converges, and the insertion loss prediction curve of the EMI filter is output. Specifically, the specific methods for obtaining the insertion loss prediction curve of the EMI filter include:

[0107] 2-5-1) Based on the attention aggregation result obtained in step 2-4-4), and combined with the characteristics of each node, the node update function is used to update each node layer by layer and pass information. The formula for updating each node is as follows:

[0108]

[0109] In the formula, For node update functions, Encode the i-th node of the (k-1)-th layer.

[0110] When the information is passed to the last layer, the input node features h will be... I and output node features h O Concatenate the features to form a global feature map of the equivalent coding map. Among them, the global features of the equivalent coding graph The expression is as follows:

[0111]

[0112] In the formula, The global features of the equivalent coding graph; Encode the input nodes of the k-th layer; Encode the output node of the k-th layer.

[0113] 2-5-2) The global features of the obtained equivalent coding map are used as input and fed into a fully connected network to calculate the error between the output value and the label value. Each neuron in the fully connected network is connected to all neurons in the previous layer, enabling further nonlinear transformation and feature extraction of the global features of the input equivalent coding map to learn the complex mapping relationship between global features and EMI filter insertion loss.

[0114] In this embodiment, the output value is calculated by the fully connected network through forward propagation based on the global features of the input equivalent coding map. This output value is the model's prediction result for the insertion loss of the EMI filter.

[0115] The label values ​​are given in advance and represent the actual insertion loss of the EMI filter. Usually, during model training, a known dataset is used, in which each sample has a corresponding label value, to supervise the learning of the model.

[0116] 2-5-3) Based on the error calculated in step 2-5-2), the backpropagation algorithm is used to calculate the gradients of each model parameter. Then, using the calculated gradients, an optimization algorithm is employed to update the model parameters, gradually reducing the error. The model parameters include the node encoding network weights W. n The weights W of the edge-encoding network e The attention network weights W and the attention weight vector δ.

[0117] 2-5-4) Repeat steps 2-5-2) to 2-5-3), continuously calculating the error and updating the model parameters. Each iteration adjusts the model parameters in a direction that reduces the error until the error converges. When the error converges to the point where it no longer decreases or the decrease is less than a predetermined threshold, the model is considered to have been successfully trained, and the insertion loss prediction curve of the EMI filter is output. For example... Figure 2 As shown, the process of predicting the insertion loss curve by using a model is called forward prediction, also known as forward forecasting. The insertion loss prediction curve of this EMI filter can intuitively demonstrate the filter's insertion loss performance under different conditions.

[0118] Specifically, the construction of the equivalent encoded graph is a preprocessing step for the Graph Attention Network (GAT). This equivalent encoded graph provides the GAT with encoded node and edge features, enabling the GAT to effectively transfer and learn information about the graph structure. In other words, the encoded graph provides a high-dimensional feature representation for the GAT through feature encoding, while the GAT performs deep feature learning on the encoded graph through attention mechanisms and information transfer.

[0119] In this embodiment, the insertion loss prediction model consists of a 1-layer Graph Encoding Network (GIN) and a 3-layer Graph Attention Network (GAT), with ReLU (Modified Linear Unit) used as the activation function at the end of each layer. During model training, the model-predicted insertion loss value (represented by the insertion loss function) is compared with the label value (representing the actual insertion loss data), and the mean squared error (MSE) is calculated as the value of the loss function. This MSE measures the average of the squares of the errors between the model-predicted insertion loss value and the label value, effectively reflecting the accuracy of the model's prediction. Minimizing the MSE allows the model's prediction results to be as close as possible to the true value.

[0120] The initial learning rate is set to 0.01. The learning rate controls the step size of parameter updates during model training; a suitable learning rate ensures stable convergence. If the learning rate is too large, the model may skip the optimal solution; if the learning rate is too small, the model's convergence speed will become very slow.

[0121] In this embodiment, 5000 circuit structure samples with different inductor and capacitor combinations were generated using electromagnetic simulation software as the original dataset. Each sample in the dataset contains an input feature vector (component type, component value, component specification, component position, and relative position) and a target output insertion loss value. After 500 epochs, the loss function converged, meaning that as training progressed, the model's prediction error gradually stabilized, reaching a relatively optimal state. Ultimately, the average prediction error of the insertion loss curve was controlled within 4dB, indicating that the model can accurately predict the insertion loss of a given circuit. Specifically, the insertion loss curve includes differential-mode insertion loss and common-mode insertion loss curves.

[0122] 3) such as Figure 3 As shown, based on the insertion loss prediction curve of the EMI filter, the EMI filter is subjected to reverse optimization design to ensure that the error between the insertion loss prediction values ​​before and after optimization meets the accuracy requirements. In this embodiment, the specific method for reverse optimization design of the EMI filter includes:

[0123] 3-1) Based on the insertion loss prediction curve of the output EMI filter, obtain the insertion loss function.

[0124] 3-2) Define the desired insertion loss function y * And using the insertion loss function, an optimization objective function is defined, where the formula for the optimization objective function is:

[0125]

[0126] That is, the L2 norm of the difference between the actual insertion loss function and the expected insertion loss function; Let y be the insertion loss function. * Desired insertion loss function.

[0127] Specifically, the aforementioned expected insertion loss function is set based on the target insertion loss curve, that is, the expected insertion loss function is a functional expression of the target insertion loss curve, and the target insertion loss curve is set according to the requirements.

[0128] Because the L2 norm can comprehensively consider the magnitude of the error, it guides the model to optimize in the direction of reducing the error. In this embodiment, the L2 norm of the difference between the target insertion loss function and the predicted insertion loss function is used as the inverse optimization objective function. Compared with traditional manual design methods, the model of this invention has a significant speed advantage, capable of completing one optimization iteration of circuit layout within seconds. This allows the model to quickly generate circuit design schemes that meet the target insertion loss requirements, greatly improving design efficiency. Simultaneously, its design results exhibit performance comparable to manual design in other circuit characteristics such as gain and bandwidth, effectively ensuring design quality.

[0129] 3-3) By adjusting the equivalent circuit model of the EMI filter (continuously adjusting the filter circuit layout), the optimization objective function is brought to convergence. Specifically, the update formula for the component positions in this filter circuit is as follows:

[0130] p = p * +sigmoid(q)dm

[0131] In the formula, p is the update position of the element; p * d is the initial position of the component; d is a direction vector in the set of direction vectors {(-1,0),(1,0),(0,-1),(0,1)}, representing the direction of movement of the component (up, down, left, right); m is the maximum distance that the component can move in the selected direction d (without coinciding with other components); q is an adjustable function parameter.

[0132] 3-4) Repeat step 3-3) until the objective function converges to its minimum value, i.e. The goal is to minimize the error between the predicted insertion loss of the EMI filter before and after optimization, ensuring that the error meets accuracy requirements. The current circuit design is then output. In essence, the convergence of the objective function to its minimum value signifies that the predicted insertion loss of the optimized EMI filter meets accuracy requirements compared to the original value.

[0133] Therefore, the reverse optimization process is to adjust the parameters layer by layer from the given output to make the objective function converge to the minimum. In other words, by continuously adjusting the circuit parameters, the equivalent circuit insertion loss curve (the curve corresponding to the optimization objective function) is made as close as possible to the target insertion loss curve, thereby completing the circuit design.

[0134] In summary, modeling and optimization using graph attention networks can effectively improve the accuracy and efficiency of EMI filter design. Compared to traditional simulation and trial-and-error methods, it significantly reduces the design cycle and computational resource requirements. Furthermore, since most optimization work is performed in a simulation environment, the number of physical prototype fabrications is greatly reduced, thereby significantly lowering R&D costs. The embodiments of this invention verify the effectiveness of graph attention networks in EMI filter design, especially demonstrating significant advantages in handling complex coupling relationships and multi-parameter optimization, providing a new and efficient approach for filter design.

[0135] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications made to the present invention by those skilled in the art without departing from the spirit of the present invention shall fall within the protection scope of the present invention.

Claims

1. An EMI filter design method based on graph neural networks, characterized in that, Includes the following steps: 1) Following the traditional EMI filter design scheme, design the equivalent circuit model of the EMI filter as needed; 2) Based on the equivalent circuit model of the EMI filter, establish an insertion loss prediction model based on graph neural network to output the insertion loss prediction curve corresponding to the equivalent circuit model of the EMI filter. 3) Based on the target insertion loss curve, perform reverse optimization design on the equivalent circuit model of the EMI filter to ensure that the error between the predicted insertion loss values ​​before and after optimization meets the accuracy requirements.

2. The EMI filter design method according to claim 1, characterized in that, Step 2) involves establishing the insertion loss prediction model, which includes the following steps: 2-1) Take each component in the equivalent circuit model of the EMI filter as a node and establish an equivalent original graph. The edges between the nodes in the equivalent original graph are used to represent the relative positions between the components in the equivalent circuit model of the EMI filter. 2-2) A coding network is used to map the features of all nodes in the equivalent original graph to a high-dimensional space to form an equivalent coded graph; 2-3) Construct the adjacency matrix of the equivalent coding graph, and combine it with the edge coding in the equivalent coding graph to construct a coupling matrix to characterize the coupling effect between various components in the equivalent circuit model of the EMI filter. 2-4) Calculate the attention coefficients between nodes in the equivalent coding graph, and combine them with the coupling matrix to calculate the sum of the coupling effects of all neighboring nodes on each node in the graph attention network, as the attention aggregation result; 2-5) Based on the attention aggregation result, each node is updated layer by layer through the node update function, and information is transmitted. By calculating the error between the output value and the label value, the backpropagation algorithm is used to continuously update the model parameters until the error converges, and the insertion loss prediction curve of the EMI filter is output.

3. The EMI filter design method according to claim 2, characterized in that, In step 2), the nodes of the equivalent original graph include quadruple feature vectors, which consist of element type, element parameters, element coordinates, and element size. The edge features of the equivalent original graph are binary tuples, which are used to represent the relative positions between the elements in the equivalent original graph.

4. The EMI filter design method according to claim 2, characterized in that, In step 2-2), the specific construction method of the equivalent coding map includes: 2-2-1) By using an encoding network, all node features in the equivalent original graph are mapped to a high-dimensional space to obtain the node encoding of each node; 2-2-2) Then, the edge features between two adjacent nodes in the equivalent original graph are concatenated with the node codes of these two nodes and input into the encoding network to obtain the edge code corresponding to the edge between the two adjacent nodes. 2-2-3) Repeat step 2-2-2) until you get the edge codes of all edges in the equivalent original graph. Combine the node codes of each node to form an equivalent coded graph.

5. The EMI filter design method according to claim 2, characterized in that, In steps 2-3), the specific construction method of the coupling matrix includes: 2-3-1) Based on the equivalent coding graph, define the adjacency matrix A = (a ij ) N×N And the matrix element a of the adjacency matrix A ij The rules for determining the value are as follows: In the formula, L is the maximum distance at which coupling effects can occur; Δl is the Euclidean distance between the i-th node and the j-th node; a ij Let be the element in the i-th row and j-th column of the adjacency matrix A; 2-3-2) Based on the adjacency matrix A and the edge codes in the equivalent coding graph, the coupling matrix used to characterize the coupling effect between various components in the equivalent circuit model of the EMI filter is constructed as follows: In the formula, C is the coupling matrix. This represents the coupling effect between the i-th and j-th components in the k-th layer of the equivalent circuit model of an EMI filter.

6. The EMI filter design method according to claim 2, characterized in that, In steps 2-4), the specific methods for obtaining the attention aggregation result include: 2-4-1) Define node-edge fusion features based on the equivalent coding graph; 2-4-2) Based on the node-edge fusion features, the attention scores between nodes in the equivalent coding graph are obtained; 2-4-3) Process the attention scores between nodes in the equivalent coding graph to obtain the attention coefficients; 2-4-4) Using the attention coefficients between nodes in the equivalent encoding graph and the coupling matrix, the sum of the coupling effects of all neighboring nodes on each node in the graph attention network is calculated as the attention aggregation result.

7. The EMI filter design method according to claim 2, characterized in that, In steps 2-5), the specific method for obtaining the insertion loss prediction curve of the EMI filter includes: 2-5-1) Based on the attention aggregation result and combined with the characteristics of each node, the nodes are updated and information is passed layer by layer through the node update function to obtain the global features of the equivalent coding graph. 2-5-2) The global features of the equivalent coding map are used as input and fed into a fully connected network to calculate the error between the output value and the label value; 2-5-3) Based on the error calculated in step 2-5-2), the backpropagation algorithm is used to calculate the gradient of each model parameter, and the calculated gradient is used to update the model parameters using an optimization algorithm. 2-5-4) Repeat steps 2-5-2) to 2-5-3) until the error converges and output the insertion loss prediction curve of the EMI filter.

8. The EMI filter design method according to claim 1, characterized in that, In step 3), the specific methods for reverse optimization design of the EMI filter include: 3-1) Obtain the insertion loss function based on the insertion loss prediction curve of the output EMI filter; 3-2) Define the desired insertion loss function, and use the insertion loss function to define the optimization objective function; 3-3) By adjusting the equivalent circuit model of the EMI filter, the optimization objective function is made to converge; 3-4) Repeat step 3-3) until the optimization objective function converges to the minimum value, and then use the circuit design at this point as the final output scheme.

9. The EMI filter design method according to claim 7, characterized in that, In step 6-3), the model parameters include node encoding network weights, edge encoding network weights, attention network weights, and attention weight vectors.