Git Product home page Git Product logo

rosbag_to_mat's Introduction

rosbag_to_mat

Adapted my old/archived my_matlab_rosbag code to work with the ROS Toolbox for MATLAB (v2019 and up).

Data collection is as follows:

  1. Record Demonstrations as ROSbags: Record demonstrations as time-series of geometry_msgs::PoseStamped (for position and orientation, WrenchStamped can be used for FT messages) messages in rosbags. A repo that provides useful code (for different robots) and launch files in ROS for easy data collection can be found in the easy-kinesthetic-recording package.
  2. Extract Trajectories from ROSbags to MATLAB: Extract desired messages and create trajectories of matlab structures (containing all pose information) stored in .mat. See examples below.
  3. Segment Trajectories: In this repo you will find the scripts to define segmentation points when gripper state has opened/closed -- this is only useful for pick-and-place tasks! For continuous tasks that are not defined by gripper changes a seperate segmentation algorithm must be used, such as the one being developed in dsltl which is used for some of the tasks below.

Examples

Industrial Task

The script xsens_mitsubishi_process_rosbags.m loads the rosbags that were recorded by tracking the right hand of a human operator with the Xsens MVN Motion Capture system and workspace object locations via a dual-kinect setup using the AprilTags detection algorithm as designed for the Mitsubishi Cobot Assista MIT Project.

Note: This script only extracts the trajectories from the saved rosbags and converts them to the robot's reference frame.

Trajectory Segmentation: In order to learn individual goal-oriented motion policies (such as attractor-based Dynamical Systems) from this data one must segment the trajectories. For this task a state-change segmentation algorithm is used to cluster trajectories corresponding to different known action proposition (AP) regions. This approach is under development/in preparation for submission by Felix Yanwei Wang and Nadia Figueroa, see dsltl.

Household Tasks

Cooking preparation task

This task involves scooping and mixing ingredients from bowls. The script franka_cooking_process_rosbags.m loads the rosbags recorded by tracking the end-effector for the franka emika panda during kinesthetic demonstrations as shown below:

This kinesthetic teaching example is documented in the franka_interactive_controllers package or the easy-kinesthetic-recording package on the latest-franka branch.

Note: The franka_cooking_process_rosbags.m script only extracts the trajectories as shown above.

Trajectory Segmentation: In order to learn individual goal-oriented motion policies (such as attractor-based Dynamical Systems) from this data one must segment the trajectories into clusters as shown below:

The same segmentation algorithm for the industrial task is used here. See dsltl or contact Felix Yanwei Wang and/or Nadia Figueroa.

Table setting task

Involves grasping plates/cutlery from dish rack and placing it on a table. The script franka_tablesetting_process_rosbags.mloads the rosbags recorded by tracking the end-effector for the franka emika panda during kinesthetic demonstrations as shown in the kinesthetic teaching example with the franka_interactive_controllers package or the easy-kinesthetic-recording package on the latest-franka branch.

Gripper State-Based Trajectory Segmentation Since these continuous demonstrations involving a series of pick-and-place tasks we can automatically segment the trajectories into goal-oriented clusters based on the state of the of gripper and the object locations where the gripper grasped/released an object.

To fill:...

Contact

Nadia Figueroa (nadiafig AT seas dot upenn dot edu)

rosbag_to_mat's People

Contributors

nbfigueroa avatar

Watchers

 avatar James Cloos avatar

Forkers

sunannnsun

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.