Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable Open, Close, and Detect actions in PDDL capabilities #237

Merged
merged 5 commits into from
Aug 14, 2024

Conversation

sea-bass
Copy link
Owner

@sea-bass sea-bass commented Aug 14, 2024

This PR includes some of our new actions (open, close, detect) in the PDDL domains.

You can test this with the new 06_open_close_detect planning domain:

  • Core: python3 pyrobosim/examples/demo_pddl.py --example 06_open_close_detect --verbose
  • ROS: ros2 launch pyrobosim_ros demo_pddl.launch.py example:=06_open_close_detect

Note that this has some limitations:

  • Hallway state is not communicated across the ROS interface (but location state does!)
  • Open/locked state pertains to entire locations, but the PDDL domains deal in individual object spawns. As such, you may not get things working exactly as desired with openable locations that have multiple object spawns.
  • At the start of planning, we assume no locations have been observed (which is not true in subsequent plans).
  • Detect actions do not specify a specific object instance.

These limitations have been documented with TODOs in the code. If anyone wants to implement updates, you are welcome to do so :)

Closes #209

Copy link

github-actions bot commented Aug 14, 2024

Coverage

Coverage Report
FileStmtsMissCoverMissing
__init__.py00100% 
core
   __init__.py90100% 
   dynamics.py430100% 
   gazebo.py136894%55, 124, 230, 244–248
   hallway.py93891%193, 235–238, 262–264
   locations.py1312183%69, 71, 88, 103–104, 106, 117–118, 120–121, 138, 196, 211, 236, 246, 291, 302–303, 305–306, 335
   objects.py69494%78, 106, 137, 197
   robot.py4596685%259–260, 272, 275, 279–280, 285–286, 334–335, 359, 425–428, 432–435, 480, 482, 524–525, 527–528, 545–547, 563–565, 632–634, 659–661, 712–714, 783–785, 795, 839–841, 851, 866, 872–873, 875, 877, 880–882, 895, 903, 909, 915, 921, 933, 975, 993, 996, 1001
   room.py48197%113
   world.py73919074%147–148, 184–185, 189, 242–243, 245–246, 274–275, 298–300, 337–339, 351–353, 382–384, 409–411, 464, 478–479, 481–482, 497–499, 519–523, 525–527, 529–530, 533, 535–538, 542–546, 549–551, 554–565, 581–582, 600–602, 616–618, 654–656, 668–670, 692–694, 719–721, 769–770, 773, 789, 819–820, 831, 834, 842, 858–862, 864–866, 869–870, 873–876, 878, 881, 883–885, 887–889, 891, 906, 913, 924–928, 963–964, 968–969, 987–988, 994–995, 997–998, 1000, 1002–1003, 1005, 1007–1008, 1018–1019, 1022, 1024, 1038, 1040, 1047, 1094, 1125–1126, 1137, 1148–1150, 1152–1155, 1157, 1174–1175, 1179–1180, 1215–1216, 1218, 1235–1236, 1267, 1281–1284, 1296–1299, 1313, 1324–1325, 1327, 1371–1372, 1424, 1504–1505
   yaml_utils.py1151190%65, 69, 156–158, 162–163, 183–184, 203–204
gui
   __init__.py20100% 
   main.py1903084%22–24, 45, 77–78, 196, 208–212, 219–222, 224, 227–233, 237, 242–243, 247–248, 259
   world_canvas.py2845580%44–45, 47–51, 54, 62–63, 171–174, 181, 183, 240–242, 289, 326, 360–361, 384–385, 387, 389–391, 394–397, 399, 403–409, 412, 415–416, 431–433, 436, 455, 498, 519, 523, 546, 563, 577
manipulation
   __init__.py10100% 
   grasping.py2366174%102, 110–112, 114–122, 124, 132, 462, 464–466, 470–472, 566–568, 571–575, 583, 586–588, 593–594, 600–604, 607–614, 617–619, 628, 630, 632–638
navigation
   __init__.py30100% 
   a_star.py781087%67–72, 74–76, 165
   execution.py90693%73–75, 80–82
   occupancy_grid.py1391489%44–47, 49–53, 56, 192, 226, 234, 238
   path_planner.py26676%33, 36, 38, 42, 89, 94
   planner_base.py591771%29–35, 51, 57–59, 142–147
   prm.py72297%61–62
   rrt.py1740100% 
   world_graph.py70395%118, 121, 145
planning
   __init__.py00100% 
   actions.py1120100% 
planning/pddlstream
   __init__.py7185%13
   default_mappings.py90100% 
   planner.py40880%119–126
   primitives.py61493%68, 82, 94, 232
   utils.py99891%66, 93, 105, 115–116, 207–208, 211
utils
   __init__.py00100% 
   general.py33487%23, 45, 51–52
   knowledge.py1542285%86, 117, 156–161, 163–164, 167–168, 170–173, 189, 204, 208, 250, 266, 329
   motion.py650100% 
   polygon.py1110100% 
   pose.py890100% 
   search_graph.py93396%240–242
   trajectory.py670100% 
TOTAL420656386% 

Tests Skipped Failures Errors Time
196 0 💤 0 ❌ 0 🔥 3m 26s ⏱️

@sea-bass sea-bass merged commit 72611b0 into main Aug 14, 2024
7 checks passed
@sea-bass sea-bass deleted the open-close-detect-pddl branch August 14, 2024 01:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Augment the PDDL interface to support domains with Open/Close/Detect actions
1 participant