Giter VIP home page Giter VIP logo

opvp3's Introduction

Feasible Region Self-Limitation: A Novel Approach to Policy Optimization in Offline Reinforcement Learning

This project provides the open source implementation of the POFRS method introduced in the paper: "Feasible Region Self-Limitation: A Novel Approach to Policy Optimization in Offline Reinforcement Learning" .

Installation

1. System requirements

  • Tested in Ubuntu 20.04, should be fine with Ubuntu 18.04
  • I would recommend to use Anaconda3 for python env management

2. System-wise dependencies installation

Since we will use mujoco and mujocu_py for the gym environment experiments, so some dependencies should be installed with sudo permissions. To install the dependencies, run D4RL can be installed by cloning the repository as follows:

git clone https://github.com/Farama-Foundation/d4rl.git
cd d4rl
pip install -e .

And enter the sudo password to finish dependencies installation.

3. Anaconda Python env setup

Back to the repo root folder, activate a python 3.7 virtual anaconda env, and then run

conda create -n POFRS python=3.7
conda activate POFRS
cd ../.. && bash install_all.sh

It will install the modified gym and this repo's python package dependencies that are listed in requirement.txt. Note that we modify the original environment repos to accelerate the training process, so not using our provided envs may require additional hyper-parameters fine-tuning.

4. Install pytorch

To install the pytroch, run

pip install torch==1.8.0+cu111 torchvision==0.9.0+cu111 torchaudio==0.8.0 -f https://download.pytorch.org/whl/torch_stable.html

You can also refer to this tutorial tutorial here for installation on your platform.

Training

How to run a single experiment

Before running, you need to download the dataset.

Simply run

python script/POFRS_main.py -wan

Check the result of the experiment

You can log in to Wandb to view the training results.

opvp3's People

Contributors

zhushi-math avatar

Watchers

 avatar

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.