Datasets

Glue Factory supports several datasets for training and evaluation. Most datasets are implemented to download themselves automatically to the data/ directory.

Training Datasets

  • Homographies (datasets.homographies):
    • Generates synthetic homographies from the Revisited Oxford-Paris 1M dataset.
    • Used for the first stage of training (pre-training).
  • MegaDepth (datasets.megadepth):
    • Real-world outdoor scenes with depth and pose.
    • Used for fine-tuning.

Evaluation Benchmarks

  • HPatches (datasets.hpatches): Planar scenes with illumination and viewpoint changes.
  • MegaDepth-1500: A validation subset of MegaDepth for relative pose estimation.
  • ScanNet-1500: Indoor scenes with ground truth pose.
  • ETH3D: High-resolution images for line and point evaluation.

Helper Datasets

  • datasets.image_folder: Loads images from a local directory without ground truth.
  • datasets.image_pairs: Loads pairs of images defined in a text file.
  • datasets.posed_images: Loads images with associated pose information.

Interface

All datasets inherit from BaseDataset. Key configuration parameters usually include:

  • batch_size: Number of samples per batch.
  • num_workers: Number of data loading threads.
  • preprocessing: Image resizing and padding options (e.g., resize: 1024, side: long).
  • grayscale: Convert images to grayscale on load.