# SAFEVISION: Efficient Image Guardrail with
Robust Policy Adherence and Explainability

This repository is the official implementation of SAFEVISION: Efficient Image Guardrail with
Robust Policy Adherence and Explainability. 

## Requirements

To install requirements:

```setup
pip install -r requirements.txt
```

## Training

Our training code includes four stages: **dataset creation**, **model preparation**, **self-refinement training**, and **post-training**. Code for each stage is provided in each subdirectory with detailed documentation.

## Evaluation

Code for inference and evaluation is provided in the subdirectory `Inference` with detailed documentation.
