Filename print twice

Hi, I always get naming error when loading my own dataset:
why the filename print twice?
FileNotFoundError: [Errno 2] No such file or directory: ‘./dataset/train_GT./dataset/train/32.png’
My folder structure:
is there something wrong with the filename? and I define GT_path as follows:
` def getitem (self, index):

image_path = self.image_paths[index]
filename = image_path.split(’_’)[-1][:-len(".jpg")]
GT_path = self.GT_paths + filename + ‘.png’`
With reagards.Any help would be so grateful!

why you are split with (’’)
filename = image_path.split(’
you get --> ./dataset/train/32

and not with (’/)’
filename = image_path.split(’/’)[-1][:-len(".jpg")]