changing name of val_image
Adding functions to trans_image