A method and system for recognizing the state of a switch and an indicator light of an indoor substation
By using YOLOv3 and DenseNet deep learning models, combined with image recognition technology, the problem of low efficiency in judging equipment category, location and status in substations has been solved, achieving fast and accurate equipment status identification and reducing the time and manpower consumption of manual verification.
Patent Information
- Application Number
- CN202210383578.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-04-12
- Publication Date
- 2025-12-19
- Estimated Expiration
- 2042-04-12
AI Technical Summary
Existing technologies are inefficient in determining the type, location, and status of equipment in substations, especially under complex operational tasks, which require a lot of time and manpower. Traditional methods can only determine the type and location of equipment.
We employ dual deep learning models, YOLOv3 and DenseNet, to predict the location of target devices using image recognition technology. We combine the YOLOv3 network structure model with the DenseNet dense convolutional network structure model for category and state detection, and iteratively adjust the model to improve recognition accuracy.
It enables rapid and accurate identification of the location, type, and status of substation switches and indicator lights, improving identification efficiency and reducing the time and manpower required for manual verification.
Smart Images

Figure CN114821309B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The application relates to the technical field of industrial vision, in particular to an indoor substation switch and indicator light state recognition method and system. BACKGROUND
[0002] In a substation, the device state is one of the contents that are mainly focused on by a substation operation personnel in daily work, and is closely related to the safe and stable operation of the entire power grid and even the power system. The physical on-off position of the primary device of the substation is a direct basis for reflecting the working condition of the connected part of the live primary device, mainly including the closing and opening positions of the outdoor disconnecting switch and the auxiliary grounding knife switch thereof.
[0003] In the past operation work, the substation operation personnel mainly checks the position signal uploaded by the secondary loop auxiliary node of the field device through a background monitoring system to determine the physical on-off position, and manually reaches the device field to check again. However, in most cases, the object device may be far away from the staff, and it is time-consuming and laborious to manually observe on site. In the case of special substation operation tasks or complex operation tasks, each operation needs to be manually checked on site before entering the next operation, which is extremely inconvenient and consumes a large amount of time and manpower.
[0004] With the application and popularization of intelligent devices such as intelligent inspection and fixed-point monitoring of substations, the scene of determining the physical on-off of the device through images is increasing, and it is time-consuming and laborious to identify and analyze the inspection image data through manual identification. If a machine is used for automatic analysis, the traditional method is to use a fixedly installed camera or a mobile inspection robot, but the traditional method can only realize the determination of the device type and the determination of the device position.
[0005] Therefore, it is of great significance to design an indoor substation switch and indicator light state recognition method and system which can quickly and accurately determine the device type, position and device state. SUMMARY
[0006] The embodiment of the application proposes an indoor substation switch and indicator light state recognition method and system to solve the technical problems mentioned in the background technology part.
[0007] In a first aspect, the embodiment of the application provides an indoor substation switch and indicator light state recognition method, including the following steps:
[0008] S110, a plurality of switch cabinet pictures are acquired, the switch cabinet pictures are classified and cropped according to the size of a target device and are preprocessed, and the switch cabinet pictures are divided into training set images and test set images in proportion;
[0009] S120, import the training set image into the yolov3 network structure model for dimension reduction and feature extraction, output the position prediction result of the target device of small, medium and large three dimensions respectively, and iteratively adjust the yolov3 network structure model;
[0010] S130, import the training set image whose position has been predicted in step S120 into the densenet dense convolution network structure model for training, the densenet dense convolution network structure model includes a bottleneck layer and a transition layer, the target device is detected in category and state through the densenet dense convolution network structure model, and the densenet dense convolution network structure model is iteratively adjusted;
[0011] S140, obtain the final recognition model combined yolov3 network structure model and densenet dense convolution network structure model; and
[0012] S150, test the recognition model by using the test set image, and obtain the position, category and state of the switch and indicator light of the transformer substation.
[0013] In a specific embodiment, step S120 imports the training set image into the yolov3 network structure model for dimension reduction and feature extraction, and outputs the position prediction result of the target device of small, medium and large three dimensions respectively, which specifically includes:
[0014] S121, adjust the size of the training set image to a picture array with a size of 416*416*3 in width, height and channel;
[0015] S122, reduce the picture array to 52, 26 and 13 dimensions through 3*3 convolution and 1*1 convolution, and predict small, medium and large target devices through three dimensions respectively;
[0016] S123, there are three full convolution feature extraction layers on 52, 26 and 13 dimensions respectively, wherein the full convolution feature extraction layer includes a 1*1 convolution kernel for dimension reduction and a 3*3 convolution kernel for feature extraction;
[0017] S124, the full convolution feature extraction layer outputs the position prediction result of the target device.
[0018] In a specific embodiment, in step S120, iteratively adjusting the yolov3 network structure model includes:
[0019] Import the training set image into the yolov3 network structure model in batches for dimension reduction and feature extraction, and obtain the yolov3 network structure model trained initially;
[0020] The test set image is imported into the preliminarily trained yolov3 network structure model, the accuracy of target device position recognition is analyzed, if the accuracy is lower than the set threshold, the training set image is supplemented, and the training of the yolov3 network structure model is continued.
[0021] In specific embodiments, in step S130, iteratively adjusting the densenet dense convolution network structure model further comprises: making the densenet dense convolution network structure model reach a convergence state by a minimum loss function, and the minimum loss function used is:
[0022]
[0023] Wherein, p is a real distribution, and q is an approximate distribution.
[0024] In specific embodiments, in step S130, further comprising optimizing the densenet dense convolution network structure model parameters according to the training results in the training process, and continuously improving the structure of the densenet dense convolution network structure model, wherein the objective function is the average of the loss functions of each sample in the training set image, and the objective function of n samples is:
[0025]
[0026] Wherein, f i (x) is the loss function of the i-th sample, and x represents the parameter vector of the model.
[0027] The gradient calculation formula of the objective function to x is:
[0028]
[0029] The expression for updating the random sample i is:
[0030]
[0031] Wherein, alpha is a set learning rate, and a group of samples are randomly extracted after each training by stochastic gradient descent, and the parameters are updated once according to the gradient.
[0032] In specific embodiments, in step S140, the recognition model is obtained by training on GPU3080, wherein the number of categories of the target device is 21, the maximum number of iterations is 80, the batch size is 18, and the step size is 0.01.
[0033] In specific embodiments, in step S110, the switch cabinet picture is classified and cropped according to the size of the target device and preprocessed, wherein the preprocessing includes horizontal mirror image, rotating image, random brightness and contrast enhancement.
[0034] In specific embodiments, the target device includes a rotary switch, a closing indicator light, an opening indicator light, a handcart indicator light, a pressure plate, and an air switch.
[0035] In a second aspect, the present application provides a switch and indicator light state recognition system for indoor substations, which comprises:
[0036] An acquisition module is configured to acquire multiple switch cabinet images, classify and crop the switch cabinet images according to the size of target devices, and perform preprocessing, and divide the switch cabinet images into training set images and test set images according to a proportion.
[0037] A position prediction module is configured to import the training set images into a yolov3 network structure model to perform dimension reduction and feature extraction, output position prediction results of small, medium and large dimensions of target devices respectively, and iteratively adjust the yolov3 network structure model.
[0038] A category prediction module is configured to import the training set images whose positions have been predicted in the position prediction module into a densenet dense convolution network structure model to perform training, the densenet dense convolution network structure model is added with a bottleneck layer and a transition layer, the target device is detected in category and state through the densenet dense convolution network structure model, and the densenet dense convolution network structure model is iteratively adjusted.
[0039] A recognition module is configured to obtain a final recognition model combined by the yolov3 network structure model and the densenet dense convolution network structure model.
[0040] An output module is configured to test the recognition model by using the test set images, and obtain the position, category and state of the switch and indicator light of the substation.
[0041] In a third aspect, the present application provides a computer readable storage medium, which stores a computer program, when the computer program is executed by a processor, the method of any one of the above aspects is implemented.
[0042] The indoor substation switch and indicator light state recognition method and system provided by the embodiments of the present application adopt the double deep learning models yolov3 and densenet, which can not only determine the category and position of the recognition device, but also determine the state of the device, such as opening and closing, bright and dark, etc. The single-stage model yolov3 which can generate alternative boxes integrally can quickly and accurately recognize the position, category and state of the switch and indicator light. BRIEF DESCRIPTION OF DRAWINGS
[0043] Other features, objects, and advantages of the application will become more apparent from the following detailed description when read in conjunction with the accompanying drawings:
[0044] Figure 1 is a flow chart of a switch and indicator light state recognition method for an indoor substation according to the present application;
[0045] Figure 2 is a schematic diagram of Yolov3 feature extraction of a switch and indicator light state recognition method according to the present application;
[0046] Figure 3 is an effect diagram predicted by a recognition model according to one embodiment of the present application;
[0047] Figure 4 is an effect diagram predicted by a recognition model according to another embodiment of the present application;
[0048] Figure 5 is a schematic diagram of a switch and indicator light state recognition system for an indoor substation according to the present application;
[0049] Figure 6 is a structural schematic diagram of a computer system of an electronic device suitable for implementing embodiments of the present application. DETAILED DESCRIPTION
[0050] The present application will be further described below in conjunction with the drawings and embodiments. It can be understood that the specific embodiments described herein are only used to explain the related application, and not to limit the application. In addition, it should be noted that only parts related to the application are shown in the drawings for ease of description. It should be noted that the embodiments and features in the embodiments of the present application can be combined with each other without conflict. The present application will be described in detail below with reference to the drawings and in conjunction with the embodiments.
[0051] Figure 1 shows a flow chart of a switch and indicator light state recognition method for an indoor substation according to the present application, as shown in Figure 1 the method 100 includes the following steps:
[0052] S110, a plurality of switch cabinet pictures are obtained, the switch cabinet pictures are classified and cropped according to the size of the target device and preprocessed, and are divided into training set images and test set images in proportion;
[0053] In specific embodiments, the pre-processing of the picture can include horizontal mirroring of the image, rotating the image, random brightness and contrast enhancement.
[0054] S120, import the training set image into the yolov3 network structure model for dimension reduction and feature extraction, output the position prediction results of the small, medium and large three-dimensional target devices respectively, and iteratively adjust the yolov3 network structure model;
[0055] Figure 2 The schematic diagram of the Yolov3 feature extraction of the indoor substation switch and indicator light state recognition method of the application is shown, combined with reference Figure 1 and Figure 2 In a specific embodiment, step S120 specifically comprises the following sub-steps:
[0056] S121, adjust the size of the training set image to a picture array with a width, height and channel of 416*416*3;
[0057] S122, reduce the dimension of the picture array to 52, 26 and 13 dimensions through 3*3 convolution and 1*1 convolution, and predict small, medium and large target devices through three dimensions respectively;
[0058] S123, there are three full convolution feature extraction layers on 52, 26 and 13 dimensions respectively, that is, Figure 2 Convolutional Set on the right, 1*1 convolution kernel is used for dimension reduction, 3*3 convolution kernel is used for feature extraction, and multiple convolution kernels are staggered to achieve the purpose. Each full convolution feature layer is connected, and the Figure 2 Concatenate flag means that the input of the current feature layer has part of the output from the previous layer. And each feature layer has an output Predict, that is, the result of predicting each type of switch and indicator light device.
[0059] S124, the full convolution feature extraction layer outputs the position prediction result of the target device.
[0060] In a specific embodiment, in step S120, iteratively adjusting the yolov3 network structure model specifically comprises:
[0061] Import the training set image into the yolov3 network structure model in batches for dimension reduction and feature extraction, and obtain the yolov3 network structure model trained initially;
[0062] Import the test set image into the yolov3 network structure model trained initially, analyze the accuracy of target device position recognition, if the accuracy is lower than the set threshold, supplement the training set image, and continue to train the yolov3 network structure model.
[0063] Continue to refer to Figure 1The indoor substation switch and indicator light state recognition method provided in the application further includes S130, introducing the training set image whose position has been predicted in step S120 into a densenet dense convolution network structure model for training, the densenet dense convolution network structure model includes a bottleneck layer and a transition layer, and the densenet dense convolution network structure model is used for classifying and state detection of the target device, and the densenet dense convolution network structure model is iteratively adjusted;
[0064] The specific process of introducing the training set image whose position has been predicted into the densenet dense convolution network structure model for training is as follows:
[0065] The robot-mounted camera holder shoots pictures of the switch cabinet in the indoor substation, classifies and cuts the target device on the switch cabinet picture, and the target device mainly includes various rotating switches, closing indicator lights, opening indicator lights, handcart indicator lights, pressing plates, air switches and circuit breaker mechanical indicators. Through multiple batches of picture collection, the data set is constantly improved;
[0066] Each type of device is placed in a corresponding folder and labeled, and the training set and the test set are divided in a ratio of 8:1. The path for reading the data set in the network is set, and training and testing are performed respectively.
[0067] The classification network densenet directly connects all the layers through splicing, that is, each layer obtains input from all previous layers, and the feature mapping of itself is transmitted to all subsequent layers. The splicing method can make the information propagate more smoothly in the network compared with the resnet cumulative method. However, the splicing method will cause the number of channels of the feature map to be stacked in multiples, increasing the complexity of the calculation. In order to control the number of channels of the feature map, a bottleneck layer and a transition layer are added to the network. The bottleneck layer reduces the number of channels of the feature map by introducing a 1x1 convolution before a 3x3 convolution, and the transition layer reduces the number of channels by adding a compression factor after the dense module. For example, a feature map with m channels output by the dense module can be multiplied by a compression factor b in the subsequent transition layer, so that the number of channels is changed to b x m, and b is usually set to a constant between 0 and 1. The bottleneck layer and the transition layer can reduce the number of feature maps, thereby reducing the number of network parameters and improving the running efficiency of the model.
[0068] The data set of the application is collected in batches. After a model is initially trained, the recognition accuracy of each type of target device is analyzed, and the robot is used to collect pictures of target devices with low accuracy to supplement the data set for training. The generalization ability of the model is enhanced by expanding the data set.
[0069] In deep learning, the loss function is used to measure the gap between the predicted value of the neural network and the true value. By minimizing the loss function, the model reaches a state of convergence, reducing the error of the model's prediction. Selecting an appropriate loss function during model training can greatly improve the performance of the model.
[0070] In step S130, the iterative adjustment of the densenet dense convolution network structure model further includes: making the densenet dense convolution network structure model reach a state of convergence by minimizing the loss function, and optimizing it by the stochastic gradient descent method (SGD).
[0071] Wherein, the minimum loss function used is:
[0072]
[0073] Wherein, p is the real distribution, and q is the approximate distribution.
[0074] In a specific embodiment, in step S130, it further includes optimizing the parameters of the densenet dense convolution network structure model according to the training results during the training process, and continuously improving the structure of the densenet dense convolution network structure model, wherein the objective function is the average of the loss functions of each sample in the training set image, and the objective function of n samples is:
[0075]
[0076] Wherein, f i (x) is the loss function of the i-th sample, and x represents the parameter vector of the model.
[0077] The gradient calculation formula of the objective function with respect to x is:
[0078]
[0079] The expression for updating the random sample i is:
[0080]
[0081] Wherein, a is the learning rate set, and through the stochastic gradient descent, a group of samples are randomly selected after each training, and the parameters are updated once according to the gradient.
[0082] In the above manner, the output result of the network can be continuously optimized.
[0083] S140, obtaining a final recognition model combined yolov3 network structure model and densenet dense convolution network structure model;
[0084] In a specific embodiment, in step S140, the identification model of the application is obtained by training on the GPU 3080, wherein the number of categories of the target device is 21, the maximum number of iterations is 80, the batch size is 18, and the step size is 0.01.
[0085] S150, test the identification model using the test set image, and obtain the position, category and state of the switch and indicator light of the substation.
[0086] The data set used to train the target detection model of the application yolov3 has more than 30,000 images, the data set used to train the densenet state recognition model has more than 160,000 images of 21 categories, and the test set has more than 20,000 images. Figure 3 and Figure 4 The effect diagram predicted by the identification model in the specific embodiment of the application is shown.
[0087] On the basis of the position of the target device predicted by yolov3, the classification model is used to detect the category and state of the device. In view of the problem that the substation equipment image classification recognition model is large and the accuracy is low, the network of the densenet series is used to retrain the model.
[0088] The experimental results are shown in Table 1. The newly trained densenet series model provided by the application is smaller than the original resnet model, which can save storage space, improve operation efficiency, and improve overall recognition efficiency. Compared with the original model, the accuracy of densenet169 and densenet201 is increased by 1.8% and 2.3% respectively, reaching more than 95%.
[0089] Table 1 Comparison of accuracy of different training models
[0090]
[0091] Figure 5 The schematic diagram of the indoor substation switch and indicator light state recognition system of the application is shown. The system comprises:
[0092] The acquisition module 510 is configured to acquire a plurality of switch cabinet pictures, classify and crop the switch cabinet pictures according to the size of the target device, and perform preprocessing, and divide the switch cabinet pictures into training set images and test set images according to a proportion; and
[0093] The position prediction module 520 is configured to import the training set images into the yolov3 network structure model for dimension reduction and feature extraction, output the position prediction results of the target device in small, medium and large three dimensions respectively, and iteratively adjust the yolov3 network structure model; and
[0094] The category prediction module 530 is configured to introduce the training set images whose positions have been predicted in the position prediction module into a densenet dense convolution network structure model for training, the densenet dense convolution network structure model is added with a bottleneck layer and a transition layer, the target device is detected in category and state through the densenet dense convolution network structure model, and the densenet dense convolution network structure model is iteratively adjusted; and
[0095] The recognition module 540 is configured to obtain a final recognition model combined by the yolov3 network structure model and the densenet dense convolution network structure model; and
[0096] The output module 550 is configured to test the recognition model by using the test set images, and obtain the position, category and state of the switch and the indicator light of the transformer substation.
[0097] The indoor transformer substation switch and indicator light state recognition method and system provided by the embodiment of the present application adopts the double deep learning models yolov3 and densenet, can not only determine the category position of the recognition device, but also determine the state of the device, such as split and combination, bright and dark, etc. The single-stage model yolov3 which can integrally generate a candidate box can quickly and accurately recognize the position, category and state of the switch and the indicator light.
[0098] The present application further provides a computer readable storage medium, the medium stores a computer program, when the computer program is executed by a processor, the method as any one of the above embodiments is implemented.
[0099] As shown in Figure 6 , the computer system 600 includes a central processing unit (CPU) 601, which can perform various appropriate actions and processes according to programs stored in a read-only memory (ROM) 602 or programs loaded from a storage portion 608 to a random access memory (RAM) 603. In the RAM 603, various programs and data required for the operation of the system 600 are also stored. The CPU 601, the ROM 602, and the RAM 603 are connected to each other through a bus 604. An input / output (I / O) interface 605 is also connected to the bus 604.
[0100] The following components are connected to the I / O interface 605: an input section 606 including a keyboard, a mouse, etc.; an output section 607 including a liquid crystal display (LCD), etc., and a speaker, etc.; a storage section 608 including a hard disk, etc.; and a communication section 609 including a network interface card such as a LAN card, a modem, etc. The communication section 609 performs communication processing via a network such as the Internet. A drive 610 is also connected to the I / O interface 605 as necessary. A removable medium 611 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc. is attached to the drive 610 as necessary, so that a computer program read out therefrom is installed in the storage section 608 as necessary.
[0101] In particular, the processes described above with reference to the flow charts can be implemented as a computer software program according to embodiments of the present disclosure. For example, embodiments of the present disclosure include a computer program product comprising a computer program carried on a computer readable medium, the computer program comprising program code for performing the methods illustrated by the flow charts. In such embodiments, the computer program can be downloaded and installed from a network via the communication section 609, and / or installed from the removable medium 611. When the computer program is executed by the central processing unit (CPU) 601, the above-described functions defined in the methods of the present application are performed. It should be noted that the computer readable medium described in the present application can be a computer readable signal medium or a computer readable storage medium or any combination of the two. The computer readable medium may, for example, be, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus or device, or any suitable combination of the above. More specific examples of the computer readable medium can include, but are not limited to, an electrical connection having one or more wires, a portable computer diskette, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present application, the computer readable medium can be any tangible medium that contains or stores a program that can be used by or in connection with an instruction execution system, apparatus or device. In the present application, the computer readable signal medium can include a data signal carried in a baseband or as part of a carrier wave, in which the computer readable program code is carried. Such a propagated data signal can take a variety of forms, including but not limited to, an electromagnetic signal, an optical signal or any suitable combination of the above. The computer readable signal medium can also be any computer readable medium that can be used to carry or store a program for use by or in connection with an instruction execution system, apparatus or device. The program code contained on the computer readable medium can be transmitted by any suitable medium, including but not limited to, wireless, wire line, optical fiber cable, RF, etc., or any suitable combination of the above.
[0102] Computer program code for carrying out operations of the present application can be written in any combination of one or more programming languages, including an object oriented programming language such as Java, Smalltalk, C++ or the like, and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code can execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the latter scenario, the remote computer can be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or the connection can be made to an external computer (for example, through the Internet using an Internet Service Provider).
[0103] The computer program instructions can also be loaded onto a computer or other programmable information processing apparatus to cause a series of operations to be performed on the computer or other programmable information processing apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable information processing apparatus implement the functions / acts specified in the flowchart and / or block diagram block or blocks.
[0104] The modules described in the embodiments of the present application can be implemented through software or hardware. The modules described can be set in a processor, for example, can be described as: a processor includes an acquisition module, an analysis module and an output module. In some cases, the names of the modules do not constitute a limitation on the modules themselves.
[0105] The above description is merely the preferred embodiments of the present application and the technical principles used. Those skilled in the art should understand that the scope of the application involved in the present application is not limited to the technical solutions formed by the specific combinations of the above technical features, and should also cover other technical solutions formed by the above technical features or equivalent features in any combination without departing from the above inventive concept. For example, the above features are replaced with the technical features disclosed in the present application (but not limited to) having similar functions to form technical solutions.
Claims
1. A method for recognizing the state of a switch and an indicator light of an indoor substation, characterized by, The method comprises the following steps: S110, obtaining multiple switch cabinet pictures, classifying and cropping the switch cabinet pictures according to a target device size, and preprocessing and dividing the switch cabinet pictures into training set images and test set images in proportion; S120, importing the training set images into a yolov3 network structure model to perform dimension reduction and feature extraction, and outputting position prediction results of the target device in small, medium and large dimensions respectively, and iteratively adjusting the yolov3 network structure model; S130, importing the training set images whose positions have been predicted in step S120 into a densenet dense convolution network structure model to perform training, the densenet dense convolution network structure model comprising a bottleneck layer and a transition layer, and performing category and state detection on the target device through the densenet dense convolution network structure model, and iteratively adjusting the densenet dense convolution network structure model; In step S130, iteratively adjusting the densenet dense convolution network structure model further comprises: The densenet dense convolution network structure model reaches a convergence state through a minimum loss function, and the minimum loss function used is: Wherein, p is a real distribution, and q is an approximate distribution; In step S130, the densenet dense convolution network structure model parameters are optimized according to the training results in the training process, and the structure of the densenet dense convolution network structure model is continuously improved, wherein the objective function is the average of the loss functions of each sample in the training set images, and the objective function of n samples is: wherein, L is the loss function for the i-th sample, x represents the parameter vector of the model; The gradient calculation formula of the objective function on x is: The expression for updating the random sample i is: Wherein, α is a set learning rate, and a group of samples are randomly extracted after each training through stochastic gradient descent, and the parameters are updated once according to the gradient; S140, obtaining a final recognition model combined with the yolov3 network structure model and the densenet dense convolution network structure model; and S150, testing the recognition model by using the test set images to obtain the position, category and state of the substation switch and indicator light.
2. The method of claim 1, wherein, In step S120, the training set images are imported into the yolov3 network structure model to perform dimension reduction and feature extraction, and the position prediction results of the target device in small, medium and large dimensions are output respectively, and specifically comprising: S121, adjusting the size of the training set images to a picture array with a size of 416*416*3 in width, height and channel; S122, reducing the picture array to 52, 26 and 13 dimensions through 3*3 convolution and 1*1 convolution, and predicting small, medium and large target devices through the three dimensions respectively; S123, there are three full convolution feature extraction layers in the 52, 26 and 13 dimensions respectively, wherein the full convolution feature extraction layer comprises a 1*1 convolution kernel for dimension reduction and a 3*3 convolution kernel for feature extraction; S124, the full convolution feature extraction layer outputs the position prediction results of the target device.
3. The method of claim 1, wherein, In step S120, iteratively adjusting the yolov3 network structure model comprises: In batches, the training set images are imported into the yolov3 network structure model for dimension reduction and feature extraction, and a preliminarily trained yolov3 network structure model is obtained. The test set images are imported into the preliminarily trained yolov3 network structure model, the accuracy of the target device position recognition is analyzed, if the accuracy is lower than the set threshold, the training set images are supplemented, and the training of the yolov3 network structure model is continued.
4. The method of claim 1, wherein, In step S140, the recognition model is obtained by training on the GPU 3080, wherein the number of categories of the target device is 21, the maximum number of iterations is 80, the batch size is 18, and the step size is 0.
01.
5. The method of claim 1, wherein, In step S110, the switch cabinet pictures are classified and cropped according to the size of the target device and preprocessed, wherein the preprocessing includes horizontal mirroring, rotating the image, random brightness and contrast enhancement.
6. The method of claim 1, wherein, The target device includes a rotating switch, a closing indicator light, an opening indicator light, a handcart indicator light, a pressure plate and an air switch.
7. An indoor substation switch and indicator light status recognition system, characterized by, The system comprises: An acquisition module is configured to acquire multiple switch cabinet pictures, classify and crop the switch cabinet pictures according to the size of the target device, and preprocess the switch cabinet pictures, and divide the switch cabinet pictures into training set images and test set images according to a proportion; and A position prediction module is configured to import the training set images into a yolov3 network structure model for dimension reduction and feature extraction, output position prediction results of the target device in small, medium and large dimensions respectively, and iteratively adjust the yolov3 network structure model; and A category prediction module is configured to import the training set images whose positions have been predicted by the position prediction module into a densenet dense convolution network structure model for training, the densenet dense convolution network structure model is added with a bottleneck layer and a transition layer, the target device is detected in categories and states by the densenet dense convolution network structure model, and the densenet dense convolution network structure model is iteratively adjusted. Iteratively adjusting the densenet dense convolution network structure model further comprises: The densenet dense convolution network structure model reaches a convergence state by using a minimum loss function, and the minimum loss function used is: Wherein, p is a real distribution, and q is an approximate distribution. Further comprising optimizing the parameters of the densenet dense convolution network structure model according to the training results in the training process, and continuously improving the structure of the densenet dense convolution network structure model, wherein the objective function is the average of the loss functions of each sample in the training set images, and the objective function of n samples is: wherein, L is the loss function for the i-th sample, x represents the parameter vector of the model; The gradient calculation formula of the objective function on x is: The expression for updating the random sample i is: Wherein, alpha is a set learning rate, a group of samples are randomly extracted after each training by stochastic gradient descent, and the parameters are updated once according to the gradient; and An identification module is configured to obtain a final identification model combined by the yolov3 network structure model and the densenet dense convolution network structure model. An output module is configured to test the identification model by using a test set image to obtain positions, categories and states of the substation switch and the indicator light. 8.A computer readable storage medium, wherein a computer program is stored in the medium, and when the computer program is executed by a processor, the method according to any one of claims 1-6 is implemented.
Citation Information
Patent Citations
Target detection method based on a dense connection characteristic pyramid network
CN109614985A
Infrared image fault detection method and device for power equipment
CN111986172A
Method and device for identifying screen cabinet indicating lamp based on convolutional neural network
CN113989802A