Simulated circuit fault diagnosis method based on feature fusion and improved particle swarm algorithm
By using feature fusion and improving the particle swarm optimization algorithm to optimize the parameters of the support vector machine, the problems of insufficient feature extraction and local optima in analog circuit fault diagnosis are solved, and high-precision fault diagnosis results are achieved.
Patent Information
- Application Number
- CN202210515698.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-12
- Publication Date
- 2025-10-24
- Estimated Expiration
- 2042-05-12
AI Technical Summary
The difficulty in diagnosing analog circuit faults lies in the fuzzy fault boundaries, high degree of fault coupling, susceptibility to external environmental influences, and the limited number of measurable nodes. This leads to poor performance of traditional feature extraction methods, and the particle swarm optimization algorithm is prone to getting trapped in local optima during parameter optimization, which affects the fault diagnosis accuracy of support vector machines.
A feature fusion method is adopted to transform one-dimensional time-domain data into two-dimensional time-frequency image data. Features are extracted by combining one-dimensional convolutional neural networks and deep residual networks. The penalty parameters and kernel parameters of the support vector machine are optimized by improving the particle swarm optimization algorithm. A balance factor and particle distance are introduced to calculate the comprehensive score. The velocity update strategy of particle self-development and nonlinear time-varying inertial weights is combined to improve the accuracy of fault feature extraction and diagnosis.
It achieves more accurate fault feature extraction and diagnosis, improves the accuracy and robustness of analog circuit fault diagnosis, reduces the probability of particle swarm optimization getting trapped in local optima, and enhances the global exploration and local exploitation capabilities of the population.
Smart Images

