Skip to content

Latest commit

 

History

History
42 lines (32 loc) · 1.25 KB

README.md

File metadata and controls

42 lines (32 loc) · 1.25 KB

Generating-by-Discovering (GRADER)

This is the official implementation of NeurIPS 2022 paper Generalizing Goal-Conditioned Reinforcement Learning with Variational Causal Reasoning. The released code only contains the Chemistry environment modified from this repo.

Setup code environment

The code is tested with Ubuntu 20.04 and Python 3.8.

# clone the code
git clone https://github.com/GilgameshD/GRADER.git
cd GRADER

# create conda environment
conda create -n grader python=3.8
conda activate grader

# install dependency
pip install -r requirement.txt

Run experiment

Run the following script to train and test agents under different settings.

# mode - [IID/OOD-S]: environment type
# grader_model - [full/causal/gnn/mlp]: model type
# graph - [collider/chain/full/jungle]: groundtruth graph used in chemistry environment
# exp_name: name of the folder to save results

# one example of training GRADER in IID setting
python train_agent.py --mode IID --grader_model causal --graph chain --exp_name test