Datasets:
Download code/README.md from nvidia/VESPER: direct link, hf CLI and curl.
- Browser
- Download file 2.56 kB
-
https://huggingface.co/datasets/nvidia/VESPER/resolve/main/code/README.md
- Command line
-
hf download hf://datasets/nvidia/VESPER/code/README.md
-
curl -L -o README.md https://huggingface.co/datasets/nvidia/VESPER/resolve/main/code/README.md
VESPER evaluation code
Minimal code to evaluate a vision-language model on VESPER. It queries the model through an OpenAI-compatible chat-completions API, labels each answer as stop or continue with an LLM judge, and reports the paper's metrics.
Setup
cd code
pip install -r requirements.txt
export VLM_API_BASE="https://your-provider.example" # /v1/chat/completions is appended
export VLM_API_KEY="<your-api-key>"
If your endpoint's path does not end in /v1/chat/completions, pass the full URL
with --api-url. Model names are passed through unchanged, so use the names your
provider expects.
Usage
Run the commands from this code/ directory. The annotations and clips are in the
parent directory.
# 1. Query the model under the four prompt conditions.
python -m evaluation.run_inference \
--scenarios ../benchmark.json \
--model gemini-2.5-pro \
--output-dir ./eval_results
# 2. Label each answer with the LLM judge. The paper used GPT-5.2.
python -m evaluation.run_judge \
--output-dir ./eval_results \
--judge-model gpt-5.2
# 3. Report dangerous (D) and safe (S) accuracy and Geo = sqrt(D * S).
python -m evaluation.summarize_results \
--output-dir ./eval_results
Settings used in the paper
| Models | Visual input |
|---|---|
| Gemini 2.5 Pro, Gemini 2.5 Flash, Gemini 3 Flash | the whole clip as one video (--input-mode gemini_video, chosen automatically) |
| GPT-5.1 | 32 frames (--input-mode openai_frames --max-frames 32) |
| Claude Sonnet 4.6 | 16 frames (--input-mode openai_frames --max-frames 16) |
| Kimi K2.5 | 10 frames (--input-mode openai_frames --max-frames 10) |
--input-mode auto, the default, sends frames to models whose name containsgpt-or/gpt, and the whole clip to every other model. The whole clip goes as a base64data:video/mp4URL in animage_urlpart; if your endpoint does not accept video that way, use--input-mode openai_frames.- Frames are spread evenly from the first to the last frame of the clip.
- Model requests carry only the model name and the messages. Each judge request
sends
temperature: 0andmax_tokens: 64.
License
The code is released under the NVIDIA OneWay Noncommercial License; see LICENSE. It may be used non-commercially, meaning for research or evaluation purposes only. The dataset in the parent directory is covered by the NVIDIA Evaluation Dataset License Agreement.