User GuideΒΆ
This page is the day-to-day operations manual for SpaRRTa after initial setup is complete.
If you have not done your first install or first run yet, start with Getting Started. This guide assumes you already understand the basic two-repo layout:
- This repository: project website and
unreal-scene-gen/ turhancan97/SpaRRTa: evaluation, probing, transfer, lego evaluation, and attention analysis
The goal here is to help researchers move from βit runsβ to βI know how to use it well.β
Environment Variables and Data LayoutΒΆ
The evaluation repo relies on a small set of environment variables to find data, cache features, and store model weights.
Core VariablesΒΆ
export SPARRTA_DATA_ROOT=/path/to/sparrta/unreal
export SPARRTA_LEGO_ROOT=/path/to/sparrta/lego
export SPARRTA_ANALYSIS_ROOT=/path/to/sparrta/attn
export SPARRTA_CACHE_DIR=./cache
export SPARRTA_MODELS_DIR=~/.cache/sparrta/models
What each variable is forΒΆ
SPARRTA_DATA_ROOT: synthetic Unreal dataset used for the main benchmarkSPARRTA_LEGO_ROOT: real-world lego dataset used for sim-to-real evaluationSPARRTA_ANALYSIS_ROOT: attention-analysis dataset with masksSPARRTA_CACHE_DIR: cache for frozen features computed from backbonesSPARRTA_MODELS_DIR: storage location for downloaded model weights
Expected synthetic data layoutΒΆ
The upstream evaluation repo documents the Unreal dataset like this:
$SPARRTA_DATA_ROOT/
forest/mid-objects/
img_0001.jpg
params_0001.json
...
desert/mid-objects/
winter_town/mid-objects/
bridge/mid-objects/
city/mid-objects/
Each sample is an image plus a matching params_*.json file. In practice:
img_*.jpgstores the rendered sceneparams_*.jsonstores the camera and actor geometry used by the benchmark
The lego dataset is organized by class labels such as front, back, left, and right, while the attention-analysis dataset adds segmentation masks under a metadata/ folder.
Common Evaluation WorkflowsΒΆ
Run one backbone on one environmentΒΆ
This is the safest default experimental path:
python train.py \
backbone=dino_b16 \
dataset=unreal_position \
probe=classifier probe._target_=sparrta.models.probes.EfficientProbing \
dataset.perspective=camera \
environment=forest
This command means:
- backbone:
dino_b16 - dataset: synthetic Unreal benchmark
- probe head:
EfficientProbing - perspective: camera / egocentric
- environment: forest
Switch from egocentric to allocentricΒΆ
To run the same experiment from the human viewpoint:
python train.py \
backbone=dino_b16 \
dataset=unreal_position \
probe=classifier probe._target_=sparrta.models.probes.EfficientProbing \
dataset.perspective=human \
environment=forest
Use:
dataset.perspective=camerafor SpaRRTa-egodataset.perspective=humanfor SpaRRTa-allo
Swap the probe headΒΆ
The upstream repo exposes three main probing choices:
sparrta.models.probes.ClassificationHeadsparrta.models.probes.ABMILPHeadsparrta.models.probes.EfficientProbing
Example with a simpler baseline probe:
python train.py \
backbone=dino_b16 \
dataset=unreal_position \
probe=classifier probe._target_=sparrta.models.probes.ClassificationHead \
dataset.perspective=camera \
environment=forest
Change the backboneΒΆ
Once the workflow is stable, you can swap the backbone on the CLI:
python train.py \
backbone=mae_b16 \
dataset=unreal_position \
probe=classifier probe._target_=sparrta.models.probes.EfficientProbing \
dataset.perspective=camera \
environment=forest
Other safe starting choices from the upstream README include:
dinov2_b14dinov2_b14_regdinov2_l14_regdinov3_timmclip_b16_laion
Inspect the resolved Hydra configΒΆ
Before launching a run, inspect the final resolved config:
This is the fastest way to verify:
- selected backbone
- selected probe
- dataset perspective
- environment
- output configuration
Where results goΒΆ
The upstream repo writes results under its default output directory, result/. Feature caches are written under SPARRTA_CACHE_DIR.
Choosing Backbones and ProbesΒΆ
Recommended starting backbonesΒΆ
For a reliable first set of experiments, start with backbones that work out of the box:
dino_b16dinov2_b14dinov2_b14_regdinov2_l14_regdinov3_timmmae_b16clip_b16_laion
These are easier to use because they do not require separate external code repositories.
Backbones that need extra setupΒΆ
Some backbones depend on external repos or weights:
vggt_l16needsVGGT_REPOspa_b16,spa_l16needSPA_REPOcroco_b16,crocov2_b16needCROCO_REPOdinov3_b16needsDINOV3_REPOandDINOV3_WEIGHTS
If one of these fails immediately, the usual cause is a missing environment variable or missing local checkout.
Practical probe tradeoffsΒΆ
- ClassificationHead: cheapest and simplest baseline; useful for quick comparisons
- ABMILPHead: attention-based pooling; stronger than a plain pooled baseline
- EfficientProbing: strongest default choice; best fit when you care about the benchmarkβs main result that spatial information lives in patch tokens
Recommended default:
- start with
EfficientProbingfor serious experiments - use
ClassificationHeadwhen you want a lightweight baseline
Advanced WorkflowsΒΆ
Leave-one-environment-out and few-shot transferΒΆ
What it is for: testing generalization across environments and few-shot adaptation to a held-out domain.
Relevant scripts:
scripts/run_loto_fewshot.pyscripts/summarize_loto_fewshot.py
What you need:
SPARRTA_DATA_ROOT- a working evaluation installation
What to expect: result CSVs and summary tables/plots for holdout-environment transfer and adaptation performance.
The upstream repo also documents three protocol values used by the training pipeline:
defaultloto_source_to_targettarget_only
Lego sim-to-real evaluationΒΆ
What it is for: testing whether probes trained on synthetic SpaRRTa data transfer to a small real-world setup.
Relevant scripts:
scripts/run_lego_rebuttal.pyscripts/summarize_lego_rebuttal.py
What you need:
SPARRTA_LEGO_ROOT- a trained or runnable experimental configuration
What to expect: comparison results for synthetic-to-real transfer on the lego split.
Attention analysisΒΆ
What it is for: understanding where frozen backbones attend and how attention flows between objects, background, and CLS/register tokens.
Relevant scripts:
sparrta/analysis/visualize_patch_masks.pysparrta/analysis/compute_attention.pysparrta/analysis/plot_attention.pysparrta/analysis/aggregate_attention.pysparrta/analysis/attention_rollout.py
What you need:
SPARRTA_ANALYSIS_ROOT- the attention-analysis dataset with masks
What to expect: per-layer attention CSVs, plots, and rollout visualizations, usually under result/attention/<environment>/.
The upstream README shows a minimal command:
And for config inspection:
Using Custom Unreal DataΒΆ
If you want to go beyond the published benchmark data, this repository provides the Unreal generation pipeline in unreal-scene-gen.
That pipeline can generate:
- RGB images
- scene metadata in
params_*.json - optional masks via UnrealCV
This is useful for:
- generating more samples
- exploring new scene layouts
- testing custom data curation ideas
However, generated outputs should be treated carefully in relation to the evaluation repo:
- the local generator provides the core ingredients needed by SpaRRTa
- the evaluation repo expects a specific on-disk layout
- custom outputs may require adaptation to match that layout
So the practical recommendation is:
- start with the published datasets
- validate your workflow
- only then move to custom generated data
TroubleshootingΒΆ
The run fails immediately with a dataset error
Check SPARRTA_DATA_ROOT, SPARRTA_LEGO_ROOT, or SPARRTA_ANALYSIS_ROOT. A wrong path or missing dataset is the most common failure mode.
A selected backbone errors before training starts
Backbones such as VGGT, SPA, CroCo, and local DINOv3 may need external repos or local weights. If you want the most reliable path, use dino_b16, dinov2_*, dinov3_timm, mae_b16, or clip_b16_laion.
The run completes but expected outputs are missing
Inspect the resolved Hydra config first and verify the output directory assumptions. Also check whether results are being written under result/ and features under SPARRTA_CACHE_DIR.
Do I need UnrealCV for all SpaRRTa workflows?
No. UnrealCV is only needed for mask generation in the Unreal pipeline. Standard benchmark evaluation on published data does not require UnrealCV.
ReferencesΒΆ
- Getting Started
- Evaluation of VFMs
- Unreal Scene Generation
- Spatial evaluation overview
- Upstream evaluation repo: turhancan97/SpaRRTa