Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
T
traffic-signal-platform
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
signal
traffic-signal-platform
Commits
ffb125e1
Commit
ffb125e1
authored
Apr 02, 2025
by
duwei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
优化交通指标
parent
fc457a8a
Changes
13
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
227 additions
and
67 deletions
+227
-67
RunningEvaluateController.java
...a/net/wanji/opt/controller/RunningEvaluateController.java
+3
-0
TrendServiceImpl.java
...ain/java/net/wanji/opt/service/impl/TrendServiceImpl.java
+138
-50
TableQueryVO.java
...-service/src/main/java/net/wanji/opt/vo/TableQueryVO.java
+1
-1
CrossDirDataRealtimePO.java
...ain/java/net/wanji/databus/po/CrossDirDataRealtimePO.java
+4
-0
CrossTurnDataRealtimePO.java
...in/java/net/wanji/databus/po/CrossTurnDataRealtimePO.java
+4
-0
CrossDataHistVO.java
...s/src/main/java/net/wanji/databus/vo/CrossDataHistVO.java
+5
-0
CrossDirDataHistVO.java
...rc/main/java/net/wanji/databus/vo/CrossDirDataHistVO.java
+12
-0
CrossLaneDataHistVOExt.java
...ain/java/net/wanji/databus/vo/CrossLaneDataHistVOExt.java
+9
-0
CrossTurnDataHistVO.java
...c/main/java/net/wanji/databus/vo/CrossTurnDataHistVO.java
+9
-0
CrossDataHistMapper.xml
wj-databus/src/main/resources/mapper/CrossDataHistMapper.xml
+11
-1
CrossDirDataHistMapper.xml
...abus/src/main/resources/mapper/CrossDirDataHistMapper.xml
+1
-1
CrossLaneDataHistMapper.xml
...bus/src/main/resources/mapper/CrossLaneDataHistMapper.xml
+20
-13
CrossTurnDataHistMapper.xml
...bus/src/main/resources/mapper/CrossTurnDataHistMapper.xml
+10
-1
No files found.
signal-optimize-service/src/main/java/net/wanji/opt/controller/RunningEvaluateController.java
View file @
ffb125e1
...
@@ -61,6 +61,7 @@ public class RunningEvaluateController {
...
@@ -61,6 +61,7 @@ public class RunningEvaluateController {
return
JsonViewObject
.
newInstance
().
success
(
res
);
return
JsonViewObject
.
newInstance
().
success
(
res
);
}
}
//TODO 拥堵指数
@ApiOperation
(
value
=
"拥堵情况"
,
notes
=
"拥堵情况"
,
response
=
JsonViewObject
.
class
,
@ApiOperation
(
value
=
"拥堵情况"
,
notes
=
"拥堵情况"
,
response
=
JsonViewObject
.
class
,
produces
=
MediaType
.
APPLICATION_JSON
,
consumes
=
MediaType
.
APPLICATION_JSON
)
produces
=
MediaType
.
APPLICATION_JSON
,
consumes
=
MediaType
.
APPLICATION_JSON
)
@PostMapping
(
value
=
"/congestionStatus"
,
@PostMapping
(
value
=
"/congestionStatus"
,
...
@@ -73,6 +74,7 @@ public class RunningEvaluateController {
...
@@ -73,6 +74,7 @@ public class RunningEvaluateController {
return
JsonViewObject
.
newInstance
().
success
(
res
);
return
JsonViewObject
.
newInstance
().
success
(
res
);
}
}
//TODO 失衡指数
@ApiOperation
(
value
=
"失衡情况"
,
notes
=
"失衡情况"
,
response
=
JsonViewObject
.
class
,
@ApiOperation
(
value
=
"失衡情况"
,
notes
=
"失衡情况"
,
response
=
JsonViewObject
.
class
,
produces
=
MediaType
.
APPLICATION_JSON
,
consumes
=
MediaType
.
APPLICATION_JSON
)
produces
=
MediaType
.
APPLICATION_JSON
,
consumes
=
MediaType
.
APPLICATION_JSON
)
@PostMapping
(
value
=
"/unbalanceStatus"
,
@PostMapping
(
value
=
"/unbalanceStatus"
,
...
@@ -85,6 +87,7 @@ public class RunningEvaluateController {
...
@@ -85,6 +87,7 @@ public class RunningEvaluateController {
return
JsonViewObject
.
newInstance
().
success
(
res
);
return
JsonViewObject
.
newInstance
().
success
(
res
);
}
}
//TODO 溢出指数
@ApiOperation
(
value
=
"溢出情况"
,
notes
=
"溢出情况"
,
response
=
JsonViewObject
.
class
,
@ApiOperation
(
value
=
"溢出情况"
,
notes
=
"溢出情况"
,
response
=
JsonViewObject
.
class
,
produces
=
MediaType
.
APPLICATION_JSON
,
consumes
=
MediaType
.
APPLICATION_JSON
)
produces
=
MediaType
.
APPLICATION_JSON
,
consumes
=
MediaType
.
APPLICATION_JSON
)
@PostMapping
(
value
=
"/spilloverStatus"
,
@PostMapping
(
value
=
"/spilloverStatus"
,
...
...
signal-optimize-service/src/main/java/net/wanji/opt/service/impl/TrendServiceImpl.java
View file @
ffb125e1
This diff is collapsed.
Click to expand it.
signal-optimize-service/src/main/java/net/wanji/opt/vo/TableQueryVO.java
View file @
ffb125e1
...
@@ -167,7 +167,7 @@ public class TableQueryVO {
...
@@ -167,7 +167,7 @@ public class TableQueryVO {
@ApiModelProperty
(
value
=
"溢出指数"
)
@ApiModelProperty
(
value
=
"溢出指数"
)
@ExcelProperty
(
"溢出指数"
)
@ExcelProperty
(
"溢出指数"
)
private
Double
overflowIndex
;
private
Double
overflowIndex
=
0.0d
;
@ApiModelProperty
(
value
=
"失衡指数"
)
@ApiModelProperty
(
value
=
"失衡指数"
)
@ExcelProperty
(
"失衡指数"
)
@ExcelProperty
(
"失衡指数"
)
...
...
wj-databus/src/main/java/net/wanji/databus/po/CrossDirDataRealtimePO.java
View file @
ffb125e1
...
@@ -65,4 +65,8 @@ public class CrossDirDataRealtimePO {
...
@@ -65,4 +65,8 @@ public class CrossDirDataRealtimePO {
public
Double
effusionRate
;
public
Double
effusionRate
;
@ApiModelProperty
(
value
=
"绿灯有效利用率"
,
notes
=
""
)
@ApiModelProperty
(
value
=
"绿灯有效利用率"
,
notes
=
""
)
public
Double
greenLightEfficiency
;
public
Double
greenLightEfficiency
;
@ApiModelProperty
(
value
=
"时间占用率"
,
notes
=
""
)
public
Double
timeOccupancy
;
@ApiModelProperty
(
value
=
"非机动车流量"
,
notes
=
""
)
public
Double
nonMotorFlow
;
}
}
wj-databus/src/main/java/net/wanji/databus/po/CrossTurnDataRealtimePO.java
View file @
ffb125e1
...
@@ -100,4 +100,8 @@ public class CrossTurnDataRealtimePO {
...
@@ -100,4 +100,8 @@ public class CrossTurnDataRealtimePO {
private
int
trafficFlowB
;
private
int
trafficFlowB
;
@ApiModelProperty
(
value
=
"小车流量"
,
notes
=
""
)
@ApiModelProperty
(
value
=
"小车流量"
,
notes
=
""
)
private
int
trafficFlowC
;
private
int
trafficFlowC
;
@ApiModelProperty
(
value
=
"时间占有率"
,
notes
=
""
)
private
double
timeOccupancy
;
@ApiModelProperty
(
value
=
"空间占有率"
,
notes
=
""
)
private
double
vehicleLengthRatioMean
;
}
}
wj-databus/src/main/java/net/wanji/databus/vo/CrossDataHistVO.java
View file @
ffb125e1
...
@@ -10,4 +10,9 @@ import net.wanji.databus.po.CrossDataRealtimePO;
...
@@ -10,4 +10,9 @@ import net.wanji.databus.po.CrossDataRealtimePO;
@Data
@Data
@ApiModel
(
value
=
"CrossDataHistVO"
,
description
=
"路口实时数据历史"
)
@ApiModel
(
value
=
"CrossDataHistVO"
,
description
=
"路口实时数据历史"
)
public
class
CrossDataHistVO
extends
CrossDataRealtimePO
{
public
class
CrossDataHistVO
extends
CrossDataRealtimePO
{
//非机动车流量
//行人流量
//平均车头时距
}
}
wj-databus/src/main/java/net/wanji/databus/vo/CrossDirDataHistVO.java
View file @
ffb125e1
...
@@ -15,4 +15,16 @@ public class CrossDirDataHistVO extends CrossDirDataRealtimePO {
...
@@ -15,4 +15,16 @@ public class CrossDirDataHistVO extends CrossDirDataRealtimePO {
public
double
trafficFlowB
;
public
double
trafficFlowB
;
public
double
trafficFlowA
;
public
double
trafficFlowA
;
//非机动车流量
//行人数量
//平均车头时距
//拥堵指数
//溢出指数
//失衡指数
}
}
wj-databus/src/main/java/net/wanji/databus/vo/CrossLaneDataHistVOExt.java
View file @
ffb125e1
...
@@ -15,5 +15,14 @@ public class CrossLaneDataHistVOExt extends CrossLaneDataRealTimePO {
...
@@ -15,5 +15,14 @@ public class CrossLaneDataHistVOExt extends CrossLaneDataRealTimePO {
private
Integer
sort
;
private
Integer
sort
;
// 转向
// 转向
private
Integer
turn
;
private
Integer
turn
;
//非机动车流量
//行人数量
//拥堵指数
//溢出指数
//失衡指数
}
}
wj-databus/src/main/java/net/wanji/databus/vo/CrossTurnDataHistVO.java
View file @
ffb125e1
...
@@ -11,4 +11,13 @@ import net.wanji.databus.po.CrossTurnDataRealtimePO;
...
@@ -11,4 +11,13 @@ import net.wanji.databus.po.CrossTurnDataRealtimePO;
@Data
@Data
@ApiModel
(
value
=
"CrossTurnDataHistVO"
,
description
=
"路口转向实时数据历史"
)
@ApiModel
(
value
=
"CrossTurnDataHistVO"
,
description
=
"路口转向实时数据历史"
)
public
class
CrossTurnDataHistVO
extends
CrossTurnDataRealtimePO
{
public
class
CrossTurnDataHistVO
extends
CrossTurnDataRealtimePO
{
//非机动车流量
//行人数量
//拥堵指数
//溢出指数
//失衡指数
}
}
wj-databus/src/main/resources/mapper/CrossDataHistMapper.xml
View file @
ffb125e1
...
@@ -118,7 +118,17 @@
...
@@ -118,7 +118,17 @@
COALESCE ( sum( traffic_flow_A ), 0) AS trafficFlowA,
COALESCE ( sum( traffic_flow_A ), 0) AS trafficFlowA,
avg( t2.speed ) AS speed,
avg( t2.speed ) AS speed,
MAX( t2.queue_length ) AS queueLength,
MAX( t2.queue_length ) AS queueLength,
AVG( t2.stop_times ) AS stopTimes
AVG( t2.stop_times ) AS stopTimes,
avg(t2.time_occupancy) as timeOccupancy,
avg(t2.sturation) as sturation,
avg(t2.congestion_index) as congestionIndex,
avg(t2.spillover_index) as spilloverIndex,
avg(t2.unbalance_index) as unbalanceIndex,
avg(t2.no_stop_rate) as noStopRate,
avg(t2.one_stop_rate) as oneStopRate,
avg(t2.two_stop_rate) as twoStopRate,
avg(t2.three_stop_rate) as threeStopRate,
avg(t2.non_motor_flow) as nonMotorFlow
FROM
FROM
t_base_cross_info t1
t_base_cross_info t1
LEFT JOIN t_cross_data_hist t2 ON t1.id = t2.cross_id
LEFT JOIN t_cross_data_hist t2 ON t1.id = t2.cross_id
...
...
wj-databus/src/main/resources/mapper/CrossDirDataHistMapper.xml
View file @
ffb125e1
This diff is collapsed.
Click to expand it.
wj-databus/src/main/resources/mapper/CrossLaneDataHistMapper.xml
View file @
ffb125e1
...
@@ -142,19 +142,26 @@
...
@@ -142,19 +142,26 @@
avg( t1.speed ) AS speed,
avg( t1.speed ) AS speed,
avg( t1.vehhead_dist ) AS vehheadDist,
avg( t1.vehhead_dist ) AS vehheadDist,
avg( t1.vehhead_time ) AS vehheadTime,
avg( t1.vehhead_time ) AS vehheadTime,
t1.queue_length,
t1.delay_time,
avg(t1.queue_length) as queueLength,
t1.stop_times,
avg(t1.delay_time) as delayTime,
t1.vehhead_time,
avg(t1.stop_times) as stopTimes,
t1.vehhead_dist,
avg(t1.vehhead_time) as vehheadTime,
t1.batch_time,
avg(t1.vehhead_dist) as vehheadDist,
t1.time_occupancy,
avg(t1.batch_time) as batchTime,
t1.vehicle_nums_ratio_mean,
avg(t1.time_occupancy) as timeOccupancy,
t1.start_time,
avg(t1.vehicle_nums_ratio_mean) as vehicleNumsRatioMean,
t1.v_85,
avg(t1.start_time) as startTime,
t1.non_motor_flow,
avg(t1.v_85) as v85,
t1.time_occupancy,
avg(t1.non_motor_flow) as nonMotorFlow,
t1.vehicle_length_ratio_mean
avg(t1.time_occupancy) as timeOccupancy,
avg(t1.vehicle_length_ratio_mean) as vehicleLengthRatioMean,
avg(t1.sturation) as sturation,
avg(t1.no_stop_rate) as noStopRate,
avg(t1.one_stop_rate) as oneStopRate,
avg(t1.two_stop_rate) as twoStopRate,
avg(t1.three_stop_rate) as threeStopRate,
AVG(t1.non_motor_flow) as nonMotorFlow
FROM
FROM
t_base_lane_info t2
t_base_lane_info t2
LEFT JOIN t_lane_data_hist t1 ON t1.id = t2.id
LEFT JOIN t_lane_data_hist t1 ON t1.id = t2.id
...
...
wj-databus/src/main/resources/mapper/CrossTurnDataHistMapper.xml
View file @
ffb125e1
...
@@ -104,7 +104,16 @@
...
@@ -104,7 +104,16 @@
COALESCE(sum( t2.traffic_flow_A ), 0) AS trafficFlowA,
COALESCE(sum( t2.traffic_flow_A ), 0) AS trafficFlowA,
avg( t2.speed ) AS speed,
avg( t2.speed ) AS speed,
MAX( t2.queue_length ) AS queueLength,
MAX( t2.queue_length ) AS queueLength,
AVG( t2.stop_times ) AS stopTimes
AVG( t2.stop_times ) AS stopTimes,
AVG( t2.time_occupancy) as timeOccupancy,
AVG( t2.vehicle_length_ratio_mean) as vehicleLengthRatioMean,
AVG( t2.vehhead_time) as vehheadTime,
AVG( t2.sturation) as sturation,
AVG( t2.no_stop_rate) as noStopRate,
AVG( t2.one_stop_rate) as oneStopRate,
AVG( t2.two_stop_rate) as twoStopRate,
AVG( t2.three_stop_rate) as threeStopRate,
AVG( t2.non_motor_flow) as nonMotorFlow
FROM
FROM
t_base_cross_turn_info t1
t_base_cross_turn_info t1
LEFT JOIN t_cross_turn_data_hist t2 ON t1.id = t2.id
LEFT JOIN t_cross_turn_data_hist t2 ON t1.id = t2.id
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment