I am preparing my own datasets and I want to combine my own sketch and photo images into one picture for trainning on the pix2pix model. I read the "Prepare your own datasets for pix2pix"instruction carefully, also, I searched the issues similar but there is no help. So I open a new issue for help.
the sketch images are in the
/pytorch-CycleGAN-and-pix2pix/datasets/combine/A/train
and there are 72 images named like frame_0028.jpg.
the photo images are in the
/pytorch-CycleGAN-and-pix2pix/datasets/combine/B/train
and there are 72 corresponding object photo images with same name in A.
and the output folder:
/pytorch-CycleGAN-and-pix2pix/datasets/combine/AB
my first try command is:
python datasets/combine_A_and_B.py --fold_A ./datasets/combine/A --fold_B ./datasets/combine/B --fold_AB ./datasets/combine/AB
but terminal says:
[fold_A] = ./datasets/combine/A
[fold_B] = ./datasets/combine/B
[fold_AB] = ./datasets/combine/AB
[num_imgs] = 1000000
[use_AB] = False
Traceback (most recent call last):
File "datasets/combine_A_and_B.py", line 22, in
img_list = os.listdir(img_fold_A)
NotADirectoryError: [Errno 20] Not a directory: './datasets/combine/A/.DS_Store'
I think maybe I should specify the train folder, so my second try command is:
python datasets/combine_A_and_B.py --fold_A ./datasets/combine/A/train --fold_B ./datasets/combine/B/train --fold_AB ./datasets/combine/AB
terminal still unhappy:
[fold_A] = ./datasets/combine/A/train
[fold_B] = ./datasets/combine/B/train
[fold_AB] = ./datasets/combine/AB
[num_imgs] = 1000000
[use_AB] = False
Traceback (most recent call last):
File "datasets/combine_A_and_B.py", line 22, in
img_list = os.listdir(img_fold_A)
NotADirectoryError: [Errno 20] Not a directory: './datasets/combine/A/train/frame_0028.jpg'
Could anyone give me some advice? Thanks a lot !
Could you try to remove .DS_store and use python datasets/combine_A_and_B.py --fold_A ./datasets/combine/A --fold_B ./datasets/combine/B --fold_AB ./datasets/combine/AB?
Could you try to remove
.DS_storeand usepython datasets/combine_A_and_B.py --fold_A ./datasets/combine/A --fold_B ./datasets/combine/B --fold_AB ./datasets/combine/AB?
Thanks a lot. I searched the keyword '.DS_store' and got understand what happened.
find . -name '*.DS_Store' -type f -delete' to delete it.python datasets/combine_A_and_B.py --fold_A ./datasets/combine/A --fold_B ./datasets/combine/B --fold_AB ./datasets/combine/ABthen I got what I want.
@diaosiji I am getting same issue with selfie2anime dataset and deleting dstore did not solve problem
https://www.kaggle.com/arnaud58/selfie2anime
Most helpful comment
Could you try to remove
.DS_storeand usepython datasets/combine_A_and_B.py --fold_A ./datasets/combine/A --fold_B ./datasets/combine/B --fold_AB ./datasets/combine/AB?