The method for the class must be __getitem__(self, index) not get_item()
def __getitem__(self, index):
    sample = torch.Tensor(self.data_arr[index])
    enc_label = torch.Tensor(self.enc_label_arr[index])

    return (sample, enc_label)