A weather recognition method and system based on multi-task learning

The weather identification method through multi-task learning uses convolutional neural network models and multi-scale feature extraction technology, combined with weather object segmentation and classification tasks, to solve the problem of weather state identification under the influence of severe weather in intelligent monitoring systems, achieving efficient and accurate Get weather information.

CN114998820BActive Publication Date: 2024-09-13OCEAN UNIV OF CHINA
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210442778.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-04-25
Publication Date
2024-09-13
Estimated Expiration
2042-04-25

AI Technical Summary

Technical Problem

In intelligent monitoring systems, severe weather (such as rain, snow, fog) affects image quality, making it difficult for traditional methods to effectively identify weather conditions. Especially in intelligent transportation applications, accurate weather information needs to be obtained quickly and efficiently to alleviate traffic impacts. .

Method used

A weather recognition method based on multi-task learning is adopted to extract weather features through the shared convolution layer of the convolutional neural network model, and combined with weather object segmentation and classification tasks, multi-scale feature extraction and trainable pooling technology are used to achieve weather status Accurate identification.

Benefits of technology

This method can efficiently and accurately identify weather conditions, solve the problem of difficulty in extracting weather features in traditional methods, improve the accuracy and efficiency of weather information acquisition, and is suitable for identifying weather conditions in outdoor monitoring scene images.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114998820B
    Figure CN114998820B
Patent Text Reader

Abstract

The present invention discloses a weather recognition method and system based on multi-task learning, including: inputting the acquired target image into the shared convolution layer of the convolutional neural network model for weather recognition to obtain shared weather features; inputting the shared weather features into the weather object segmentation task framework of the convolutional neural network model to segment the weather object to obtain the weather object segmentation result; inputting the weather object segmentation result and the shared weather features into the weather classification task framework of the convolutional neural network model to classify the weather and obtain the weather label; and determining the weather state information recognized for the target image according to the weather object segmentation result and the weather label. By establishing a multi-task deep learning framework, the present invention can extract shared weather features in the shared layer, and obtain richer weather state information by integrating classification and segmentation tasks, which can be applied to weather state recognition in outdoor monitoring scene images.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of data processing technology, and more particularly, to a weather recognition method and system based on multi-task learning. Background Art

[0002] Outdoor intelligent monitoring systems consist of large-scale cameras, image transmission, and image storage. These systems capture massive amounts of outdoor scene images, enabling intelligent real-time target monitoring, behavior recognition, and timely warnings of anomalies. These systems play a significant role in environmental protection and intelligent transportation.

[0003] In the field of intelligent surveillance, systems rely on clear images to achieve tasks such as target detection, recognition, and tracking. However, in real-world situations, camera images can be affected by adverse weather conditions such as rain, snow, and fog, introducing noise. For example, in intelligent transportation applications, rainy and snowy weather can make roads slippery, affecting vehicle speeds and causing congestion or accidents. In these situations, the system needs to perceive and capture weather information within the scene to accurately control traffic signals and mitigate the impact of rain and snow on traffic. Therefore, timely and accurate weather information is crucial in practical applications. Traditionally, weather information acquisition relies primarily on hardware sensors collecting weather data and manual observation to determine the weather. With the tremendous success of computer vision research in recent years, researchers have increasingly considered weather recognition as a computer vision task: analyzing images captured by outdoor intelligent surveillance systems, automatically classifying the weather within the images, and identifying the weather information contained within them.

[0004] Weather classification is different from general image classification tasks. The difficulty lies in that the same target objects may exist in weather images of different categories, which makes it difficult for traditional feature extraction methods to obtain effective weather features in the image. Summary of the Invention

[0005] The present invention proposes a weather recognition method and system based on multi-task learning to solve the problem of how to quickly and efficiently identify weather conditions.

[0006] In order to solve the above problem, according to one aspect of the present invention, a weather recognition method based on multi-task learning is provided, the method comprising:

[0007] Input the acquired target weather image into the shared convolutional layer of the convolutional neural network model for weather recognition to obtain shared weather features;

[0008] Inputting the shared weather features into the weather object segmentation task framework of the convolutional neural network model to segment the weather object to obtain a weather object segmentation result;

[0009] Inputting the weather object segmentation results and shared weather features into the weather classification task framework of the convolutional neural network model to perform weather classification and obtain weather labels;

[0010] Weather state information identified for the target weather image is determined according to the weather object segmentation result and the weather label.

[0011] Preferably, the step of inputting the shared weather features into the weather object segmentation task framework of the convolutional neural network model to segment the weather object to obtain the weather object segmentation result includes:

[0012] Extracting multi-scale features based on the shared weather features to obtain multi-scale weather features;

