I have been able to do so much so far, would really appreciate helps from others to do remaining tasks.
Thank you 
from torch.utils.data import Dataset
import torch
import torchvision
import pandas as pd
from skimage.io import imread
from skimage.color import gray2rgb
class ChallengeDataset(Dataset):
def init(self, dataset,csv_path,train_split=0.8 ):
self.data=pd.read_csv(csv_path)
def getitem (self,index):
pixel_sequence = self.data[‘pixels’][index]
face = [int(pixel) for pixel in pixel_sequence.split(’ ')]
label = self.labels[index]
    return face, label