Low-illumination traffic image enhancement method based on machine learning
By automatically adjusting the auxiliary light source and shooting angle in a low-illumination environment, the problem that the existing technology of low-illumination traffic image enhancement methods cannot accurately capture vehicle information, achieving higher data accuracy and better driving experience.
Patent Information
- Application Number
- CN202411276922.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-12
- Publication Date
- 2024-12-27
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The existing low-illumination traffic image enhancement method based on machine learning cannot automatically take pictures based on vehicle locations in low-illumination environments and judge the accuracy of image data, resulting in missed or incorrect shooting, affecting the visual effects of traffic monitoring and autonomous driving applications.
By setting the detection range, obtaining the target traffic image, performing information extraction and comparison strategies. If the data is inconsistent, use the image enhancement training model to adjust the fill light, and automatically adjust the brightness and shooting angle of the auxiliary light source to ensure the accuracy of the image data.
Automatically extract license plate information in low-illumination environments, reduce missed or incorrect shooting, improve data accuracy, reduce the risk of car owners receiving records that do not belong to their own violations, and improve driving experience and data accuracy.
Smart Images

Figure CN119205534A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of traffic image acquisition, and in particular to a low-illumination traffic image enhancement method based on machine learning. Background Art
[0002] Under low-light conditions, traffic images often face low contrast and high noise, which makes traditional image enhancement technology limited in effect. Machine learning-based methods can effectively improve such problems, including: deep learning models, adaptive brightness adjustment, noise suppression, image super-resolution, feature learning and transfer learning, as well as data enhancement and synthesis. By combining the powerful capabilities of machine learning, the quality of low-light traffic images can be significantly improved, thereby improving the visual effects in applications such as traffic monitoring and autonomous driving.
[0003] Convolutional neural networks (CNNs) are used to extract features from low-light images and perform image enhancement. Generative adversarial networks (GANs) use adversarial learning to train a generator and a discriminator to enhance low-light images. Machine learning models can learn how to adaptively adjust the brightness and contrast of images according to different lighting conditions to avoid overexposure or over-darkening. Deep learning methods are used for noise modeling and denoising. Combined with image super-resolution technology, the resolution of low-light images is improved to make details clearer. Commonly used methods include super-resolution convolutional neural networks (SRCNN) and generative adversarial networks (SRGANs). Pre-trained deep learning models (such as models trained on large-scale datasets) are used for transfer learning to improve image quality under low-light conditions. Enhanced datasets are used for training to improve the generalization ability of the model under low-light conditions. Synthetic low-light images are generated as part of the training data, which can also improve the robustness of the model.
[0004] The existing low-light traffic image enhancement method based on machine learning cannot take pictures according to the position of the vehicle in a low-light environment, and cannot determine whether the data automatically recognized by the image collected by the camera is accurate. It cannot automatically fill in the light for the image corresponding to the inaccurate data according to the vehicle's environment and position. It cannot automatically adjust the brightness of the auxiliary light source and the shooting angle according to the vehicle's own lighting brightness and the vehicle's environment. It is easy to miss or take the wrong picture, so the owner can only manually refute the violation record when encountering one that does not belong to him. Its practicality has certain limitations. Summary of the invention
[0005] The present invention provides a low-light traffic image enhancement method based on machine learning, which is used to promote the solution of the problems mentioned in the background technology.
[0006] The present invention provides the following technical solution: a low-light traffic image enhancement method based on machine learning, comprising:
[0007] Set the detection range;
[0008] If there is no vehicle within the detection range, traffic image capture will not be performed;
[0009] If there is a vehicle within the detection range, the target traffic image is acquired;
[0010] According to the target traffic image, the information extraction strategy is used to form the extraction data;
[0011] If there is extracted data, the information comparison strategy is executed to form comparison data;
[0012] If the comparison data determines that the data are consistent, the extracted data is stored in the database;
[0013] If the comparison data determines that the data is inconsistent, the image enhancement training model is obtained, and the fill light adjustment strategy is executed to form adjustment data;
[0014] If the extracted data does not exist, the image enhancement training model is obtained, and the fill light adjustment strategy is executed to form adjustment data;
[0015] According to the adjustment data and the image enhancement training model, an adjustment traffic image is formed;
[0016] The adjusted traffic image is identified as the target traffic image, and the information extraction strategy is repeatedly executed.
[0017] As an optional solution of the low-light traffic image enhancement method based on machine learning described in the present invention, the information extraction strategy is specifically:
[0018] Set target areas;
[0019] Extract information data in the target area and define it as target data;
[0020] Get character database;
[0021] Set the number of analyses;
[0022] According to the number of analyses, the target data is divided into several sub-target data;
[0023] Compare each sub-target data with all the data in the character database one by one;
[0024] If there is data in the character database that is consistent with the sub-target data, the data is defined as the analysis sub-data;
[0025] If there is no data consistent with the sub-target data in the character database, the data is defined as missing data;
[0026] If there is no missing data in the target data, the target data will be identified as extracted data;
[0027] If there is missing data in the target data, it is determined that there is no extracted data.
[0028] As an optional solution of the low-light traffic image enhancement method based on machine learning described in the present invention, the information comparison strategy is specifically:
[0029] Get the collection time point corresponding to the extracted data and set it as the current time point;
[0030] Obtain all the collection time points corresponding to the extracted data and set them as analysis time points;
[0031] Calculate the analysis duration, analysis duration = current time point - analysis time point;
[0032] The extracted data corresponding to the analysis time point with the smallest extraction value is defined as the previous extracted data;
[0033] The extracted data corresponding to the current time point is defined as the post-extracted data;
[0034] Obtain vehicle information corresponding to the previously extracted data, which is defined as the previous vehicle information;
[0035] If the vehicle information corresponding to the data is extracted later, it is defined as the later vehicle information;
[0036] If the rear vehicle data = the front extraction data, the data are determined to be consistent;
[0037] If the rear vehicle data ≠ the front extracted data, it is determined that the data are inconsistent.
[0038] As an optional solution of the low-light traffic image enhancement method based on machine learning described in the present invention, the image enhancement training model obtained includes a fill light model, specifically:
[0039] Set the collection area;
[0040] Identify vehicles within the collection area as analysis vehicles;
[0041] Obtain the number of analyzed vehicles in the collection area, which is defined as the number of vehicles;
[0042] If the number of vehicles = 1, then the illumination of the analyzed vehicle is obtained and is defined as the analysis brightness;
[0043] Obtaining all illumination levels of the analyzed vehicle, including a first brightness and a second brightness;
[0044] If the analyzed brightness is the first brightness, a low brightness adjustment strategy is executed;
[0045] If the analyzed brightness is the second brightness, a high brightness adjustment strategy is executed;
[0046] If the number of vehicles is greater than 1, a vehicle is randomly selected as the target vehicle;
[0047] If there are vehicles on both sides of the target vehicle, the low brightness adjustment strategy will be executed;
[0048] If there are no vehicles on both sides of the target vehicle, the high brightness adjustment strategy will be executed.
[0049] As an optional solution of the low-light traffic image enhancement method based on machine learning described in the present invention, the low-light adjustment strategy is specifically:
[0050] Get auxiliary light source;
[0051] Extract the target point of auxiliary light source;
[0052] Obtain the center point of the target area and set it as the first determination point;
[0053] connecting the target point and the first determination point to form a first analysis line;
[0054] Obtain all low brightness of auxiliary light sources and set them as target low brightness;
[0055] Obtain the light range corresponding to the low brightness of each target and set it as the judgment range;
[0056] Extracting a determination edge line where the first analysis line is within the determination range and defining it as a target adjustment edge line;
[0057] Extract the target low brightness corresponding to the target adjustment edge line and set it as the adjustment brightness;
[0058] Control the auxiliary light source to adjust the brightness.
[0059] As an optional solution of the low-light traffic image enhancement method based on machine learning described in the present invention, the high brightness adjustment strategy is specifically:
[0060] Get auxiliary light source;
[0061] Extract the target point of auxiliary light source;
[0062] Obtain the center point of the target area and set it as the first determination point;
[0063] connecting the target point and the first determination point to form a first analysis line;
[0064] Obtaining the sight line position point of the driver of the target vehicle as the second determination point;
[0065] Connect the target point and the second determination point to form a second analysis line;
[0066] defining the range between the first analysis line and the second analysis line as the limit range;
[0067] Obtain all high brightness of auxiliary light sources and set them as target high brightness;
[0068] Obtain the light range corresponding to the high brightness of each target and set it as the judgment range;
[0069] Extract the boundary line of each judgment range and set it as the target boundary line;
[0070] Extract all target edges within the limit range and define them as judgment edges;
[0071] Extracting a determination edge line where the first analysis line is within the determination range and defining it as a target adjustment edge line;
[0072] Extract the target high brightness corresponding to the target adjustment edge line and set it as the adjustment brightness;
[0073] Control the auxiliary light source to adjust the brightness.
[0074] As an optional solution of the low-light traffic image enhancement method based on machine learning described in the present invention, wherein: the acquisition of the image enhancement training model also includes an image enhancement model, specifically:
[0075] Obtain the first analysis line of the auxiliary light source;
[0076] Obtain the angle between the first analysis line and the ground, which is defined as the projection angle;
[0077] Obtain all projection angles of auxiliary light sources to form a light set;
[0078] Acquire all shooting angles that the image acquisition device can adjust to form an image acquisition set;
[0079] Mapping the elements in the light set to the elements in the image acquisition set one by one to form an adjustment set;
[0080] According to each element in the adjustment set in turn, the target image is collected and determined as a judgment image;
[0081] Execute the information extraction strategy for each judgment image to form extraction data;
[0082] If there is extracted data, the information comparison strategy is executed to form comparison data;
[0083] If the comparison data determines that the data is consistent, the determined image is considered a valid image;
[0084] If the comparison data determines that the data is inconsistent, the determined image is deemed to be an invalid image;
[0085] If the extracted data does not exist, the determined image is deemed as an invalid image;
[0086] Extract all valid images;
[0087] Extract the elements in the adjustment set corresponding to each valid image and define them as valid elements;
[0088] Obtain appearance information of the target vehicle;
[0089] According to the appearance information of different target vehicles, all corresponding valid elements are integrated respectively to form a valid set.
[0090] As an optional solution of the low-light traffic image enhancement method based on machine learning described in the present invention, the fill light adjustment strategy is specifically:
[0091] Obtain the position of the target vehicle and set it as the target position point;
[0092] Get the collection area;
[0093] If the target location point is within the acquisition area, the fill light model in the image enhancement training model is executed;
[0094] If the target position point is not within the acquisition area, the fill light model is not executed, and the target position point continues to be acquired until the target position point is within the acquisition area, and then the fill light model in the image enhancement training model is executed.
[0095] As an optional solution of the low-light traffic image enhancement method based on machine learning of the present invention, wherein: the adjustment of the traffic image is formed according to the adjustment data and the image enhancement training model, specifically:
[0096] Get the adjusted brightness;
[0097] Obtain appearance information of the target vehicle and set it as target information;
[0098] Obtain the image enhancement model in the image enhancement training model;
[0099] Extract the valid set corresponding to the target information and define it as the target valid set;
[0100] According to each element in the effective target set, the projection angle of the auxiliary light source and the shooting angle of the image acquisition device are adjusted;
[0101] Obtain the traffic image corresponding to each element in the target valid set and define it as the adjustment image;
[0102] All adjustment images are integrated to form an adjustment image set.
[0103] The present invention has the following beneficial effects:
[0104] 1. The low-light traffic image enhancement method based on machine learning takes pictures according to the position of the vehicle in a low-light environment, automatically extracts the license plate information in the image, and extracts the historical image of the license plate information at the same time, and determines whether the historical image is consistent with the image taken this time. If they are consistent, the image can be directly stored. If they are inconsistent, it means that the recognized information may be affected by the shooting angle or poor light, resulting in data recognition errors. It is necessary to re-shoot with fill light to reduce the situation of missed or erroneous shooting, thereby reducing the situation where car owners receive violation records that do not belong to them, improving the driving experience of car owners, reducing conflicts between car owners and service personnel, and improving data accuracy.
[0105] 2. This low-light traffic image enhancement method based on machine learning automatically brings the vehicle into the fill light model in the image enhancement training model for the image corresponding to the data recognition error. According to the position of the vehicle and the vehicle's own lighting brightness, and whether there are other vehicles on both sides of the vehicle, it automatically determines the brightness adjustment strategy corresponding to the vehicle, and automatically adjusts the brightness of the auxiliary light source to reduce the situation of missed shots or erroneous shots due to insufficient light, thereby reducing the situation where car owners receive violation records that do not belong to them. At the same time, it also avoids the impact of the use of auxiliary light sources on the driver's driving vision as much as possible, thereby reducing accidents, improving the driver's driving experience, reducing conflicts between car owners and service personnel, and improving data accuracy.
[0106] 3. The low-light traffic image enhancement method based on machine learning simulates different light angles and shooting angles, shoots vehicles with different appearances, extracts the light angles and shooting angles with the highest data accuracy, and automatically extracts all light angles and shooting angles with the highest data accuracy corresponding to the appearance of the vehicle by obtaining the appearance of the vehicle, and automatically adjusts the light angle and shooting angle of the auxiliary light source to shoot the corresponding image, and then re-judges whether the data of the shot image is accurate, thereby reducing the situation of missed shots or erroneous shots caused by shooting angles or insufficient light, thereby reducing the situation where car owners receive violation records that do not belong to them, and at the same time, it also avoids the use of auxiliary light sources as much as possible. The influence on the driving vision of the car owner, thereby reducing accidents, improving the driving experience of the car owner, reducing conflicts between the car owner and the service personnel, and improving data accuracy. BRIEF DESCRIPTION OF THE DRAWINGS
[0107] Figure 1 This is a flow chart of the low-light traffic image enhancement method based on machine learning of the present invention. DETAILED DESCRIPTION
[0108] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0109] Embodiment 1, a low-light traffic image enhancement method based on machine learning, see Figure 1 ,include:
[0110] Setting a detection range, wherein the detection range is a shooting range of the camera for shooting target data of the vehicle;
[0111] If there is no vehicle within the detection range, traffic image capture will not be performed;
[0112] If there is a vehicle within the detection range, the target traffic image is acquired;
[0113] According to the target traffic image, the information extraction strategy is used to form the extraction data;
[0114] If there is extracted data, the information comparison strategy is executed to form comparison data;
[0115] If the comparison data determines that the data is consistent, the extracted data will be stored in the database, which means that the extracted data is correctly identified and there is no deviation in the identified information, so the data can be directly stored;
[0116] If the comparison data determines that the data is inconsistent, the image enhancement training model is obtained, and the fill light adjustment strategy is executed to form the adjusted data, which means that the extracted data recognition is wrong, the recognized information is biased, and the data cannot be directly stored;
[0117] If the extracted data does not exist, the image enhancement training model is obtained, and the fill light adjustment strategy is executed to form adjustment data;
[0118] According to the adjustment data and the image enhancement training model, an adjustment traffic image is formed;
[0119] The adjusted traffic image is identified as the target traffic image, and the information extraction strategy is repeatedly executed.
[0120] Through the above method, photos are taken according to the position of the vehicle in a low-light environment, and it is determined whether the data automatically recognized by the image collected by the camera is accurate. For the images corresponding to the inaccurate data, fill-in light shooting is automatically performed again according to the environment and position of the vehicle. The brightness of the auxiliary light source and the shooting angle are automatically adjusted according to the vehicle's own lighting brightness and the vehicle's environment to reduce missed shots or erroneous shots, thereby reducing the situation where car owners receive violation records that do not belong to them, improving the driving experience of car owners, reducing conflicts between car owners and service personnel, and improving data accuracy.
[0121] Embodiment 2: This embodiment is an improvement made on the basis of Embodiment 1. The low-light traffic image enhancement method based on machine learning, the information extraction strategy is specifically:
[0122] Setting a target area, wherein the target area is a license plate location area;
[0123] Extract information data in the target area and define it as target data;
[0124] Obtaining a character database, wherein the character database is a database used to form license plate information, including province abbreviations and letters;
[0125] Set the number of analyses, which is 1;
[0126] According to the number of analyses, the target data is divided into several sub-target data;
[0127] Compare each sub-target data with all the data in the character database one by one;
[0128] If there is data in the character database that is consistent with the sub-target data, the data is defined as the analysis sub-data;
[0129] If there is no data consistent with the sub-target data in the character database, the data is defined as missing data;
[0130] If there is no missing data in the target data, the target data will be identified as extracted data;
[0131] If there is missing data in the target data, it is determined that there is no extracted data.
[0132] This embodiment also provides that the information comparison strategy is specifically:
[0133] Get the collection time point corresponding to the extracted data and set it as the current time point;
[0134] Obtain all the collection time points corresponding to the extracted data and set them as analysis time points;
[0135] Calculate the analysis duration, analysis duration = current time point - analysis time point;
[0136] The extracted data corresponding to the analysis time point with the smallest extraction value is defined as the previous extracted data;
[0137] The extracted data corresponding to the current time point is defined as the post-extracted data;
[0138] Acquire vehicle information corresponding to the previously extracted data, which is defined as the previous vehicle information, wherein the vehicle information includes vehicle appearance, vehicle brand, and vehicle owner;
[0139] If the vehicle information corresponding to the data is extracted later, it is defined as the later vehicle information;
[0140] If the rear vehicle data = the front extraction data, the data are determined to be consistent;
[0141] If the rear vehicle data ≠ the front extracted data, it is determined that the data are inconsistent.
[0142] Embodiment 3: This embodiment is an improvement made on the basis of Embodiment 2. In this embodiment, the image enhancement training model is obtained, including a fill light model, specifically:
[0143] Set a capture area, where the capture area is the maximum range that the camera can capture at the current angle and position;
[0144] Identify vehicles within the collection area as analysis vehicles;
[0145] Obtain the number of analyzed vehicles in the collection area, which is defined as the number of vehicles;
[0146] If the number of vehicles = 1, the illumination of the analyzed vehicle is obtained and defined as the analysis brightness, where the illumination is the brightness of the vehicle's headlights;
[0147] Obtaining all illuminations of the analyzed vehicle, including a first brightness and a second brightness, wherein the first brightness is the low beam and the second brightness is the high beam;
[0148] If the analyzed brightness is the first brightness, a low brightness adjustment strategy is executed;
[0149] If the analyzed brightness is the second brightness, a high brightness adjustment strategy is executed;
[0150] If the number of vehicles is greater than 1, a vehicle is randomly selected as the target vehicle;
[0151] If there are vehicles on both sides of the target vehicle, the low brightness adjustment strategy will be executed, which means that there are auxiliary light sources provided by other vehicles on both sides of the vehicle to be photographed, and no additional auxiliary fill light is needed;
[0152] If there are no vehicles on both sides of the target vehicle, the high brightness adjustment strategy will be executed, which means that there are no auxiliary light sources provided by other vehicles on both sides of the vehicle to be photographed, and additional auxiliary fill light is required.
[0153] The low brightness adjustment strategy is specifically as follows:
[0154] Acquire an auxiliary light source, where the auxiliary light source is a fill light that needs to be turned on for fill light when the camera cannot capture a clear image under natural light;
[0155] Extracting a target point of the auxiliary light source, wherein the target point is the center point of the light projected by the auxiliary light source;
[0156] Obtain the center point of the target area and set it as the first determination point;
[0157] connecting the target point and the first determination point to form a first analysis line;
[0158] Obtain all low brightness of auxiliary light sources and set them as target low brightness;
[0159] Obtaining the light range corresponding to the low brightness of each target and defining it as the determination range, wherein the light range is the maximum range that the auxiliary light source can illuminate at the target brightness;
[0160] Extracting a determination edge line where the first analysis line is within the determination range and defining it as a target adjustment edge line;
[0161] Extract the target low brightness corresponding to the target adjustment edge line and set it as the adjustment brightness;
[0162] Control the auxiliary light source to adjust the brightness.
[0163] The high brightness adjustment strategy is specifically as follows:
[0164] Acquire an auxiliary light source, where the auxiliary light source is a fill light that needs to be turned on for fill light when the camera cannot capture a clear image under natural light;
[0165] Extracting a target point of the auxiliary light source, wherein the target point is the center point of the light projected by the auxiliary light source;
[0166] Obtain the center point of the target area and set it as the first determination point;
[0167] connecting the target point and the first determination point to form a first analysis line;
[0168] Obtaining the sight line position point of the driver of the target vehicle as the second determination point;
[0169] Connect the target point and the second determination point to form a second analysis line;
[0170] defining the range between the first analysis line and the second analysis line as the limit range;
[0171] Obtain all high brightness of auxiliary light sources and set them as target high brightness;
[0172] Obtain the light range corresponding to the high brightness of each target and define it as the determination range, wherein the light range is the maximum range that the auxiliary light source can illuminate at the target brightness;
[0173] Extract the boundary line of each judgment range and set it as the target boundary line;
[0174] Extract all target edges within the limit range and define them as judgment edges;
[0175] Extracting a determination edge line where the first analysis line is within the determination range and defining it as a target adjustment edge line;
[0176] Extract the target high brightness corresponding to the target adjustment edge line and set it as the adjustment brightness;
[0177] Control the auxiliary light source to adjust the brightness.
[0178] This embodiment also provides that the acquisition of the image enhancement training model also includes an image enhancement model, specifically:
[0179] Obtain the first analysis line of the auxiliary light source;
[0180] Obtain the angle between the first analysis line and the ground, which is defined as the projection angle;
[0181] Obtain all projection angles of auxiliary light sources to form a light set;
[0182] Acquire all shooting angles that can be adjusted by an image acquisition device to form an image acquisition set, wherein the image acquisition device is a camera;
[0183] Mapping the elements in the light set to the elements in the image acquisition set one by one to form an adjustment set;
[0184] According to each element in the adjustment set in turn, the target image is collected and determined as a judgment image;
[0185] Execute the information extraction strategy for each judgment image to form extraction data;
[0186] If there is extracted data, the information comparison strategy is executed to form comparison data;
[0187] If the comparison data determines that the data is consistent, the determined image is considered a valid image;
[0188] If the comparison data determines that the data is inconsistent, the determined image is deemed to be an invalid image;
[0189] If the extracted data does not exist, the determined image is deemed as an invalid image;
[0190] Extract all valid images;
[0191] Extract the elements in the adjustment set corresponding to each valid image and define them as valid elements;
[0192] Acquire appearance information of the target vehicle, wherein the appearance information includes vehicle height, vehicle width, and license plate installation position;
[0193] According to the appearance information of different target vehicles, all corresponding valid elements are integrated respectively to form a valid set.
[0194] Embodiment 4: This embodiment is an improvement made on the basis of Embodiment 3. In this embodiment, the fill light adjustment strategy is specifically as follows:
[0195] Obtain the position of the target vehicle and set it as the target position point;
[0196] Get the collection area;
[0197] If the target location point is within the acquisition area, the fill light model in the image enhancement training model is executed;
[0198] If the target position point is not within the acquisition area, the fill light model is not executed, and the target position point continues to be acquired until the target position point is within the acquisition area, and then the fill light model in the image enhancement training model is executed.
[0199] This embodiment also provides that the adjusting traffic image is formed according to the adjustment data and the image enhancement training model, specifically:
[0200] Get the adjusted brightness;
[0201] Obtain appearance information of the target vehicle and set it as target information;
[0202] Obtain the image enhancement model in the image enhancement training model;
[0203] Extract the valid set corresponding to the target information and define it as the target valid set;
[0204] According to each element in the effective target set, the projection angle of the auxiliary light source and the shooting angle of the image acquisition device are adjusted;
[0205] Obtain the traffic image corresponding to each element in the target valid set and define it as the adjustment image;
[0206] All adjustment images are integrated to form an adjustment image set.
[0207] In this embodiment, photos are taken according to the position of the vehicle in a low-light environment, and it is determined whether the data automatically recognized by the image collected by the camera is accurate. For images corresponding to inaccurate data, fill-in light shooting is automatically performed again according to the environment and position of the vehicle. The brightness of the auxiliary light source and the shooting angle are automatically adjusted according to the vehicle's own lighting brightness and the vehicle's environment to reduce missed shots or erroneous shots, thereby reducing the situation where car owners receive violation records that do not belong to them, improving the driving experience of car owners, reducing conflicts between car owners and service personnel, and improving data accuracy.
[0208] The embodiments of the present disclosure also provide a non-transitory computer-readable storage medium, which stores computer instructions, and the computer instructions are used to enable the computer to execute the low-light traffic image enhancement method based on machine learning in the aforementioned method embodiment.
[0209] It should be noted that more specific examples of computer-readable storage media may include portable computer disks, hard disks, erasable programmable read-only memories (EPROMs or flash memories), optical storage devices, magnetic storage devices, or any suitable combination thereof. In the present disclosure, computer-readable storage media may be any tangible medium that contains or stores a program, which may be used by or in conjunction with an instruction execution system, apparatus, or device, and the computer-readable medium may be contained in the electronic device; or it may exist independently without being assembled into the electronic device.
[0210] The computer-readable medium carries one or more programs. When the one or more programs are executed by the electronic device, the electronic device can implement the solution provided by the method embodiment.
[0211] Computer program code for performing operations of the present disclosure may be written in one or more programming languages or a combination thereof, and may be executed entirely on a user's computer, partially on a user's computer, as a stand-alone software package, partially on a user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., through the Internet using an Internet service provider).
[0212] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device.
[0213] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the technical principles of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.
Claims
1. A low-light traffic image enhancement method based on machine learning, characterized in that: include: Set the detection range; If there is no vehicle within the detection range, traffic image capture will not be performed; If there is a vehicle within the detection range, the target traffic image is acquired; According to the target traffic image, the information extraction strategy is used to form the extraction data; If there is extracted data, the information comparison strategy is executed to form comparison data; If the comparison data determines that the data are consistent, the extracted data is stored in the database; If the comparison data determines that the data is inconsistent, the image enhancement training model is obtained, and the fill light adjustment strategy is executed to form adjustment data; If the extracted data does not exist, the image enhancement training model is obtained, and the fill light adjustment strategy is executed to form adjustment data; An adjusted traffic image is formed according to the adjusted data and the image enhancement training model; The adjusted traffic image is identified as the target traffic image, and the information extraction strategy is repeatedly executed.
2. The low-light traffic image enhancement method based on machine learning according to claim 1, characterized in that: The information extraction strategy is specifically as follows: Set target areas; Extract information data in the target area and define it as target data; Get character database; Set the number of analyses; According to the number of analyses, the target data is divided into several sub-target data; Compare each sub-target data with all the data in the character database one by one; If there is data in the character database that is consistent with the sub-target data, the data is defined as the analysis sub-data; If there is no data consistent with the sub-target data in the character database, the data is defined as missing data; If there is no missing data in the target data, the target data will be identified as extracted data; If there is missing data in the target data, it is determined that there is no extracted data.
3. The low-light traffic image enhancement method based on machine learning according to claim 1, characterized in that: The information comparison strategy is specifically as follows: Get the collection time point corresponding to the extracted data and set it as the current time point; Obtain all the collection time points corresponding to the extracted data and set them as analysis time points; Calculate the analysis duration, analysis duration = current time point - analysis time point; The extracted data corresponding to the analysis time point with the smallest extraction value is defined as the previous extracted data; The extracted data corresponding to the current time point is defined as the post-extracted data; Obtain vehicle information corresponding to the previously extracted data, which is defined as the previous vehicle information; If the vehicle information corresponding to the data is extracted later, it is defined as the later vehicle information; If the rear vehicle data = the front extraction data, the data are determined to be consistent; If the rear vehicle data ≠ the front extracted data, it is determined that the data are inconsistent.
4. The low-light traffic image enhancement method based on machine learning according to claim 1, characterized in that: The image enhancement training model is obtained, including a fill light model, specifically: Set the collection area; Identify vehicles within the collection area as analysis vehicles; Obtain the number of analyzed vehicles in the collection area, which is defined as the number of vehicles; If the number of vehicles = 1, then the illumination of the analyzed vehicle is obtained and is defined as the analysis brightness; Obtaining all illumination levels of the analyzed vehicle, including a first brightness and a second brightness; If the analyzed brightness is the first brightness, a low brightness adjustment strategy is executed; If the analyzed brightness is the second brightness, a high brightness adjustment strategy is executed; If the number of vehicles is greater than 1, a vehicle is randomly selected as the target vehicle; If there are vehicles on both sides of the target vehicle, the low brightness adjustment strategy will be executed; If there are no vehicles on both sides of the target vehicle, the high brightness adjustment strategy will be executed.
5. The low-light traffic image enhancement method based on machine learning according to claim 4 is characterized in that: The low brightness adjustment strategy is specifically: Get auxiliary light source; Extract the target point of the auxiliary light source; Obtain the center point of the target area and set it as the first determination point; connecting the target point and the first determination point to form a first analysis line; Obtain all low brightness of auxiliary light sources and set them as target low brightness; Obtain the light range corresponding to the low brightness of each target and set it as the judgment range; Extracting a determination edge line where the first analysis line is within the determination range and defining it as a target adjustment edge line; Extract the target low brightness corresponding to the target adjustment edge line and set it as the adjustment brightness; Control the auxiliary light source to adjust the brightness.
6. The low-light traffic image enhancement method based on machine learning according to claim 4, characterized in that: The high brightness adjustment strategy is specifically as follows: Get auxiliary light source; Extract the target point of the auxiliary light source; Obtain the center point of the target area and set it as the first determination point; connecting the target point and the first determination point to form a first analysis line; Obtaining the sight line position point of the driver of the target vehicle as the second determination point; Connect the target point and the second determination point to form a second analysis line; defining the range between the first analysis line and the second analysis line as the limit range; Obtain all high brightness of auxiliary light sources and set them as target high brightness; Obtain the light range corresponding to the high brightness of each target and set it as the judgment range; Extract the boundary line of each judgment range and set it as the target boundary line; Extract all target edges within the limit range and define them as judgment edges; Extracting a determination edge line where the first analysis line is within the determination range and defining it as a target adjustment edge line; Extract the target high brightness corresponding to the target adjustment edge line and set it as the adjustment brightness; Control the auxiliary light source to adjust the brightness.
7. The low-light traffic image enhancement method based on machine learning according to claim 6, characterized in that: The acquisition of the image enhancement training model also includes an image enhancement model, specifically: Obtain the first analysis line of the auxiliary light source; Obtain the angle between the first analysis line and the ground, which is defined as the projection angle; Obtain all projection angles of auxiliary light sources to form a light set; Acquire all shooting angles that the image acquisition device can adjust to form an image acquisition set; Mapping the elements in the light set to the elements in the image acquisition set one by one to form an adjustment set; According to each element in the adjustment set in turn, the target image is collected and determined as a judgment image; Execute the information extraction strategy for each judgment image to form extraction data; If there is extracted data, the information comparison strategy is executed to form comparison data; If the comparison data determines that the data is consistent, the determined image is considered a valid image; If the comparison data determines that the data is inconsistent, the determined image is deemed to be an invalid image; If the extracted data does not exist, the determined image is deemed as an invalid image; Extract all valid images; Extract the elements in the adjustment set corresponding to each valid image and define them as valid elements; Obtain appearance information of the target vehicle; According to the appearance information of different target vehicles, all corresponding valid elements are integrated respectively to form a valid set.
8. The low-light traffic image enhancement method based on machine learning according to claim 1, characterized in that: The fill light adjustment strategy is specifically as follows: Obtain the position of the target vehicle and set it as the target position point; Get the collection area; If the target location point is within the acquisition area, the fill light model in the image enhancement training model is executed; If the target position point is not within the acquisition area, the fill light model is not executed, and the target position point continues to be acquired until the target position point is within the acquisition area, and then the fill light model in the image enhancement training model is executed.
9. The low-light traffic image enhancement method based on machine learning according to claim 1, characterized in that: The adjusting traffic image is formed according to the adjustment data and the image enhancement training model, specifically: Get the adjusted brightness; Obtain appearance information of the target vehicle and set it as target information; Obtain the image enhancement model in the image enhancement training model; Extract the valid set corresponding to the target information and define it as the target valid set; According to each element in the effective target set, the projection angle of the auxiliary light source and the shooting angle of the image acquisition device are adjusted; Obtain the traffic image corresponding to each element in the target valid set and define it as the adjustment image; All adjustment images are integrated to form an adjustment image set.
Citation Information
Patent Citations
License plate identification control system and identification control method thereof
CN106469292A
Historical data-based license plate information restoration method and system
CN111860412A
Glare-free license plate recognition method and system
CN115457535A
A parking control system based on a hybrid method of license plate and vehicle recognition and a parking control method using the same
KR102407315B1
