def __getitem__(
        self, idx: int
    ) -> Union[TorchTrainingDatasetOutput, TorchInferenceDatasetOutput]:
        """Returns a sample drawn from this dataset."""
Returns a sample drawn from this dataset.
darts/utils/data/torch_datasets/dataset.py