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
1e01b681
Commit
1e01b681
authored
Sep 15, 2023
by
duanruiming
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/master'
parents
ff855602
3f5c9534
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
36 additions
and
23 deletions
+36
-23
SchemeEvaluateServiceImpl.java
...net/wanji/opt/service/impl/SchemeEvaluateServiceImpl.java
+0
-3
BaseCrossDirInfoMapper.xml
...abus/src/main/resources/mapper/BaseCrossDirInfoMapper.xml
+18
-10
BaseCrossTurnInfoMapper.xml
...bus/src/main/resources/mapper/BaseCrossTurnInfoMapper.xml
+18
-10
No files found.
signal-optimize-service/src/main/java/net/wanji/opt/service/impl/SchemeEvaluateServiceImpl.java
View file @
1e01b681
...
...
@@ -440,9 +440,6 @@ public class SchemeEvaluateServiceImpl implements SchemeEvaluateService {
.
mapToDouble
(
CrossTurnDataHistPO:
:
getSturation
)
.
max
()
.
orElse
(
0
);
metricsMap
.
put
(
StrategyAndMetricsEnum
.
Metrics
.
SATURATION
.
getCode
(),
maxSaturation
+
StrategyAndMetricsEnum
.
Metrics
.
SATURATION
.
getUnit
());
// 计算指标是否合格
boolean
isQualified
=
calcSecurity
(
maxSaturation
,
OptionalDouble
.
of
(
clearRateMax
));
if
(!
isQualified
)
{
...
...
wj-databus/src/main/resources/mapper/BaseCrossDirInfoMapper.xml
View file @
1e01b681
...
...
@@ -39,16 +39,24 @@
</select>
<select
id=
"selectDirEmergencyCount"
resultType=
"java.lang.Integer"
>
SELECT COUNT(*)
FROM holo_roadnet_jinan.t_event_info
WHERE type IN ('33', '34', '35', '6')
AND UNIX_TIMESTAMP(start_time)
<![CDATA[ >= ]]>
#{startStamp}
AND UNIX_TIMESTAMP(start_time)
<![CDATA[ <= ]]>
#{endStamp}
AND cross_id = #{crossId}
AND lane_id in
<foreach
collection=
"laneIds"
item=
"id"
separator=
","
open=
"("
close=
")"
>
#{id}
</foreach>
<choose>
<when
test=
"laneIds != null and laneIds.size() > 0"
>
SELECT COUNT(*)
FROM holo_roadnet_jinan.t_event_info
WHERE type IN ('33', '34', '35', '6')
AND UNIX_TIMESTAMP(start_time)
<![CDATA[ >= ]]>
#{startTimeStamp}
AND UNIX_TIMESTAMP(start_time)
<![CDATA[ <= ]]>
#{endTimeStamp}
AND cross_id = #{crossId}
AND lane_id in
<foreach
collection=
"laneIds"
item=
"id"
separator=
","
open=
"("
close=
")"
>
#{id}
</foreach>
</when>
<otherwise>
SELECT 0
</otherwise>
</choose>
</select>
</mapper>
wj-databus/src/main/resources/mapper/BaseCrossTurnInfoMapper.xml
View file @
1e01b681
...
...
@@ -19,17 +19,25 @@
</select>
<select
id=
"selectTurnEmergencyCount"
resultType=
"java.lang.Integer"
>
SELECT COUNT(*)
FROM holo_roadnet_jinan.t_event_info
WHERE type IN ('33', '34', '35', '6')
AND UNIX_TIMESTAMP(start_time)
<![CDATA[ >= ]]>
#{startStamp}
AND UNIX_TIMESTAMP(start_time)
<![CDATA[ <= ]]>
#{endStamp}
AND cross_id = #{crossId}
AND lane_id in
<foreach
collection=
"laneIds"
item=
"id"
separator=
","
open=
"("
close=
")"
>
#{id}
</foreach>
<choose>
<when
test=
"laneIds != null and laneIds.size() > 0"
>
SELECT COUNT(*)
FROM holo_roadnet_jinan.t_event_info
WHERE type IN ('33', '34', '35', '6')
AND UNIX_TIMESTAMP(start_time)
<![CDATA[ >= ]]>
#{startTimeStamp}
AND UNIX_TIMESTAMP(start_time)
<![CDATA[ <= ]]>
#{endTimeStamp}
AND cross_id = #{crossId}
AND lane_id in
<foreach
collection=
"laneIds"
item=
"id"
separator=
","
open=
"("
close=
")"
>
#{id}
</foreach>
</when>
<otherwise>
SELECT 0
</otherwise>
</choose>
</select>
</mapper>
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