Created by Li-Zhong Szu-Tu, Ting-Lin Wu, Chia-Jui Chang, He Syu, Yu-Lun Liu
This repository contains PyTorch implementation of YearCLIP in "Beyond Memorization: A Multi-Modal Ordinal Regression Benchmark to Expose Popularity Bias in Vision-Language Models".
Project Page | Paper | Dataset | Statistics
git clone --depth 1 https://github.com/Sytwu/BeyondMemocd BeyondMemo
sh prepare.shDownload links: [Google Drive]
Download data and save them to data/ according to the config files.
Base weights download links: [Google Drive]
Download checkpoints (Pytorch/CLIP/Custom) and save them to .cache/ accordingly.
.cache
├── clip
│ ├── RN50.pt
│ └── ViT-B-16.pt
├── resnet
│ └── resnet50_imagenet.pt
└── vgg
├── vgg16_imagenet.pt
└── vgg_imdb_wiki.pt
YearCLIP best weights (MAE=39.26) download links: [Google Drive]
Download checkpoints and save them to results/building/ accordingly.
Manually install:
conda create --name yearclip python=3.8 -y
conda activate yearclip
pip install "pip<24.1"
pip install -r requirements.txt
pip install git+https://github.com/openai/CLIP
pip install -e .Directly run the code (train+test):
python scripts/run.py --config configs/building.yamlReproduce from ckpt (test):
python scripts/run.py --config configs/building.yaml --test_onlyReproduce YearCLIP best (test):
python scripts/run.py --config configs/building.yaml --output_dir results/building/YearCLIP_114514 --test_onlyTry out the interactive Gradio demo locally:
conda activate yearclip
python gradio_demo_local.pyThen open http://localhost:7861 in your browser.
Features:
- Upload building images or select from example datasets (FI-London, MapYourCity, YearGuessr)
- Optional GPS coordinates for improved accuracy
- AI-powered explainability showing architectural features
- Interactive card-based example gallery
Each experiment has its own name, with several config component names split by "_".
The experiment folder includes:
ckpt/: checkpoints*_logger/: the logs frompytorch_lightningconfig.yaml: configrun.log: log the status of model during runningval/test_stats.json: metrics to be parsedval/val_stats.json: metrics to be parsedval/ordinality.json: metrics to be parsed
Many thanks to the following repositories:
If you find this codebase helpful, please consider to cite:
@misc{szutu2025memorizationmultimodalordinalregression,
title={Beyond Memorization: A Multi-Modal Ordinal Regression Benchmark to Expose Popularity Bias in Vision-Language Models},
author={Li-Zhong Szu-Tu and Ting-Lin Wu and Chia-Jui Chang and He Syu and Yu-Lun Liu},
year={2025},
eprint={2512.21337},
archivePrefix={arXiv},
primaryClass={cs.CV},
url={https://arxiv.org/abs/2512.21337},
}