[0013] Performing an upsampling operation on the multi-scale weather features to restore the size of the feature map to the original image size;

[0014] Weather object classification is performed pixel by pixel on the feature map of the restored size to obtain a weather object segmentation result consistent with the size of the target weather image.

[0015] Preferably, extracting multi-scale features based on the shared weather features to obtain multi-scale weather features includes:

[0016] Multi-scale features are extracted using dilated convolution, which consists of a 1x1 convolution and three 3x3 dilated convolutions with sampling rates of {6, 12, 18}. Multi-scale weather features are obtained by fusing the features extracted by the 1x1 convolution and the three dilated convolution layers based on splicing.

[0017] Preferably, the upsampling operation on the multi-scale weather features to restore the size of the feature map to the original image size includes:

[0018] The multi-scale weather feature map is upsampled by a bilinear interpolation method, and new elements are inserted between the pixels of the feature map to restore the size of the feature map to the size of the input image.

[0019] Preferably, the step of performing pixel-by-pixel weather object classification on the feature map of the restored size to obtain a weather object segmentation result consistent with the size of the target weather image comprises:

[0020] Perform softmax classification on each pixel of the feature map of the restored size to determine the category to which each pixel belongs. Combine all pixel classifications to finally obtain the weather object segmentation result consistent with the input image size.

[0021] Preferably, the step of inputting the weather object segmentation result and the shared weather features into the weather classification task framework of the convolutional neural network model to perform weather classification and obtain weather labels includes:

[0022] Performing feature fusion on the shared weather features and the weather object segmentation results to obtain weather fusion features;

[0023] Performing a pooling operation on the weather fusion feature to obtain a weather feature representation vector;

[0024] The weather feature representation vector is input into a classifier to perform weather label classification to obtain a weather label.

[0025] Preferably, performing a pooling operation on the weather fusion feature to obtain a weather feature representation vector includes:

[0026]

[0027] in, represents the result of generalized average pooling of the feature map of the kth channel, v (g) is the weather feature representation vector obtained after pooling the weather features; X k is the activation map of the kth feature channel; each feature map has a different pooling parameter p k , obtained by training.

[0028] According to another aspect of the present invention, a weather recognition system based on multi-task learning is provided, the system comprising:

[0029] a shared weather feature acquisition unit, configured to input the acquired target weather image into a shared convolutional layer of a convolutional neural network model for weather recognition to acquire shared weather features;

[0030] a weather object segmentation unit, configured to input the shared weather features into the weather object segmentation task framework of the convolutional neural network model to segment the weather object, thereby obtaining a weather object segmentation result;

[0031] A weather classification unit, configured to input the weather object segmentation results and shared weather features into the weather classification task framework of the convolutional neural network model to perform weather classification and obtain a weather label;

[0032] A weather status information acquisition unit is used to determine the weather status information identified for the target weather image according to the weather object segmentation result and the weather label.

[0033] Preferably, the weather object segmentation unit inputs the shared weather features into the weather object segmentation task framework of the convolutional neural network model to segment the weather object to obtain a weather object segmentation result, including:

[0034] Extracting multi-scale features based on the shared weather features to obtain multi-scale weather features;

[0035] Performing an upsampling operation on the multi-scale weather features to restore the size of the feature map to the original image size;

[0036] Weather object classification is performed pixel by pixel on the feature map of the restored size to obtain a weather object segmentation result consistent with the size of the target weather image.

[0037] Preferably, the weather object segmentation unit extracts multi-scale features based on the shared weather features to obtain multi-scale weather features, including:

[0038] Multi-scale features are extracted using dilated convolution, which consists of a 1x1 convolution and three 3x3 dilated convolutions with sampling rates of {6, 12, 18}. Multi-scale weather features are obtained by fusing the features extracted by the 1x1 convolution and the three dilated convolution layers based on splicing.

[0039] Preferably, the weather object segmentation unit performs an upsampling operation on the multi-scale weather features to restore the size of the feature map to the original image size, comprising:

[0040] The multi-scale weather feature map is upsampled by a bilinear interpolation system, and new elements are inserted between the pixels of the feature map to restore the size of the feature map to the size of the input image.

[0041] Preferably, the weather object segmentation unit performs pixel-by-pixel weather object classification on the feature map of the restored size to obtain a weather object segmentation result consistent with the size of the target weather image, including:

[0042] Perform softmax classification on each pixel of the feature map of the restored size to determine the category to which each pixel belongs. Combine all pixel classifications to finally obtain the weather object segmentation result consistent with the input image size.

[0043] Preferably, the weather classification unit inputs the weather object segmentation result and the shared weather features into the weather classification task framework of the convolutional neural network model to perform weather classification and obtain a weather label, including:

