def __getitem__(
        self, exp_idx: Union[int, slice]
    ) -> Union[TCLDataset, Sequence[TCLDataset]]:
        """
        Gets the dataset associated to an experience.

        :param exp_idx: The ID of the experience.
        :return: The dataset associated to the experience.
        """
        # A lot of unuseful lines needed for MyPy -_-
        indexing_collate: Callable[[Iterable[TCLDataset]], Sequence[TCLDataset]] = (
            lambda x: list(x)
        )
        result = manage_advanced_indexing(
            exp_idx,
            self._get_experience_and_load_if_needed,
            len(self),
            indexing_collate,
        )
        return result

        Gets the dataset associated to an experience.

        :param exp_idx: The ID of the experience.
        :return: The dataset associated to the experience.
        
avalanche/benchmarks/scenarios/deprecated/lazy_dataset_sequence.py