Similar Items: Equivalence of Coarse and Fine-Grained Models for Learning with Distribution Shift