Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
db-guided-mrmp
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
rmoan2
db-guided-mrmp
Commits
2214a772
Commit
2214a772
authored
4 weeks ago
by
rachelmoan
Browse files
Options
Downloads
Patches
Plain Diff
add back in plotting
parent
ec657d7f
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
guided_mrmp/controllers/multi_path_tracking_db.py
+5
-4
5 additions, 4 deletions
guided_mrmp/controllers/multi_path_tracking_db.py
with
5 additions
and
4 deletions
guided_mrmp/controllers/multi_path_tracking_db.py
+
5
−
4
View file @
2214a772
...
...
@@ -435,10 +435,8 @@ class MultiPathTrackerDB(MultiPathTracker):
for
c
in
all_conflicts
:
# 3. If they do collide, then reroute the reference trajectories of these robots
# Get the robots involved in the conflict
robot_positions
=
[
[
state
[
i
][:
2
]]
for
i
in
c
]
# for i in (c):
# robot_positions.append(state[i][:2])
# Get the positions of robots involved in the conflict
robot_positions
=
[
state
[
i
][:
2
]
for
i
in
c
]
# get the largest x and y difference between the robots in conflict
x_diff
=
max
([
abs
(
robot_positions
[
i
][
0
]
-
robot_positions
[
j
][
0
])
for
i
in
range
(
len
(
c
))
for
j
in
range
(
len
(
c
))])
...
...
@@ -478,6 +476,9 @@ class MultiPathTrackerDB(MultiPathTracker):
self
.
settings
[
"
database
"
][
"
smoothing_sigma
"
]
)
if
show_plots
:
draw_grid_solution
(
self
.
num_robots
,
self
.
radius
,
self
.
grid_size
,
self
.
cell_size
,
self
.
env
,
self
.
trajs
,
continuous_soln
,
state
,
grid_origin
,
grid_obstacle_map
,
c
,
time
)
# for each robot in conflict, reroute its reference trajectory to match the grid solution
import
copy
old_paths
=
copy
.
deepcopy
(
self
.
paths
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment