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

Allow for Simulating Acquisition #124

Merged
merged 3 commits into from
Feb 17, 2024
Merged

Allow for Simulating Acquisition #124

merged 3 commits into from
Feb 17, 2024

Conversation

amalnanavati
Copy link
Contributor

@amalnanavati amalnanavati commented Feb 17, 2024

Describe this pull request. Link to relevant GitHub issues, if any.

The PR, joint with ada_feeding#164, allows users to simulate bite acquisition.

Specifically, it provides two ways to simulate bite acquisition:

  1. Launching everything in mock, using the app as expected with dummy SegmentFromPoint. This PR makes dummy SegmentFromPoint return depth info as well, resulting in its masks working with AcquireFood.
  2. Playing back pickled goal requests to AcquireFood.

Explain how this pull request was tested, including but not limited to the below checkmarks.

  • Pull this code and ada_feeding#164, rebuild your workspace.
  • Launch the system in mock as documented here.
  • Verify the first way of simulating bite acquisition:
    • Use the web app as expected, including selecting a mask in bite selection.
    • Verify that the mock robot in RVIZ moves through the expected acquisition action.
  • Verify the second way of simulating bite acquisition:
    • Play back the pickled goal request: ros2 launch feeding_web_app_ros2_test feeding_dummy_acquirefood_launch.py
    • Verify that the robot moves above the plate and does the acquition action.
    • Change the acquisition action executed in feeding to another one based on the launch argument.
    • Verify that it executes the other action.
  • Verify that you can pickle AcquireFood goal requests:
    • Terminate the code running in the perception and republisher screens.
    • In perception, run real perception: ros2 launch ada_feeding_perception ada_feeding_perception.launch.py
    • In republisher, run only the dummy RealSense: ros2 launch feeding_web_app_ros2_test feeding_web_app_dummy_nodes_launch.xml run_web_bridge:=false run_food_detection:=false run_face_detection:=false run_motion:=false
    • Add the pickle_goal_path parameter to the AcquireFoodTree, pointing to a path you'd like to store the pickled goal request.
    • Re-build and re-run the feeding code.
    • Invoke bite acquisition through the web app. Verify that a pickle file is saved in the specified path.

Before creating a pull request

  • [N/A] Format React code with npm run format
  • Format Python code by running python3 -m black . in the top-level of this repository
  • [N/A] Thoroughly test your code's functionality, including unintended uses.
  • [N/A] Fully test the responsiveness of the feature as documented in the Responsiveness Testing Guidelines. If you deviate from those guidelines, document above why you deviated and what you did instead.
  • [N/A] Consider the user flow between states that this feature introduces, consider different situations that might occur for the user, and ensure that there is no way for the user to get stuck in a loop.

Before merging a pull request

  • Squash all your commits into one (or Squash and Merge)

@amalnanavati amalnanavati merged commit 1264852 into main Feb 17, 2024
4 checks passed
@amalnanavati amalnanavati deleted the amaln/sim_acquisition branch February 17, 2024 04:09
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.

1 participant