Add caching for modular scale, because it's slow