![]() |
simple_pybullet_ros2 repositorypybullet_panda sim_recorder sim_spawner simple_arm_control simple_interface |
|
Repository Summary
Checkout URI | https://github.com/09ubberboy90/simple_pybullet_ros2.git |
VCS Type | git |
VCS Version | main |
Last Updated | 2022-07-07 |
Dev Status | UNMAINTAINED |
CI status | No Continuous Integration |
Released | UNRELEASED |
Tags | No category tags. |
Contributing |
Help Wanted (0)
Good First Issues (0) Pull Requests to Review (0) |
Packages
Name | Version |
---|---|
pybullet_panda | 0.0.0 |
sim_recorder | 1.0.0 |
sim_spawner | 1.0.0 |
simple_arm_control | 1.0.0 |
simple_interface | 0.0.0 |
README
simple_pybullet_ros2
This repository contains 2 tasks for Pybullet
Stacking Task
This task involves one Franka Panda robotic arm randomly taking 5cm cubes from a table with 21 cubes arranged in a 7 * 3 grid and stacking them. It will stack them into 3 stacks of 5 cubes. The number of columns and the the heigt can be configured in moveit_controller.launch.py
Throw Task
For this, a Franka Panda arm will pick up a cube and throw it toward a pyramid made of 6 cubes. The arm will go as far back as it can and perform a throwing motion toward the ground in front of it. The ball will be released at 50% of the trajectory as it is the moment with the most amount of forces. The pyramid is placed such that a successful throw at full power will collapse it.
Instructions
Requirements
-
OS: Ubuntu 20.04 (Focal)
- Other distributions might work (not tested).
Dependencies
These are the primary dependencies required to use this project.
Building
Clone this repository and import submodules. Then install dependencies and build with colcon.
# Install pyquaternion
pip install pyquaternion
# Clone this repository and the submodules into your favourite ROS 2 workspace
git clone https://github.com/09ubberboy90/simple_pybullet_ros2.git
# Install external dependencies via rosdep
rosdep install -r --from-paths src --ignore-src --rosdistro ${ROS_DISTRO}
# Build with colcon
colcon build --merge-install --symlink-install --cmake-args "-DCMAKE_BUILD_TYPE=Release"
Sourcing
Before utilising this package, remember to source the ROS 2 workspace overlay.
source ${ROS2_WS}/install/local_setup.bash
Running
The following tasks can be either run as an independant launch or can be recorded
Stacking cube
ros2 launch pybullet_panda stack_cubes.launch.py
Throwing cube
ros2 launch pybullet_panda throw_cubes.launch.py
Recorder
The recorder can be launched with.
ros2 run sim_recorder run_recording
It has some argument option to configure what the task will be
--help: Gives a list of arguments
-t, --throw: Start the Throwing Task
-i, --iteration: Number of run that should be performed
-s, --start: Start index in case some run need to be rerun after an interuption
--headless: runs without a GUI
The recorder will save the CPU and RAM usage in sim_recoder/data/{sim_name}
.
sim_name
is created automatically based ont the simulation name ignition
and on the arguments:
-
_gui
is added if--headless
is not passed -
_throw
is added if--throw
is passed
An analysis of the run can be performed by running from the source of the repo
python ./sim_recorder/sim_recoder/grapher.py {name_of_folder}
With name of folder being the name of the folder you want to analyse