src/transformers/models/jukebox/modeling_jukebox.py/JukeboxAttention/_cache_len
class JukeboxAttention:    def _cache_len(self):
        return 0 if "key" not in self.cache else self.cache["key"].shape[1]