Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
I
integrated-scheduling-v3
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
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
张晓彤
integrated-scheduling-v3
Commits
1f0fe212
Commit
1f0fe212
authored
Aug 16, 2023
by
张晓彤
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
调整车辆速度,删除穿越装载区配置
parent
978328b8
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
14 deletions
+9
-14
algorithm.py
alg/algorithm.py
+2
-2
config.json
config.json
+5
-10
group.py
core/group.py
+2
-2
No files found.
alg/algorithm.py
View file @
1f0fe212
...
@@ -195,7 +195,7 @@ class ExpectedTime(AlgorithmBase):
...
@@ -195,7 +195,7 @@ class ExpectedTime(AlgorithmBase):
# 车辆驶往各目的地时间
# 车辆驶往各目的地时间
truck_reach_time_ls
=
60
*
self
.
group
.
park_to_excavator_distance
[
0
,
:]
/
1000
/
\
truck_reach_time_ls
=
60
*
self
.
group
.
park_to_excavator_distance
[
0
,
:]
/
1000
/
\
self
.
truck
.
empty_speed
[
truck_id
]
+
truck_avl_time
empty_speed
+
truck_avl_time
# 计算车辆得到服务时间
# 计算车辆得到服务时间
truck_service_time
=
np
.
maximum
(
truck_reach_time_ls
,
group_excavator_avl_time_ls
)
truck_service_time
=
np
.
maximum
(
truck_reach_time_ls
,
group_excavator_avl_time_ls
)
...
@@ -326,7 +326,7 @@ class ExpectedTime(AlgorithmBase):
...
@@ -326,7 +326,7 @@ class ExpectedTime(AlgorithmBase):
# 车辆驶往各目的地时间
# 车辆驶往各目的地时间
truck_reach_time_ls
=
60
*
self
.
group
.
to_excavator_distance
[
unload_area_group_index
,
:]
\
truck_reach_time_ls
=
60
*
self
.
group
.
to_excavator_distance
[
unload_area_group_index
,
:]
\
/
1000
/
self
.
truck
.
empty_speed
[
truck_id
]
+
truck_avl_time
/
1000
/
empty_speed
+
truck_avl_time
# 计算车辆得到服务时间
# 计算车辆得到服务时间
truck_service_time
=
np
.
maximum
(
truck_reach_time_ls
,
group_excavator_avl_time_ls
)
truck_service_time
=
np
.
maximum
(
truck_reach_time_ls
,
group_excavator_avl_time_ls
)
...
...
config.json
View file @
1f0fe212
{
{
"para"
:
{
"para"
:
{
"log_path"
:
"/usr/local/fleet-log/dispatch"
,
"log_path"
:
"/usr/local/fleet-log/dispatch"
,
"empty_speed"
:
17
,
"empty_speed"
:
25
,
"heavy_speed"
:
17
,
"heavy_speed"
:
25
,
"dump_target_mass"
:
5000
,
"dump_target_mass"
:
5000
,
"excavator_target_mass"
:
5000
"excavator_target_mass"
:
5000
},
},
"mysql"
:
{
"mysql"
:
{
"host"
:
"172.16.0.
51
"
,
"host"
:
"172.16.0.
103
"
,
"port"
:
"3306"
,
"port"
:
"3306"
,
"user"
:
"root"
,
"user"
:
"root"
,
"password"
:
"Huituo@123"
,
"password"
:
"Huituo@123"
,
"database"
:
"ht_zhunneng"
"database"
:
"ht_zhunneng"
},
},
"postgresql"
:
{
"postgresql"
:
{
"host"
:
"172.16.0.
51
"
,
"host"
:
"172.16.0.
103
"
,
"port"
:
"5432"
,
"port"
:
"5432"
,
"user"
:
"postgres"
,
"user"
:
"postgres"
,
"password"
:
"Huituo@123"
,
"password"
:
"Huituo@123"
,
"database"
:
"gis_zhunneng"
"database"
:
"gis_zhunneng"
},
},
"redis"
:
{
"redis"
:
{
"host"
:
"172.16.0.
51
"
,
"host"
:
"172.16.0.
103
"
,
"password"
:
"Huituo@123"
"password"
:
"Huituo@123"
},
"gothrough"
:
{
"closer_area_name"
:
"哈1010平盘"
,
"further_area_name"
:
"哈1026平盘"
}
}
}
}
\ No newline at end of file
core/group.py
View file @
1f0fe212
...
@@ -581,7 +581,7 @@ class GroupDispatcher:
...
@@ -581,7 +581,7 @@ class GroupDispatcher:
# self.redispatch_to_dump(truck_id, truck_dispatch, truck_locate, truck_trip)
# self.redispatch_to_dump(truck_id, truck_dispatch, truck_locate, truck_trip)
try
:
try
:
truck_info
.
redispatch
=
\
truck_info
.
redispatch
=
\
self
.
redispatcher
.
redispatch_to_dump
(
truck_id
,
truck_dispatch
,
truck_locate
,
truck_trip
)
self
.
redispatcher
.
redispatch_to_dump
(
truck_id
,
truck_dispatch
,
truck_locate
,
truck_trip
,
truck_info
)
except
Exception
as
es
:
except
Exception
as
es
:
self
.
logger
.
error
(
"二次调度至卸载点失败"
)
self
.
logger
.
error
(
"二次调度至卸载点失败"
)
self
.
logger
.
error
(
es
)
self
.
logger
.
error
(
es
)
...
@@ -761,7 +761,7 @@ class GroupDispatcher:
...
@@ -761,7 +761,7 @@ class GroupDispatcher:
truck_name
=
truck_uuid_to_name_dict
[
truck_id
]
truck_name
=
truck_uuid_to_name_dict
[
truck_id
]
# 获取车辆当前派车计划
# 获取车辆当前派车计划
if
truck_task
in
[
0
,
1
,
5
]:
if
truck_task
in
[
0
,
1
,
2
]:
excavator_index
=
int
(
truck_trip
[
1
])
excavator_index
=
int
(
truck_trip
[
1
])
dump_index
=
int
(
truck_trip
[
0
])
dump_index
=
int
(
truck_trip
[
0
])
...
...
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