## Main requirements

The experiments are conducted in the following environments:
* **torch == 2.1.1**
* **torchvision == 0.16.1**
* **Python 3.9**

Install the environments by the following steps:
```
conda install pytorch==2.1.1 torchvision==0.16.1 pytorch-cuda=12.1 -c pytorch -c nvidia
pip install -r requirements.txt
pip install git+https://github.com/openai/CLIP.git
```

## Pretrain models and datasets

Our code uses pre-trained CLIP model and Stable Diffusion model. Their weight will be automatically downloaded when running the code. The datasets will also be downloaded by set the download parameter to `True` in `data_providers/al_sampler.py`.

## Usage

```bash
python main.py --method ours_gen --dataset cifar10 --iter 0
```