[0044] Performing feature fusion on the shared weather features and the weather object segmentation results to obtain weather fusion features;

[0045] Performing a pooling operation on the weather fusion feature to obtain a weather feature representation vector;

[0046] The weather feature representation vector is input into a classifier to perform weather label classification to obtain a weather label.

[0047] Preferably, the weather classification unit performs a pooling operation on the weather fusion feature to obtain a weather feature representation vector, including:

[0048]

[0049] in, represents the result of generalized average pooling of the feature map of the kth channel, v (g) is the weather feature representation vector obtained after pooling the weather features; X k is the activation map of the kth feature channel; each feature map has a different pooling parameter p k , obtained by training.

[0050] The present invention provides a weather recognition method and system based on multi-task learning, including: inputting the acquired target weather image into the shared convolution layer of a convolutional neural network model for weather recognition to obtain shared weather features; inputting the shared weather features into the weather object segmentation task framework of the convolutional neural network model to perform weather object segmentation to obtain weather object segmentation results; inputting the weather object segmentation results and the shared weather features into the weather classification task framework of the convolutional neural network model to perform weather classification to obtain weather labels; and determining the weather status information identified for the target weather image based on the weather object segmentation results and weather labels. The present invention establishes a multi-task deep learning framework and jointly learns to process weather label classification and weather object segmentation tasks. Due to the intrinsic connection between the two tasks, weather features with more weather identification information can be extracted through training and learning in the shared layer, and richer weather status information can be obtained by combining classification and segmentation tasks; the weather classification task is based on a trainable pooling technology, and different generalized average pooling parameters are used to pool the weather feature maps of different channels, so as to solve the incompleteness of global maximum pooling and average pooling in weather feature pooling, so as to extract feature vectors with more sufficient weather information for classification; the weather object segmentation task is based on a multi-scale feature extraction technology, and weather target objects of different scales are taken into account in the feature extraction process, and effective features are extracted for weather objects of each scale for pixel-level classification in the weather object segmentation task; the method of the present invention can be applied to weather status recognition in outdoor monitoring scene images, and can efficiently and accurately identify weather status. BRIEF DESCRIPTION OF THE DRAWINGS

[0051] A more complete understanding of exemplary embodiments of the present invention may be obtained by referring to the following drawings:

[0052] Figure 1 Flowchart of a weather recognition method 100 based on multi-task learning according to an embodiment of the present invention;

[0053] Figure 2 Schematic diagram of a multi-task deep learning framework based on a convolutional neural network according to an embodiment of the present invention;

[0054] Figure 3 Flowchart of a weather object segmentation branch based on multi-scale feature extraction according to an embodiment of the present invention;

[0055] Figure 4 A flowchart of multi-scale feature extraction according to an embodiment of the present invention;

[0056] Figure 5 Flowchart of a weather classification task branch based on a trainable pooling method according to an embodiment of the present invention. DETAILED DESCRIPTION

[0057] Exemplary embodiments of the present invention will now be described with reference to the accompanying drawings. However, the present invention may be embodied in many different forms and is not limited to the embodiments described herein. These embodiments are provided to provide a thorough and complete disclosure of the present invention and to fully convey the scope of the present invention to those skilled in the art. The terminology used in the exemplary embodiments shown in the accompanying drawings is not intended to limit the present invention. In the accompanying drawings, identical elements are denoted by the same reference numerals.

[0058] Unless otherwise specified, the terms used herein (including technical terms) have the meanings commonly understood by those skilled in the art. In addition, it is understood that terms defined in commonly used dictionaries should be understood to have the same meanings as those in the context of the relevant fields, and should not be understood as idealized or overly formal meanings.

[0059] Figure 1 FIG. 1 is a flow chart of a weather recognition method 100 based on multi-task learning according to an embodiment of the present invention. Figure 1As shown, the weather recognition method based on multi-task learning provided by the embodiment of the present invention establishes a multi-task deep learning framework, and jointly learns and processes weather label classification and weather object segmentation tasks. Due to the intrinsic connection between the two tasks, weather features with more weather recognition information can be extracted through training and learning in the shared layer, and richer weather status information can be obtained by combining classification and segmentation tasks; the weather classification task is based on trainable pooling technology, and different generalized average pooling parameters are used to pool the weather feature maps of different channels, so as to solve the incompleteness of global maximum pooling and average pooling in weather feature pooling, so as to extract feature vectors with more sufficient weather information for classification; the weather object segmentation task is based on multi-scale feature extraction technology, and weather target objects of different scales are taken into account in the process of feature extraction, and effective features are extracted for weather objects of each scale for pixel-level classification in the weather object segmentation task; the method of the present invention can be applied to weather status recognition in outdoor monitoring scene images, and can efficiently and accurately identify weather status. The multi-task learning-based weather recognition method 100 provided in an embodiment of the present invention starts from step 101. In step 101, the acquired target weather image is input into the shared convolution layer of the convolutional neural network model for weather recognition to obtain shared weather features.

