> For the complete documentation index, see [llms.txt](https://avikpal.gitbook.io/social-driving/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://avikpal.gitbook.io/social-driving/master.md).

# Social Driving

![Snapshot of 7 agents in a nuScenes Intersection](/files/-MKKYQ2qPRdks5-ZJIEQ)

## Installation

Create a new Conda environment

```
$ conda create --name sdriving python=3.8
$ conda activate sdriving
```

Follow the instructions given [here](https://pytorch.org/get-started/locally/) to install PyTorch. Install PyTorch version `1.5.2` or `1.7` if you want to use JIT compilation which speeds up the code by roughly 1.5-2x.

Install the [Nuscenes DevKit](https://github.com/nutonomy/nuscenes-devkit/) for access to realistic simulation environments. Use the master branch instead of the pip version. Additionally, download the map expansion pack.

Finally, install sdriving using the following instructions.

```
$ git clone https://github.com/fidler-lab/social-driving.git sdriving
$ cd sdriving
$ python setup.py develop
```

If you need to train an agent, some additional configuration is needed. You can skip these steps if you are only interested in generating rollouts / don't care about logging on the server (using `WANDB_MODE=dryrun`).

1. Create a Wandb account using `wandb login` and following the steps given there.
2. A project named `social-driving` will be automatically created. If anything goes wrong here please open an issue.