Figure CN115186564B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of analog circuit fault diagnosis, and particularly relates to an analog circuit fault diagnosis method based on feature fusion and an improved particle swarm algorithm. BACKGROUND
[0002] The statements in this section merely provide background information related to the present application and do not necessarily constitute the prior art.
[0003] In electronic products, circuits are the core components. Circuits can be divided into digital circuits and analog circuits. According to relevant research, in today's electronic products, integrated digital circuits account for as high as 80%, and analog circuits account for only 20%. However, 80% of the faults in the circuit are analog circuit faults, and the faults occurring in the digital circuit account for only 20%. Since the analysis of digital signals is relatively simple and easy to observe, the faults in the digital circuit are relatively easy to identify and locate. However, due to the tolerance of capacitors, resistors and other components in analog circuits, faults are not easy to identify and the probability of fault occurrence is greater. Therefore, the performance of analog circuits has a decisive influence on the stability and reliability of the entire circuit system.
[0004] The difficulties in the research of analog circuit fault diagnosis mainly include the following aspects:
[0005] (1) Fuzzy fault boundary. Unlike digital circuits, the signals in analog circuits have continuity, and the faults cannot be simply quantified; at the same time, the boundary between the normal working state and the fault state of the circuit is relatively fuzzy, so it is difficult to diagnose and locate the faults.
[0006] (2) High degree of fault coupling. The coupling between components in analog circuits is strong, and if a component fails, it is likely to cause other components to fail in a short period of time; single fault and faults caused by two or more components are mixed, increasing the difficulty of diagnosis.
[0007] (3) Easily affected by external environment. The information in analog circuits is transmitted in the form of analog signals, and factors such as temperature, humidity, noise and electromagnetic environment of the working environment will produce some noise, making it more difficult to distinguish the collected fault data.
[0008] (4) Few actual measurable nodes. With the improvement of circuit integration, there are a large number of inaccessible test nodes in actual circuits, and the data for fault diagnosis can only be collected at a small number of accessible test nodes. At the same time, compared with the normal state, the fault state time is short, so the fault data samples are more scarce.
[0009] The inventors find that early faults of analog circuits have the characteristics of strong coupling, few samples and fuzzy fault boundaries, and the fault features extracted by traditional feature extraction methods such as principal component analysis and wavelet packet decomposition cannot effectively distinguish various faults, and the feature self-learning method based on neural network usually only extracts the distinguishing information in the original one-dimensional time domain data or the transformed two-dimensional image data; due to the small number of early fault samples, the features extracted by the feature self-learning method are often not rich enough.
[0010] Support vector machine (SVM) has been widely used in the field of analog circuit fault diagnosis due to its outstanding performance in small sample, non-linear and high-dimensional pattern recognition problems, but the performance of support vector machine is greatly affected by model parameters; the parameters obtained by the traditional grid optimization method are too rough and cannot fully exert the performance of support vector machine. In order to improve the classification accuracy of SVM, particle swarm algorithm is often used for parameter optimization of SVM, but in complex optimization problems, the original particle swarm algorithm is easy to fall into local optimum. At present, the improved particle swarm algorithm for SVM parameter optimization still has problems such as easy to suffer from rapid loss of diversity, easy to fall into local optimum and poor balance between global exploration and local development in the field of strong coupling analog circuit early fault. SUMMARY
[0011] In order to solve the problems in the prior art, the present application provides an analog circuit fault diagnosis method based on feature fusion and improved particle swarm algorithm, which greatly improves the accuracy of analog circuit fault diagnosis.
[0012] In order to achieve the above purpose, the technical scheme adopted by the present application is as follows:
[0013] The present application provides an analog circuit fault diagnosis method based on feature fusion and improved particle swarm algorithm.
[0014] An analog circuit fault diagnosis method based on feature fusion and improved particle swarm algorithm, comprising the following processes:
[0015] Obtain the one-dimensional time domain data of the analog circuit, and convert the one-dimensional time domain data into two-dimensional time-frequency image data;
[0016] According to the one-dimensional time domain data and the one-dimensional convolutional neural network, a first feature is obtained; according to the two-dimensional time-frequency image data and the deep residual network, a second feature is obtained; after splicing the first feature and the second feature, the final fault feature is obtained;
[0017] According to the fault feature and the pre-trained support vector machine, the fault type is obtained;
[0018] In the improved particle swarm algorithm, the comprehensive score of each particle is calculated according to a balance factor, the distance between the particle and the optimal particle of the population in terms of fitness, and the fitness value, the particle with the highest comprehensive score is selected as the optimal particle.
[0019] As an optional implementation, the one-dimensional time domain data is converted into two-dimensional time-frequency image data by using cross wavelet transform.
[0020] As an optional implementation, the distance between the ith particle and the optimal particle of the population in terms of fitness Gbest is:
[0021]
[0022] As an optional implementation, the comprehensive score of each particle is calculated according to a balance factor, the distance between the particle and the optimal particle of the population in terms of fitness, and the fitness value, and includes:
[0023] FDBscore i =α(1-normF i )+(1-α)normDG i
[0024] Wherein, alpha is the balance factor, normF i is the normalized value of the fitness value, and DG i is the normalized value of the distance between the ith particle and the optimal particle of the population in terms of fitness Gbest.
[0025] Further,
[0026]
[0027] Wherein, t max is the maximum number of iterations, and t is the current number of iterations.
[0028] As an optional implementation, the improved particle swarm algorithm further includes:
[0029] The optimal particle of the population Gbest is replaced by the optimal particle FDBbest, and the second speed formula is replaced by the first speed formula for updating the particle speed; wherein the first speed formula is: The second speed formula is: c1 and c2 are empirical weights, and r1 and r2 are discount factors.
[0030] The optimal particle FDBbest and the particle with poor fitness value are crossed.
[0031] A probability factor is introduced, the value of which linearly decreases from 0.5 to 0 with the increase of iteration number, if the random number Rand is less than the probability factor, the particle carries out speed updating according to the first speed formula; otherwise, speed updating is carried out according to the second speed formula.
[0032] As an optional implementation, each particle develops the surrounding solution space according to the current position of the particle, including:
[0033] N random numbers obeying U(0, 1) standard uniform distribution are generated;
[0034] N random numbers ρ i (i=1, 2,..., N) are sorted from large to small, and N particles are sorted from small to large according to the fitness value;
[0035] The N random numbers are corresponded to the N particles one by one, the particle with a small fitness value is paired with a large random number, and the particle with a large fitness value is paired with a small random number;
[0036] In each iteration, if the particle corresponding to ρ i is greater than a threshold P s , the particle carries out particle individual self-development operation; otherwise, the particle does not carry out particle individual self-development operation;
[0037] All particles with ρ i greater than the current threshold P s develop the surrounding area according to the following formula:
[0038]
[0039] Wherein, normrndC id indicates that a random number obeying N(0, C id ) normal distribution is randomly generated, C id is the development range of the dth dimension of the ith particle.
[0040] The second aspect of the application provides a simulation circuit fault diagnosis system based on feature fusion and improved particle swarm algorithm.
[0041] A simulation circuit fault diagnosis system based on feature fusion and improved particle swarm algorithm, comprising:
[0042] A data acquisition module configured to acquire one-dimensional time domain data of a fault of a simulation circuit, and convert the one-dimensional time domain data into two-dimensional time-frequency image data;
[0043] The feature extraction module is configured to obtain first features according to one-dimensional time domain data and a one-dimensional convolutional neural network; obtain second features according to two-dimensional time-frequency image data and a deep residual network; and obtain final fault features after splicing the first features and the second features.
[0044] The fault diagnosis module is configured to obtain a fault type according to the fault features and a pre-trained support vector machine.
[0045] In the improved particle swarm algorithm, the comprehensive score of each particle is calculated according to a balance factor, the distance between the particle and the optimal particle in the population and the fitness value, the particles are sorted from high to low according to the scores of the particles, and the particle with the highest comprehensive score is selected as the comprehensive optimal particle.
[0046] The third aspect of the present application provides a computer readable storage medium having a program stored thereon, the program being executed by a processor to implement the steps in the analog circuit fault diagnosis method based on feature fusion and improved particle swarm algorithm according to the first aspect of the present application.
[0047] The fourth aspect of the present application provides an electronic device comprising a memory, a processor and a program stored on the memory and executable on the processor, wherein the processor implements the steps in the analog circuit fault diagnosis method based on feature fusion and improved particle swarm algorithm according to the first aspect of the present application when executing the program.
[0048] Compared with the prior art, the present application has the following advantages:
[0049] 1. The analog circuit fault diagnosis method based on feature fusion and improved particle swarm algorithm, according to one-dimensional time domain data and a one-dimensional convolutional neural network, obtains first features; according to two-dimensional time-frequency image data and a deep residual network, obtains second features; after splicing the first features and the second features, obtains final fault features, realizes more accurate feature extraction, and improves the accuracy of fault diagnosis.
[0050] 2. The analog circuit fault diagnosis method based on feature fusion and improved particle swarm algorithm, in the improved particle swarm algorithm, the comprehensive score of each particle is calculated according to a balance factor, the distance between the particle and the optimal particle in the population and the fitness value, the particles are sorted from high to low according to the scores of the particles, and the particle with the highest comprehensive score is selected as the comprehensive optimal particle, which further improves the accuracy of fault diagnosis.
[0051] 3. The analog circuit fault diagnosis method based on feature fusion and improved particle swarm algorithm, the better the fitness of the particle, the more likely it is to develop the area around itself; in the early stage of iteration, P sThe value is small, the number of particles that can perform ISE operation is more, the exploration range is also larger, and the exploration ability of the population is stronger; in the later iteration stage, the value of P s The value is large, only a few particles with good fitness can use the ISE strategy to develop in a small range, and the development ability of the population is enhanced.
[0052] 4. The simulation circuit fault diagnosis method based on feature fusion and improved particle swarm algorithm, when the particle selection speed updating mode is introduced, the probability factor P f , the value gradually decreases from 0.5 linearly with the increase of the iteration number; if the random number Rand is less than P f , the particle is updated according to the first formula; otherwise, the particle is updated according to the second formula; this updating mode can not only reduce the probability of the population falling into local optimum, but also can retain the characteristics of fast convergence of the particle swarm algorithm.
[0053] The advantages of the additional aspects of the application will be partially given in the following description, partially become obvious from the following description, or be known by the practice of the application. BRIEF DESCRIPTION OF DRAWINGS
[0054] The drawings accompanying the specification of the application form part of the specification and serve to further illustrate the illustrative embodiments of the application and to explain the application, and do not limit the application in any way.
[0055] Figure 1 The flowchart of the HPSO-FDB-ISE algorithm provided for the embodiment 1 of the application.
[0056] Figure 2 The principle diagram of the Chebyshev filter circuit provided for the embodiment 1 of the application.
[0057] Figure 3 The principle diagram of the Four-op-amp filter circuit provided for the embodiment 1 of the application.
[0058] Figure 4 The original feature distribution diagram provided for the embodiment 1 of the application.
[0059] Figure 5 The feature distribution diagram extracted by the deep feature fusion network provided for the embodiment 1 of the application.
[0060] Figure 6 The convergence curve diagram of the HPSO-FDB-ISE and its variants provided for the embodiment 1 of the application.
[0061] Figure 7 The simulation circuit fault diagnosis flowchart provided for the embodiment 1 of the application.
[0062] Figure 8 The diagnostic accuracy comparison chart provided for embodiment 1 of the present application.
[0063] Figure 9 The convergence curve chart of two algorithms provided for embodiment 1 of the present application on the Chebyshev filter circuit.
[0064] Figure 10 The distribution diagram of the original data set of the actual Chebyshev filter circuit and the fault feature data set extracted by the deep feature fusion network in the three-dimensional space provided for embodiment 1 of the present application.
[0065] Figure 11 The distribution diagram of the original data set of the actual Four-op-amp filter circuit and the fault feature data set extracted by the deep feature fusion network in the three-dimensional space provided for embodiment 1 of the present application. DETAILED DESCRIPTION
[0066] The present application will be further described below in conjunction with the drawings and embodiments.
[0067] It should be noted that the following detailed description is exemplary and is intended to provide further explanation of the present application. Unless otherwise indicated, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which the present application belongs.
[0068] It should be noted that the terms used herein are only for the purpose of describing specific embodiments and are not intended to limit the exemplary embodiments according to the present application. As used herein, the singular form is intended to include the plural form unless the context clearly indicates otherwise, and it should also be understood that when the terms "comprise" and / or "include" are used in the specification, there is a presence of the features, steps, operations, devices, components and / or combinations thereof.
[0069] The embodiments in the present application and the features in the embodiments can be combined with each other without conflict.
[0070] Embodiment 1:
[0071] In order to solve the problems existing in the prior art, i.e. the feature extraction capability of the early fault diagnosis model of the analog circuit is insufficient and the particle swarm algorithm is prone to fall into local optimum in complex optimization problems, thereby affecting the fault diagnosis precision of the SVM, the present embodiment 1 provides a simulation circuit fault diagnosis method based on feature fusion and improved particle swarm algorithm, including the following processes:
[0072] Obtaining the fault one-dimensional time domain data of the analog circuit, converting the one-dimensional time domain data into two-dimensional time-frequency image data;
[0073] According to one-dimensional time domain data and one-dimensional convolutional neural network, first features are obtained; according to two-dimensional time-frequency image data and deep residual network, second features are obtained; after splicing the first features and the second features, final fault features are obtained;
[0074] According to the fault features and a pre-trained support vector machine, a fault type is obtained.
[0075] Specifically, the following steps are included:
[0076] S1: Collecting fault data and constructing an original fault data set: first, an excitation signal is applied to the input end of the circuit to be tested; then, the voltage signal at the output end of the circuit is collected as an original data sample, and the original fault data collected under the fault state k is denoted as wherein, is the i-th sample collected under the fault state k; finally, the circuit data samples of different circuit states (including the data samples of the normal state) are arranged to form an original data set.
[0077] S2: Using cross wavelet transform to convert the original time domain data into time-frequency image data to increase the information quantity of the original data, and the main formula of the cross wavelet transform is as follows:
[0078] Suppose x(t) and y(t) are two time series, then the cross wavelet transform between them can be expressed as:
[0079] CWT(a,τ)=WT x (a,τ)WT y * (a,τ) (1)
[0080] In the formula, WT x (a,τ) and WT y (a,τ) are the continuous wavelet transforms of x(t) and y(t) respectively, and * represents complex conjugate.
[0081] The output data of the circuit with all elements at the nominal value are selected as the reference signal, and the sample data of the circuit in other states are selected as another signal; by performing cross wavelet transform on the circuit output signals in different states and the reference signal, the original one-dimensional time domain data is converted into time-frequency image data, thereby forming a time-frequency image data set.
[0082] S3: Using a deep feature fusion network based on one-dimensional convolutional neural network (1DCNN) and deep residual network (ResNet) for feature extraction: first, the original one-dimensional time domain data is input into the one-dimensional convolutional neural network, and the detailed parameter settings of the neural network are shown in Table 1:
[0083] Table 1: 1DCNN parameter settings
[0084]
[0085]
[0086] The first layer convolutional layer selects a convolution kernel with a size of 7*1 to obtain more comprehensive feature information. After the model is trained, the features output by the first fully connected layer are extracted for subsequent feature fusion. Then, the two-dimensional time-frequency image data is input into a deep residual network. The residual network selected in this embodiment is ResNet18, and the parameter settings are as shown in Table 2. Like the 1DCNN, the features output by the ResNet fully connected layer are extracted. Finally, the features extracted by the 1DCNN and the ResNet are spliced, and the output is the final feature fault dataset.
[0087] Table 2: ResNet18 network parameter settings
[0088]
[0089]
[0090] S4: The feature fault dataset extracted by the deep feature fusion network is divided into a training set and a test set at a ratio of 7:3.
[0091] S5: The training set is input into a support vector machine, and the penalty parameter and the kernel parameter of the SVM are optimized by using an improved particle swarm algorithm. The flowchart of parameter optimization of the improved algorithm HPSO-FDB-ISE is as shown in Figure 1 .
[0092] S6: The initial parameters of the particle swarm are set, such as the maximum number of iterations t max , the number of particles N, the dimension D of the search space, the range [X min , X max ] of the search space, the range [V min , V max ] of the particle velocity, and the maximum and minimum inertia weights ω min and ω max .
[0093] S7: The population is initialized, and the initialization formula is as follows:
[0094]
[0095] In the formula, X id is the value of the dth dimension of the ith particle, and Rand is a random number obeying the U(0, 1) standard uniform distribution.
[0096] S8: Iteration begins, the fitness value of each particle is calculated and the best comprehensive particle FDBbest is selected. The selection of FDBbest depends not only on the fitness value, but also on the distance between each particle and Gbest (the population fitness optimal particle). The distance between the ith particle and Gbest is calculated as follows:
[0097]
[0098] In order to select FDBbest, an optimal particle selection strategy based on fitness and distance (FDB) is constructed to build a scoring function. The argument of the function is DG i and fitness value F i .
[0099] First, DG i and F i are normalized according to formula (4) and formula (5):
[0100]
[0101]
[0102] In the formula, DG and F are the sets of DG i and F i of all particles in this iteration, respectively.
[0103] Then, the comprehensive score FDBscore i of each particle is calculated according to formula (7). Finally, the particles are ranked from high to low according to the scores, and the particle with the highest comprehensive score is selected as FDBbest.
[0104]
[0105] FDBscore i = a (1-normF i ) + (1-a) normDG i (7)
[0106] In the formula, t max is the maximum number of iterations, a is the balance factor. The smaller a is, the greater the influence of normDG i on FDBscore i , the more conducive to the global exploration of the population; the greater a is, the greater the influence of normF i on FDBscore i , the more conducive to the local development of the population.
[0107] The FDBbest selected by the above strategy will replace Gbest to guide the particle to complete speed update. The new speed update formula is as follows:
[0108]
[0109] where c1 and c2 are experience weights, and r1 and r2 are discount factors.
[0110] S9: Update Pbest and Gbest, if the fitness value of a particle is better than Pbest or Gbest, then use the position X i of the particle to replace Pbest or Gbest.
[0111] S10: Cross operation between FDBbest and the particle with worse fitness value, which mainly follows the idea of elite strategy, and improves the overall search efficiency of the population by strengthening the information exchange between the poor performing particle and FDBbest. The update formula of this strategy is as follows:
[0112]
[0113] where r3 is a random number obeying U(0, 1) standard uniform distribution; N c is the number of particles for cross operation.
[0114] S11: Calculate the inertia weight of this iteration, and the formula is as follows.
[0115]
[0116] where ω max = 0.9, ω min = 0.2, which are the maximum and minimum values of the inertia weight respectively; p = 0.25.
[0117] S12: Alternately use FDB strategy and traditional speed update strategy: when each particle updates the speed, it will be updated according to formula (8) or basic speed update formula (11) at random, and the basic speed update formula is as follows:
[0118]
[0119] where c1 and c2 are experience weights, and r1 and r2 are discount factors.
[0120] According to formula (12) to update the position, and the update formula is as follows:
[0121]
[0122] Considering the characteristics of particle swarm that it focuses on global exploration in the early stage and local development in the later stage, a probability factor P fwhose value linearly decreases from 0.5 to 0 with the increase of iteration number. If the random number Rand is less than P f , the particle updates its velocity according to formula (8); otherwise, it updates its velocity according to formula (11). This updating method not only reduces the probability of the population falling into local optimum, but also preserves the fast convergence characteristics of the particle swarm algorithm.
[0123] S13: Each particle develops the surrounding solution space according to its current position. According to the characteristics of the particle swarm, particles with good fitness have higher development efficiency. Therefore, in the individual self-development (ISE) strategy, each particle will have different probabilities of developing its surrounding space according to its fitness value.
[0124] First, N random numbers obeying the standard uniform distribution U(0, 1) are generated. Second, the N random numbers ρ i (i = 1, 2,..., N) are sorted in descending order. At the same time, for the minimization problem, the N particles are sorted in ascending order according to their fitness values. Then, the N random numbers are matched with the N particles one by one, so that the particles with small fitness values are matched with large random numbers, and the particles with large fitness values are matched with small random numbers. Finally, in each iteration, if the particle's corresponding ρ i is greater than the threshold value P s , the particle performs ISE operation; otherwise, it does not perform ISE operation.
[0125] The definition of P s is as follows:
[0126]
[0127] Considering that the development of particles becomes more and more fine in the later iteration period, the range of the particles' development around themselves should also gradually decrease with the increase of iteration number.
[0128] The development range coefficient C id is defined as follows:
[0129]
[0130] In the formula, C id is the development range of the i-th particle in the d-th dimension.
[0131] In this iteration, all particles whose ρ i are greater than the current threshold value P s will develop their surrounding areas according to formula (15).
[0132]
[0133] In the formula, normrndC idrepresents randomly generating a random number subject to a N(0, C id ) normal distribution.
[0134] As can be seen, in the ISE strategy proposed in this section, the better the fitness of a particle, the more likely it is to develop the area around itself. In the early iteration stage, the value of P s is small, the number of particles that can perform ISE operations is large, the exploration range is large, and the exploration ability of the population is strong; in the later iteration stage, the value of P s is large, only a small number of particles with good fitness can use the ISE strategy to develop a small range, and the development ability of the population is enhanced.
[0135] If the probability value of the i-th particle ρ i > P s , the particle uses the ISE strategy to develop the space around itself; otherwise, it is not developed, and returns to S9.
[0136] S14: Determine whether the maximum number of iterations is reached. If so, the iteration stops, and the model training is completed; otherwise, return to S9.
[0137] S5: After the model training is completed, the test set is input into the trained SVM to complete the test of the fault diagnosis model.
[0138] The test circuits used in this embodiment are Chebyshev filter circuits and four-op-amp filter circuits. In the two circuits, the tolerance value of the resistor is set to 5% of the nominal value, and the tolerance value of the capacitor is set to 10% of the nominal value. The parameter values of the elements within the normal tolerance range are considered to be in a normal state, and the circuit state within 30% of the nominal value is considered to be an early fault. The circuit schematics of the Chebyshev filter circuit and the Four-op-amp filter circuit are shown in Figure 2 and Figure 3 , and the original feature distribution diagram is shown in Figure 4 . The feature distribution diagram of the original fault data using the deep feature fusion network for feature extraction is shown in Figure 5 . As can be seen from the figure, the features extracted by the deep feature fusion network can basically separate different types of faults and have good intra-class aggregation and inter-class distance, showing good distinguishability, which indicates that the deep feature fusion network can mine deeper fault features with better distinguishability.
[0139] In the experiment, the improved particle swarm optimization algorithm is named HPSO-FDB-ISE. In order to verify the performance of each strategy in HPSO-FDB-ISE, the CEC2017 benchmark test set proposed by P. N. Suganthan team is used for comparison experiment. The convergence curves of HPSO-FDB-ISE and its variants on benchmark functions F1, F3, F4, F11-F14, F18-F20, F28, F30 are shown in Figure 6 As shown in (b), (g) and (j) in Figure 6 , although PSO has a faster convergence speed than PSO-FDB in the early stage, it falls into local optimum in the later stage. PSO-FDB avoids falling into local optimum to some extent due to the introduction of FDB strategy, and thus achieves better optimization results, but the development ability of PSO-FDB is slightly insufficient. Throughout the iteration process, the fitness value of PSO-FDB-ISE is better than that of PSO-FDB, and the gap between them is widening, indicating that the ISE strategy plays an active role in the local development process of PSO-FDB-ISE.
[0140] In each subgraph of Figure 6 , the accuracy and convergence speed of HPSO-FDB-ISE are stronger than those of PSO, PSO-FDB and PSO-FDB-ISE. Although in (a), (e), (l) of Figure 6 , the performance of PSO-FDB-ISE in the middle of iteration is better than that of HPSO-FDB-ISE, but PSO-FDB-ISE fails to balance the exploration and development ability of the population at this stage, so that the population falls into local optimum in the later stage of iteration. HPSO-FDB-ISE avoids falling into local optimum due to the use of nonlinear time-varying inertia weight, which better balances the global exploration and local development ability of the population in this process, so the fitness value decreases and the optimization ability of the population is improved.
[0141] In summary, the optimal particle selection strategy of fitness and distance improves the global exploration ability of the population and reduces the probability of falling into local optimum, the particle individual self-development strategy improves the local development ability of the population, and the nonlinear time-varying inertia weight well balances the global and local search ability of the population. Under the action of the three, the comprehensive performance of HPSO-FDB-ISE algorithm is obviously improved.
[0142] As Figure 7As shown in the figure, the deep feature fusion network and the SVM optimized by the HPSO-FDB-ISE algorithm are integrated to form a complete intelligent fault diagnosis model of analog circuits, and the performance of the model is verified on the simulation circuit and the actual circuit. In the simulation circuit, the accuracy rates of the SVM, the PSO-SVM and the HPSO-FDB-ISE-SVM on the Chebyshev filter circuit and the Four-op-amp filter circuit are as follows Figure 8 As shown in the figure, Figure 8 It can be seen that the accuracy rates of the proposed fault diagnosis model on the Chebyshev filter circuit and the Four-op-amp filter circuit are 100% and 99.70% respectively. This shows that after being optimized by the HPSO-FDB-ISE algorithm, the SVM can accurately classify the fault samples that overlap together. The convergence curves of the PSO and the HPSO-FDB-ISE in the process of optimizing the SVM are as follows Figure 9 As shown in the figure, the best fitness is the fitness of the global optimal particle, and the average fitness is the average of the fitnesses of all particles in this iteration. As can be seen from Figure 9 (a), the fitness value of the PSO algorithm falls into a local optimum when it reaches about 98%; as can be seen from the average fitness, the population diversity of the original PSO algorithm is lost too fast in the early iteration, and the optimization process of all particles has already stagnated. As can be seen from Figure 9 (b), although the HPSO-FDB-ISE algorithm falls into a local optimum in the early iteration, it quickly jumps out of the local optimum, thereby achieving a higher fault diagnosis accuracy; as can be seen from the average fitness, in the early and middle iterations, the exploration process of the entire particle swarm is very active, and in the late iteration, in order to speed up the convergence, the fitnesses of all particles gradually approach the global optimal value.
[0143] The overall process of applying the intelligent fault diagnosis model to the actual circuit is as follows: taking the Chebyshev filter circuit as an example, the original data acquisition device includes three parts, namely, a signal generator, a circuit to be tested and an oscilloscope. First, the signal generator sends out a pulse voltage with an amplitude of 10V, which is input into the circuit to be tested. Then, the voltage signal at the output end of the circuit to be tested is introduced into the oscilloscope, and the output waveform of the Chebyshev filter circuit displayed by the oscilloscope is shown in the figure. Finally, the original data information is exported from the oscilloscope as a csv file, and after integration, the original data set is formed.
[0144] After obtaining the original dataset of the actual circuit, firstly, the original dataset is subjected to feature extraction using a deep feature fusion network. Then, the extracted fault feature dataset is divided into a training set and a test set. The training set is used for training of the SVM model, and the penalty parameter and kernel parameter of the SVM are optimized using the HPSO-FDB-ISE algorithm. Finally, the test set is input into the trained model for fault diagnosis and output of the diagnosis result.
[0145] The distribution of the original dataset of the two actual circuits and the fault feature dataset extracted by the deep feature fusion network in three-dimensional space is shown in Figure 10 and Figure 11 It can be seen from the figures that the original faults are mixed and scattered. After feature extraction by the deep feature fusion network, the distinguishability between the various fault features is already relatively obvious, but the intra-class aggregation degree is generally low, and the possible reasons are as follows: one is that the parameter distribution of the fault components during data acquisition is not uniform, and the other is that there are some noise interferences (such as noise introduced by connecting lines or joints) in the actual circuit.
[0146] The feature dataset extracted by the deep feature fusion network is input into the HPSO-FDB-ISE-optimized SVM for fault diagnosis, and the diagnosis accuracy on the two circuits is shown in Table 3. It can be known from the table that the intelligent fault diagnosis model of the analog circuit proposed in the present application maintains a relatively high fault diagnosis precision on the Chebyshev filter circuit with a relatively simple network structure. Although the diagnosis precision of the HPSO-FDB-ISE-SVM on the actual Four-op-amp filter circuit decreases by about 3% compared with the simulation circuit, overall, the intelligent fault diagnosis model still has good implementability and generalization ability.
[0147] Table 3: Intelligent fault diagnosis model diagnosis accuracy statistical table (%)
[0148]
[0149] Example 2:
[0150] The embodiment 2 of the present application provides an analog circuit fault diagnosis system based on feature fusion and improved particle swarm algorithm, comprising:
[0151] The data acquisition module is configured to: acquire one-dimensional time domain data of the analog circuit, and convert the one-dimensional time domain data into two-dimensional time-frequency image data;
[0152] The feature extraction module is configured to: obtain first features according to the one-dimensional time domain data and a one-dimensional convolutional neural network; obtain second features according to the two-dimensional time-frequency image data and a deep residual network; and obtain final fault features after splicing the first features and the second features;
[0153] The fault diagnosis module is configured to obtain the fault type according to the fault feature and the pre-trained support vector machine;
[0154] The improved particle swarm algorithm is used to optimize the penalty parameter and the kernel parameter of the support vector machine, in the improved particle swarm algorithm, the comprehensive score of each particle is calculated according to a balance factor, the distance between the particle and the optimal particle of the population and the fitness value, the particles are sorted from high to low according to the scores of the particles, and the particle with the highest comprehensive score is selected as the optimal particle.
[0155] The working method of the system is the same as the simulation circuit fault diagnosis method based on feature fusion and improved particle swarm algorithm provided in Embodiment 1, and details are not repeated here.
[0156] Embodiment 3:
[0157] Embodiment 3 of the present application provides a computer readable storage medium, which stores a program, and the program is executed by a processor to realize the steps in the simulation circuit fault diagnosis method based on feature fusion and improved particle swarm algorithm as described in Embodiment 1 of the present application.
[0158] Embodiment 4:
[0159] Embodiment 4 of the present application provides an electronic device, which includes a memory, a processor and a program stored in the memory and executable on the processor, and the processor realizes the steps in the simulation circuit fault diagnosis method based on feature fusion and improved particle swarm algorithm as described in Embodiment 1 of the present application when executing the program.
[0160] Those skilled in the art will understand that the embodiments of the present application can be provided as a method, a system or a computer program product. Therefore, the present application can take the form of a hardware embodiment, a software embodiment or an embodiment combining software and hardware aspects. Moreover, the present application can take the form of a computer program product implemented on one or more computer usable storage media (including but not limited to disk storage and optical storage, etc.) containing computer usable program code.
[0161] The present application is described with reference to flowcharts and / or block diagrams of methods, devices (systems) and computer program products according to embodiments of the present application. It should be understood that each flow and / or block in the flowcharts and / or block diagrams, and the combination of flows and / or blocks in the flowcharts and / or block diagrams can be realized by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, a special-purpose computer, an embedded processor or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device produce a device that implements the functions described in the flowcharts and / or block diagrams. Figure 1 one flow or multiple flows and / or blocksFigure 1 means for performing the function specified in the block or blocks.
[0162] These computer program instructions can also be stored in a computer readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer readable memory produce an article of manufacture including instructions which implement the flow Figure 1 flow or flows and / or blocks Figure 1 means for performing the function specified in the block or blocks.
[0163] These computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the flow Figure 1 flow or flows and / or blocks Figure 1 means for performing the function specified in the block or blocks.
[0164] Those skilled in the art can understand that all or part of the flow of the above-mentioned embodiment method can be completed by computer program instructing related hardware, and the program can be stored in a computer readable storage medium. When the program is executed, it can include the flow of the above-mentioned embodiment method. The storage medium can be a magnetic disc, an optical disc, a read-only memory (ROM) or a random access memory (RAM), etc.
[0165] The above only describes the preferred embodiments of the present application and is not used to limit the present application. For those skilled in the art, the present application can have various changes and modifications. Any modification, equivalent replacement, improvement, etc. within the spirit and principle of the present application shall be included in the protection scope of the present application.
Claims
1. A method for analog circuit fault diagnosis based on feature fusion and improved particle swarm optimization, characterized in that: The method comprises the following processes: obtaining fault one-dimensional time domain data of an analog circuit, and converting the one-dimensional time domain data into two-dimensional time-frequency image data; obtaining first features according to the one-dimensional time domain data and a one-dimensional convolutional neural network, and obtaining second features according to the two-dimensional time-frequency image data and a deep residual network; and obtaining final fault features by splicing the first features and the second features; obtaining a fault type according to the fault features and a pre-trained support vector machine; wherein, the improved particle swarm algorithm is used to optimize penalty parameters and kernel parameters of the support vector machine, and the improved particle swarm algorithm further comprises: replacing the population of particles with the optimal particles FDBbest replacing the population of particles with the optimal particles Gbest , the second velocity formula is replaced by a first velocity formula for updating the particle velocity; wherein the first velocity formula is: ; and the second velocity formula is: , c 1 and c 2 are empirical weights, r 1 and r 2 are discount factors; performing cross operation on the comprehensive optimal particle FDBbest and a particle with a poor fitness value; a probability factor is introduced, a value of the probability factor gradually linearly decreases from 0.5 to 0 with an increase in the number of iterations, if a random number Rand is less than the probability factor, a particle is updated in speed according to a first speed formula; otherwise, the particle is updated in speed according to a second speed formula; A comprehensive score of each particle is calculated according to the balance factor, the distance between the particle and the fittest particle of the population, and the fitness value , comprising: wherein, is a balancing factor, normF i is a normalized value of the fitness value, DG i is a normalized value of the distance between the i-th particle and the population fitness optimal particle Gbest . the particle with the highest comprehensive score is selected as the comprehensive optimal particle according to a sorting from high to low of scores of the particles.
2. The analog circuit fault diagnosis method based on feature fusion and an improved particle swarm algorithm according to claim 1, characterized in that: the one-dimensional time domain data is converted into the two-dimensional time-frequency image data by using cross wavelet transform.
3. The analog circuit fault diagnosis method based on feature fusion and an improved particle swarm algorithm according to claim 1, characterized in that: No. i Particles and the particle with the best fitness in the population Gbest The distance between them is: 。 4. The analog circuit fault diagnosis method based on feature fusion and an improved particle swarm algorithm according to claim 1, characterized in that: wherein t max is the maximum number of iterations, t is the current iteration number.
5. The analog circuit fault diagnosis method based on feature fusion and an improved particle swarm algorithm according to claim 1, characterized in that: each particle develops a surrounding solution space according to a current position of the particle, comprising: producing N one that obeys a standard uniform distribution of random numbers; Sort the N random numbers ( i =1,2,..., N ) from large to small, and sort the N particles from small to large according to the fitness values; Will N Random numbers and N The particles are matched one by one, so that particles with small fitness values are paired with large random numbers, and particles with large fitness values are paired with small random numbers; In each iteration, if the particle corresponds to greater than a threshold P s then the particle performs a particle individual self-development operation; otherwise, no particle individual self-development operation is performed; All greater than the current threshold P s particles, all develop their own surrounding area according to the following formula: in, normrnd Indicates that a random obedience Normally distributed random numbers, For the i The particle d Dimensional development scope.
6. An analog circuit fault diagnosis system based on feature fusion and an improved particle swarm algorithm, characterized in that: comprising: a data acquisition module configured to obtain fault one-dimensional time domain data of an analog circuit, and convert the one-dimensional time domain data into two-dimensional time-frequency image data; a feature extraction module configured to obtain first features according to the one-dimensional time domain data and a one-dimensional convolutional neural network, and obtain second features according to the two-dimensional time-frequency image data and a deep residual network; and obtain final fault features by splicing the first features and the second features; a fault diagnosis module configured to obtain a fault type according to the fault features and a pre-trained support vector machine; wherein, the improved particle swarm algorithm is used to optimize penalty parameters and kernel parameters of the support vector machine, and the improved particle swarm algorithm further comprises: replacing the population of particles with the optimal particles FDBbest replacing the population of particles with the optimal particles Gbest , the second velocity formula is replaced by a first velocity formula for updating the particle velocity; wherein the first velocity formula is: ; and the second velocity formula is: , c 1 and c 2 are empirical weights, r 1 and r 2 are discount factors; performing cross operation on the comprehensive optimal particle FDBbest and a particle with a poor fitness value; a probability factor is introduced, a value of the probability factor gradually linearly decreases from 0.5 to 0 with an increase in the number of iterations, if a random number Rand is less than the probability factor, a particle is updated in speed according to a first speed formula; otherwise, the particle is updated in speed according to a second speed formula; A comprehensive score of each particle is calculated according to the balance factor, the distance between the particle and the fittest particle of the population, and the fitness value , comprising: wherein, is a balancing factor, normF i is a normalized value of the fitness value, DG i is a normalized value of the distance between the i-th particle and the population fitness optimal particle Gbest . According to the order of the particle scores from high to low, the particle with the highest comprehensive score is selected as the most optimal particle.
7. A computer-readable storage medium having stored thereon a program, characterized in that, The program is executed by the processor to implement the steps in the simulation circuit fault diagnosis method based on feature fusion and improved particle swarm algorithm according to any one of claims 1-5.
8. An electronic device comprising a memory, a processor, and a program stored in the memory and executable on the processor, characterized by The processor executes the program to implement the steps in the simulation circuit fault diagnosis method based on feature fusion and improved particle swarm algorithm according to any one of claims 1-5.
Citation Information
Patent Citations
Analog circuit fault diagnosis method based on deep confidence network feature extraction
CN108414923A
Analogue circuit fault diagnosis method based on generalized multiple kernel learning-support vector machine
WO2017128455A1