[0060] The goal of multi-task learning is to process two related tasks simultaneously in one framework. The joint learning structure can make the two related tasks mutually beneficial by exploring the shared information between the two tasks. In short, by exploring the intrinsic relationship between different tasks, the multi-task learning framework has achieved success in many fields. Therefore, in order to explore more effective and rich weather features, the present invention designs a multi-task framework based on a deep learning network, which simultaneously processes the weather label classification task and the weather information (such as shadows, blue sky and other target objects with weather information in the image) segmentation task, explores the intrinsic relationship between the weather label classification and weather information segmentation tasks, and optimizes the extraction of shared weather features between tasks to achieve weather recognition for outdoor monitoring scene images.

[0061] The multi-task weather recognition framework designed by the present invention includes three parts: a shared feature extraction layer, a weather label classification task branch, and a weather information segmentation task branch. The shared feature extraction layer adopts the convolution and pooling layers of the existing convolutional neural network structure. After the shared convolution layer extracts weather features, the network framework is divided into a weather classification task and a weather information segmentation task, and weather features are input into both tasks at the same time. Considering that various weather objects in the weather information segmentation task can provide classification clues for weather categories, in order to further promote the classification task, the weather features obtained in the segmentation task are fused with the weather features obtained in the classification task, and the fused weather features are used to perform weather classification.

[0062] In the present invention, the weather recognition method based on multi-task learning adopts a multi-task deep learning framework based on convolutional neural networks. In addition to the shared feature extraction layer, it mainly includes a weather classification branch based on trainable pooling technology and a weather object segmentation branch based on multi-scale feature extraction.

[0063] like Figure 2 As shown in the figure, the process of the multi-task deep learning framework based on convolutional neural network is as follows:

[0064] 1. Input the outdoor surveillance image into the shared convolutional layer to extract shared weather features, which are then input into the weather classification branch and the weather object segmentation task branch respectively;

[0065] 2. In the weather label classification task branch, weather features are further extracted and pooled using a trainable pooling method to obtain a final weather feature representation vector for classification. This branch ultimately outputs the weather label corresponding to the image.

[0066] 3. In the weather object segmentation task branch, features of the weather objects are further extracted, and a multi-scale feature extraction method is used to semantically segment the weather objects based on the multi-scale features. This branch ultimately outputs a weather object segmentation map, which together with the weather label serves as the weather status information identified for the input outdoor image.

[0067] In the present invention, the weather image is input into the shared convolution layer, the shared weather features are extracted, and the shared weather features are input into the weather classification branch and the weather object segmentation task branch respectively. The weather image can be an outdoor monitoring image.

[0068] In step 102, the shared weather features are input into the weather object segmentation task framework of the convolutional neural network model to segment the weather object to obtain a weather object segmentation result.

[0069] Preferably, the step of inputting the shared weather features into the weather object segmentation task framework of the convolutional neural network model to segment the weather object to obtain the weather object segmentation result includes:

[0070] Extracting multi-scale features based on the shared weather features to obtain multi-scale weather features;

[0071] Performing an upsampling operation on the multi-scale weather features to restore the size of the feature map to the original image size;

[0072] Weather object classification is performed pixel by pixel on the feature map of the restored size to obtain a weather object segmentation result consistent with the size of the target weather image.

[0073] Preferably, extracting multi-scale features based on the shared weather features to obtain multi-scale weather features includes:

[0074] Multi-scale features are extracted using dilated convolution, which consists of a 1x1 convolution and three 3x3 dilated convolutions with sampling rates of {6, 12, 18}. Multi-scale weather features are obtained by fusing the features extracted by the 1x1 convolution and the three dilated convolution layers based on splicing.

[0075] Preferably, the upsampling operation on the multi-scale weather features to restore the size of the feature map to the original image size includes:

[0076] The multi-scale weather feature map is upsampled by a bilinear interpolation method, and new elements are inserted between the pixels of the feature map to restore the size of the feature map to the size of the input image.

[0077] Preferably, the step of performing pixel-by-pixel weather object classification on the feature map of the restored size to obtain a weather object segmentation result consistent with the size of the target weather image comprises:

[0078] Perform softmax classification on each pixel of the feature map of the restored size to determine the category to which each pixel belongs. Combine all pixel classifications to finally obtain the weather object segmentation result consistent with the input image size.

