AISTATS 2026 · arXiv:2604.10952
UniPROT is a novel subset selection framework that minimises the optimal transport (OT) distance between a uniformly weighted prototypical distribution and the target distribution. Existing methods often rely on implicit importance scores skewed towards majority classes, leading to low-quality prototypes for minority classes. UniPROT reformulates the OT marginal constraints to yield a partial optimal transport-based submodular objective, enabling a greedy algorithm with a
Given a source pool
Directly solving this is intractable because the uniform-weight constraint makes the objective super-additive, ruling out standard submodular guarantees. UniPROT addresses this by reformulating the OT marginal constraints to obtain an equivalent partial optimal transport (POT) objective:
where
UniPROT/
├── UniPROT/ # Core UniPROT implementation
│ ├── UniPROT.py # Greedy prototype selector (exact & approx)
│ ├── sinkhorn.py # Partial OT solvers (custom + POT wrappers)
│ └── fairOT.py # Standalone driver / quick-start script
│
├── baselines/ # Comparison methods
│ ├── main.py # TinyImageNet baseline experiment entry point
│ ├── SPOTgreedy.py # SPOT-Greedy subset selection
│ ├── evaluation.py # Cost/similarity matrices and data splits
│ ├── features.py # HuggingFace feature extraction
│ ├── loader.py # TinyImageNet DataLoader
│ └── MMDcritic/ # MMD-Critic baseline
│
├── image/ # Vision experiments
│ ├── exp.py # Main image experiment (all methods & datasets)
│ ├── exp_ablation.py # Ablation: regularisation / method variants
│ ├── exp_ablation_other_datasets.py
│ ├── datasets_viz.py # Dataset visualisation utilities
│ └── proto_selection_evals/ # Flickr30K prototype evaluation scripts
│
└── llm-experiments/ # LLM fine-tuning experiments
├── train/
│ ├── train.py # Main training entry point
│ ├── uniprot.py # UniPROT data selection for LLMs
│ ├── facility_location.py # Facility-location baseline
│ ├── SPOTgreedy.py # SPOT-Greedy baseline
│ ├── subset_trainer_distributed.py # Distributed subset trainer
│ └── ...
├── data/ # Dataset loaders and prompt templates
├── math_eval/ # Math reasoning evaluation suite
├── superglue_eval/ # SuperGLUE evaluation suite
└── scripts/ # Shell scripts for full runs
# Core dependencies
pip install torch torchvision transformers peft
pip install POT scikit-learn numpy matplotlib tqdm scipy
# Optional: GPU-accelerated similarity matrices
pip install cupy-cuda12x # match your CUDA version
# Optional: experiment tracking
pip install wandbimport torch
from UniPROT.UniPROT import UniPROT
# Build a cosine-similarity matrix (n_source × n_target)
S = torch.randn(1000, 500)
# Select 50 prototypes using the fast approximation
selector = UniPROT(regularization=0.1, device="cpu")
indices, objectives = selector.prototype_selection(
S, num_prototypes=50, method="approx", epsilon=0.001
)
# indices — LongTensor of selected row indices into Sfrom UniPROT.sinkhorn import pot_partial_library, pot_partial_extended
# POT-based solver (recommended)
plan = pot_partial_library(cost_matrix, reg=0.1, k=50)
# Custom extended-dummy-row solver
plan = pot_partial_extended(cost_matrix, reg=0.1, k=50)cd image
# Full comparison: UniPROT vs SPOT-Greedy vs MMD-Critic vs uniform random
# Datasets: MNIST, Letter, USPS, TinyImageNet, Flickr30K
# Evaluation: 1-NN accuracy under varying class skew (10 %–100 %)
python exp.py
# Ablation over regularisation strength and method variants
python exp_ablation.pyKey hyperparameters (edit at the top of exp.py):
| Parameter | Default | Description |
|---|---|---|
total_prototypes |
500 | Fixed prototype budget |
regularization |
0.1 | UniPROT entropic regularisation |
skew_levels |
[10,30,50,70,100] | Target class-skew percentages |
n_runs |
5 | Independent random repetitions |
Results are saved to image/plots/.
# Set dataset path, then run SPOT-Greedy + random baselines
export TINYIMAGENET_ROOT=/path/to/tiny-imagenet-200
python baselines/main.pycd llm-experiments
# SuperGLUE (RTE, MRPC, CoLA, QQP …) with UniPROT data selection
python train/train.py \
--model_name_or_path microsoft/phi-2 \
--train_files superglue-rte \
--output_dir ./output/phi2_rte \
--data_selection_method uniprot \
--num_train_epochs 3 \
--per_device_train_batch_size 8 \
--learning_rate 2e-4 \
--lora_r 8 \
--regularization 0.1
# Convenience shell scripts
bash scripts/run_superglue.sh
bash scripts/run_math.shSupported --data_selection_method values: none, facility_location, greedy_diversity, uniprot.
If you use UniPROT in your research, please cite:
@inproceedings{chanda2026uniprot,
title = {UniPROT: Uniform Prototype Selection via Partial Optimal Transport with Submodular Guarantees},
author = {Chanda, Prateek and Agrawal, Prayas and Gurumoorthy, Karthik S. and Ramakrishnan, Ganesh and Mishra, Bamdev and Jawanpuria, Pratik},
booktitle = {Proceedings of the 29th International Conference on Artificial Intelligence and Statistics (AISTATS)},
year = {2026},
eprint = {2604.10952},
archivePrefix = {arXiv},
}