Traffic signal indication monitoring method and device, electronic equipment and storage medium
By obtaining and analyzing the image and video information of traffic lights, we judge the abnormality of abnormal signal lights and the importance of the intersection, and output prompt information to solve the traffic congestion caused by traffic light abnormalities, so that abnormalities can be discovered and dealt with in a timely manner to avoid traffic congestion.
Patent Information
- Application Number
- CN202411897867.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-23
- Publication Date
- 2025-04-15
AI Technical Summary
The existing technology is difficult to detect and deal with abnormal traffic lights in a timely manner, resulting in traffic congestion.
By obtaining the image information of the traffic lights, we judge whether there are abnormal signal lights, and determine the abnormality of the abnormal signal lights and the importance of the intersection where they are located based on the image information and video information, and output prompt information to remind staff to guide traffic in a timely manner.
It has achieved timely detection of traffic light abnormalities and promptly reminded staff to deal with it, avoiding traffic congestion.
Smart Images

Figure CN119832759A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of road traffic signal monitoring, and in particular to a traffic signal indication monitoring method, device, electronic device and storage medium. Background Art
[0002] The development of roads is crisscrossed, forming multiple intersections. In order to ensure the safety of vehicles and pedestrians passing through each intersection, multiple sets of traffic lights are set up at the intersections so that vehicles and pedestrians can pass through each intersection regularly. Traffic lights are operated throughout the day and have long operation times. Moreover, traffic lights are located in outdoor scenes and are easily affected by bad weather. After long-term operation, they may become abnormal or damaged, thus affecting their function of directing traffic. At present, staff regularly patrol and check whether there are any abnormalities in traffic lights, which is not only time-consuming and labor-intensive, but also easily leads to traffic congestion if abnormalities are not discovered in time. Summary of the invention
[0003] In order to detect abnormalities of traffic lights in a timely manner and remind staff to divert traffic in a timely manner, the present application provides a traffic signal indication monitoring method, device, electronic device and storage medium.
[0004] In a first aspect, the present application provides a traffic signal indication monitoring method, which adopts the following technical solution: A traffic signal indication monitoring method, comprising: Obtaining image information of each traffic light in a preset area, wherein the image information is an image when one unit of the traffic light is lit; Determining whether there is an abnormal signal light based on the image information; If there is an abnormal signal light, determining the abnormality degree of each abnormal signal light based on the image information, and obtaining video information of the intersection where each abnormal signal light is located; Determine the motor vehicle flow, non-motor vehicle flow and pedestrian flow at the intersection where the abnormal signal light is located based on the video information; Determine the importance of each intersection where the abnormal signal light is located based on the motor vehicle flow, non-motor vehicle flow and pedestrian flow; Based on the abnormality degree and importance, it is determined whether there is a target intersection, and the target intersection is an intersection that requires staff to intervene to direct traffic; If there is a target intersection, output prompt information.
[0005] By adopting the above technical solution, image information is obtained when one unit of each traffic light in the preset area is lit. The image information represents the operating status of the traffic light. The similarity between the image information and the preset image information of the normal traffic light can reflect whether the traffic light is abnormal. Based on the image information, it is judged whether there is an abnormal traffic light. If there is an abnormal traffic light, the degree of abnormality of each abnormal traffic light is determined based on the image information. The degree of abnormality is an important factor affecting whether the intersection can be passed normally. When there is an abnormal traffic light, it may cause people and vehicles at the intersection to be unable to pass through the intersection in an orderly manner. Therefore, video information of the intersection where each abnormal traffic light is located is obtained. The video information can reflect the traffic conditions at the intersection where the abnormal traffic light is located. Based on the video information, it is determined The motor vehicle flow, non-motor vehicle flow and pedestrian flow at the intersection where the abnormal traffic light is located. The flow rate can reflect whether the traffic conditions at the intersection are good. The larger the flow rate, the lower the impact on traffic. All three represent the traffic conditions at the intersection. The importance of each intersection where the abnormal traffic light is located is determined based on the motor vehicle flow, non-motor vehicle flow and pedestrian flow. The importance represents the external impact of the abnormal traffic light. Based on the degree of abnormality and importance, it is determined whether there is a target intersection that requires staff to intervene to direct traffic. The problems of the abnormal traffic light itself and the traffic conditions of the intersection itself may cause congestion at the intersection. If there is a target intersection, a prompt message will be output to detect the abnormality of the traffic light in time and remind the staff to direct traffic in time.
[0006] In another possible implementation, the determining whether there is an abnormal signal light based on the image information includes: Determining the similarity between the image information and preset image information; If there is a signal light whose similarity is lower than the preset similarity threshold, then there is an abnormal signal light; If there is no signal light whose similarity is lower than the preset similarity threshold, then there is no abnormal signal light.
[0007] In another possible implementation, determining the abnormality degree of each abnormal signal light based on the image information includes: determining a pixel value of the abnormal signal light based on the image information; Determine the area of the region where the pixel value is lower than a preset pixel threshold; Determine the first number of lamp beads based on the ratio of the area to the preset area of a single lamp bead, and determine a first ratio of the first number of lamp beads to a preset number threshold, wherein the first lamp bead is a lamp bead whose pixel value is lower than the preset pixel threshold; Determine the scores of all second lamp beads based on the image information, each of the second lamp beads being a lamp bead whose pixel value reaches a preset pixel threshold; A first score is determined based on the first ratio, the second lamp bead score and the respective first coefficients, wherein the first score represents the abnormality degree of each abnormal signal lamp.
[0008] In another possible implementation, determining the second lamp bead score based on the image information includes: Determine the number of second lamp beads; Determine an average pixel value of the second lamp bead based on the image information; Obtaining the usage time of the abnormal signal light; The second lamp bead score is determined based on the number of the second lamp beads, the average pixel value, the usage time and the respective second coefficients.
[0009] In another possible implementation, judging whether there is a target intersection based on the abnormality degree and the importance degree includes: Determine a second score based on the abnormality level, the importance level, and respective second weights; Obtain the historical damage count of the intersection; determining a third score based on the second score, the number of historical damages, and respective third coefficients; If the third score is lower than a preset score threshold, it is determined that there is a target intersection; If the third score reaches the preset score threshold, it is determined that there is no target intersection.
[0010] In another possible implementation, the output prompt information includes: Obtaining the location of staff within a preset range of the target intersection; Determine a route for the staff member to the target intersection, and determine a congestion level of the route; Determine the distance from the worker to the target intersection based on the position; Determine the target staff member based on the distance and congestion level; Output prompt information to the target staff member.
[0011] In another possible implementation, the method further includes: Determine a target score based on the first number of lamp beads, the area, and respective target coefficients; Determine the number of circles and target brightness of the target lamp bead based on the target score, the target lamp bead being the lamp bead outside the area where the first lamp bead is located; Control and increase the brightness of the target lamp bead to the target brightness.
[0012] In a second aspect, the present application provides a traffic signal indication monitoring device, which adopts the following technical solution: A traffic signal indication monitoring device, comprising: An acquisition module, used to acquire image information of each traffic light in a preset area, wherein the image information is an image when one unit of the traffic light is lit; A first judging module, configured to judge whether there is an abnormal signal light based on the image information; A first determination module is used to determine the abnormality degree of each abnormal signal light based on the image information if there is an abnormal signal light, and obtain video information of the intersection where each abnormal signal light is located; A second determination module is used to determine the motor vehicle flow, non-motor vehicle flow and pedestrian flow at the intersection where the abnormal signal light is located based on the video information; A third determination module is used to determine the importance of each intersection where the abnormal signal light is located based on the motor vehicle flow, non-motor vehicle flow and pedestrian flow; A second judgment module is used to judge whether there is a target intersection based on the abnormality degree and importance, and the target intersection is an intersection that requires staff to intervene to direct traffic; The output module is used to output prompt information if there is a target intersection.
[0013] By adopting the above technical solution, the acquisition module obtains the image information when one unit of each traffic light in the preset area is lit, the image information represents the operating status of the traffic light, the similarity between the image information and the preset image information of the normal traffic light can reflect whether the traffic light is abnormal, the first judgment module determines whether there is an abnormal traffic light based on the image information, if there is an abnormal traffic light, the first determination module determines the abnormality of each abnormal traffic light based on the image information, the abnormality is an important factor affecting whether the intersection can pass normally, when there is an abnormal traffic light, it may cause people and vehicles at the intersection to be unable to pass through the intersection in an orderly manner, therefore, the video information of each intersection where the abnormal traffic light is located is obtained, the video information can reflect the traffic conditions at the intersection where the abnormal traffic light is located, the second determination module determines the abnormality of each abnormal traffic light based on the video information The information determines the motor vehicle flow, non-motor vehicle flow and pedestrian flow at the intersection where the abnormal traffic light is located. The flow rate can reflect whether the traffic conditions at the intersection are good. The larger the flow rate, the lower the impact on traffic. All three represent the traffic conditions at the intersection. The third determination module determines the importance of each intersection where the abnormal traffic light is located based on the motor vehicle flow, non-motor vehicle flow and pedestrian flow. The importance represents the external impact of the abnormal traffic light. The second judgment module determines whether there is a target intersection where staff needs to intervene to direct traffic based on the degree of abnormality and importance. The problems of the abnormal traffic light itself and the traffic conditions of the intersection itself may cause congestion at the intersection. If there is a target intersection, the output module outputs a prompt message, which can promptly detect the abnormality of the traffic light and remind the staff to promptly direct traffic.
[0014] In another possible implementation, when the first judgment module judges whether there is an abnormal signal light based on the image information, it is specifically configured to: Determining the similarity between the image information and preset image information; If there is a signal light whose similarity is lower than the preset similarity threshold, then there is an abnormal signal light; If there is no signal light whose similarity is lower than the preset similarity threshold, then there is no abnormal signal light.
[0015] In another possible implementation, when the first determination module determines the abnormality degree of each abnormal signal light based on the image information, it is specifically configured to: determining a pixel value of the abnormal signal light based on the image information; Determine the area of the region where the pixel value is lower than a preset pixel threshold; Determine the first number of lamp beads based on the ratio of the area to the preset area of a single lamp bead, and determine a first ratio of the first number of lamp beads to a preset number threshold, wherein the first lamp bead is a lamp bead whose pixel value is lower than the preset pixel threshold; Determine the scores of all second lamp beads based on the image information, each of the second lamp beads being a lamp bead whose pixel value reaches a preset pixel threshold; A first score is determined based on the first ratio, the second lamp bead score and the respective first coefficients, wherein the first score represents the abnormality degree of each abnormal signal lamp.
[0016] In another possible implementation, when the first determination module determines the second lamp bead score based on the image information, it is specifically used to: Determine the number of second lamp beads; Determine an average pixel value of the second lamp bead based on the image information; Obtaining the usage time of the abnormal signal light; The second lamp bead score is determined based on the number of the second lamp beads, the average pixel value, the usage time and the respective second coefficients.
[0017] In another possible implementation, when the second judgment module judges whether there is a target intersection based on the abnormality degree and the importance degree, it is specifically used to: Determine a second score based on the abnormality level, the importance level, and respective second weights; Obtain the historical damage count of the intersection; determining a third score based on the second score, the number of historical damages, and respective third coefficients; If the third score is lower than a preset score threshold, it is determined that there is a target intersection; If the third score reaches the preset score threshold, it is determined that there is no target intersection.
[0018] In another possible implementation, when outputting the prompt information, the output module is specifically used to: Obtaining the location of staff within a preset range of the target intersection; Determine a route for the staff member to the target intersection, and determine a congestion level of the route; Determine the distance from the worker to the target intersection based on the position; Determine the target staff member based on the distance and congestion level; Output prompt information to the target staff member.
[0019] In another possible implementation, the device further includes: A target score determination module, configured to determine a target score based on the first number of lamp beads and the area and respective target coefficients; A fourth determination module, used to determine the number of circles and target brightness of a target lamp bead based on the target score, wherein the target lamp bead is a lamp bead outside the area where the first lamp bead is located; The control module is used to control and increase the brightness of the target lamp bead to the target brightness.
[0020] In a third aspect, the present application provides an electronic device, which adopts the following technical solution: An electronic device, comprising: at least one processor; Memory; At least one application, wherein at least one application is stored in a memory and configured to be executed by at least one processor, and at least one is configured to: execute a traffic signal indication monitoring method shown in any possible implementation of the first aspect.
[0021] In a fourth aspect, the present application provides a computer-readable storage medium, which adopts the following technical solution: A computer-readable storage medium, when the computer program is executed in a computer, causes the computer to execute a traffic signal indication monitoring method as described in any one of the first aspects.
[0022] In summary, the present application includes at least one of the following beneficial technical effects: Obtain image information when one unit of each traffic light in the preset area is lit. The image information represents the operating status of the traffic light. The similarity between the image information and the preset image information of the normal traffic light can reflect whether the traffic light is abnormal. Determine whether there is an abnormal traffic light based on the image information. If there is an abnormal traffic light, determine the degree of abnormality of each abnormal traffic light based on the image information. The degree of abnormality is an important factor affecting whether the intersection can pass normally. When there is an abnormal traffic light, it may cause people and vehicles at the intersection to be unable to pass through the intersection in an orderly manner. Therefore, obtain video information of each intersection where the abnormal traffic light is located. The video information can reflect the traffic conditions at the intersection where the abnormal traffic light is located. Determine the abnormal traffic light based on the video information The motor vehicle flow, non-motor vehicle flow and pedestrian flow at the intersection. The flow rate can reflect whether the traffic conditions at the intersection are good. The larger the flow rate, the lower the impact on traffic. All three represent the traffic conditions at the intersection. The importance of each intersection where the abnormal traffic light is located is determined based on the motor vehicle flow, non-motor vehicle flow and pedestrian flow. The importance represents the external impact of the abnormal traffic light. Based on the degree of abnormality and importance, it is determined whether there is a target intersection that requires staff to intervene to direct traffic. The problems of the abnormal traffic light itself and the traffic conditions of the intersection itself may cause congestion at the intersection. If there is a target intersection, a prompt message will be output to detect the abnormality of the traffic light in time and remind the staff to divert traffic in time. BRIEF DESCRIPTION OF THE DRAWINGS
[0023] Figure 1 It is a flow chart of a traffic signal indication monitoring method according to an embodiment of the present application.
[0024] Figure 2 It is a schematic diagram of a specific process for determining the degree of abnormality in an embodiment of the present application.
[0025] Figure 3 It is a structural schematic diagram of a traffic signal indication monitoring device according to an embodiment of the present application.
[0026] Figure 4 It is a structural schematic diagram of an electronic device according to an embodiment of the present application. DETAILED DESCRIPTION
[0027] The present application is further described in detail below in conjunction with the accompanying drawings.
[0028] After reading this specification, those skilled in the art may make non-creative modifications to this embodiment as needed, but such modifications are protected by patent law as long as they are within the scope of the claims of this application.
[0029] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0030] In addition, the term "and / or" in this article is only a description of the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article, unless otherwise specified, generally means that the associated objects before and after are in an "or" relationship.
[0031] The embodiments of the present application are further described in detail below in conjunction with the drawings in the specification.
[0032] The embodiment of the present application provides a traffic signal indication monitoring method, which is executed by an electronic device, which can be a server or a terminal device, wherein the server can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server providing cloud computing services. The terminal device can be a smart phone, a tablet computer, a laptop computer, a desktop computer, etc., but is not limited thereto. The terminal device and the server can be directly or indirectly connected via wired or wireless communication, which is not limited in the embodiment of the present application. Figure 1 As shown, the method includes step S101, step S102, step S103, step S104 and step S105, wherein: S101, obtaining image information of each traffic light in a preset area.
[0033] The image information is an image when one unit of the traffic light is lit.
[0034] For the embodiments of the present application, the preset area may be a certain area artificially demarcated, such as a certain urban area. Specifically, a map of a certain area may be stored in the electronic device, and the staff may demarcate the preset area on the map, and the map records the road distribution and the type of each traffic light. The staff sets up a first camera device near each traffic light in advance, and the first camera device faces the traffic light to collect image information of the traffic light. The first camera device is wirelessly connected to the electronic device, and the electronic device obtains image information of each traffic light in the preset area when a unit is lit through the first camera device. The image information shows the operating status of the traffic light.
[0035] S102, judging whether there is an abnormal signal light based on the image information.
[0036] For the embodiment of the present application, the image information can reflect whether there is an abnormality with the traffic light. The electronic device calculates the image information with the preset image information when the traffic light is normal, which is pre-stored in the electronic device, to obtain the similarity between the two images. The similarity reflects the degree of similarity of the traffic lights between the two images. If the similarity is lower than the preset similarity threshold, there is an abnormal traffic light. If the similarity reaches the preset similarity threshold, there is no abnormal traffic light.
[0037] S103: If there is an abnormal traffic light, determine the abnormality level of each abnormal traffic light based on the image information, and obtain video information of the intersection where each abnormal traffic light is located.
[0038] For the embodiment of the present application, if there is an abnormal signal light, the electronic device determines the degree of abnormality of the abnormal signal light based on the image information.
[0039] A second camera device is set in the preset area, which can collect video information at the intersection. The second camera device is wirelessly connected to the electronic device, and the electronic device obtains video information of each intersection where the abnormal traffic light is located. The video information reflects the traffic conditions at the intersection where the abnormal traffic light is located.
[0040] S104, determining the motor vehicle flow, non-motor vehicle flow, and pedestrian flow at the intersection where the abnormal traffic light is located based on the video information.
[0041] For the embodiments of the present application, the electronic device divides the video information into regions, and performs feature recognition on the areas enclosed by the zebra crossings at each fork in the road at the intersection. For example, the video information is input into a trained convolutional neural network model for feature recognition, thereby respectively determining the motor vehicle flow, non-motor vehicle flow, and pedestrian flow passing through within a preset time. The flow size represents whether the traffic conditions at the intersection are good.
[0042] S105, determining the importance of each intersection where the abnormal traffic light is located based on the traffic flow of motor vehicles, the traffic flow of non-motor vehicles, and the traffic flow of people.
[0043] For the embodiment of the present application, the motor vehicle flow, non-motor vehicle flow and pedestrian flow are all important factors affecting the traffic conditions at the intersection where each abnormal traffic light is located. The electronic device determines the flow score based on the motor vehicle flow, non-motor vehicle flow and pedestrian flow and their respective first weights. Assuming that the motor vehicle flow is 15, the non-motor vehicle flow is 20, and the pedestrian flow is 3, and the first weights of the three are 0.4, 0.4, and 0.2 respectively, the electronic device calculates the flow score to be 15×0.4×20×0.4+3×0.2=14.6. The flow score represents the importance of the intersection where each abnormal traffic light is located. The larger the flow, the lower the importance of the abnormality of the traffic light at this intersection to this intersection, and the smaller the impact on the traffic at this intersection.
[0044] S106, judging whether there is a target intersection based on the abnormality degree and importance degree.
[0045] Among them, the target intersection is the intersection that requires staff intervention to direct traffic.
[0046] For the embodiment of the present application, the electronic device determines the second score based on the degree of abnormality and importance, and determines whether there is a target intersection based on the second score and the number of historical damages, that is, an intersection where staff intervention is required to direct traffic. If the score is lower, the traffic at this intersection is more congested, and staff is urgently needed to direct traffic so that people and vehicles can pass through this intersection as soon as possible.
[0047] S107: If the target intersection exists, output prompt information.
[0048] For the embodiment of the present application, if there is a target intersection, a prompt message such as "Traffic needs to be diverted at XX intersection, please go as soon as possible" can be output. The abnormal traffic lights and the flow of people and vehicles are determined by the image information of the traffic lights and the video information at the intersection, and then the importance of the intersection where each traffic light is located is determined. Based on the degree of abnormality and importance, it is determined whether there is a target intersection that requires staff to divert traffic. If there is a target intersection, a prompt message is output, which can timely detect the abnormality of the traffic lights and promptly remind the staff to divert traffic in time.
[0049] In a possible implementation of the embodiment of the present application, in step S102, judging whether there is an abnormal signal light based on the image information specifically includes step S1021 (not shown in the figure), step S1022 (not shown in the figure), and step S1023 (not shown in the figure), wherein: Step S1021, determining the similarity between the image information and the preset image information.
[0050] For the embodiment of the present application, the similarity can be calculated by the structural similarity metric (SSIM). It can also be calculated by cosine similarity, that is, the image information is represented as a vector, and the electronic device characterizes the similarity between the image information and the preset image information by calculating the cosine distance between the vectors. The preset image information is an image when the traffic light is normal, which is stored in the electronic device. The similarity characterizes the similarity between the traffic lights in the two images. The lower the similarity, the greater the difference between the traffic light and the normal traffic light. In addition, the similarity can be calculated by histogram, and the similarity can be calculated by other methods, which are not limited here.
[0051] S1022: If there is a traffic light whose similarity is lower than a preset similarity threshold, then there is an abnormal traffic light.
[0052] For the embodiment of the present application, the electronic device compares the calculated similarity with the preset similarity threshold. If there is a signal light whose similarity is lower than the preset similarity threshold, it means that the signal light is not fully lit and there are too many areas that are off, which is too different from the normal operation of the signal light, and it is determined that there is an abnormal signal light.
[0053] S1023: If there is no traffic light whose similarity is lower than the preset similarity threshold, then there is no abnormal traffic light.
[0054] For the embodiment of the present application, the electronic device compares the calculated similarity with the preset similarity threshold. If there is no signal light with a similarity lower than the preset similarity threshold, it means that the signal light is normally worn out and is close to the normal operation of the signal light. The extinguishing of a small area does not affect the normal use of the signal light, and it is determined that there is no abnormal signal light.
[0055] In a possible implementation of the embodiment of the present application, the abnormality degree of each abnormal signal light is determined based on the image information in step S103, specifically including steps S1031, S1032, S1033, S1034 and S1035. Figure 2 As shown, Step S1031, determining the pixel value of the abnormal signal light based on the image information.
[0056] For the embodiment of the present application, the electronic device sets different values 0-255 corresponding to each pixel of the abnormal signal light in the image information according to different colors and depths, which is the pixel value of the abnormal signal light. The pixel value is an RGB value, and the pixel value represents the color of the abnormal signal light when it is on.
[0057] Step S1032, determining the area of the region where the pixel value is lower than the preset pixel threshold.
[0058] For the embodiment of the present application, if there is an abnormality in the signal light, it means that some areas are damaged and some areas are not lit, or there is a difference between the color of some areas when they are lit and the color when they are operating normally, and the difference is too large, so the area cannot normally indicate the correct color. The electronic device selects the area with a pixel value lower than the preset pixel threshold and calculates the area of this area. The larger the area, the larger the damaged area. If the area is small, it may not affect the indication function of the signal light.
[0059] Step S1033, determining the first number of lamp beads based on the ratio of the area to the preset area of a single lamp bead, and determining a first ratio of the first number of lamp beads to a preset number threshold.
[0060] Among them, the first lamp bead is a lamp bead whose pixel value is lower than a preset pixel threshold.
[0061] For the embodiment of the present application, the signal light is composed of multiple lamp beads, and the area of each lamp bead presented in the image information after lighting is the preset single lamp bead area. The electronic device determines the lamp bead with a pixel value lower than the preset pixel threshold as the first lamp bead. Therefore, the electronic device can calculate the ratio of the area to the preset single lamp bead area to obtain the number of first lamp beads. The more the number of first lamp beads, the larger the damaged area in the abnormal signal light.
[0062] The number of lamp beads of the signal light is a fixed value. The electronic device stores the preset number threshold of all lamp beads of the normal signal light in the electronic device, and calculates a first ratio of the first number of lamp beads to the preset number threshold. The ratio represents the proportion of damaged first lamp beads.
[0063] Step S1034, determining the scores of all second lamp beads based on the image information.
[0064] Among them, each second lamp bead is a lamp bead whose pixel value reaches a preset pixel threshold.
[0065] For the embodiment of the present application, the image information also includes a second lamp bead whose pixel value can light up normally and reaches a preset pixel threshold, so the electronic device determines the score of the second lamp bead based on the image information.
[0066] Step S1035, determining the first score based on the first ratio, the second lamp bead score and the respective first coefficients.
[0067] The first score represents the abnormality degree of each abnormal signal light.
[0068] For the embodiment of the present application, the first ratio and the second lamp bead score are important factors affecting the degree of abnormality of the abnormal signal light. The larger the first ratio, the more abnormal the abnormal signal light is; the lower the second lamp bead score, the more abnormal the abnormal signal light is. The electronic device determines the first score based on the first ratio, the second lamp bead score and their respective first coefficients. The first score represents the degree of abnormality of each abnormal signal light. Assuming that the first ratio and the second lamp bead score are 0.4 and 15.9 respectively, and their first coefficients are 8 and 0.06 respectively, the electronic device calculates the first score as 0.4×8+15.9×0.06=4.154.
[0069] In a possible implementation of the embodiment of the present application, the second lamp bead score is determined based on the image information in step S1034, specifically including step S1 (not shown in the figure), step S2 (not shown in the figure), step S3 (not shown in the figure) and step S4 (not shown in the figure), wherein: Step S1, determining the number of second lamp beads.
[0070] For the embodiments of the present application, the electronic device can obtain the second number of lamp beads by calculating the difference between a preset number threshold and the first number of lamp beads, or can obtain the second number of lamp beads by determining the ratio of the area where the pixel value reaches the preset pixel threshold to the preset area of a single lamp bead.
[0071] Step S2, determining the average pixel value of the second lamp bead based on the image information.
[0072] For the embodiment of the present application, the electronic device determines the pixel value of each second lamp bead in the image information, and calculates the average of all the second lamp bead pixel values to obtain the average pixel value. The lower the average pixel value, the lower the brightness of the second lamp bead and the lower the health level.
[0073] Step S3, obtaining the usage time of the abnormal signal light.
[0074] For the embodiment of the present application, the installation time of each traffic light is recorded in advance and stored in the electronic device. The electronic device obtains the installation time of the abnormal traffic light and calculates the usage time of the abnormal traffic light in combination with the current time. The longer the usage time, the more likely the abnormal traffic light is to have an abnormality.
[0075] Step S4, determining the second lamp bead score based on the number of second lamp beads, the average pixel value, the usage time and the respective second coefficients.
[0076] For the embodiment of the present application, the number of second lamp beads characterizes the current working status and reliability of the abnormal signal light, the average pixel value characterizes the current lighting effect and visibility, and the usage time indicates the service life of the abnormal signal light. The electronic device determines the second lamp bead score based on the number of second lamp beads, the average pixel value, the usage time and the respective second coefficients. Assuming that the number of second lamp beads is 300, the average pixel value is 170, and the usage time is 5 years, the second coefficients of the number of second lamp beads, the average pixel value and the usage time are 0.08, 0.07 and -4 respectively. The electronic device calculates the second lamp bead score as 300×0.08+170×0.07+5×(-4)=15.9.
[0077] In a possible implementation of the embodiment of the present application, in step S106, judging whether there is a target intersection based on the degree of abnormality and the degree of importance specifically includes step S1061 (not shown in the figure), step S1062 (not shown in the figure), step S1063 (not shown in the figure), step S1064 (not shown in the figure) and step S1065 (not shown in the figure), wherein: Step S1061, determining a second score based on the abnormality degree, the importance degree, and respective second weights.
[0078] For the embodiment of the present application, the degree of abnormality represents the intrinsic impact of the abnormal signal light, and the degree of importance represents the external impact of the abnormal signal light. Therefore, the electronic device determines the second score based on the degree of abnormality, the degree of importance and the respective second weights. Assuming that the degree of abnormality is 4.154, the degree of importance is 14.6, and the respective second weights are 0.6 and 0.4 respectively, the electronic device calculates the second score to be 4.154×0.6+14.6×0.4=8.3324.
[0079] Step S1062, obtaining the historical damage count of the intersection.
[0080] For the embodiment of the present application, each time a traffic light at an intersection is damaged is recorded and counted by an electronic device, which obtains the historical number of damages at the intersection. The more historical damages there are, the greater the traffic safety hazard at the intersection, and the more staff are needed to direct traffic in a timely manner.
[0081] Step S1063, determining a third score based on the second score, the number of historical damages, and respective third coefficients.
[0082] For the embodiment of the present application, the second score represents the impact of the current abnormal traffic light on traffic, and the number of historical damages reflects the aging degree of the traffic light. Therefore, the electronic device determines the third score based on the second score, the number of historical damages and the respective third coefficients. The lower the third score, the higher the traffic risk at this intersection.
[0083] Step S1064: If the third score is lower than the preset score threshold, there is a target intersection.
[0084] For the embodiment of the present application, the electronic device determines the third score. If the third score is lower than the preset score threshold, it means that significant congestion has occurred at this intersection, which means that there is a target intersection and staff are required to direct traffic as soon as possible.
[0085] Step S1065: If the third score reaches the preset score threshold, there is no target intersection.
[0086] For the embodiment of the present application, the electronic device determines the third score. If the third score reaches a preset score threshold, the target intersection does not exist.
[0087] In a possible implementation of the embodiment of the present application, the prompt information is output in step S107, which specifically includes step S1071 (not shown in the figure), step S1072 (not shown in the figure), step S1073 (not shown in the figure), step S1074 (not shown in the figure) and step S1075 (not shown in the figure), wherein: Step S1071, obtaining the position of the staff within a preset range of the target intersection.
[0088] For the embodiment of the present application, the electronic device can obtain a map of a preset area from a map website in advance, and the staff will mark the location of each intersection on the map. At the same time, the staff are equipped with a positioning device, and the real-time location of the positioning device is synchronously displayed on the map. When the target intersection is determined, the electronic device can obtain the location of the staff within the preset range of the target intersection.
[0089] Step S1072, determine the route of the staff to the target intersection and determine the congestion level of the route.
[0090] For the embodiment of the present application, the existence of a target intersection indicates that staff are needed to direct traffic as soon as possible. Therefore, it is necessary to determine a staff member who can reach the target intersection the fastest among the staff members within a preset range of the target intersection. The map simultaneously updates the real-time traffic conditions and marks the sections in congestion. The electronic device determines the route of the staff member to the target intersection based on the map, and at the same time determines the length of the section in congestion in the route, which is the degree of congestion of the route.
[0091] Step S1073, determining the distance from the staff member to the target intersection based on the position.
[0092] For the embodiment of the present application, the electronic device determines the distance from the staff to the target intersection based on the staff's position and the target intersection in the map. The shorter the distance, the faster the staff can reach the target intersection to direct traffic.
[0093] Step S1074, determining the target staff based on distance and congestion level.
[0094] For the embodiment of the present application, the closer the distance is, the faster the target intersection is reached, the lower the congestion level is, and the time required for the staff to reach the target intersection is shorter, and the time will not be increased due to traffic congestion. Therefore, the electronic device determines the fourth score based on the distance and congestion level and the respective fourth coefficients, and determines the staff member with the lowest fourth score as the target staff member.
[0095] Step S1075, output prompt information to the target staff member.
[0096] For the embodiment of the present application, the electronic device is wirelessly connected to the communication device of the target staff member, and outputs prompt information such as "Traffic needs to be diverted at XX intersection, please go there as soon as possible" to the target staff member.
[0097] In a possible implementation manner of the embodiment of the present application, the method further includes step 1, step 2 and step 3, wherein: Step 1: Determine the target score based on the number and area of the first lamp beads and their respective target coefficients.
[0098] For the embodiment of the present application, the more first lamp beads there are, the fewer lamp beads that normally light up in the abnormal signal light, and the overall brightness of the abnormal signal light will also decrease. If it occurs in weather with strong light and high surrounding brightness, such as sunny days, the insufficient brightness of the signal light will cause pedestrians and drivers to be unable to judge whether the signal light can pass through the intersection normally. Therefore, the remedy at this time is to increase the brightness of the surrounding lamp beads to supplement the darkness of the first lamp beads and enhance the indication effect of the abnormal signal light. Therefore, the electronic device determines the target score based on the number and area of the first lamp beads and their respective target coefficients.
[0099] Step 2: Determine the number of circles and target brightness of the target lamp bead based on the target score, and the target lamp bead is the lamp bead outside the area where the first lamp bead is located.
[0100] For the embodiment of the present application, multiple preset score intervals are stored in the electronic device, each interval corresponds to the number of circles and brightness of the surrounding lamp beads that are lit, the electronic device determines the preset score interval where the target score is located, and determines the number of circles and target brightness corresponding to the score interval as the number of circles and target brightness that need to be adjusted for the abnormal signal light.
[0101] The electronic device determines the position of the first lamp bead on the abnormal signal light (such as by establishing a coordinate system for the image information to determine the coordinates of the first lamp bead) and the position of the area covered by the first lamp bead, thereby determining the surrounding lamp beads that need to increase brightness based on the determined number of circles.
[0102] Step 3: Control and increase the brightness of the target lamp beads to the target brightness.
[0103] For the embodiment of the present application, the electronic device controls the terminal device to increase the brightness of the target lamp beads according to different numbers of circles. For example, if the number of circles is one, the brightness of the first surrounding circle is increased to the corresponding target brightness. If the number of circles is three, the target lamp beads in the three surrounding circles are increased to the target brightness.
[0104] The above embodiment introduces a traffic signal indication monitoring method from the perspective of method flow, and the following embodiment introduces a traffic signal indication monitoring device from the perspective of a virtual module or a virtual unit. Please refer to the following embodiment for details.
[0105] The present application embodiment provides a traffic signal indication monitoring device 20, such as Figure 3 As shown, the traffic signal indication monitoring device 20 may specifically include: An acquisition module 201 is used to acquire image information of each traffic light in a preset area, where the image information is an image when one unit of the traffic light is lit; A first judging module 202, configured to judge whether there is an abnormal signal light based on the image information; The first determination module 203 is used to determine the abnormality degree of each abnormal signal light based on the image information if there is an abnormal signal light, and obtain the video information of the intersection where each abnormal signal light is located; A second determination module 204 is used to determine the motor vehicle flow, non-motor vehicle flow and pedestrian flow at the intersection where the abnormal signal light is located based on the video information; The third determination module 205 is used to determine the importance of each intersection where the abnormal signal light is located based on the motor vehicle flow, non-motor vehicle flow and pedestrian flow; The second judgment module 206 is used to judge whether there is a target intersection based on the degree of abnormality and importance, and the target intersection is an intersection that requires staff to intervene to direct traffic; The output module 207 is used to output prompt information if there is a target intersection.
[0106] The embodiment of the present application discloses a traffic signal indication monitoring device 20, wherein an acquisition module 201 acquires image information when a unit of each traffic light in a preset area is lit, the image information represents the operating state of the traffic light, and the similarity between the image information and the preset image information of the normal traffic light can reflect whether the traffic light is abnormal, the first judgment module 202 determines whether there is an abnormal traffic light based on the image information, if there is an abnormal traffic light, the first determination module 203 determines the degree of abnormality of each abnormal traffic light based on the image information, the degree of abnormality is an important factor affecting whether the intersection can pass normally, when there is an abnormal traffic light, it may cause people and vehicles at the intersection to be unable to pass through the intersection in an orderly manner, therefore, the video information of the intersection where each abnormal traffic light is located is acquired, the video information can reflect the traffic conditions at the intersection where the abnormal traffic light is located, and the second determination module 203 determines whether there is an abnormal traffic light based on the image information. Module 204 determines the motor vehicle flow, non-motor vehicle flow and pedestrian flow at the intersection where the abnormal signal light is located based on the video information. The flow rate can reflect whether the traffic conditions at the intersection are good. The larger the flow rate, the lower the impact on traffic. All three represent the traffic conditions at the intersection. The third determination module 205 determines the importance of each intersection where the abnormal signal light is located based on the motor vehicle flow, non-motor vehicle flow and pedestrian flow. The importance represents the external impact of the abnormal signal light. The second judgment module 206 determines whether there is a target intersection where staff needs to intervene to direct traffic based on the degree of abnormality and importance. The problems of the abnormal signal light itself and the traffic conditions of the intersection itself may cause congestion at the intersection. If there is a target intersection, the output module 207 outputs a prompt message, which can promptly detect the abnormality of the signal light and remind the staff to promptly direct traffic.
[0107] In a possible implementation of the embodiment of the present application, when the first judgment module 202 judges whether there is an abnormal signal light based on the image information, it is specifically used to: Determining the similarity between the image information and the preset image information; If there is a signal light whose similarity is lower than a preset similarity threshold, it is determined that there is an abnormal signal light; If there is no signal light whose similarity is lower than the preset similarity threshold, it is determined that there is no abnormal signal light.
[0108] In a possible implementation of the embodiment of the present application, when the first determination module 203 determines the abnormality degree of each abnormal signal light based on the image information, it is specifically used to: Determine a pixel value of the abnormal signal light based on the image information; Determine the area of the region where the pixel value is lower than a preset pixel threshold; Determine the number of first lamp beads based on the ratio of the area to the preset area of a single lamp bead, determine a first ratio of the number of first lamp beads to a preset number threshold, the first lamp beads being lamp beads having pixel values lower than the preset pixel threshold; Determine the scores of all second lamp beads based on the image information, each second lamp bead being a lamp bead whose pixel value reaches a preset pixel threshold; A first score is determined based on the first ratio, the second lamp bead score, and the respective first coefficients, and the first score represents the degree of abnormality of each abnormal signal light.
[0109] In a possible implementation of the embodiment of the present application, when the first determination module 203 determines the second lamp bead score based on the image information, it is specifically used to: Determine the number of second lamp beads; Determine an average pixel value of the second lamp bead based on the image information; Get the usage time of abnormal signal light; The second lamp bead score is determined based on the number of second lamp beads, the average pixel value, the usage time and the respective second coefficients.
[0110] In a possible implementation of the embodiment of the present application, when the second judgment module 206 judges whether there is a target intersection based on the abnormality degree and the importance degree, it is specifically used to: determining a second score based on the abnormality degree, the importance degree, and respective second weights; Get the historical damage count of the intersection; determining a third score based on the second score, the number of historical damages, and the respective third coefficients; If the third score is lower than the preset score threshold, it is determined that there is a target intersection; If the third score reaches the preset score threshold, it is determined that there is no target intersection.
[0111] In a possible implementation of the embodiment of the present application, when the output module 207 outputs the prompt information, it is specifically used to: Get the location of the staff within the preset range of the target intersection; Determine the route that staff will take to the target intersection and determine the degree of congestion on the route; Determine the worker's distance to the target intersection based on the location; Target workers based on distance and congestion levels; Output prompt information to the target staff member.
[0112] In a possible implementation of the embodiment of the present application, the device 20 further includes: A target score determination module, used to determine the target score based on the number and area of the first lamp beads and their respective target coefficients; A fourth determination module, used to determine the number of circles and target brightness of a target lamp bead based on the target score, the target lamp bead being a lamp bead outside the area where the first lamp bead is located; The control module is used to control and increase the brightness of the target lamp beads to the target brightness.
[0113] An electronic device is provided in an embodiment of the present application, such as Figure 4 As shown, Figure 4 The electronic device 30 shown includes: a processor 301 and a memory 303. The processor 301 and the memory 303 are connected, such as through a bus 302. Optionally, the electronic device 30 may also include a transceiver 304. It should be noted that in actual applications, the transceiver 304 is not limited to one, and the structure of the electronic device 30 does not constitute a limitation on the embodiments of the present application.
[0114] The processor 301 may be a CPU (Central Processing Unit), a general-purpose processor, a DSP (Digital Signal Processor), an ASIC (Application Specific Integrated Circuit), an FPGA (Field Programmable Gate Array) or other programmable logic devices, transistor logic devices, hardware components or any combination thereof. It may implement or execute various exemplary logic blocks, modules and circuits described in conjunction with the disclosure of this application. The processor 301 may also be a combination that implements computing functions, such as a combination of one or more microprocessors, a combination of a DSP and a microprocessor, etc.
[0115] The bus 302 may include a path to transmit information between the above components. The bus 302 may be a PCI (Peripheral Component Interconnect) bus or an EISA (Extended Industry Standard Architecture) bus. The bus 302 may be divided into an address bus, a data bus, a control bus, etc. For ease of representation, only one thick line is used in the figure, but it does not mean that there is only one bus or one type of bus.
[0116] The memory 303 may be a ROM (Read Only Memory) or other types of static storage devices that can store static information and instructions, a RAM (Random Access Memory) or other types of dynamic storage devices that can store information and instructions, or an EEPROM (Electrically Erasable Programmable Read Only Memory), a CD-ROM (Compact Disc Read Only Memory) or other optical disk storage, optical disk storage (including compressed optical disk, laser disk, optical disk, digital versatile disk, Blu-ray disk, etc.), a magnetic disk storage medium or other magnetic storage device, or any other medium that can be used to carry or store the desired program code in the form of instructions or data structures and can be accessed by a computer, but is not limited thereto.
[0117] The memory 303 is used to store the application code for executing the solution of the present application, and the execution is controlled by the processor 301. The processor 301 is used to execute the application code stored in the memory 303 to implement the contents shown in the above method embodiment.
[0118] The electronic devices include, but are not limited to, mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), vehicle-mounted terminals (such as vehicle-mounted navigation terminals), and fixed terminals such as digital TVs, desktop computers, etc. It can also be a server, etc. Figure 4 The electronic device shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.
[0119] The embodiment of the present application provides a computer-readable storage medium, on which a computer program is stored. When the computer-readable storage medium is run on a computer, the computer can execute the corresponding content in the aforementioned method embodiment. Compared with the related art, the embodiment of the present application obtains image information when a unit of each traffic light in a preset area is lit. The image information represents the operating status of the traffic light. The similarity between the image information and the preset image information of the normal traffic light can reflect whether the traffic light is abnormal. Based on the image information, it is determined whether there is an abnormal traffic light. If there is an abnormal traffic light, the degree of abnormality of each abnormal traffic light is determined based on the image information. The degree of abnormality is an important factor affecting whether the intersection can pass normally. When there is an abnormal traffic light, it may cause people and vehicles at the intersection to be unable to pass through the intersection in an orderly manner. Therefore, video information of the intersection where each abnormal traffic light is located is obtained. The video information can reflect the traffic conditions at the intersection where the abnormal traffic light is located. Based on the video information Determine the motor vehicle flow, non-motor vehicle flow and pedestrian flow at the intersection where the abnormal traffic light is located. The flow rate can reflect whether the traffic conditions at the intersection are good. The larger the flow rate, the lower the impact on traffic. All three represent the traffic conditions at the intersection. The importance of each intersection where the abnormal traffic light is located is determined based on the motor vehicle flow, non-motor vehicle flow and pedestrian flow. The importance represents the external impact of the abnormal traffic light. Based on the degree of abnormality and importance, determine whether there is a target intersection that requires staff to intervene to direct traffic. The problems of the abnormal traffic light itself and the traffic conditions of the intersection itself may cause congestion at the intersection. If there is a target intersection, a prompt message will be output to promptly detect the abnormality of the traffic light and remind the staff to promptly direct traffic.
[0120] It should be understood that, although the steps in the flowchart of the accompanying drawings are displayed in sequence as indicated by the arrows, these steps are not necessarily executed in sequence in the order indicated by the arrows. Unless otherwise specified herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least a part of the steps in the flowchart of the accompanying drawings may include multiple sub-steps or multiple stages, and these sub-steps or stages are not necessarily executed at the same time, but can be executed at different times, and their execution order is not necessarily sequential, but can be executed in turn or alternately with other steps or at least a part of the sub-steps or stages of other steps.
[0121] The above are only some implementation methods of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.
Claims
1. A traffic signal indication monitoring method, characterized in that: include: Obtaining image information of each traffic light in a preset area, wherein the image information is an image when one unit of the traffic light is lit; Determining whether there is an abnormal signal light based on the image information; If there is an abnormal signal light, determining the abnormality degree of each abnormal signal light based on the image information, and obtaining video information of the intersection where each abnormal signal light is located; Determine the motor vehicle flow, non-motor vehicle flow and pedestrian flow at the intersection where the abnormal signal light is located based on the video information; Determine the importance of each intersection where the abnormal signal light is located based on the motor vehicle flow, non-motor vehicle flow and pedestrian flow; Based on the abnormality degree and importance, it is determined whether there is a target intersection, and the target intersection is an intersection that requires staff to intervene to direct traffic; If there is a target intersection, output prompt information.
2. A traffic signal indication monitoring method according to claim 1, characterized in that: The determining whether there is an abnormal signal light based on the image information includes: Determining the similarity between the image information and preset image information; If there is a signal light whose similarity is lower than the preset similarity threshold, then there is an abnormal signal light; If there is no signal light whose similarity is lower than the preset similarity threshold, then there is no abnormal signal light.
3. A traffic signal indication monitoring method according to claim 1, characterized in that: The determining the abnormality degree of each abnormal signal light based on the image information includes: determining a pixel value of the abnormal signal light based on the image information; Determine the area of the region where the pixel value is lower than a preset pixel threshold; Determine the first number of lamp beads based on the ratio of the area to the preset area of a single lamp bead, and determine a first ratio of the first number of lamp beads to a preset number threshold, wherein the first lamp bead is a lamp bead whose pixel value is lower than the preset pixel threshold; Determine the scores of all second lamp beads based on the image information, each of the second lamp beads being a lamp bead whose pixel value reaches a preset pixel threshold; A first score is determined based on the first ratio, the second lamp bead score and the respective first coefficients, wherein the first score represents the abnormality degree of each abnormal signal lamp.
4. A traffic signal indication monitoring method according to claim 3, characterized in that: The determining the second lamp bead score based on the image information includes: Determine the number of second lamp beads; Determine an average pixel value of the second lamp bead based on the image information; Obtaining the usage time of the abnormal signal light; The second lamp bead score is determined based on the number of the second lamp beads, the average pixel value, the usage time and the respective second coefficients.
5. A traffic signal indication monitoring method according to claim 1, characterized in that: The determining whether there is a target intersection based on the abnormality degree and importance degree includes: determining a second score based on the abnormality degree, the importance degree, and respective second weights; Obtain the historical damage count of the intersection; determining a third score based on the second score, the number of historical damages, and respective third coefficients; If the third score is lower than a preset score threshold, it is determined that there is a target intersection; If the third score reaches the preset score threshold, it is determined that there is no target intersection.
6. A traffic signal indication monitoring method according to claim 1, characterized in that: The output prompt information includes: Obtaining the location of staff within a preset range of the target intersection; Determine a route for the staff member to the target intersection, and determine a congestion level of the route; Determine the distance from the worker to the target intersection based on the position; Determine the target staff member based on the distance and congestion level; Output prompt information to the target staff member.
7. A traffic signal indication monitoring method according to claim 3, characterized in that: The method further comprises: Determine a target score based on the first number of lamp beads, the area, and respective target coefficients; Determine the number of circles and target brightness of the target lamp bead based on the target score, the target lamp bead being the lamp bead outside the area where the first lamp bead is located; Control to increase the brightness of the target lamp bead to the target brightness.
8. A traffic signal indication monitoring device, characterized in that: include: An acquisition module, used to acquire image information of each traffic light in a preset area, wherein the image information is an image when one unit of the traffic light is lit; A first judging module, configured to judge whether there is an abnormal signal light based on the image information; A first determination module is used to determine the abnormality degree of each abnormal signal light based on the image information if there is an abnormal signal light, and obtain video information of the intersection where each abnormal signal light is located; A second determination module is used to determine the motor vehicle flow, non-motor vehicle flow and pedestrian flow at the intersection where the abnormal signal light is located based on the video information; A third determination module is used to determine the importance of each intersection where the abnormal signal light is located based on the motor vehicle flow, non-motor vehicle flow and pedestrian flow; A second judgment module is used to judge whether there is a target intersection based on the abnormality degree and importance, and the target intersection is an intersection that requires staff to intervene to direct traffic; The output module is used to output prompt information if there is a target intersection.
9. An electronic device, characterized in that: It includes: at least one processor; Memory; At least one application, wherein the at least one application is stored in the memory and is configured to be executed by the at least one processor, and the at least one application is used to execute a traffic signal indication monitoring method according to any one of claims 1 to 7.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed in a computer, the computer is caused to execute a traffic signal indication monitoring method as claimed in any one of claims 1 to 7.
Citation Information
Cited By
Traffic signal lamp emergency control method and system, terminal and storage medium
CN120998052A