Skip to content

Latest commit

 

History

History
executable file
·
118 lines (79 loc) · 6.75 KB

SAMPLES.md

File metadata and controls

executable file
·
118 lines (79 loc) · 6.75 KB

Our Samples

Still WIP.

We have several showcase examples (all located in the simulator folder).

Each one of the python files has its own configuration yaml file. More details will be given below for each file

To follow these tutorials, we suggest that either you download one of our example environments here and human animations here or you use our code SMPL to USD and Blender to USD to create your own assets.

We also suggest that you pre-install the drone control and placement repository. This is necessary to be able to use our placement strategy, control the drone with our custom 6DOF controller, or use FUEL with IsaacSim.

Each simulation file will power up the environment, load the assets and manage the saving based on the loaded configuration file.

The scripts are the following:

  1. FUEL_indoor_simulation this is the code that we used to generate the dataset.
  2. irotate_simulation this is the code that we used to simulate iRotate, our active SLAM method, with Isaac Sim. This is very similar to 1 and 2, despite using an initial location but shwos how you can manage different robot with practically the same code.
  3. multi_robot_sim simulate multi robots, a bit hardcoded but generalizable. This simulate two drones and a ground robot. The two drones will be controlled independently with two FUEL sessions, while the ground robot is controlled with iRotate.
  4. savana_simulation to show how we created the Savana with the Zebras. Animated animals are pre-positioned within the environment. The robot is controlled through joint waypoints. THIS DOES NOT WORK in v2022.2.1 DUE TO ISAACSIM BUGS

Each config needs to be updated with your own paths


Paper(ros) simulation

Install ROS and create a catkin_ws and install this.

The default location for this installation is $HOME (/home/user/catkin_ws).

The repo above will install

  1. FUEL, our chosen exploration manager
  2. mav_comm and mav_control_rw which are used to control the robot and get velocity commands to follow the path generated by FUEL
  3. custom_6dof_joint_controller which is the bridge between the position/velocity commands and the joint velocities expected by IsaacSim
  4. moveit_based_collision_checker_and_placement which is needed to do the placement of the "objects"

The README already explicate the dependencies.

If you install it in a different location update setup_python_env.sh:2 with your new location.

Remember that you can also source ... --extend to source different environments in cascade.

At this point, assuming you are locate in the ISAAC folder you can run

./python.sh GRADE-RR/simulator/paper_simulation.py --config="/GLOBAL/GRADE-RR/simulator/configs/config_paper.yaml" 

BASH PROCESSING If you want to run everything (including the exploration visualization and the rosbag recorder) the bash_process.zsh file is what you are looking for. That file is what we used to streamline the generation and process in batches. In the config file you can easily chose which sensor to use.

Similarly

./python.sh GRADE-RR/simulator/simulator_ros.py --config="/GLOBAL/simulator/configs/config.yaml" 

would work. Note that in this case you need to edit both the configs and the code otherwise the robot will not move.


iRotate simulation

Download and install the iRotate package here from the Isaac branch.

This simulation by default does NOT use animated objects. You can see how one can have a blueprint and quickly edit it based on its own convenience.

update setup_python_env.sh:2 with your catkin workspace location.

Before launching the simulation you need to open a terminal and run python[3] irotate_specific/republish_tf.py

Also, run irotate as explained in the repo. A set of commands could be:

roslaunch robotino_simulations world.launch
roslaunch robotino_simulations rtabmap.launch delete:=-d
roslaunch active_slam active_node.launch
roslaunch robotino_mpc robotino_mpc.launch

Note that we launch the FSM later on.

With iRotate we usually let the robot start from 0,0,0 and yaw=0. If you change this, like with the previous work, you need to change the ekfs accordingly.

The transform world->map is constant. map->odom is done by rtabmap. odom->base_link is done from the ekfs.

Isaac is setted up to publish the tfs to the /tf2 topic. Step 4 is necessary to publish everything back to the /tf cleaned up of the ground truth estimation.

The custom joint controller has been updated. You need to be sure you are running the one from irotate repository. Thus, we need either to build everything in the same workspace or use source ... --extend if you are using two workspaces. You can eventually change the scripts to have it working how you want.

You can launch an rviz visualization with rviz -d irotate_specific irotate.rviz

./python.sh GRADE-RR/simulator/irotate_simulation.py --config="/GLOBAL/GRADE-RR/simulator/configs/config_irotate.yaml" 

Once the simulation is running, you can launch roslaunch robotino_fsm robotino_fsm.launch kind:=2 only_last_set:=false pre_fix:=true mid_optimizer:=true weighted_avg:=true robot_odom:=/odometry/filtered cam_odom:=/camera/odometry/filtered

Note how the topics are stilll without /my_robot_x. This should be changed in the EKF formulation.


Multi robot

For this you need both the irotate repository and the original paper repository. The code will launch first the irotate robot and then two drones. You need to include both workspaces in setup_python_env.sh:2 using first the ros_isaac_drone and then the irotate workspace (use the --extend keyword).

You can follow a similar procedure like the one above to launch iRotate.

To run the main simulation

./python.sh GRADE-RR/simulator/multi_robot_sim.py --config="/GLOBAL/GRADE-RR/simulator/configs/config_multi_robot.yaml" 

This piece of code show you how multiple robots can be loaded and controlled, how the configuration file can be expanded (e.g. only iRotate's robot has an initial location) and how everything can be customized.


Savana - not working on 2022

Is another simple scenario since everything is managed internally. The animations are already placed within the environment and the robot has pre-defined waypoints. The FSM is internal to the main source code which can be launched with

./python.sh GRADE-RR/simulator/savana_simulation.py --config="/GLOBAL/GRADE-RR/simulator/configs/config_savana.yaml"