[0079] Weather object segmentation belongs to semantic segmentation, which requires pixel-level image recognition, that is, marking the object category corresponding to each pixel in the image, for example, marking which area in the image is the sky area and which area represents the shadow area, etc. However, the areas occupied by different weather clues in outdoor monitoring scene images are inconsistent in size. For example, in an image with sunny weather conditions, the blue sky area is generally larger, while the shadow area illuminated by the sun is generally smaller. In the weather object segmentation task, weather objects have different sizes and it is difficult to extract effective features for different weather objects at the same time. In response to the above problems, the present invention considers weather targets of different scales in the weather object segmentation task, adopts multi-scale weather object feature extraction technology, and simultaneously extracts effective features for weather objects of each scale for pixel-level classification in the final segmentation task.

[0080] In the present invention, weather object segmentation based on multi-scale feature extraction includes:

[0081] (1) First, the acquired shared weather features are input into the multi-scale feature extraction module for multi-scale feature extraction;

[0082] (2) Then, the obtained multi-scale feature map is upsampled to reach the size of the original image;

[0083] (3) Finally, the restored feature map is subjected to pixel-by-pixel weather object classification to obtain a weather object segmentation map that is consistent with the original image size, i.e., the weather object segmentation result.

[0084] like Figure 3 The figure shows the process of weather object segmentation task based on multi-scale feature extraction. The specific steps are as follows:

[0085] 1. The shared features extracted by the shared convolution layer are input to the weather object segmentation task branch. Based on this, the present invention uses a multi-scale weather feature extraction module to further explore the multi-scale information of weather objects. The multi-scale weather feature extraction module uses atrous convolutions instead of standard convolutions, which consists of a 1x1 convolution and three 3x3 atrous convolutions with sampling rates of {6, 12, 18}, as shown in the figure. Figure 4 As shown in the figure. In a standard convolution operation, the local input region corresponding to each output neuron is continuous, while the local input region corresponding to a dilated convolution is spatially discontinuous. While the dilated convolution maintains the same number of convolution parameters, it achieves a larger effective receptive field. By controlling the receptive field size at different sampling rates, it captures multi-scale information. The features extracted by the aforementioned 1x1 convolution and the three dilated convolution layers are concatenated and fused to generate multi-scale weather features.

[0086] 2. The generated multi-scale weather features are upsampled using the bilinear interpolation method, and new elements are inserted between the pixels of the feature map to restore the size of the weather object feature map to the input image size.

[0087] 3. Perform semantic segmentation on the upsampled weather object features, i.e., classify each pixel pixel by pixel. The pixel categories include the selected weather object category and the background. Softmax classification is performed on each pixel to determine the category to which each pixel belongs. All pixel classifications are combined to obtain a weather object segmentation map with the same size as the input image.

[0088] In step 103, the weather object segmentation result and the shared weather features are input into the weather classification task framework of the convolutional neural network model to perform weather classification and obtain weather labels.

[0089] Preferably, the step of inputting the weather object segmentation result and the shared weather features into the weather classification task framework of the convolutional neural network model to perform weather classification and obtain weather labels includes:

[0090] Performing feature fusion on the shared weather features and the weather object segmentation results to obtain weather fusion features;

[0091] Performing a pooling operation on the weather fusion feature to obtain a weather feature representation vector;

[0092] The weather feature representation vector is input into a classifier to perform weather label classification to obtain a weather label.

[0093] Preferably, performing a pooling operation on the weather fusion feature to obtain a weather feature representation vector includes:

[0094]

[0095] in, represents the result of generalized average pooling of the feature map of the kth channel, v (g) is the weather feature representation vector obtained after pooling the weather features; X k is the activation map of the kth feature channel; each feature map has a different pooling parameter p k , obtained by training.

[0096] Before classification in the existing network structure, the fused weather features are pooled using the global maximum pooling or average pooling method to obtain the final weather feature vector for weather classification. Since the above pooling methods do not fully utilize the activation information on each feature map, they are not suitable for extracting weather feature vectors and performing weather classification. The global maximum pooling method takes the maximum activation value on each weather feature map as the pooling result, and loses other activation value information; the average pooling method averages all activation values ​​on each feature map as the pooling result. Although it retains global information, it may weaken the distinguishing performance of weather representation. In response to the above problems, the present invention proposes a trainable adaptive pooling technology, which fully utilizes all activation values ​​on each weather feature map while using different generalized pooling parameters for pooling different channel feature maps to extract feature vectors suitable for weather classification.

[0097] In the present invention, weather classification based on trainable pooling technology includes:

