I am looking at the documentation and this guide
And I need to write in
def __getitem__(self, idx):
Which gets the length of the dataset, and the getting a data sample using a particular index. So I am wondering if this is appropriate to use for multiple files, and if so, are there any best practices for this?