<h1>Reinforcement Learning from Safety Feedback</h1>

## Credit
Code build upon https://github.com/hmhuy2000/SIM-RL 

## Train RLSF and other baselines
1. To train any of the methods, use their respective ".sh" files in the Scripts dir. Note that 'SIMKC', 'SIM' and 'SDM' can be run using the run_train_good_bad.sh file with different mode settings.
For example, to run train RLSF:

    ``` bash
    ./Scripts/run_train_pref.sh

    ```
2. The parameters for each method are described in the Parameters dir.

## Environment informations
To use the the safety gymnasium environments, please specify the environment name as defined in[Safety-gymnaisum](https://www.safety-gymnasium.com/en/latest/). 

The Blocked Swimmer and Biased Pendulum environments can be accessed by specifying the env_name as 'BlockedSwimmer' and 'BiasedPendulum' respectively.

The 3 Safe Driver environments can be accessed by specifying the env_name as 'SafeDriverBlocking', 'SafeDriverTwoLanes' and 'SafeDriverLaneChange' respectively.