[0098] (1) First, the shared weather features and weather object segmentation results are fused to obtain richer weather features;

[0099] (2) Then, the fused weather features are pooled to obtain the weather feature representation vector;

[0100] (3) Finally, the weather feature representation vector is input into the classifier to classify the weather label and obtain the weather label.

[0101] like Figure 5 As shown in Figure 1, the process of weather classification task based on the trainable pooling method is as follows:

[0102] 1. Because weather objects contain rich weather information and play a crucial role in determining weather conditions, the weather features obtained by fusing high-level semantic features from the segmentation branch are richer and more predictive. The shared features extracted by the shared convolutional layer are combined with the high-level semantic features from the weather object segmentation task branch through feature concatenation to obtain weather features X that are richer in weather information.

[0103] 2. For the weather feature X obtained in 1, its dimension is W×H×K, where K is the number of feature maps, X i is the W×H activation value on the i-th feature map. A pooling layer is used to operate on the weather feature X to generate the weather feature vector v, which is the final weather feature representation used for weather classification. In previous weather classification work, weather feature vector generation uses global maximum pooling or flat pooling, as shown in formulas (1) and (2), respectively:

[0104]

[0105]

[0106] in, Represents the feature map X of the kth channel k The result of the maximum pooling, v (m) Represents the feature representation vector obtained by maximizing the pooling of weather features. Represents the feature map X of the kth channel k The result of average pooling, v (a) represents the feature representation vector obtained by averaging the weather features. Both pooling methods fail to fully utilize the activation information in each weather feature map. In this paper, a trainable generalized pooling method is designed to perform pooling operations on weather features by combining the above two pooling methods, as shown in formula (3):

[0107]

[0108] in, represents the result of generalized average pooling of the feature map of the kth channel, v (g) is the weather feature representation vector obtained after pooling the weather features; X k is the activation map of the kth feature channel; each feature map has a different pooling parameter p k .

[0109] Pooling methods (1) and (2) are special cases of the generalized pooling method in (3). That is, when p k →∞, then (3) is the maximum pooling (1), when p k= 1, (3) is average pooling (2). Pooling parameter p k It is learned during training. Because this operation is differentiable, it can be used as part of backpropagation. The corresponding derivative is given by the following formula:

[0110]

[0111]

[0112] In formula (3), each feature map has a different pooling parameter p k , pooling operation is performed on the weather feature map according to the pooling parameters obtained through training to obtain the weather feature representation vector.

[0113] 3. The fully connected layer maps the learned distributed feature representation to the sample label space. The weather feature representation extracted in 2 is operated through the fully connected layer to realize weather classification and output the weather label corresponding to the input image.

[0114] In step 104 , weather status information identified for the target weather image is determined based on the weather object segmentation result and the weather label.

[0115] This invention is based on a deep learning method, which uses a convolutional neural network structure to extract data-driven image weather features. Based on the weather features, the invention simultaneously trains image weather classification and weather information segmentation tasks according to the training data, and realizes richer and more effective weather feature extraction and weather status information recognition through multi-task learning.

[0116] The weather recognition system 600 based on multi-task learning provided by the embodiment of the present invention includes: a shared weather feature acquisition unit 601, a weather object segmentation unit 602, a weather classification unit 603 and a weather status information acquisition unit 604.

[0117] Preferably, the shared weather feature acquisition unit 601 is used to input the acquired target weather image into a shared convolutional layer of a convolutional neural network model for weather recognition to obtain shared weather features.

[0118] Preferably, the weather object segmentation unit 602 is used to input the shared weather features into the weather object segmentation task framework of the convolutional neural network model to perform weather object segmentation to obtain weather object segmentation results.

[0119] Preferably, the weather object segmentation unit 602 inputs the shared weather features into the weather object segmentation task framework of the convolutional neural network model to segment the weather object to obtain a weather object segmentation result, including:

[0120] Extracting multi-scale features based on the shared weather features to obtain multi-scale weather features;

[0121] Performing an upsampling operation on the multi-scale weather features to restore the size of the feature map to the original image size;

[0122] Weather object classification is performed pixel by pixel on the feature map of the restored size to obtain a weather object segmentation result consistent with the size of the target weather image.

[0123] Preferably, the weather object segmentation unit 602 extracts multi-scale features based on the shared weather features to obtain multi-scale weather features, including:

[0124] Multi-scale features are extracted using dilated convolution, which consists of a 1x1 convolution and three 3x3 dilated convolutions with sampling rates of {6, 12, 18}. Multi-scale weather features are obtained by fusing the features extracted by the 1x1 convolution and the three dilated convolution layers based on splicing.

