gg-dema / Stable-Motion-Primitives-via-Imitation-and-Contrastive-Learning

Code accompanying the paper: "Stable Motion Primitives via Imitation and Contrastive Learning" (T-RO).

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Stable Motion Primitives via Imitation and Contrastive Learning

License

Code accompanying the paper: "Stable Motion Primitives via Imitation and Contrastive Learning" (T-RO). For details, please refer to https://arxiv.org/pdf/2302.10017.pdf.

The current version of the paper can be cited using the following reference:

@article{PerezDattari2023TRO,
  author  = {P\'{e}rez-Dattari, Rodrigo AND Kober, Jens},
  journal = {IEEE Transactions on Robotics},
  title   = {Stable Motion Primitives via Imitation and Contrastive Learning},
  year    = {2023},
  pages   = {1--20},
  doi     = {10.1109/TRO.2023.3289597},
  code    = {https://github.com/rperezdattari/Stable-Motion-Primitives-via-Imitation-and-Contrastive-Learning},
  file    = {https://arxiv.org/pdf/2302.10017.pdf},
  project = {FlexCRAFT},
  video   = {https://youtu.be/OM-2edHBRfc},
  oa      = {green},
}

Teaser: executing learned motion for multiple initial conditions

Options

This repository allows learning dynamical systems of multiple dimensions and orders.

First-order 2-dimensional dynamical systems

Second-order 2-dimensional dynamical systems

First-order 3-dimensional dynamical systems

First-order N-dimensional dynamical systems

Robot Experiments

This repository contains simulated experiments; however, this framework has also been tested using a KUKA LBR iiwa robot manipulator. These results are shown in https://youtu.be/OM-2edHBRfc.

Installation with poetry

You can install the package using poetry.

poetry install

Enter the virtual environment using:

poetry shell

Requirements can be found at pyproject.toml. `

Usage

In the folder src run:

Training

  python train.py --params <params_file_name>

The parameter files required for the argument params_file_name can be found in the folder params.

Simulate learned 2D motion

  python simulate_ds.py

Hyperparameter Optimization

  python run_optuna.py --params <params_file_name>

Troubleshooting

If you run into problems of any kind, don't hesitate to open an issue on this repository.

About

Code accompanying the paper: "Stable Motion Primitives via Imitation and Contrastive Learning" (T-RO).

License:MIT License


Languages

Language:Python 100.0%