GithubHelp home page GithubHelp logo

tianhongdai / div-hindsight Goto Github PK

View Code? Open in Web Editor NEW
10.0 2.0 2.0 2.78 MB

This is the official code of our paper "Diversity-based Trajectory and Goal Selection with Hindsight Experience Relay" [PRICAI 2021].

License: MIT License

Python 100.00%
deep-reinforcement-learning hindsight-experience-replay determinantal-point-processes

div-hindsight's Introduction

Diversity-based Trajectory and Goal Selection with Hindsight Experience Replay

This is the official implementation of our paper "Diversity-based Trajectory and Goal Selection with Hindsight Experience Replay" [PRICAI 2021][Arxiv][Slides].

envs

Pre-requisites

  • python==3.6.8
  • gym==0.12.5
  • mujoco-py==2.0.2.0
  • tensorflow==1.13.1

Installation

  1. Install the OpenMPI:
sudo apt-get install openmpi-bin openmpi-doc libopenmpi-dev
  1. Install the required python packages.
  2. Install baseline:
pip install -e .

Usage

Enter to the specific location:

cd ./baselines/her/experiment

The scripts for FetchEnv:

python train.py --env_name FetchPush-v1 --clip_div=0.001 --use_kdpp True --prioritization diversity --seed 0 --n_epochs 50 --num_cpu 16 --logdir logs/fetchpushv1/cpu16ep50/alg=DDPG+DTGSH=/r0 --logging True
python train.py --env_name FetchPickAndPlace-v1 --clip_div=0.001 --use_kdpp True --prioritization diversity --seed 0 --n_epochs 50 --num_cpu 16 --logdir logs/fetchpickv1/cpu16ep50/alg=DDPG+DTGSH=/r0 --logging True

The scripts for HandEnv:

python train.py --env_name HandManipulateEggFull-v0 --use_kdpp True  --prioritization diversity --seed 0 --goal_type full --sigma 0.1 --n_epochs 50 --num_cpu 16 --logdir logs/handegg1/cpu16ep50/alg=DDPG+DTGSH=/r0 --logging True
python train.py --env_name HandManipulateBlockRotateXYZ-v0 --use_kdpp True  --prioritization diversity --seed 0 --goal_type rotate --sigma 0.1 --n_epochs 50 --num_cpu 16 --logdir logs/handblock1/cpu16ep50/alg=DDPG+DTGSH=/r0 --logging True
python train.py --env_name HandManipulatePenRotate-v0 --use_kdpp True --prioritization diversity --seed 0 --goal_type rotate --sigma 0.1 --n_epochs 50 --num_cpu 16 --logdir logs/handpen1/cpu16ep50/alg=DDPG+DTGSH=/r0 --logging True

Acknowledgements

BibTex

To cite this code for publications - please use:

@inproceedings{dai2021her
	author={Dai, Tianhong and Liu, Hengyan and Arulkumaran, Kai and Ren, Guangyu and Bharath, Anil Anthony},
	title={Diversity-Based Trajectory and Goal Selection with Hindsight Experience Replay},
	booktitle={Pacific Rim International Conference on Artificial Intelligence},
	year={2021},
	pages={32--45},
	publisher={Springer},
}

div-hindsight's People

Contributors

tianhongdai avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

div-hindsight's Issues

error when running the code

hello,
when I running the code, it reports an error like the following shows:

marg= lmbda[i-1] * E[rem-1,i-1]/(E[rem,i]+1e-100)
IndexError: index -101 is out of bounds for axis 0 with size 100

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.