Image-based vehicle recognition method, device, system, apparatus and storage medium
By acquiring multi-scale information of vehicle images through a trained vehicle recognition network, identifying dense areas and magnifying them, the problem of inaccurate vehicle recognition in ultra-dense scenes is solved, and accurate recognition of the number and location of vehicles is achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- CHINA TELECOM CORP LTD
- Filing Date
- 2022-12-30
- Publication Date
- 2026-05-29
AI Technical Summary
Existing image-based vehicle recognition methods are inaccurate in ultra-dense scenes, especially when detecting vehicles using detection models. The density map distribution of the vehicle count density map differs greatly from the true distribution, resulting in a lack of spatial information.
A trained vehicle recognition network is used to obtain vehicle location distribution maps, vehicle count density maps, and multi-scale candidate region attention maps of vehicle images. Dense regions are identified through a multi-layer candidate region network, and local images are magnified for resolution processing. Combined with vehicle localization and counting networks, accurate vehicle localization and counting results are obtained.
It improves the accuracy and applicability of vehicle recognition, enabling accurate identification of the number and location of vehicles in ultra-dense scenes. It achieves precise identification of the number and location of vehicles through local image magnification processing.
Smart Images

Figure CN115830551B_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of computer vision technology, and in particular to an image-based vehicle recognition method, apparatus, system, device, and storage medium. Background Technology
[0002] Currently, there are two main approaches to image-based vehicle recognition using vehicle images: one is to directly detect each vehicle in the image using a detection model and obtain the result by counting; the other is to predict the number of vehicles by building a vehicle count density map and performing integral estimation.
[0003] The first approach, which uses a detection model to detect each vehicle in an image, performs poorly in ultra-dense scenes. While the approach that uses a vehicle count density map for estimation theoretically yields a density map integral value that is comparable to the number of vehicles in the image, the learned density map distribution differs significantly from the actual density map distribution. This approach, which relies solely on the relationship between feature density and number to build a model, is prone to missing spatial information, which is detrimental to further vehicle analysis.
[0004] Therefore, how to provide a widely applicable and accurate image-based vehicle recognition method is a technical problem that urgently needs to be solved.
[0005] It should be noted that the information disclosed in the background section above is only used to enhance the understanding of the background of this disclosure, and therefore may include information that does not constitute prior art known to those skilled in the art. Summary of the Invention
[0006] This disclosure provides an image-based vehicle recognition method, apparatus, system, device, and storage medium, which at least to some extent overcomes the technical problem of low accuracy in image-based vehicle recognition schemes in related technologies.
[0007] Other features and advantages of this disclosure will become apparent from the following detailed description, or may be learned in part by practice of this disclosure.
[0008] According to one aspect of this disclosure, an image-based vehicle recognition method is provided. The method includes: acquiring a vehicle image, wherein the vehicle image contains one or more vehicles; inputting the vehicle image into a trained vehicle recognition network to output a vehicle location distribution map, a vehicle count density map, and a multi-scale candidate region attention map of the vehicle image; determining vehicle localization results and vehicle count results of the vehicle image based on the vehicle location distribution map and vehicle count density map of the vehicle image; determining one or more dense regions in the vehicle image where vehicles are densely distributed based on the multi-scale candidate region attention map of the vehicle image; acquiring local images of each dense region, and after increasing the resolution of the local images of each dense region, inputting them into the vehicle recognition network to output a precise vehicle location distribution map and a precise vehicle count density map of each dense region; determining precise vehicle localization results and precise vehicle count results of each dense region based on the precise vehicle location distribution map and precise vehicle count density map of each dense region; and replacing the vehicle localization results and vehicle count results of corresponding regions in the vehicle image with the precise vehicle localization results and precise vehicle count results of each dense region to obtain precise vehicle localization results and precise vehicle count results of the vehicle image.
[0009] In some embodiments, before inputting the vehicle image into a trained vehicle recognition network and outputting the vehicle location distribution map, vehicle count density map, and multi-scale candidate region attention map of the vehicle image, the method further includes: generating training data, wherein the training data includes: multiple vehicle images and corresponding vehicle location distribution maps, vehicle count density maps, and multi-scale candidate region attention maps; training a vehicle recognition network composed of a feature extraction network, a vehicle localization network, a vehicle counting network, and a multi-layer candidate region network using the training data to obtain a trained vehicle recognition network, wherein the input data of the feature extraction network is the vehicle image, and the output data of the feature extraction network is the feature information of the vehicle image; the input data of the vehicle localization network is the feature information of the vehicle image, and the output data of the vehicle localization network is the vehicle location distribution map of the vehicle image; the input data of the vehicle counting network is the feature information of the vehicle image, and the output data of the vehicle counting network is the vehicle count density map of the vehicle image; the input data of the multi-layer candidate region network is the vehicle location distribution map and the vehicle count density map of the vehicle image, and the output data of the multi-layer candidate region network is one or more densely distributed regions of vehicles in the vehicle image.
[0010] In some embodiments, the feature extraction network is the first 33 layers of a 34-layer ResNet-34 residual network; the vehicle localization network consists of 9 dilated convolutional layers, 4 deconvolutional layers, and 1×1 ordinary convolutional layer; the vehicle counting network consists of 6 dilated convolutional layers and 1 deconvolutional layer; and the multi-layer candidate region network consists of 3 dilated convolutional layers.
[0011] In some embodiments, determining the vehicle location result and vehicle count result of the vehicle image based on the vehicle location distribution map and vehicle count density map of the vehicle image includes: determining the vehicle location result of the vehicle image based on the vehicle location distribution map of the vehicle image; determining a first vehicle count result based on the vehicle location distribution map of the vehicle image, and determining a second vehicle count result based on the vehicle count density map of the vehicle image; and performing a weighted average of the first vehicle count result and the second vehicle count result to obtain the vehicle count result of the vehicle image.
[0012] In some embodiments, a weighted average is performed on the first vehicle counting result and the second vehicle counting result to obtain the vehicle counting result of the vehicle image, including: obtaining a first weight coefficient of the vehicle localization network and a second weight coefficient of the vehicle counting network; and performing a weighted average on the first vehicle counting result and the second vehicle counting result based on the first weight coefficient of the vehicle localization network and the second weight coefficient of the vehicle counting network to obtain the vehicle counting result of the vehicle image.
[0013] In some embodiments, determining the vehicle location result of the vehicle image based on the vehicle location distribution map of the vehicle image includes: passing the vehicle location distribution map through a kernel size of 3. A 3-point average pooling operation, followed by a kernel size of 3 The maximum pooling operation of 3 is used to obtain the processed vehicle location distribution map; the processed vehicle location distribution map is compared with the unprocessed vehicle location distribution map at the pixel level, and the local peak points are determined according to the comparison results; the local peak points with response values greater than the preset threshold are determined as the vehicle positioning results.
[0014] According to another aspect of this disclosure, an image-based vehicle recognition system is also provided. The system includes: an image acquisition device for acquiring vehicle images, wherein the vehicle images contain one or more vehicles; and an image processing device for inputting the vehicle images into a trained vehicle recognition network, outputting a vehicle location distribution map, a vehicle count density map, and a multi-scale candidate region attention map of the vehicle images, determining vehicle localization results and vehicle count results of the vehicle images based on the vehicle location distribution map and vehicle count density map, and determining one or more densely distributed vehicles in the vehicle images based on the multi-scale candidate region attention map of the vehicle images. The system identifies dense regions and acquires local images of each region. These images are then enlarged in resolution and input into the vehicle recognition network. The network outputs precise vehicle location distribution maps and precise vehicle count density maps for each dense region. Based on these maps, the network determines the precise vehicle location and vehicle count results for each region. Finally, the precise vehicle location and vehicle count results for each region are used to replace the vehicle location and vehicle count results for the corresponding regions in the vehicle image, resulting in the precise vehicle location and vehicle count results for the vehicle image.
[0015] According to another aspect of this disclosure, an image-based vehicle recognition device is also provided. The device includes: a vehicle image acquisition module for acquiring vehicle images, wherein the vehicle images contain one or more vehicles; a network prediction module for inputting the vehicle images into a trained vehicle recognition network and outputting a vehicle location distribution map, a vehicle count density map, and a multi-scale candidate region attention map of the vehicle images; a vehicle recognition module for determining vehicle localization results and vehicle count results of the vehicle images based on the vehicle location distribution map and vehicle count density map; and a dense region determination module for determining one or more dense regions in the vehicle images where vehicles are densely distributed, based on the multi-scale candidate region attention map of the vehicle images. The system comprises a dense region identification module, which acquires local images of each dense region, enlarges the resolution of each local image, and inputs it into the vehicle recognition network to output a precise vehicle location distribution map and a precise vehicle count density map for each dense region; a precise vehicle recognition module, which determines the precise vehicle location result and precise vehicle count result for each dense region based on the precise vehicle location distribution map and precise vehicle count density map; and a vehicle recognition result fusion module, which uses the precise vehicle location result and precise vehicle count result of each dense region to replace the vehicle location result and vehicle count result of the corresponding region in the vehicle image, respectively, to obtain the precise vehicle location result and precise vehicle count result of the vehicle image.
[0016] According to another aspect of this disclosure, an electronic device is also provided, comprising: a processor; and a memory for storing executable instructions of the processor; wherein the processor is configured to perform the image-based vehicle recognition method described in any one of the preceding claims by executing the executable instructions.
[0017] According to another aspect of this disclosure, a computer-readable storage medium is also provided, on which a computer program is stored, which, when executed by a processor, implements the image-based vehicle recognition method described in any of the preceding claims.
[0018] According to another aspect of this disclosure, a computer program product is also provided, including a computer program that, when executed by a processor, implements the image-based vehicle recognition method of any of the above.
[0019] The image-based vehicle recognition method, apparatus, system, device, and storage medium provided in the embodiments of this disclosure pre-train a vehicle recognition network capable of predicting location distribution maps, vehicle count density maps, and multi-scale candidate region attention maps. After acquiring a vehicle image containing one or more vehicles, the vehicle image is input into the trained vehicle recognition network, which outputs the corresponding vehicle location distribution map, vehicle count density map, and multi-scale candidate region attention map. Then, based on the vehicle location distribution map and vehicle count density map of the vehicle image, the vehicle localization result and vehicle count result of the vehicle image are determined, and based on the multi-scale candidate region attention map of the vehicle image, the vehicle distribution in the vehicle image is determined. One or more dense regions are identified, and local images of each dense region are acquired. After the local images of each dense region are enlarged in resolution, they are input into the vehicle recognition network. The network outputs a precise vehicle location distribution map and a precise vehicle count density map for each dense region. Based on the precise vehicle location distribution map and the precise vehicle count density map of each dense region, the precise vehicle localization result and the precise vehicle count result for each dense region are determined. Finally, the precise vehicle localization result and the precise vehicle count result for the corresponding region in the vehicle image are replaced with the precise vehicle localization result and the precise vehicle count result for the vehicle image.
[0020] The solution provided in this embodiment can not only identify the number of vehicles in an image, but also the location of the vehicles in the image. Furthermore, by magnifying the densely distributed area of the vehicle in the image, accurate identification of the number and location of vehicles can be achieved.
[0021] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit this disclosure. Attached Figure Description
[0022] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this disclosure and, together with the description, serve to explain the principles of this disclosure. It is obvious that the drawings described below are merely some embodiments of this disclosure, and those skilled in the art can obtain other drawings based on these drawings without any inventive effort.
[0023] Figure 1 A schematic diagram of an image-based vehicle recognition system architecture is shown in an embodiment of this disclosure;
[0024] Figure 2 A flowchart of an image-based vehicle recognition method according to an embodiment of this disclosure is shown;
[0025] Figure 3 A flowchart illustrating the training process of a vehicle recognition network according to an embodiment of this disclosure is shown.
[0026] Figure 4 This diagram illustrates a vehicle identification network according to an embodiment of the present disclosure.
[0027] Figure 5 A schematic diagram of an image-based vehicle recognition device according to an embodiment of the present disclosure is shown;
[0028] Figure 6 This diagram illustrates a structural block diagram of an electronic device according to an embodiment of the present disclosure.
[0029] Figure 7 A schematic diagram of a computer-readable storage medium according to an embodiment of the present disclosure is shown. Detailed Implementation
[0030] Exemplary embodiments will now be described more fully with reference to the accompanying drawings. However, these exemplary embodiments can be implemented in many forms and should not be construed as limited to the examples set forth herein; rather, they are provided so that this disclosure will be more comprehensive and complete, and will fully convey the concept of the exemplary embodiments to those skilled in the art. The described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments.
[0031] Furthermore, the accompanying drawings are merely illustrative of this disclosure and are not necessarily drawn to scale. The same reference numerals in the drawings denote the same or similar parts, and therefore repeated descriptions of them will be omitted. Some block diagrams shown in the drawings are functional entities and do not necessarily correspond to physically or logically independent entities. These functional entities may be implemented in software, in one or more hardware modules or integrated circuits, or in different network and / or processor devices and / or microcontroller devices.
[0032] The specific implementation methods of the embodiments of this disclosure will now be described in detail with reference to the accompanying drawings.
[0033] Figure 1 A schematic diagram of an image-based vehicle recognition system architecture according to an embodiment of this disclosure is shown. Figure 1 As shown, the system architecture may include: an image acquisition device 101 and an image processing device 102.
[0034] In this embodiment of the disclosure, the medium providing the communication link between the image acquisition device 101 and the image processing device 102 can be a wired network or a wireless network.
[0035] Optionally, the aforementioned wireless or wired networks use standard communication technologies and / or protocols. The network is typically the Internet, but can also be any network, including but not limited to Local Area Networks (LANs), Metropolitan Area Networks (MANs), Wide Area Networks (WANs), mobile, wired or wireless networks, private networks, or any combination of virtual private networks. In some embodiments, technologies and / or formats including Hyper Text Markup Language (HTML), Extensible Markup Language (XML), etc., are used to represent data exchanged over the network. Furthermore, conventional encryption technologies such as Secure Socket Layer (SSL), Transport Layer Security (TLS), Virtual Private Networks (VPNs), and Internet Protocol Security (IPsec) can be used to encrypt all or some links. In other embodiments, custom and / or dedicated data communication technologies can be used to replace or supplement the aforementioned data communication technologies.
[0036] The aforementioned image acquisition device 101 can be any kind of camera device capable of acquiring images, including, but not limited to, various cameras installed on roads.
[0037] The image processing device 102 described above can be a terminal device or a server. In some embodiments, when the image processing device 102 is a terminal device, it can be, but is not limited to, electronic devices such as smartphones, tablets, laptops, and desktop computers. Optionally, the clients of the applications installed on different terminal devices can be the same, or clients of the same type of application based on different operating systems. Depending on the terminal platform, the specific form of the application client can also be different; for example, the application client can be a mobile client, a PC client, etc.
[0038] In other embodiments, when the image processing device 102 is a server, the server can be a server providing various services, a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN (Content Delivery Network), and big data and artificial intelligence platforms. The terminal and the server can be directly or indirectly connected via wired or wireless communication, and this disclosure does not impose any limitations.
[0039] Those skilled in the art will know that Figure 1 The number of image acquisition devices and image processing devices shown is merely illustrative; any number of such devices can be used depending on actual needs. This disclosure does not limit the scope of the embodiments.
[0040] Under the above system architecture, this disclosure provides an image-based vehicle recognition method, which can be executed by any electronic device with computing power.
[0041] In some embodiments, the image-based vehicle recognition method provided in this disclosure can be executed by the image processing device of the system architecture described above; in other embodiments, the image-based vehicle recognition method provided in this disclosure can be implemented by the image processing device and the image acquisition device in the system architecture interacting with each other.
[0042] Figure 2 This diagram illustrates a flowchart of an image-based vehicle recognition method according to an embodiment of the present disclosure, such as... Figure 2 As shown, the image-based vehicle recognition method provided in this embodiment may include the following steps:
[0043] S202, Obtain a vehicle image, wherein the vehicle image contains one or more vehicles.
[0044] S204: Input the vehicle image into the trained vehicle recognition network and output the vehicle location distribution map, vehicle count density map and multi-scale candidate region attention map of the vehicle image.
[0045] In one embodiment, the vehicle count density map can be generated according to the following formula. :
[0046] (1)
[0047] in,
[0048] (2)
[0049] (3)
[0050] in, Here are the coordinates of the point in question; For vehicle number, This represents the total number of vehicles in the image. Distance Recent Average distance between vehicles ,Right now It is any constant between 0 and 1; For the first The vehicle's coordinates, The coordinates of the vehicles are .
[0051] When detecting vehicles in an image, each vehicle is tightly enclosed by a rectangular detection box. The coordinates of the four vertices of this rectangle can then be obtained using the formula... Calculate the coordinates of the center point (where, The coordinates of the top-left and bottom-right vertices of the bounding box are used to generate a density map, which serves as the label. This label image has the same resolution as the original vehicle image, with each bright spot representing one vehicle. This makes it easy to count the total number of vehicles and the coordinates of each vehicle for subsequent network training.
[0052] S206. Based on the vehicle location distribution map and vehicle count density map of the vehicle image, determine the vehicle location result and vehicle count result of the vehicle image.
[0053] S208, Based on the multi-scale candidate region attention map of the vehicle image, determine one or more dense regions in the vehicle image where vehicles are densely distributed.
[0054] In practice, a vehicle attention map is output through a multi-scale candidate region attention map, and then a dense region in the vehicle attention map is determined by the connected component analysis algorithm in OpenCV.
[0055] S210: Acquire local images of each dense region, enlarge the resolution of each local image of the dense region, input it into the vehicle recognition network, and output the accurate vehicle location distribution map and accurate vehicle count density map of each dense region.
[0056] In practice, after identifying the dense areas, each dense area is cropped from the original vehicle image according to its coordinate information. After resolution magnification, the local image corresponding to the magnified dense area is input into the vehicle recognition network to obtain the accurate vehicle location distribution map and accurate vehicle count density map of each dense area.
[0057] S212, Based on the precise vehicle location distribution map and precise vehicle counting density map of each dense area, determine the precise vehicle location result and precise vehicle counting result of each dense area.
[0058] In specific implementation, the above S212 can be achieved through the following steps: determining the vehicle positioning result of the vehicle image based on the vehicle position distribution map of the vehicle image; determining the first vehicle counting result based on the vehicle position distribution map of the vehicle image, and determining the second vehicle counting result based on the vehicle counting density map of the vehicle image; and performing a weighted average of the first vehicle counting result and the second vehicle counting result to obtain the vehicle counting result of the vehicle image.
[0059] In practice, the vehicle counting results can be obtained by integrating the vehicle counting density map.
[0060] In some embodiments, when performing a weighted average of the first vehicle counting result and the second vehicle counting result, the following steps can be taken: obtaining the first weight coefficient of the vehicle positioning network and the second weight coefficient of the vehicle counting network; and performing a weighted average of the first vehicle counting result and the second vehicle counting result based on the first weight coefficient of the vehicle positioning network and the second weight coefficient of the vehicle counting network to obtain the vehicle counting result of the vehicle image.
[0061] In practical implementation, the weight coefficients of the vehicle positioning network and the vehicle counting network can be learned (the first weight coefficient is used). The second weighting coefficient is represented using the following expression: ,in, (A number greater than 0 and less than 1) so that the learned weight coefficients can make the predicted value closer to the true value.
[0062] When the difference between the total number of vehicles and the predicted number of vehicles is less than or equal to M (M can be selected according to the actual situation). ,Right now It can take any value from 0 to 1;
[0063] When the difference between the total number of vehicles and the predicted number of vehicles is greater than M. .
[0064] In some embodiments, the vehicle location result of a vehicle image can be determined based on a vehicle location distribution map of a vehicle image by the following steps: passing the vehicle location distribution map through a kernel of size 3... A 3-point average pooling operation, followed by a kernel size of 3 The max pooling operation of step 3 yields the processed vehicle location distribution map. The processed map is then compared pixel-level with the original map to determine local peak points. Local peak points with response values greater than a preset threshold are identified as vehicle localization results. Optionally, after determining the local peak points in the image, the number of vehicles in the image can be obtained by counting these peak points.
[0065] S214, using the accurate vehicle positioning results and accurate vehicle counting results of each dense area, replace the vehicle positioning results and vehicle counting results of the corresponding areas in the vehicle image respectively, to obtain the accurate vehicle positioning results and accurate vehicle counting results of the vehicle image.
[0066] In this embodiment, a multi-scale candidate region attention map is output through a multi-layer candidate region network, in which dense regions are identified. These regions are then cropped and enlarged from the original image. The enlarged region image is fed into a feature extraction network and a vehicle localization network to obtain more accurate vehicle localization information. The detection results of the original image localization network in that region are replaced with the detection results of the enlarged dense region, i.e., the output dense region vehicle localization map replaces the vehicle localization map of the dense region in the original image. The dense region vehicle position distribution map is the localization result of a certain dense vehicle region after enlargement, which theoretically can obtain more accurate vehicle localization information than the original image.
[0067] Using the image-based vehicle recognition method provided in this embodiment for vehicle counting can improve the applicability and accuracy of vehicle counting methods.
[0068] In some embodiments, such as Figure 3 As shown in the embodiments of this disclosure, the image-based vehicle recognition method can also train the vehicle recognition network model through the following steps:
[0069] S302, Generate training data, which includes: multiple vehicle images and corresponding vehicle location distribution maps, vehicle count density maps and multi-scale candidate region attention maps;
[0070] S304, the vehicle recognition network, which is a combination of a feature extraction network, a vehicle localization network, a vehicle counting network, and a multi-layer candidate region network, is trained using training data to obtain a trained vehicle recognition network. The input data for the feature extraction network is the vehicle image, and its output data is the feature information of the vehicle image. The input data for the vehicle localization network is the feature information of the vehicle image, and its output data is the vehicle position distribution map of the vehicle image. The input data for the vehicle counting network is the feature information of the vehicle image, and its output data is the vehicle count density map of the vehicle image. The input data for the multi-layer candidate region network are the vehicle position distribution map and the vehicle count density map of the vehicle image, and its output data is one or more densely populated regions in the vehicle image where vehicles are densely distributed.
[0071] In practice, the models can be trained sequentially in the order of vehicle counting network, localization network, and multi-layer candidate region network. For training the vehicle counting network, the MSE loss between the density map output by this branch and the true density map is used as the optimization objective function to update the network parameters using gradients. For training the vehicle localization network, the weighted cross-entropy loss (BSE) between the predicted vehicle location map and the true vehicle location map is used as the optimization objective function to update the network parameters using gradients. For training the multi-layer candidate region network, the MSE loss is used as the optimization objective function.
[0072] In some embodiments, the feature extraction network can be the first 33 layers of a 34-layer ResNet-34 residual network; the vehicle localization network can consist of 9 dilated convolutional layers, 4 deconvolutional layers, and a 1×1 ordinary convolutional layer; the vehicle counting network can consist of 6 dilated convolutional layers and 1 deconvolutional layer; and the multi-layer candidate region network can consist of 3 dilated convolutional layers.
[0073] In practical implementation, the image-based vehicle recognition method provided in this disclosure embodiment can be implemented through the following steps:
[0074] 1) Construct a vehicle recognition network:
[0075] like Figure 4 As shown, the vehicle recognition network is a combined network consisting of a feature extraction network, a vehicle localization network, a vehicle counting network, and a multi-layer candidate region network. The functions of each network are as follows:
[0076] ① Feature extraction network: The first 33 layers of the ResNet-34 network are used as the base network to extract features from the initial input image.
[0077] ② Vehicle localization network: It consists of 9 dilated convolutional layers, 4 deconvolutional layers, and finally outputs the result by a 1×1 ordinary convolutional layer. It obtains features from the feature extraction network and outputs a vehicle location distribution map with the same resolution as the network input image through 9 dilated convolutional layers and 4 deconvolutional layers.
[0078] ③ Vehicle counting network: Features are obtained from the base network, and the output is a vehicle density map with a length and width of 1 / 4 of the network input image through 6 dilated convolutional layers and one deconvolutional layer.
[0079] ④ Multi-layer candidate region network: The feature map output from the penultimate deconvolution layer of the vehicle localization network and the counting network is concatenated and used as the input of the multi-layer candidate region network. Through three dilated convolutional layers, the output is an attention map with the same resolution as the input image.
[0080] 2) Multi-scale recurrent attention mechanism:
[0081] The multi-layer candidate region network outputs an attention map, in which dense regions are identified. These regions are then cropped from the original image, enlarged, and subjected to inference operations again.
[0082] 3) Pre-trained network: The parameters of the ResNet-34 network trained on ImageNet data are used as the initialization of the base network.
[0083] 4) Generate training data:
[0084] Similar to object detection methods, each vehicle in the training image is tightly bounded by a rectangular detection box. The coordinates of the four vertices of this rectangle can then be obtained using the formula... Calculate the coordinates of the center point (where (The coordinates of the top-left and bottom-right vertices of the rectangle are used), and then a density map is generated using a Gaussian filter as the label.
[0085] 5) Model training:
[0086] The generated training data is used to train the counting network, the localization network, and the multi-layer candidate region network sequentially. For the cropped and enlarged regions determined by the multi-layer candidate region network, the same model is used for inference, without the need for further training.
[0087] 6) Fusion Weights Choice
[0088] In some embodiments, when the difference between the total number of vehicles and the predicted number of vehicles is less than or equal to M (M is a natural number, which can be 30), In other embodiments, when the difference between the total number of vehicles and the predicted number of vehicles is greater than M, .
[0089] 7) Network reasoning:
[0090] For each test image, the vehicle probability density map, vehicle localization map, and attention map can be obtained from the model inference. Several dense regions are obtained from the attention map. These regions are cropped from the original image and enlarged to N times their original size. These images are then used as input for re-inference, resulting in a new vehicle localization map and multiple candidate regions. The inference process ends when no new dense regions are found among the multiple candidate regions.
[0091] 8) Determine the vehicle location information in the image:
[0092] The vehicle localization network outputs a feature map. After performing non-maximum suppression (NMS) on the local peak points in the feature map, the vehicle coordinates can be obtained, which are then used as the final predicted vehicle coordinate position.
[0093] 9) Determine the number of vehicles in the image:
[0094] The final vehicle count result is determined by fusing the vehicle counting network and the vehicle positioning network.
[0095] As can be seen from the above, the image-based vehicle recognition method provided in this embodiment obtains the vehicle count density map, vehicle localization map, and dense candidate attention map corresponding to the input image through a designed three-branch deep neural network. The vehicle count density map yields the initial vehicle count value in the image; the vehicle localization map yields the position coordinates of each vehicle in the image; and the dense region candidate map yields several densely populated regions in the image. These regions are cropped from the original image, enlarged in resolution, and then input into the vehicle localization network and vehicle counting network to obtain more accurate vehicle localization results. This process is repeated multiple times until no dense regions remain in the image. Applying the vehicle recognition method provided in this embodiment to vehicle counting improves the applicability and accuracy of vehicle counting.
[0096] Based on the same inventive concept, this disclosure also provides an image-based vehicle recognition device, as described in the following embodiments. Since the principle by which this device embodiment solves the problem is similar to that of the method embodiment described above, the implementation of this device embodiment can refer to the implementation of the method embodiment described above, and repeated details will not be repeated.
[0097] Figure 5 This illustration shows a schematic diagram of an image-based vehicle recognition device according to an embodiment of the present disclosure, such as... Figure 5As shown, the device includes: a vehicle image acquisition module 501, a network prediction module 502, a vehicle recognition module 503, a dense region determination module 504, a dense region recognition module 505, a vehicle accurate recognition module 506, and a vehicle recognition result fusion module 507.
[0098] The system includes: a vehicle image acquisition module 501, used to acquire vehicle images, wherein the vehicle images contain one or more vehicles; a network prediction module 502, used to input the vehicle images into a trained vehicle recognition network, and output a vehicle position distribution map, a vehicle count density map, and a multi-scale candidate region attention map of the vehicle images; a vehicle recognition module 503, used to determine the vehicle localization result and vehicle count result of the vehicle images based on the vehicle position distribution map and vehicle count density map of the vehicle images; a dense region determination module 504, used to determine one or more dense regions in the vehicle images where vehicles are densely distributed, based on the multi-scale candidate region attention map of the vehicle images; and a dense region recognition module 505, used to acquire various... The system takes local images of dense regions, enlarges the resolution of each local image, and inputs them into the vehicle recognition network to output accurate vehicle location distribution maps and accurate vehicle count density maps for each dense region. The vehicle accurate recognition module 506 is used to determine the accurate vehicle location results and accurate vehicle count results for each dense region based on the accurate vehicle location distribution maps and accurate vehicle count density maps for each dense region. The vehicle recognition result fusion module 507 is used to replace the vehicle location results and vehicle count results of the corresponding regions in the vehicle image with the accurate vehicle location results and accurate vehicle count results for each dense region to obtain the accurate vehicle location results and accurate vehicle count results of the vehicle image.
[0099] In some embodiments, such as Figure 5As shown in the embodiments of this disclosure, the image-based vehicle recognition device may further include: a training data generation module 508, used to generate training data, wherein the training data includes: multiple vehicle images and corresponding vehicle position distribution maps, vehicle count density maps, and multi-scale candidate region attention maps; a model training module 509, used to train a vehicle recognition network composed of a feature extraction network, a vehicle localization network, a vehicle counting network, and a multi-layer candidate region network using the training data to obtain a trained vehicle recognition network, wherein the input data of the feature extraction network is the vehicle image, and the output data of the feature extraction network is the feature information of the vehicle image; the input data of the vehicle localization network is the feature information of the vehicle image, and the output data of the vehicle localization network is the vehicle position distribution map of the vehicle image; the input data of the vehicle counting network is the feature information of the vehicle image, and the output data of the vehicle counting network is the vehicle count density map of the vehicle image; the input data of the multi-layer candidate region network is the vehicle position distribution map and the vehicle count density map of the vehicle image, and the output data of the multi-layer candidate region network is one or more dense regions in the vehicle image where vehicles are densely distributed.
[0100] In some embodiments, the feature extraction network is the first 33 layers of a 34-layer ResNet-34 residual network; the vehicle localization network consists of 9 dilated convolutional layers, 4 deconvolutional layers, and 1×1 ordinary convolutional layer; the vehicle counting network consists of 6 dilated convolutional layers and 1 deconvolutional layer; and the multi-layer candidate region network consists of 3 dilated convolutional layers.
[0101] In some embodiments, such as Figure 5 As shown, the vehicle recognition module 503 includes: a vehicle positioning module 5031, used to determine the vehicle positioning result of the vehicle image based on the vehicle position distribution map of the vehicle image; a vehicle counting module 5032, used to determine a first vehicle counting result based on the vehicle position distribution map of the vehicle image, and to determine a second vehicle counting result based on the vehicle counting density map of the vehicle image; and a weighted average calculation module 5033, used to perform a weighted average of the first vehicle counting result and the second vehicle counting result to obtain the vehicle counting result of the vehicle image.
[0102] In some embodiments, the weighted average calculation module 5033 is further configured to: obtain the first weight coefficient of the vehicle positioning network and the second weight coefficient of the vehicle counting network; and perform a weighted average of the first vehicle counting result and the second vehicle counting result based on the first weight coefficient of the vehicle positioning network and the second weight coefficient of the vehicle counting network to obtain the vehicle counting result of the vehicle image.
[0103] In some embodiments, the vehicle positioning module 5031 is further configured to: transmit the vehicle location distribution map through a kernel of size 3 A 3-point average pooling operation, followed by a kernel size of 3 The maximum pooling operation of 3 is used to obtain the processed vehicle location distribution map; the processed vehicle location distribution map is compared with the unprocessed vehicle location distribution map at the pixel level, and the local peak points are determined according to the comparison results; the local peak points with response values greater than the preset threshold are determined as the vehicle positioning results.
[0104] It should be noted that the examples and application scenarios implemented by the above modules and steps are the same, but are not limited to the content disclosed in the above method embodiments. It should also be noted that the above modules, as part of an apparatus, can be executed in a computer system such as a set of computer-executable instructions.
[0105] Those skilled in the art will understand that various aspects of this disclosure can be implemented as a system, method, or program product. Therefore, various aspects of this disclosure can be specifically implemented in the following forms: a completely hardware implementation, a completely software implementation (including firmware, microcode, etc.), or a combination of hardware and software aspects, collectively referred to herein as a "circuit," "module," or "system."
[0106] The following reference Figure 6 To describe an electronic device 600 according to such an embodiment of the present disclosure. Figure 6 The electronic device 600 shown is merely an example and should not impose any limitation on the functionality and scope of use of the embodiments disclosed herein.
[0107] like Figure 6 As shown, the electronic device 600 is manifested in the form of a general-purpose computing device. The components of the electronic device 600 may include, but are not limited to: at least one processing unit 610, at least one storage unit 620, and a bus 630 connecting different system components (including storage unit 620 and processing unit 610).
[0108] The storage unit stores program code that can be executed by the processing unit 610, causing the processing unit 610 to perform the steps described in the "Exemplary Methods" section above according to various exemplary embodiments of this disclosure. For example, the processing unit 610 can perform the following steps in the above method embodiment: acquiring a vehicle image, wherein the vehicle image contains one or more vehicles; inputting the vehicle image into a trained vehicle recognition network, outputting a vehicle position distribution map, a vehicle count density map, and a multi-scale candidate region attention map of the vehicle image; determining the vehicle localization result and vehicle count result of the vehicle image based on the vehicle position distribution map and vehicle count density map of the vehicle image; determining one or more dense regions in the vehicle image where vehicles are densely distributed based on the multi-scale candidate region attention map of the vehicle image; acquiring local images of each dense region, and after enlarging the resolution of the local images of each dense region, inputting them into the vehicle recognition network, outputting the precise vehicle position distribution map and precise vehicle count density map of each dense region; determining the precise vehicle localization result and precise vehicle count result of each dense region based on the precise vehicle position distribution map and precise vehicle count density map of each dense region; replacing the vehicle localization result and vehicle count result of the corresponding region in the vehicle image with the precise vehicle localization result and precise vehicle count result of each dense region, respectively, to obtain the precise vehicle localization result and precise vehicle count result of the vehicle image.
[0109] Storage unit 620 may include readable media in the form of volatile storage units, such as random access memory (RAM) 6201 and / or cache memory 6202, and may further include read-only memory (ROM) 6203.
[0110] Storage unit 620 may also include a program / utility 6204 having a set (at least one) program module 6205, such program module 6205 including but not limited to: operating system, one or more application programs, other program modules and program data, each or some combination of these examples may include an implementation of a network environment.
[0111] Bus 630 can represent one or more of several types of bus structures, including a memory cell bus or memory cell controller, a peripheral bus, a graphics acceleration port, a processing unit, or a local bus using any of the various bus structures.
[0112] Electronic device 600 can also communicate with one or more external devices 640 (e.g., keyboard, pointing device, Bluetooth device, etc.), and with one or more devices that enable a user to interact with electronic device 600, and / or with any device that enables electronic device 600 to communicate with one or more other computing devices (e.g., router, modem, etc.). This communication can be performed via input / output (I / O) interface 650. Furthermore, electronic device 600 can also communicate with one or more networks (e.g., local area network (LAN), wide area network (WAN), and / or public networks, such as the Internet) via network adapter 660. As shown, network adapter 660 communicates with other modules of electronic device 600 via bus 630. It should be understood that, although not shown in the figures, other hardware and / or software modules can be used in conjunction with electronic device 600, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems.
[0113] From the above description of the embodiments, those skilled in the art will readily understand that the exemplary embodiments described herein can be implemented by software or by combining software with necessary hardware. Therefore, the technical solutions according to the embodiments of this disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (such as a CD-ROM, USB flash drive, external hard drive, etc.) or on a network, including several instructions to cause a computing device (such as a personal computer, server, terminal device, or network device, etc.) to execute the methods according to the embodiments of this disclosure.
[0114] In particular, according to embodiments of this disclosure, the process described above with reference to the flowchart can be implemented as a computer program product, which includes a computer program that, when executed by a processor, implements the above-described image-based vehicle recognition method.
[0115] In exemplary embodiments of this disclosure, a computer-readable storage medium is also provided, which may be a readable signal medium or a readable storage medium. Figure 7 This illustration shows a schematic diagram of a computer-readable storage medium according to an embodiment of the present disclosure, such as... Figure 7 As shown, the computer-readable storage medium 700 stores a program product capable of implementing the methods described above in this disclosure. In some possible embodiments, various aspects of this disclosure may also be implemented as a program product comprising program code that, when the program product is run on a terminal device, causes the terminal device to perform the steps described in the "Exemplary Methods" section of this specification according to various exemplary embodiments of this disclosure.
[0116] More specific examples of computer-readable storage media in this disclosure may include, but are not limited to: electrical connections having one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.
[0117] In this disclosure, a computer-readable storage medium may include a data signal propagated in baseband or as part of a carrier wave, carrying readable program code. Such propagated data signals may take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. A readable signal medium may also be any readable medium other than a readable storage medium, capable of transmitting, propagating, or transmitting a program for use by or in connection with an instruction execution system, apparatus, or device.
[0118] Optionally, the program code contained on the computer-readable storage medium may be transmitted using any suitable medium, including but not limited to wireless, wired, optical fiber, RF, etc., or any suitable combination thereof.
[0119] In practical implementation, program code for performing the operations of this disclosure can be written in any combination of one or more programming languages, including object-oriented programming languages such as Java and C++, and conventional procedural programming languages such as C or similar languages. The program code can execute entirely on the user's computing device, partially on the user's device, as a standalone software package, partially on the user's computing device and partially on a remote computing device, or entirely on a remote computing device or server. In cases involving remote computing devices, the remote computing device can be connected to the user's computing device via any type of network, including a local area network (LAN) or a wide area network (WAN), or it can be connected to an external computing device (e.g., via the Internet using an Internet service provider).
[0120] It should be noted that although several modules or units for the device used to perform actions have been mentioned in the detailed description above, this division is not mandatory. In fact, according to embodiments of this disclosure, the features and functions of two or more modules or units described above can be embodied in one module or unit. Conversely, the features and functions of one module or unit described above can be further divided and embodied by multiple modules or units.
[0121] Furthermore, although the steps of the method in this disclosure are described in a specific order in the accompanying drawings, this does not require or imply that the steps must be performed in that specific order, or that all the steps shown must be performed to achieve the desired result. Additional or alternative steps may be omitted, multiple steps may be combined into one step, and / or a step may be broken down into multiple steps.
[0122] From the above description of the embodiments, those skilled in the art will readily understand that the exemplary embodiments described herein can be implemented by software or by combining software with necessary hardware. Therefore, the technical solutions according to the embodiments of this disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (such as a CD-ROM, USB flash drive, external hard drive, etc.) or on a network, including several instructions to cause a computing device (such as a personal computer, server, mobile terminal, or network device, etc.) to execute the methods according to the embodiments of this disclosure.
[0123] Other embodiments of this disclosure will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This disclosure is intended to cover any variations, uses, or adaptations of this disclosure that follow the general principles of this disclosure and include common knowledge or customary techniques in the art not disclosed herein. The specification and examples are to be considered exemplary only, and the true scope and spirit of this disclosure are indicated by the appended claims.
Claims
1. An image-based vehicle recognition method, characterized in that, include: Acquire vehicle images, wherein the vehicle images contain one or more vehicles; The vehicle image is input into a trained vehicle recognition network, which outputs a vehicle location distribution map, a vehicle count density map, and a multi-scale candidate region attention map. Based on the vehicle location distribution map and vehicle count density map of the vehicle image, determine the vehicle location result and vehicle count result of the vehicle image; Based on the multi-scale candidate region attention map of the vehicle image, determine one or more dense regions in the vehicle image where vehicles are densely distributed; Local images of each dense region are acquired, and after the resolution of the local images of each dense region is increased, they are input into the vehicle recognition network to output a precise vehicle location distribution map and a precise vehicle count density map of each dense region. Based on the precise vehicle location distribution map and precise vehicle count density map of each dense area, the precise vehicle location result and precise vehicle count result of each dense area are determined; By using the precise vehicle location results and precise vehicle count results of each dense area, the vehicle location results and vehicle count results of the corresponding areas in the vehicle image are replaced respectively, to obtain the precise vehicle location results and precise vehicle count results of the vehicle image. The vehicle recognition network is determined through the following steps: generating training data, wherein the training data includes: multiple vehicle images and corresponding vehicle location distribution maps, vehicle count density maps, and multi-scale candidate region attention maps; training the vehicle recognition network, which is a combination of a feature extraction network, a vehicle localization network, a vehicle counting network, and a multi-layer candidate region network, using the training data to obtain a trained vehicle recognition network, wherein the input data of the feature extraction network is the vehicle image, and the output data of the feature extraction network is the feature information of the vehicle image; the input data of the vehicle localization network is the feature information of the vehicle image, and the output data of the vehicle localization network is the vehicle location distribution map of the vehicle image; the input data of the vehicle counting network is the feature information of the vehicle image, and the output data of the vehicle counting network is the vehicle count density map of the vehicle image; the input data of the multi-layer candidate region network is the vehicle location distribution map and the vehicle count density map of the vehicle image, and the output data of the multi-layer candidate region network is one or more densely distributed regions of vehicles in the vehicle image. The feature extraction network consists of the first 33 layers of a 34-layer ResNet-34 residual network; the vehicle localization network consists of 9 dilated convolutional layers, 4 deconvolutional layers, and 1×1 ordinary convolutional layer; the vehicle counting network consists of 6 dilated convolutional layers and 1 deconvolutional layer; and the multi-layer candidate region network consists of 3 dilated convolutional layers.
2. The image-based vehicle recognition method according to claim 1, characterized in that, Based on the vehicle location distribution map and vehicle count density map of the vehicle image, determine the vehicle location result and vehicle count result of the vehicle image, including: Based on the vehicle location distribution map of the vehicle image, determine the vehicle positioning result of the vehicle image; The first vehicle count result is determined based on the vehicle location distribution map of the vehicle image, and the second vehicle count result is determined based on the vehicle count density map of the vehicle image. The vehicle count result of the vehicle image is obtained by taking a weighted average of the first vehicle count result and the second vehicle count result.
3. The image-based vehicle recognition method according to claim 2, characterized in that, The vehicle count result of the vehicle image is obtained by weighted averaging the first vehicle count result and the second vehicle count result, including: Obtain the first weight coefficient of the vehicle localization network and the second weight coefficient of the vehicle counting network; Based on the first weight coefficient of the vehicle positioning network and the second weight coefficient of the vehicle counting network, a weighted average is performed on the first vehicle counting result and the second vehicle counting result to obtain the vehicle counting result of the vehicle image.
4. The image-based vehicle recognition method according to claim 2, characterized in that, Based on the vehicle location distribution map of the vehicle image, the vehicle positioning result of the vehicle image is determined, including: The vehicle location distribution map is processed through a kernel size of 3. A 3-point average pooling operation, followed by a kernel size of 3 The maximum pooling operation of 3 is used to obtain the processed vehicle location distribution map; The processed vehicle location map is compared with the unprocessed vehicle location map at the pixel level, and local peak points are determined based on the comparison results. Local peak points with response values greater than a preset threshold are identified as vehicle positioning results.
5. An image-based vehicle recognition system, characterized in that, include: An image acquisition device for acquiring vehicle images, wherein the vehicle images include one or more vehicles; An image processing device is used to input the vehicle image into a trained vehicle recognition network, output a vehicle position distribution map, a vehicle count density map, and a multi-scale candidate region attention map of the vehicle image, determine the vehicle localization result and vehicle count result of the vehicle image based on the vehicle position distribution map and vehicle count density map of the vehicle image, determine one or more dense regions with dense vehicle distribution in the vehicle image based on the multi-scale candidate region attention map of the vehicle image, acquire local images of each dense region, enlarge the resolution of each local image of each dense region, input it into the vehicle recognition network, output a precise vehicle position distribution map and a precise vehicle count density map of each dense region, determine the precise vehicle localization result and precise vehicle count result of each dense region based on the precise vehicle position distribution map and precise vehicle count density map of each dense region, and finally replace the vehicle localization result and vehicle count result of the corresponding region in the vehicle image with the precise vehicle localization result and precise vehicle count result of the vehicle image. The vehicle recognition network is determined through the following steps: generating training data, wherein the training data includes: multiple vehicle images and corresponding vehicle location distribution maps, vehicle count density maps, and multi-scale candidate region attention maps; training the vehicle recognition network, which is a combination of a feature extraction network, a vehicle localization network, a vehicle counting network, and a multi-layer candidate region network, using the training data to obtain a trained vehicle recognition network, wherein the input data of the feature extraction network is the vehicle image, and the output data of the feature extraction network is the feature information of the vehicle image; the input data of the vehicle localization network is the feature information of the vehicle image, and the output data of the vehicle localization network is the vehicle location distribution map of the vehicle image; the input data of the vehicle counting network is the feature information of the vehicle image, and the output data of the vehicle counting network is the vehicle count density map of the vehicle image; the input data of the multi-layer candidate region network is the vehicle location distribution map and the vehicle count density map of the vehicle image, and the output data of the multi-layer candidate region network is one or more densely distributed regions of vehicles in the vehicle image. The feature extraction network consists of the first 33 layers of a 34-layer ResNet-34 residual network; the vehicle localization network consists of 9 dilated convolutional layers, 4 deconvolutional layers, and 1×1 ordinary convolutional layer; the vehicle counting network consists of 6 dilated convolutional layers and 1 deconvolutional layer; and the multi-layer candidate region network consists of 3 dilated convolutional layers.
6. An image-based vehicle recognition device, characterized in that, include: A vehicle image acquisition module is used to acquire vehicle images, wherein the vehicle images contain one or more vehicles; The network prediction module is used to input the vehicle image into a trained vehicle recognition network and output a vehicle position distribution map, a vehicle count density map, and a multi-scale candidate region attention map of the vehicle image. The vehicle recognition module is used to determine the vehicle location result and vehicle count result of the vehicle image based on the vehicle location distribution map and vehicle count density map of the vehicle image; The dense region determination module is used to determine one or more dense regions in the vehicle image where the vehicles are densely distributed, based on the multi-scale candidate region attention map of the vehicle image. The dense area recognition module is used to acquire local images of each dense area, and after enlarging the resolution of the local images of each dense area, input them into the vehicle recognition network, and output the accurate vehicle location distribution map and the accurate vehicle count density map of each dense area. The vehicle precision identification module is used to determine the precise vehicle location results and precise vehicle count results for each dense area based on the precise vehicle location distribution map and precise vehicle count density map of each dense area. The vehicle recognition result fusion module is used to replace the vehicle location results and vehicle count results of the corresponding areas in the vehicle image with the accurate vehicle location results and accurate vehicle count results of each dense area, respectively, to obtain the accurate vehicle location results and accurate vehicle count results of the vehicle image. The vehicle recognition network is determined through the following steps: generating training data, wherein the training data includes: multiple vehicle images and corresponding vehicle location distribution maps, vehicle count density maps, and multi-scale candidate region attention maps; training the vehicle recognition network, which is a combination of a feature extraction network, a vehicle localization network, a vehicle counting network, and a multi-layer candidate region network, using the training data to obtain a trained vehicle recognition network, wherein the input data of the feature extraction network is the vehicle image, and the output data of the feature extraction network is the feature information of the vehicle image; the input data of the vehicle localization network is the feature information of the vehicle image, and the output data of the vehicle localization network is the vehicle location distribution map of the vehicle image; the input data of the vehicle counting network is the feature information of the vehicle image, and the output data of the vehicle counting network is the vehicle count density map of the vehicle image; the input data of the multi-layer candidate region network is the vehicle location distribution map and the vehicle count density map of the vehicle image, and the output data of the multi-layer candidate region network is one or more densely distributed regions of vehicles in the vehicle image. The feature extraction network consists of the first 33 layers of a 34-layer ResNet-34 residual network; the vehicle localization network consists of 9 dilated convolutional layers, 4 deconvolutional layers, and 1×1 ordinary convolutional layer; the vehicle counting network consists of 6 dilated convolutional layers and 1 deconvolutional layer; and the multi-layer candidate region network consists of 3 dilated convolutional layers.
7. An electronic device, characterized in that, include: processor; as well as Memory for storing the executable instructions of the processor; The processor is configured to execute the image-based vehicle recognition method according to any one of claims 1 to 4 by executing the executable instructions.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the image-based vehicle recognition method according to any one of claims 1 to 4.