[0125] Preferably, the weather object segmentation unit 602 performs an upsampling operation on the multi-scale weather features to restore the size of the feature map to the original image size, including:

[0126] The multi-scale weather feature map is upsampled by a bilinear interpolation system, and new elements are inserted between the pixels of the feature map to restore the size of the feature map to the size of the input image.

[0127] Preferably, the weather object segmentation unit 602 performs pixel-by-pixel weather object classification on the feature map of the restored size to obtain a weather object segmentation result consistent with the size of the target weather image, including:

[0128] Perform softmax classification on each pixel of the feature map of the restored size to determine the category to which each pixel belongs. Combine all pixel classifications to finally obtain the weather object segmentation result consistent with the input image size.

[0129] Preferably, the weather classification unit 603 is used to input the weather object segmentation results and shared weather features into the weather classification task framework of the convolutional neural network model to perform weather classification and obtain weather labels.

[0130] Preferably, the weather classification unit 603 inputs the weather object segmentation result and the shared weather features into the weather classification task framework of the convolutional neural network model to perform weather classification and obtain a weather label, including:

[0131] Performing feature fusion on the shared weather features and the weather object segmentation results to obtain weather fusion features;

[0132] Performing a pooling operation on the weather fusion feature to obtain a weather feature representation vector;

[0133] The weather feature representation vector is input into a classifier to perform weather label classification to obtain a weather label.

[0134] Preferably, the weather classification unit 603 performs a pooling operation on the weather fusion feature to obtain a weather feature representation vector, including:

[0135]

[0136] in, represents the result of generalized average pooling of the feature map of the kth channel, v (g) is the weather feature representation vector obtained after pooling the weather features; X k is the activation map of the kth feature channel; each feature map has a different pooling parameter p k .

[0137] Preferably, the weather status information acquiring unit 604 is configured to determine the weather status information identified for the target weather image according to the weather object segmentation result and the weather label.

[0138] The weather recognition system 600 based on multi-task learning in an embodiment of the present invention corresponds to the weather recognition method 100 based on multi-task learning in another embodiment of the present invention, and will not be described in detail here.

[0139] The invention has been described above with reference to a few embodiments. However, it is readily apparent to a person skilled in the art that other embodiments than the ones disclosed above are equally within the scope of the invention, as defined by the appended patent claims.

[0140] Generally, all terms used in the claims are to be interpreted according to their ordinary meaning in the technical field, unless explicitly defined otherwise herein. All references to "a / the [means, component, etc.]" are to be interpreted openly as referring to at least one instance of the means, component, etc., unless explicitly stated otherwise. The steps of any method disclosed herein do not necessarily need to be performed in the exact order disclosed, unless explicitly stated otherwise.

[0141] Those skilled in the art will appreciate that the embodiments of the present application can be provided as methods, systems, or computer program products. Therefore, the present application can adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application can adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) that contain computer-usable program code.

[0142] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a 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 generate instructions for implementing the steps in the process. Figure 1 a process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0143] These computer program instructions may also be stored in a computer readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 a process or multiple processes and / or boxes Figure 1 The function specified in one or more boxes.

[0144] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operational steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing the instructions executed on the computer or other programmable device for implementing the process. Figure 1 a process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.

[0145] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit it. Although the present invention has been described in detail with reference to the above embodiments, ordinary technicians in the field should understand that the specific implementation methods of the present invention can still be modified or replaced by equivalents. Any modification or equivalent replacement that does not depart from the spirit and scope of the present invention should be covered by the scope of protection of the claims of the present invention.

Claims

1. A weather recognition method based on multi-task learning, It is characterized in that The method comprises: Inputting the acquired target weather image into the shared convolutional layer of the convolutional neural network model for weather recognition to obtain shared weather features; Inputting the shared weather features into the weather object segmentation task framework of the convolutional neural network model to segment the weather object to obtain a weather object segmentation result; Input the weather object segmentation result and the shared weather features into the weather classification task framework of the convolutional neural network model to perform weather classification and obtain weather labels; Determine weather state information identified for the target weather image according to the weather object segmentation result and the weather label; The step of inputting the shared weather features into the weather object segmentation task framework of the convolutional neural network model to segment the weather object to obtain the weather object segmentation result includes: Extracting multi-scale features according to the shared weather features to obtain multi-scale weather features; Performing an upsampling operation on the multi-scale weather features to restore the size of the feature map to the original image size; Perform pixel-by-pixel weather object classification on the feature map of the restored size to obtain a weather object segmentation result consistent with the size of the target weather image; The weather object segmentation result and the shared weather features are input into the weather classification task framework of the convolutional neural network model to perform weather classification and obtain weather labels, including: Performing feature fusion on the shared weather features and the weather object segmentation results to obtain weather fusion features; Performing a pooling operation on the weather fusion feature to obtain a weather feature representation vector; Inputting the weather feature representation vector into a classifier to classify weather labels and obtain weather labels; The step of performing a pooling operation on the weather fusion feature to obtain a weather feature representation vector includes: in, represents the result of generalized average pooling of the feature map of the kth channel, v (g) is the weather feature representation vector obtained after pooling the weather features; X k is the activation map of the kth feature channel; each feature map has a different pooling parameter p k , obtained through training.

