IDiff-Face icon indicating copy to clipboard operation
IDiff-Face copied to clipboard

Data root structure

Open ZhouCX117 opened this issue 2 years ago • 4 comments

Hi, thanks for your interesting work! What's your data root structure? I meet some mistakes when reading the datasets.

ZhouCX117 avatar Aug 29 '23 04:08 ZhouCX117

Hi, thanks for your interesting work! What's your data root structure? I meet some mistakes when reading the datasets.

I think there may be some problems in this codes when reading the datasets due to some carelessness. I reconstructed "samples_with_embeddings_folder_dataset.py", as long as the image and its embedding are corresponding. You can try it.

Suimingzhe avatar Aug 29 '23 05:08 Suimingzhe

@Suimingzhe Could you provide the related code? Thanks! I haven't use ffhq dataset before, and my data root structure is as follows. I revise the load_img_paths function in the extract_face_embeddings_from_dir.py.def load_img_paths(datadir): """load num_imgs many FFHQ images""" dir_files = sorted(os.listdir(datadir)) image_list=[] for f_name in dir_files: for img_file in os.listdir(os.path.join(datadir, f_name)): if img_file.endswith(".jpg") or img_file.endswith(".png"): image_list.append(os.path.join(datadir, f_name,img_file)) return image_list image image

ZhouCX117 avatar Aug 29 '23 06:08 ZhouCX117

i'm also facing some issues with "samples_with_embeddings_folder_dataset.py", it was throwing the error. @Suimingzhe if you have updated script could you please provide. @fdbtrs @ZhouCX117 image

TE-7000030346 avatar Feb 13 '24 11:02 TE-7000030346

Even in the new version of the code, I encountered the same issue. Has anyone solved it?

LiuXiYing avatar Feb 29 '24 08:02 LiuXiYing