A method for adjusting a green-to-traffic ratio, an electronic device, and a storage medium
Patent Information
- Application Number
- CN202410103934.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-01-24
- Publication Date
- 2026-09-22
- Estimated Expiration
- 2044-01-24
AI Technical Summary
[0004]当预测出的绿信比与当前周期内绿信比相差过多时,直接将目标交通信号灯下一个信号周期内各个相位对应的实际绿信比调整为预测出的目标交通信号灯的下一个信号周期内各个相位对应的绿信比容易造成道路拥堵,降低道路的通行效率
[0027]本发明提供的调整绿信比的方法能够获取候选绿信比列表,当所有的相位在候选绿信比列表中对应的候选绿信比与当前信号周期中对应的绿信比的差的绝对值均不大于预设绿信比差值时,将目标交通信号灯的相位在当前信号周期后的所有信号周期中的绿信比均调整为相位在候选绿信比列表中对应的候选绿信比,否则,获取绿信比调整差值,根据候选绿信比和当前绿信比的差值和绿信比调整差值,获取第一目标绿信比、第二目标绿信比和第三目标绿信比,根据第一目标绿信比、第二目标绿信比和第三目标绿信比,对目标交通信号灯的当前信号周期后的信号周期内相位对应的绿信比进行调整,将目标交通信号灯的绿信比的大小逐渐调整为与候选绿信比相同的大小,并非直接将目标交通信号灯的绿信比调整为候选绿信比,不会造成交通拥堵,有利于提高道路的通行效率。
Smart Images