2. The method according to claim 1, It is characterized in that The extracting of multi-scale features according to the shared weather features to obtain multi-scale weather features includes: Multi-scale features are extracted using dilated convolution, which consists of a 1x1 convolution and three 3x3 dilated convolutions with sampling rates = {6, 12, 18}. The features extracted by the 1x1 convolution and the three dilated convolution layers are fused based on splicing to obtain multi-scale weather features.

3. The method according to claim 1, It is characterized in that The upsampling operation on the multi-scale weather features to restore the size of the feature map to the original image size includes: The multi-scale weather features are upsampled by a bilinear interpolation method, and new elements are inserted between the pixels of the feature map to restore the size of the feature map to the size of the input image.

4. The method according to claim 1, It is characterized in that The step of performing pixel-by-pixel weather object classification on the feature map of the restored size to obtain a weather object segmentation result consistent with the size of the target weather image includes: Perform softmax classification on each pixel of the feature map of the restored size to determine the category to which each pixel belongs. Combine all pixel classifications to finally obtain a weather object segmentation result that is consistent with the input image size.

5. A weather recognition system based on multi-task learning, It is characterized in that The system comprises: A shared weather feature acquisition unit, used for inputting the acquired target weather image into a shared convolutional layer of a convolutional neural network model for weather recognition to acquire shared weather features; A weather object segmentation unit, used for inputting the shared weather features into the weather object segmentation task framework of the convolutional neural network model to perform weather object segmentation to obtain a weather object segmentation result; A weather classification unit, used for inputting the weather object segmentation result and the shared weather features into the weather classification task framework of the convolutional neural network model to perform weather classification and obtain a weather label; A weather status information acquisition unit, configured to determine the weather status information identified for the target weather image according to the weather object segmentation result and the weather label; The weather object segmentation unit inputs the shared weather features into the weather object segmentation task framework of the convolutional neural network model to segment the weather object to obtain the weather object segmentation result, including: Extracting multi-scale features according to the shared weather features to obtain multi-scale weather features; Performing an upsampling operation on the multi-scale weather features to restore the size of the feature map to the original image size; Perform pixel-by-pixel weather object classification on the feature map of the restored size to obtain a weather object segmentation result consistent with the size of the target weather image; The weather classification unit inputs the weather object segmentation result and the shared weather features into the weather classification task framework of the convolutional neural network model to perform weather classification and obtain weather labels, including: Performing feature fusion on the shared weather features and the weather object segmentation results to obtain weather fusion features; Performing a pooling operation on the weather fusion feature to obtain a weather feature representation vector; Inputting the weather feature representation vector into a classifier to classify weather labels and obtain weather labels; The weather classification unit performs a pooling operation on the weather fusion feature to obtain a weather feature representation vector, including: in, represents the result of generalized average pooling of the feature map of the kth channel, v (g) is the weather feature representation vector obtained after pooling the weather features; X k is the activation map of the kth feature channel; each feature map has a different pooling parameter p k , obtained through training.

6. The system according to claim 5, It is characterized in that The weather object segmentation unit extracts multi-scale features according to the shared weather features to obtain multi-scale weather features, including: Multi-scale features are extracted using dilated convolution, which consists of a 1x1 convolution and three 3x3 dilated convolutions with sampling rates = {6, 12, 18}. The features extracted by the 1x1 convolution and the three dilated convolution layers are fused based on splicing to obtain multi-scale weather features.

7. The system according to claim 5, It is characterized in that The weather object segmentation unit performs an upsampling operation on the multi-scale weather features to restore the size of the feature map to the original image size, including: The multi-scale weather features are upsampled by a bilinear interpolation method, and new elements are inserted between the pixels of the feature map to restore the size of the feature map to the size of the input image.

8. The system according to claim 5, It is characterized in that The weather object segmentation unit performs pixel-by-pixel weather object classification on the feature map of the restored size to obtain a weather object segmentation result consistent with the size of the target weather image, including: Perform softmax classification on each pixel of the feature map of the restored size to determine the category to which each pixel belongs. Combine all pixel classifications to finally obtain a weather object segmentation result that is consistent with the input image size.