Quick Start

Run FPS-UDA from a packaged H5 in a few commands.

The repository includes a compressed Office31 amazon -> webcam ViT feature bank. It keeps all source and target samples for that task and only the views needed by the example config.

Install

Install directly from GitHub for normal use.

pip install "fps-uda @ git+https://github.com/baogegeJiang/FPS.git"

Clone the repository when you want the packaged H5 fixture and examples.

git clone https://github.com/baogegeJiang/FPS.git
cd FPS
pip install -e ".[dev]"

Run the smoke example

PYTHONPATH=src python -m fps_uda.cli train \
  --config configs/examples/office31_amazon_to_webcam_vit_packaged_h5.yaml \
  --iter-num 2 \
  --out runs/examples/office31_aw_vit_smoke

After editable install, replace PYTHONPATH=src python -m fps_uda.cli with fps-uda.

Optional extras

Install only the pieces you use

Feature extraction

pip install -e ".[vision]"

Installs image/backbone dependencies for extracting feature banks.

Hugging Face banks

pip install -e ".[hf]"

Installs downloader support for released H5 feature banks.

Transformers backbones

pip install -e ".[transformers]"

Installs support for HuggingFace ViT, CLIP, and AutoModel vision backbones.

Next steps

Move from smoke test to a benchmark task

1

Download banks

PYTHONPATH=src python scripts/download_feature_banks.py all
2

Analyze views

PYTHONPATH=src python -m fps_uda.cli analyze-feature-bank \
  --feature-bank fps_h5cache/banks/office31_vit.h5 \
  --source-domain amazon \
  --target-domain webcam \
  --out runs/analysis/office31_vit
3

Train

PYTHONPATH=src python -m fps_uda.cli train \
  --config configs/training/office31/amazon_to_webcam/vit.yaml \
  --out runs/office31/amazon_to_webcam/vit