Figure CN117894198B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of intelligent transportation technology, and in particular to a method, electronic device, and storage medium for adjusting the green credit ratio. Background Technology
[0002] Existing methods for adjusting the green ratio of traffic lights mostly involve obtaining historical traffic flow and average vehicle speed for each phase of the intersection where the traffic light is located, analyzing the historical traffic flow and average vehicle speed for each phase, predicting the traffic flow and average vehicle speed for each phase in the next signal cycle, analyzing the predicted traffic flow and average vehicle speed for each phase, predicting the green ratio for each phase in the next signal cycle, and then adjusting the actual green ratio for each phase in the next signal cycle to the predicted green ratio for each phase in the next signal cycle through the system.
[0003] However, the above method also has the following technical problems:
[0004] When the predicted green ratio differs significantly from the green ratio in the current cycle, directly adjusting the actual green ratio of each phase in the next signal cycle of the target traffic light to the predicted green ratio of each phase in the next signal cycle of the target traffic light can easily cause road congestion and reduce road traffic efficiency. Summary of the Invention
[0005] To address the aforementioned technical problems, the technical solution adopted by this invention is as follows:
[0006] According to a first aspect of the present invention, a method for adjusting the green ratio of a target traffic light is provided, the method comprising the following steps:
[0007] S1. Obtain H = {H1, H2, ..., H...} j H n}, where H is the candidate green light ratio list, H j For A 0 j The corresponding candidate green light ratio, A 0 j Let j be the j-th phase of the target traffic signal light, where j ranges from 1 to n and n is the number of phases of the target traffic signal light. The phase of the target traffic signal light refers to the state of the signal light that grants a corresponding green light duration to traffic flows in different directions.
[0008] S2, when |H1-H 0 1|≤T、|H2-H 0 2|≤T、……、|H j-H 0 j |≤T、……、|H n -H 0 n When |≤T, A will be applied to all signal periods following the current signal period. 0 j The corresponding green credit ratios have all been adjusted to H. j Otherwise, adjust A according to the fourth processing method. 0 j The corresponding green credit ratio, where H 0 j For the target traffic light, in the current signal cycle, A 0 j The corresponding green ratio, T is the preset green ratio difference; the fourth processing method includes the following sub-steps:
[0009] S21, when H j -H 0 j ≠max(H1-H 0 1, H2-H 0 2, ..., H j -H 0 j H n -H 0 n And H j -H 0 j ≠min(H1-H 0 1, H2-H 0 2, ..., H j -H 0 j H n -H 0 n When ), A will be in the xth signal cycle after the current signal cycle of the target traffic light. 0 j The corresponding green credit ratio is adjusted to W. xj And when W xj =H j Stop adjusting at that time, W xj For A 0 j For the corresponding x-th first target green light ratio, max() is the maximum value acquisition function, min() is the minimum value acquisition function, x>0, W xj Meets the following conditions:
[0010] If x = 1, W xj =H 0 j +U xj Uxj For A 0 j The corresponding x-th green light ratio adjustment difference; if x≠1, W xj =W (x-1)j +U xj W (x -1)j is A 0 j The corresponding (x-1)th first target green light ratio, U xj Meets the following conditions:
[0011] When x = 1, U xj =min(0.02, |H j -H 0 j |)×(H j -H 0 j ) / |H j -H 0 j |;
[0012] When x≠1 and |H j -H 0 j -U (x-1)j When |=0, U xj =0, U (x-1)j For A 0 j The corresponding (x-1)th green light ratio adjustment difference;
[0013] When x≠1 and |H j -H 0 j -U (x-1)j |≠0, U xj =min(0.02, |H j -H 0 j -U (x-1)j |)×(H j -H 0 j -U (x-1)j ) / |H j -H 0 j -U (x-1)j |
[0014] S22, when H j -H 0 j =max(H1-H 0 1, H2-H 0 2, ..., H j -H 0j H n -H 0 n When ), A will be in the xth signal cycle after the current signal cycle of the target traffic light. 0 j The corresponding green credit ratio is adjusted to W. 0 xj And when W 0 xj =H j Stop adjusting at that time, W 0 xj For A 0 j The corresponding x-th second target green light ratio, W 0 xj Meets the following conditions:
[0015] When x = 1 and Σ n j=1 U xj When W ≤ 0 0 xj =H 0 j -Σ n j=1 U xj ;
[0016] When x = 1 and Σ n j=1 U xj When >0, W 0 xj =H 0 j +U xj ;
[0017] When x≠1 and Σ n j=1 U xj When W ≤ 0 0 xj =W 0 (x-1)j -Σ n j=1 U xj W 0 (x-1)j For A 0 j The corresponding green light ratio for the (x-1)th second target;
[0018] When x≠1 and Σ n j=1 U xj When >0, W 0 xj =W 0 (x-1)j +Uxj .
[0019] S23, when H j -H 0 j =min(H1-H 0 1, H2-H 0 2, ..., H j -H 0 j H n -H 0 n When ), A will be in the xth signal cycle after the current signal cycle of the target traffic light. 0 j The corresponding green credit ratio is adjusted to V. xj And when V xj =H j Stop adjusting at this time, V xj For A 0 j The corresponding x-th third target green light ratio, V xj Meets the following conditions:
[0020] When x = 1 and Σ n j=1 U xj When V > 0, xj =H 0 j -Σ n j=1 U xj ;
[0021] When x = 1 and Σ n j=1 U xj When ≤0, V xj =H 0 j +U xj ;
[0022] When x≠1 and Σ n j=1 U xj When V > 0, xj =V (x-1)j -Σ n j=1 U xj V (x-1)j For A 0 j The corresponding green light ratio of the (x-1)th third target;
[0023] When x≠1 and Σ n j=1 U xj When ≤0, V xj=V (x-1)j +U xj .
[0024] According to a second aspect of the present invention, a non-transitory computer-readable storage medium is provided, wherein a computer program or at least one computer-executable instruction is stored in the storage medium, the computer program or at least one computer-executable instruction being loaded and executed by a processor to implement the aforementioned method.
[0025] According to a third aspect of the present invention, an electronic device is provided, comprising: a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the aforementioned method.
[0026] The present invention has at least the following beneficial effects:
[0027] The method for adjusting the green ratio provided by this invention can obtain a candidate green ratio list. When the absolute value of the difference between the candidate green ratio corresponding to all phases in the candidate green ratio list and the green ratio corresponding to the current signal cycle is not greater than a preset green ratio difference, the green ratio of the target traffic light phase in all signal cycles after the current signal cycle is adjusted to the candidate green ratio corresponding to the phase in the candidate green ratio list. Otherwise, a green ratio adjustment difference is obtained. Based on the difference between the candidate green ratio and the current green ratio and the green ratio adjustment difference, a first target green ratio, a second target green ratio, and a third target green ratio are obtained. Based on the first target green ratio, the second target green ratio, and the third target green ratio, the green ratio corresponding to the phase in the signal cycles after the current signal cycle of the target traffic light is adjusted, gradually adjusting the size of the target traffic light's green ratio to the same size as the candidate green ratio, rather than directly adjusting the target traffic light's green ratio to the candidate green ratio. This avoids traffic congestion and helps improve road traffic efficiency. Attached Figure Description
[0028] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0029] Figure 1 This is a flowchart of a method for adjusting the green credit ratio provided in an embodiment of the present invention. Detailed Implementation
[0030] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0031] Embodiments of the present invention provide a method for adjusting the green ratio of a target traffic light. The method includes the following steps: Figure 1 As shown:
[0032] S1. Obtain H = {H1, H2, ..., H...} j H n}, where H is the candidate green light ratio list, H j For A 0 j The corresponding candidate green light ratio, A 0 j Let j be the j-th phase of the target traffic light, where j ranges from 1 to n, and n is the number of phases of the target traffic light.
[0033] Specifically, the phase of a target traffic light refers to the state of the traffic light that grants a corresponding green light duration to traffic flows in different directions.
[0034] Specifically, the status of traffic lights includes: red, yellow, and green.
[0035] Specifically, the phase type of the target traffic light is either a left-turn phase or a straight-ahead phase. A left-turn phase indicates that the direction of travel for vehicles is to turn left, while a straight-ahead phase indicates that the direction of travel for vehicles is to go straight.
[0036] Specifically, S1 includes the following sub-steps:
[0037] S11. Obtain A = {A1, A2, ..., A...} i , ..., A m}, A i ={A i1 A i2 , ..., A ij , ..., A in},in,
[0038] A is the initial green light ratio list set, A i For A 1 i The corresponding initial green ratio list, A 1 iThe initial green ratio scheme ID corresponding to the adaptive traffic control system controlling the target traffic light is A. The value of i ranges from 1 to m, and m is the number of initial green ratio scheme IDs corresponding to the adaptive traffic control system controlling the target traffic light. ij For A i China A 0 j The corresponding initial green ratio, the initial green ratio scheme ID and the initial green ratio list corresponding to the initial green ratio scheme ID are the green ratio scheme ID and the green ratio list corresponding to the green ratio scheme ID in the adaptive traffic control system that controls the target traffic light. The green ratio scheme is a scheme that presents the green ratio corresponding to all phases of the target traffic light.
[0039] S12, Obtain B = {B} 1 B 2 B 3}, B 1 ={B 1 1, B 1 2, ..., B 1 i , ..., B 1 m}, B 1 i ={B 1 i1 B 1 i2 , ..., B 1 ij , ...,
[0040] B 1 in}, where B is the set of traffic saturation lists corresponding to A, B 1 Let A be the first traffic saturation list set, and B be the second traffic saturation list set. 1 i For A i The corresponding first traffic saturation list, B 1 ij For A ij The corresponding first traffic saturation, B 2 Let A be the set of lists corresponding to the second traffic saturation, and B be the set of lists corresponding to the second traffic saturation. 2 ={B 2 1, B 2 2, ..., B 2 i , ..., B 2 m}, B 2 i ={B 2 i1 B 2i2 , ..., B 2 ij , ..., B 2 in}, B 2 i For A i The corresponding second traffic saturation list, B 2 ij For A ij The corresponding second traffic saturation, B 3 Let A be the set of third traffic saturation lists, and B be the set of lists corresponding to A. 3 ={B 3 1, B 3 2, ..., B 3 i , ..., B 3 m}, B 3 i ={B 3 i1 B 3 i2 , ..., B 3 ij , ..., B 3 in}, B 3 i For A i The corresponding third traffic saturation list, B 3 ij For A ij The corresponding third traffic saturation level is D, and the first traffic saturation level is D. 1 The traffic saturation corresponding to the phase of the target traffic light, and the second traffic saturation is at D. 2 The traffic saturation corresponding to the phase of the target traffic light, and the third traffic saturation is in D. 3 Traffic saturation corresponding to the phase of the target traffic light, D 1 D 2 The previous signal cycle, D 2 D 3 The previous signal cycle, D 3 The current signal cycle of the target traffic light.
[0041] Specifically, the signal cycle of the target traffic light is the total duration for all phases of the target traffic light to appear once in sequence.
[0042] Specifically, S12 includes the following sub-steps:
[0043] S121, If A i A in i1 With D 1 China A0 1 corresponds to the same green credit ratio, A i2 With D 1 China A 0 2 corresponds to the same green credit ratio, ..., A ij With D 1 China A 0 j The corresponding green credit ratios are the same, ..., A in With D 1 China A 0 n If the corresponding green credit ratios are the same, then A will be... 1 i As E and proceeding to step S22, if A1, A2, ..., A i , ..., A m There exists at least one A in each case. ij With D 1 China A 0 j If the corresponding green light ratios are not the same, the processing ends, where E is D. 1 The corresponding second green credit ratio scheme ID.
[0044] S122, When E = A 1 i At that time, obtain B 1 ij Among them, B 1 ij Meets the following conditions:
[0045] B 1 ij =λ j ×Q j ×ZQ / F j ×(R j -QR-LS), Q j D 1 China A 0 j The corresponding actual traffic flow, F j For A 0 j The corresponding maximum historical actual traffic flow, λ j For F j In the corresponding historical time period A 0 j The corresponding green light ratio, ZQ is the signal cycle duration of the target traffic light, and R j D 1 China A 0 jThe corresponding phase duration, wherein the phase duration is the sum of the phase display green light duration and the green light interval of the traffic light, QR is the preset all-red duration corresponding to the target traffic light, LS is the preset start-up loss duration corresponding to the target traffic light, and the preset all-red duration and preset start-up loss duration are preset durations set by those skilled in the art according to actual needs, F j Meets the following conditions:
[0046] F j =max(G j1 G j2 , ..., G je , ..., G jf `max()` is the function to get the maximum value. je D 1 In the corresponding e-th historical time period, A 0 j The corresponding actual traffic flow, where e ranges from 1 to f, and f is D. 1 The corresponding number of historical time periods, all of which are 10 minutes in length, are known to those skilled in the art. Any method for obtaining actual traffic flow or the method for obtaining the red light duration corresponding to the phase of a traffic light in the prior art are within the protection scope of this invention, and will not be elaborated further here.
[0047] Specifically, D 1 The corresponding historical period is D. 1 The time period between.
[0048] Specifically, the unit of measurement for traffic flow is vehicles per hour.
[0049] Specifically, the green light duration corresponding to the phase can be understood as the duration during which the signal light state presented by the phase is green.
[0050] Specifically, the green light interval of a traffic signal is the time interval between the end of the green light for one conflicting traffic flow and the start of the green light for the next traffic flow.
[0051] S123, When E≠A 1 i At that time, obtain B 1 ij Among them, B 1 ij Meets the following conditions:
[0052] B 1 ij =Z 1 j ×Z 0 j / A ij Z 1j A is the initial green ratio list corresponding to the initial green ratio scheme ID that is the same as E. 0 j The corresponding initial green light ratio corresponds to the first traffic saturation level, Z. 0 j A is the initial green ratio list corresponding to the initial green ratio scheme ID that is the same as E. 0 j The corresponding initial green light ratio.
[0053] S124, D obtained from steps S121-S123 1 The corresponding second green credit ratio scheme ID, according to D 1 The corresponding second green ratio scheme ID is obtained as B. 1 ij In the same way, obtain D 2 The corresponding second green credit ratio scheme ID, according to D 2 The corresponding second green ratio scheme ID is obtained as B. 2 ij This can be understood as: replacing D in step S121. 1 Replace with D 2 B in step S122 1 ij Replace with B 2 ij D 1 Replace with D 2 B in step S123 1 ij Replace with B 2 ij Replace the first traffic saturation with the second traffic saturation and execute steps S121-S123.
[0054] S125, D obtained from steps S121-S123 1 The corresponding second green credit ratio scheme ID, according to D 1 The corresponding second green ratio scheme ID is obtained B. 1 ij In the same way, obtain D 3 The corresponding second green credit ratio scheme ID, according to D 3 The corresponding second green ratio scheme ID is obtained as B. 3 ij This can be understood as: replacing D in step S121. 1 Replace with D 3 B in step S122 1 ij Replace with B 3 ij D 1Replace with D 3 B in step S123 1 ij Replace with B 3 ij Replace the first traffic saturation with the third traffic saturation and execute steps S121-S123.
[0055] Through the above steps, the second green ratio scheme ID corresponding to the previous signal cycle of the current signal cycle of the target traffic light is obtained. When the second green ratio ID is the same as the i-th initial green ratio scheme ID corresponding to the adaptive traffic control system controlling the target traffic light, the first traffic saturation is obtained based on the actual traffic flow corresponding to the phase in the signal cycle, the maximum historical actual traffic flow corresponding to the phase, the green ratio corresponding to the phase in the historical time period corresponding to the maximum historical actual traffic flow corresponding to the phase, the signal cycle duration of the target traffic light, the red light duration corresponding to the phase in the signal cycle, the preset all-red duration corresponding to the target traffic light, and the preset start-up loss duration corresponding to the target traffic light. When the second green ratio ID is the same as the i-th initial green ratio scheme ID corresponding to the adaptive traffic control system controlling the target traffic light, the first traffic saturation is obtained. When the i-th initial green ratio scheme ID corresponding to the adaptive traffic control system is different, the first traffic saturation is obtained according to the first traffic saturation corresponding to the initial green ratio of the phase in the initial green ratio list corresponding to the initial green ratio scheme ID with the same initial green ratio scheme ID as the second green ratio scheme ID, the initial green ratio of the phase in the initial green ratio list corresponding to the initial green ratio scheme ID with the same initial green ratio scheme ID as the second green ratio scheme ID, and the initial green ratio of the phase in the initial green ratio list corresponding to the i-th initial green ratio scheme ID. Similarly, the second traffic saturation is obtained according to the second green ratio scheme ID corresponding to the previous signal cycle of the current signal cycle, and the third traffic saturation is obtained according to the second green ratio scheme ID corresponding to the current signal cycle. This helps to improve the accuracy of obtaining traffic saturation.
[0056] S13. Process B according to the first processing method to obtain C = {C 1 C 2 C 3}, where C is the list of IDs for the first green ratio scheme corresponding to B, C 1 For B 1 The corresponding first green credit ratio scheme ID, C 2 For B 2 The corresponding first green credit ratio scheme ID, C 3 For B 3 The corresponding first green credit ratio scheme ID.
[0057] Specifically, the first processing method includes the following sub-steps:
[0058] S131, According to B1 Get C 0 ={C 0 1, C 0 2, ..., C 0 i , ..., C 0 m}, C 0 For the list of maximum traffic saturation, C 0 i For A 1 i The corresponding maximum traffic saturation, where C 0 i Meets the following conditions:
[0059] C 0 i =max(B 1 i1 B 1 i2 , ..., B 1 ij , ..., B 1 in ).
[0060] S132, when C 0 All C 0 i When all are different, C 0 The smallest C 0 i Corresponding A 1 i As C 1 Proceed to step S134 if necessary, otherwise proceed to step S133.
[0061] S133, when C 0 When any two maximum traffic saturation levels are the same, B will be... 1 1, B 1 2, ..., B 1 i , ..., B 1 m The largest first traffic saturation value in the middle is removed to update B. 1 1, B 1 2, ..., B 1 i , ..., B 1 m And proceed to step S131; this can be understood as, putting B... 1 1. In relation to max(B) 1 11 B 1 12 , ..., B 11j , ..., B 1 1n Equal B 1 1j Delete, B 1 2 and max(B) 1 21 B 1 22 , ..., B 1 2j , ..., B 1 2n Equal B 1 2j Delete, ..., B 1 i In and max(B) 1 i1 B 1 i2 , ..., B 1 ij , ..., B 1 in Equal B 1 ij Delete, ..., B 1 m In and max(B) 1 m1 B 1 m2 , ..., B 1 mj , ..., B 1 mn Equal B 1 mj delete.
[0062] S134, Using steps S131-S133 according to B 1 Get C 1 In the same way, according to B 2 Get C 2 This can be understood as: B in step S131 1 Replace with B 2 (B) 1 i1 B 1 i2 , ..., B 1 ij , ..., B 1 in Replace ) with (B 2 i1 B 2 i2 , ..., B 2 ij, ..., B 2 in ), in step S132, C 1 Replace with C 2 B in step S133 1 Replace with B 2 (B) 1 i1 B 1 i2 , ..., B 1 ij , ..., B 1 in Replace ) with (B 2 i1 B 2 i2 , ..., B 2 ij , ..., B 2 in Then execute steps S131-S133.
[0063] S135, according to steps S131-S133 based on B 1 Get C 1 In the same way, according to B 3 Get C 3 This can be understood as: B in step S131 1 Replace with B 3 (B) 1 i1 B 1 i2 , ..., B 1 ij , ..., B 1 in Replace ) with (B 3 i1 B 3 i2 , ..., B 3 ij , ..., B 3 in ), in step S132, C 1 Replace with C 3 B in step S133 1 Replace with B 3 (B) 1 i1 B 1 i2 , ..., B 1 ij , ..., B 1 in Replace ) with (B 3i1 B 3 i2 , ..., B 3 ij , ..., B 3 in Then execute steps S131-S133.
[0064] Through the above steps, a maximum traffic saturation list is obtained based on the first traffic saturation list set. When all maximum traffic saturations in the maximum traffic saturation list are different, the initial green ratio scheme ID corresponding to the smallest maximum traffic saturation in the maximum traffic saturation list is used as the first green ratio scheme ID corresponding to the first traffic saturation list set. Otherwise, the largest first traffic saturation in each first traffic saturation list is deleted, and a new maximum traffic saturation list is obtained. Then, the first green ratio scheme ID corresponding to the first traffic saturation list set is obtained. The same method is used to obtain the first green ratio scheme ID corresponding to the second traffic saturation list set and the first green ratio scheme ID corresponding to the third traffic saturation list set. This helps to improve the accuracy of obtaining the first green ratio scheme ID.
[0065] S14, when C 1 C 2 C 3 Does not conform to C 1 =C 2 =C 3 At that time, the green ratio of the target traffic light is adjusted according to the second processing method.
[0066] Specifically, the second processing method includes the following sub-steps:
[0067] S141, when C 1 =C 2 Or C 1 =C 3 At that time, it will be with C 1 The same A 1 i Corresponding A i As H.
[0068] S142, when C 2 =C 3 At that time, it will be with C 2 The same A 1 i Corresponding A i As H.
[0069] S143, when C 1 ≠C 2 C 2 ≠C 3 And C 1 ≠C3 At that time, H is obtained according to the third processing method.
[0070] Specifically, the third processing method includes the following sub-steps:
[0071] S1431. Obtain J = {J1, J2, ..., J...} j , ..., J n}, where J is the list of minimum green light ratios, J j For A 0 j The corresponding minimum green light ratio, where, when A 0 j When the phase type is a left-turn phase, J j =0.1, when A 0 j When the phase type is a straight phase, J j =0.2.
[0072] S1432, Obtain J 0 ={J 0 1, J 0 2, ..., J 0 j , ..., J 0 n}, where J 0 For the list of maximum green credit ratios, J 0 j For A 0 j The corresponding maximum green light ratio, J 0 j Meets the following conditions:
[0073] J 0 j =1-(J1+J2+……+J (j-1) +J (j+1) +……+J n ), J (j-1) For A 0 (j-1) The corresponding minimum green light ratio, J (j+1) For A 0 (j+1) The corresponding minimum green light ratio.
[0074] S1433. Obtain M = {M1, M2, ..., M} g M h}, M g ={M g1 M g2 M gj M gn},That
[0075] In the diagram, M represents the set of candidate green credit ratio lists. g Let M be the g-th candidate green light ratio list, where g ranges from 1 to h, h is the number of candidates in the green light ratio list, and M is the number of candidates in the list. gj For M g China A 0 j The corresponding candidate green light ratio, M gj Meets the following conditions:
[0076] When g = 1, M gj =J j ;
[0077] When g≠1, M gj =M (g-1)j +min(max(0.01,ceil((J 0 j -J j ) / ceil(100 / n)) / 100)), ceil() is the floor function, min() is the minimum value function, M (g-1)j For A in the (g-1)th candidate green ratio list 0 j The corresponding green credit ratio for candidates.
[0078] Specifically, M hj ≤J 0 j .
[0079] S1434. Obtain N = {N1, N2, ..., N} g , ..., N h}, where N is the list of average green light ratio differences corresponding to M, N g For M g The corresponding average green light ratio difference, N g Meets the following conditions:
[0080] N g =Σ n j=1 |M gj -H 0 j | / n,H 0 j For the target traffic light, in the current signal cycle, A 0 j The corresponding green credit ratio.
[0081] S1435, when N g =min(N1, N2, ..., N) g , ..., N h When N is used, g The corresponding Mg As H.
[0082] Through the above steps, when the first green ratio scheme IDs corresponding to the first traffic saturation list set, the second traffic saturation list set, and the third traffic saturation list set are all different, a minimum green ratio list is obtained. Based on the minimum green ratio list, a maximum green ratio list is obtained. Based on the minimum and maximum green ratio lists, a candidate green ratio list set is obtained. Based on the candidate green ratio list set, an average green ratio difference list is obtained. The candidate green ratio list corresponding to the smallest average green ratio difference in the average green ratio difference list is selected as the shortlist of candidate green ratios. This can be understood as selecting the candidate green ratio closest to the green ratio corresponding to the current signal cycle as the shortlist, which helps improve the accuracy of obtaining the shortlist of candidate green ratios. When the absolute value of the difference between the candidate green ratio corresponding to any phase in the candidate green ratio list and the corresponding green ratio in the current signal cycle is not greater than the preset green ratio difference, the green ratio of the target traffic light phase in all subsequent signal cycles is adjusted to the candidate green ratio corresponding to the phase in the candidate green ratio list. Otherwise, the green ratio adjustment difference is obtained, and the green ratio of the target traffic light is adjusted according to the green ratio adjustment difference. Through the above steps, the obtained candidate green ratio list is more accurate, and when the absolute value of the difference between the candidate green ratio corresponding to any phase in the candidate green ratio list and the corresponding green ratio in the current signal cycle is greater than the preset green ratio difference, the green ratio of the target traffic light is adjusted according to the green ratio adjustment difference, which will not cause traffic congestion and is conducive to improving road traffic efficiency.
[0083] S2, when |H1-H 0 1|≤T、|H2-H 0 2|≤T、……、|H j -H 0 j |≤T、……、|H n -H 0 n When |≤T, A will be applied to all signal periods following the current signal period. 0 j The corresponding green credit ratios have all been adjusted to H. j Otherwise, adjust A according to the fourth processing method. 0 j The corresponding green ratio, where T is the preset green ratio difference. As those skilled in the art know, the preset green ratio difference is a value that those skilled in the art have set in advance according to actual needs, and will not be elaborated here.
[0084] Specifically, the fourth processing method includes the following sub-steps:
[0085] S21, when H j -H 0 j ≠max(H1-H 0 1, H2-H 0 2, ..., H j -H 0 j H n -H 0 n And H j -H 0 j ≠min(H1-H 0 1, H2-H 0 2, ..., H j -H 0 j H n -H 0 n When ), A will be in the xth signal cycle after the current signal cycle of the target traffic light. 0 j The corresponding green credit ratio is adjusted to W. xj And when W xj =H j Stop adjusting at that time, W xj For A 0 j For the corresponding x-th first target green light ratio, max() is the maximum value acquisition function, min() is the minimum value acquisition function, x>0, W xj Meets the following conditions:
[0086] If x = 1, W xj =H 0 j +U xj U xj For A 0 j The corresponding x-th green light ratio adjustment difference; if x≠1, W xj =W (x-1)j +U xj W (x-1)j For A 0 j The corresponding (x-1)th first target green light ratio, U xj Meets the following conditions:
[0087] When x = 1, U xj =min(0.02, |H j -H 0 j |)×(H j -H 0j ) / |H j -H 0 j |;
[0088] When x≠1 and |H j -H 0 j -U (x-1)j When |=0, U xj =0, U (x-1)j For A 0 j The corresponding (x-1)th green light ratio adjustment difference;
[0089] When x≠1 and |H j -H 0 j -U (x-1)j |≠0, U xj =min(0.02, |H j -H 0 j -U (x-1)j |)×(H j -H 0 j -U (x-1)j ) / |H j -H 0 j -U (x-1)j |
[0090] S22, when H j -H 0 j =max(H1-H 0 1, H2-H 0 2, ..., H j -H 0 j H n -H 0 n When ), A will be in the xth signal cycle after the current signal cycle of the target traffic light. 0 j The corresponding green credit ratio is adjusted to W. 0 xj And when W 0 xj =H j Stop adjusting at that time, W 0 xj For A 0 j The corresponding x-th second target green light ratio, W 0 xj Meets the following conditions:
[0091] When x = 1 and Σ n j=1 U xj When W ≤ 0 0 xj =H 0 j -Σ n j=1 U xj ;
[0092] When x = 1 and Σ n j=1 U xj When >0, W 0 xj =H 0 j +U xj ;
[0093] When x≠1 and Σ n j=1 U xj When W ≤ 0 0 xj =W 0 (x -1)j-Σ n j=1 U xj W 0 (x -1)j is A 0 j The corresponding green light ratio for the (x-1)th second target;
[0094] When x≠1 and Σ n j=1 U xj When >0, W 0 xj =W 0 (x -1)j+U xj .
[0095] S23, when H j -H 0 j =min(H1-H 0 1, H2-H 0 2, ..., H j -H 0 j H n -H 0 n When ), A will be in the xth signal cycle after the current signal cycle of the target traffic light. 0 j The corresponding green credit ratio is adjusted to V. xj And when V xj=H j Stop adjusting at this time, V xj For A 0 j The corresponding x-th third target green light ratio, V xj Meets the following conditions:
[0096] When x = 1 and Σ n j=1 U xj When V > 0, xj =H 0 j -Σ n j=1 U xj ;
[0097] When x = 1 and Σ n j=1 U xj When ≤0, V xj =H 0 j +U xj ;
[0098] When x≠1 and Σ n j=1 U xj When V > 0, xj =V (x -1)j-Σ n j=1 U xj V (x -1)j is A 0 j The corresponding green light ratio of the (x-1)th third target;
[0099] When x≠1 and Σ n j=1 U xj When ≤0, V xj =V (x -1)j+U xj .
[0100] Through the above steps, when the absolute value of the difference between the candidate green ratio corresponding to any phase in the candidate green ratio list and the corresponding green ratio in the current signal cycle is greater than the preset green ratio difference, a green ratio adjustment difference is obtained. Based on the difference between the candidate green ratio and the current green ratio and the green ratio adjustment difference, a first target green ratio, a second target green ratio, and a third target green ratio are obtained. Based on the first target green ratio, the second target green ratio, and the third target green ratio, the green ratio corresponding to the phase in the signal cycle after the current signal cycle of the target traffic light is adjusted, gradually adjusting the green ratio of the target traffic light to the same size as the candidate green ratio. Instead of directly adjusting the green ratio of the target traffic light to the candidate green ratio, this does not cause traffic congestion and helps improve road traffic efficiency.
[0101] Embodiments of the present invention also provide a non-transitory computer-readable storage medium that can be disposed in an electronic device to store a computer program or at least one computer-executable instruction related to implementing a method in the method embodiments, the computer program or at least one computer-executable instruction being loaded and executed by the processor to implement the method provided in the above embodiments.
[0102] Embodiments of the present invention also provide an electronic device, including: a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the method provided in the above embodiments.
[0103] Embodiments of the present invention also provide a computer program product including program code, which, when the program product is run on an electronic device, causes the electronic device to perform the steps of the methods described above in various exemplary embodiments of the present invention.
[0104] The method for adjusting the green ratio provided by this invention can obtain a candidate green ratio list. When the absolute value of the difference between the candidate green ratio corresponding to all phases in the candidate green ratio list and the green ratio corresponding to the current signal cycle is not greater than a preset green ratio difference, the green ratio of the target traffic light phase in all signal cycles after the current signal cycle is adjusted to the candidate green ratio corresponding to the phase in the candidate green ratio list. Otherwise, a green ratio adjustment difference is obtained. Based on the difference between the candidate green ratio and the current green ratio and the green ratio adjustment difference, a first target green ratio, a second target green ratio, and a third target green ratio are obtained. Based on the first target green ratio, the second target green ratio, and the third target green ratio, the green ratio corresponding to the phase in the signal cycles after the current signal cycle of the target traffic light is adjusted, gradually adjusting the size of the target traffic light's green ratio to the same size as the candidate green ratio, rather than directly adjusting the target traffic light's green ratio to the candidate green ratio. This avoids traffic congestion and helps improve road traffic efficiency.
[0105] While specific embodiments of the invention have been described in detail by way of examples, those skilled in the art should understand that the examples are for illustrative purposes only and are not intended to limit the scope of the invention. Those skilled in the art should also understand that various modifications can be made to the embodiments without departing from the scope and spirit of the invention.
Claims
1. A method for adjusting the green ratio of a target traffic light, characterized in that, The method includes the following steps: S1. Obtain H = {H1, H2, ..., H...} j H n }, where H is the candidate green light ratio list, H j For A 0 j The corresponding candidate green light ratio, A 0 j Let j be the j-th phase of the target traffic signal light, where j can be 1 to n and n is the number of phases of the target traffic signal light. The phase of the target traffic signal light refers to the state of the signal light that gives the corresponding green light duration to traffic flows in different directions. S2, when |H1-H 0 1|≤T、|H2-H 0 2|≤T、……、|H j -H 0 j |≤T、……、|H n -H 0 n When |≤T, A will be applied to all signal periods following the current signal period. 0 j The corresponding green credit ratios have all been adjusted to H. j Otherwise, adjust A according to the fourth processing method. 0 j The corresponding green credit ratio, where H 0 j For the target traffic light, in the current signal cycle, A 0 j The corresponding green light ratio, T is the preset green light ratio difference; the fourth processing method includes the following sub-steps: S21, when H j -H 0 j ≠max(H1-H 0 1, H2-H 0 2, ..., H j -H 0 j H n -H 0 n And H j -H 0 j ≠min(H1-H 0 1, H2-H 0 2, ..., H j -H 0 j H n -H 0 n When ), A will be in the xth signal cycle after the current signal cycle of the target traffic light. 0 j The corresponding green credit ratio is adjusted to W. xj And when W xj =H j Stop adjusting at that time, W xj For A 0 j For the corresponding x-th first target green light ratio, max() is the maximum value acquisition function, min() is the minimum value acquisition function, x>0, W xj Meets the following conditions: If x = 1, W xj =H 0 j +U xj U xj For A 0 j The corresponding x-th green light ratio adjustment difference; if x≠1, W xj =W (x-1)j +U xj W (x-1)j For A 0 j The corresponding first target green light ratio, U xj Meets the following conditions: When x = 1, U xj =min(0.02, |H j -H 0 j |)×(H j -H 0 j ) / |H j -H 0 j |; When x≠1 and |H j -H 0 j -U (x-1)j When |=0, U xj =0, U (x-1)j For A 0 j The corresponding (x-1)th green light ratio adjustment difference; When x ≠ 1 and |H j -H 0 j -U (x-1)j | ≠ 0, U xj =min(0.02, |H j -H 0 j -U (x-1)j |) × (H j -H 0 j -U (x-1)j ) / |H j -H 0 j -U (x-1)j |; S22, when H j -H 0 j =max(H1-H 0 1, H2-H 0 2, ..., H j -H 0 j H n -H 0 n When ), A will be in the xth signal cycle after the current signal cycle of the target traffic light. 0 j The corresponding green credit ratio is adjusted to W. 0 xj And when W 0 xj =H j Stop adjusting at that time, W 0 xj For A 0 j The corresponding x-th second target green light ratio, W 0 xj Meets the following conditions: This x=1 and Σ n j=1 U xj ≤0 hours,W 0 xj = H 0 j -Σ n j=1 U xj ; When x = 1 and Σ n j=1 U xj When >0, W 0 xj =H 0 j +U xj ; When x≠1 and Σ n j=1 U xj When W ≤ 0 0 xj =W 0 (x-1)j -Σ n j=1 U xj W 0 (x-1)j For A 0 j The corresponding green light ratio for the (x-1)th second target; When x≠1 and Σ n j=1 U xj When >0, W 0 xj =W 0 (x-1)j +U xj ; S23, when H j -H 0 j =min(H1-H 0 1, H2-H 0 2, ..., H j -H 0 j H n -H 0 n When ), A will be in the xth signal cycle after the current signal cycle of the target traffic light. 0 j The corresponding green credit ratio is adjusted to V. xj And when V xj =H j Stop adjusting at this time, V xj For A 0 j The corresponding x-th third target green light ratio, V xj Meets the following conditions: When x = 1 and Σ n j=1 U xj When V > 0, xj =H 0 j -Σ n j=1 U xj ; When x = 1 and Σ n j=1 U xj When ≤0, V xj =H 0 j +U xj ; When x≠1 and Σ n j=1 U xj When V > 0, xj =V (x-1)j -Σ n j=1 U xj V (x-1)j For A 0 j The corresponding green light ratio of the (x-1)th third target; When x≠1 and Σ n j=1 U xj When ≤0, V xj =V (x-1)j +U xj .
2. The method for adjusting the green credit ratio according to claim 1, characterized in that, S1 includes the following sub-steps: S11, A = {A1, A2, ..., A i , , A m }, A i = {A i1 , A i2 , , A ij , , A in },That In the table, A is the initial green credit ratio list set, A i For A 1 i The corresponding initial green ratio list, A 1 i The initial green ratio scheme ID corresponding to the adaptive traffic control system controlling the target traffic light is A. The value of i ranges from 1 to m, and m is the number of initial green ratio scheme IDs corresponding to the adaptive traffic control system controlling the target traffic light. ij For A i China A 0 j The corresponding initial green ratio, the initial green ratio scheme ID and the initial green ratio list corresponding to the initial green ratio scheme ID are the green ratio scheme ID and the green ratio list corresponding to the green ratio scheme ID in the adaptive traffic control system that controls the target traffic light. The green ratio scheme is a scheme that presents the green ratio corresponding to all phases of the target traffic light. S12, Obtain B = {B} 1 B 2 B 3 }, B 1 ={B 1 1, B 1 2, ..., B 1 i , ..., B 1 m }, B 1 i ={B 1 i1 B 1 i2 , ..., B 1 ij , ..., B 1 in }, where B is the set of traffic saturation lists corresponding to A, B 1 Let A be the first traffic saturation list set, and B be the second traffic saturation list set. 1 i For A i The corresponding first traffic saturation list, B 1 ij For A ij The corresponding first traffic saturation, B 2 Let A be the set of the second traffic saturation list, and B be the set of the second traffic saturation list. 2 ={B 2 1, B 2 2, ..., B 2 i , ..., B 2 m }, B 2 i ={B 2 i1 B 2 i2 , ..., B 2 ij , ..., B 2 in }, B 2 i For A i The corresponding second traffic saturation list, B 2 ij For A ij The corresponding second traffic saturation, B 3 Let A be the set of third traffic saturation lists, and B be the set of lists corresponding to A. 3 ={B 3 1, B 3 2, ..., B 3 i , ..., B 3 m }, B 3 i ={B 3 i1 B 3 i2 , ..., B 3 ij , ..., B 3 in }, B 3 i For A i The corresponding third traffic saturation list, B 3 ij For A ij The corresponding third traffic saturation level is D, and the first traffic saturation level is D. 1 The traffic saturation corresponding to the phase of the target traffic light, and the second traffic saturation is at D. 2 The traffic saturation corresponding to the phase of the target traffic light, and the third traffic saturation is in D. 3 Traffic saturation corresponding to the phase of the target traffic light, D 1 D 2 The previous signal cycle, D 2 D 3 The previous signal cycle, D 3 The current signal cycle of the target traffic light is the total duration of all phases of the target traffic light appearing once in sequence. S13. Process B according to the first processing method to obtain C = {C 1 C 2 C 3 }, where C is the list of IDs for the first green ratio scheme corresponding to B, C 1 For B 1 The corresponding first green credit ratio scheme ID, C 2 For B 2 The corresponding first green credit ratio scheme ID, C 3 For B 3 The corresponding first green credit ratio scheme ID; S14, when C 1 C 2 C 3 Does not conform to C 1 =C 2 =C 3 At that time, the green ratio of the target traffic light is adjusted according to the second processing method.
3. The method for adjusting the green credit ratio according to claim 2, characterized in that, S12 includes the following sub-steps: S121, If A i A in i1 With D 1 China A 0 1 corresponds to the same green credit ratio, A i2 With D 1 China A 0 2 corresponds to the same green credit ratio, ..., A ij With D 1 China A 0 j The corresponding green credit ratios are the same, ..., A in With D 1 China A 0 n If the corresponding green credit ratios are the same, then A will be... 1 i As E and proceeding to step S22, if A1, A2, ..., A i , ..., A m There exists at least one A in each case. ij With D 1 China A 0 j If the corresponding green light ratios are not the same, the processing ends, where E is D. 1 The corresponding second green credit ratio scheme ID; S122, When E = A 1 i At that time, obtain B 1 ij Among them, B 1 ij Meets the following conditions: B 1 ij =λ j ×Q j ×ZQ / F j ×(R j -QR-LS), Q j D 1 China A 0 j The corresponding actual traffic flow, F j For A 0 j The corresponding maximum historical actual traffic flow, λ j For F j In the corresponding historical time period A 0 j The corresponding green light ratio, ZQ is the signal cycle duration of the target traffic light, and R j D 1 China A 0 j The corresponding phase duration, where the phase duration is the sum of the green light display duration and the green light interval of the traffic light, QR is the preset all-red duration corresponding to the target traffic light, LS is the preset start-up loss duration corresponding to the target traffic light, and F j Meets the following conditions: F j =max(G j1 G j2 , ..., G je , ..., G jf `max()` is the function to get the maximum value. je D 1 In the corresponding e-th historical time period, A 0 j The corresponding actual traffic flow, where e ranges from 1 to f, and f is D. 1 The corresponding number of historical time periods, all of which are 10 minutes long; S123, When E≠A 1 i At that time, obtain B 1 ij Among them, B 1 ij Meets the following conditions: B 1 ij =Z 1 j ×Z 0 j / A ij Z 1 j A is the initial green ratio list corresponding to the initial green ratio scheme ID that is the same as E. 0 j The corresponding initial green light ratio corresponds to the first traffic saturation level, Z. 0 j A is the initial green ratio list corresponding to the initial green ratio scheme ID that is the same as E. 0 j The corresponding initial green light ratio; S124, D obtained from steps S121-S123 1 The corresponding second green credit ratio scheme ID, according to D 1 The corresponding second green ratio scheme ID is obtained as B. 1 ij In the same way, obtain D 2 The corresponding second green credit ratio scheme ID, according to D 2 The corresponding second green ratio scheme ID is obtained as B. 2 ij ; S125, D obtained from steps S121-S123 1 The corresponding second green credit ratio scheme ID, according to D 1 The corresponding second green ratio scheme ID is obtained as B. 1 ij In the same way, obtain D 3 The corresponding second green credit ratio scheme ID, according to D 3 The corresponding second green ratio scheme ID is obtained as B. 3 ij .
4. The method for adjusting the green credit ratio according to claim 2, characterized in that, The first processing method includes the following sub-steps: S131, According to B 1 Get C 0 ={C 0 1, C 0 2, ..., C 0 i , ..., C 0 m }, C 0 For the list of maximum traffic saturation, C 0 i For A 1 i The corresponding maximum traffic saturation, where C 0 i Meets the following conditions: C 0 i =max(B 1 i1 ,B 1 i2 ,……,B 1 ij ,……,B 1 in ); S132, when C 0 All C 0 i When all are different, C 0 The smallest C 0 i Corresponding A 1 i As C 1 Proceed to step S134; otherwise proceed to step S133. S133, when C 0 When any two maximum traffic saturation levels are the same, B will be... 1 1, B 1 2, ..., B 1 i , ..., B 1 m The largest first traffic saturation value in the middle is removed to update B. 1 1, B 1 2, ..., B 1 i , ..., B 1 m Then proceed to step S131; S134, Using steps S131-S133 according to B 1 Get C 1 In the same way, according to B 2 Get C 2 ; S135, according to steps S131-S133 based on B 1 Get C 1 In the same way, according to B 3 Get C 3 .
5. The method for adjusting the green credit ratio according to claim 2, characterized in that, The second processing method includes the following sub-steps: S141, when C 1 =C 2 Or C 1 =C 3 At that time, it will be with C 1 The same A 1 i Corresponding A i As H; S142, when C 2 =C 3 At that time, it will be with C 2 The same A 1 i Corresponding A i As H; S143, when C 1 ≠C 2 C 2 ≠C 3 And C 1 ≠C 3 At that time, H is obtained according to the third processing method.
6. The method for adjusting the green credit ratio according to claim 5, characterized in that, The phase type of the target traffic light is either a left-turn phase or a straight-ahead phase.
7. The method for adjusting the green credit ratio according to claim 6, characterized in that, The third processing method includes the following sub-steps: S1431. Obtain J = {J1, J2, ..., J...} j , ..., J n }, where J is the list of minimum green light ratios, J j For A 0 j The corresponding minimum green light ratio, where, when A 0 j When the phase type is a left-turn phase, J j =0.1, when A 0 j When the phase type is a straight phase, J j =0.2; S1432, Obtain J 0 ={J 0 1, J 0 2, ..., J 0 j , ..., J 0 n }, where J 0 For the list of maximum green credit ratios, J 0 j For A 0 j The corresponding maximum green light ratio, J 0 j Meets the following conditions: J 0 j =1-(J1+J2+……+J (j-1) +J (j+1) +……+J n ), J (j-1) For A 0 (j-1) The corresponding minimum green light ratio, J (j+1) For A 0 (j+1) The corresponding minimum green light ratio; S1433. Obtain M = {M1, M2, ..., M} g M h }, M g ={M g1 M g2 M gj M gn }, Where M is the set of candidate green credit ratio lists, M g Let M be the g-th candidate green light ratio list, where g ranges from 1 to h, h is the number of candidate green light ratio lists, and M is the number of candidates. gj For M g China A 0 j The corresponding candidate green light ratio, M gj Meets the following conditions: When g = 1, M gj =J j ; When g≠1, M gj =M (g-1)j +min(max(0.01,ceil((J 0 j -J j ) / ceil(100 / n)) / 100)), ceil() is the floor function, min() is the minimum value function, M (g-1)j For A in the (g-1)th candidate green ratio list 0 j The corresponding green credit ratio; S1434. Obtain N = {N1, N2, ..., N} g , ..., N h }, where N is the list of average green light ratio differences corresponding to M, N g For M g The corresponding average green light ratio difference, N g Meets the following conditions: N g =Σ n j=1 |M gj -H 0 j | / n,H 0 j For the target traffic light, in the current signal cycle, A 0 j The corresponding green credit ratio; S1435, when N g =min(N1, N2, ..., N) g , ..., N h When N is used, g The corresponding M g As H.
8. A non-transitory computer-readable storage medium, characterized in that, The storage medium stores a computer program or at least one computer-executable instruction, which is loaded and executed by a processor to implement the method as described in any one of claims 1-7.
9. An electronic device, characterized in that, include: A processor, a memory, and a computer program stored in the memory and executable on the processor, characterized in that the processor, when executing the computer program, implements the method as described in any one of claims 1-7.
Citation Information
Patent Citations
Traffic signal lamp control method and device and electronic equipment
CN115273506A
Signal lamp deploying system
CN116129661A