hamidreza_hayatjou:

'/dataset/Train48d48.mat'


this path shouldn’t work in first place. You are trying to load something from the root subdirectory (add . in front to point to current dir)
Another thing is:



 hamidreza_hayatjou:

    def __getitem__(self, index):
        data = io.loadmat(self.mat_paths[index])



You are loading whole dataset every time single item is requested by the dataloader. Consider moving this part to __init__, otherwise it will bottleneck your loop.