Open ping-sun opened 5 years ago
I meet the same error!
me too! do you know the reason??
anyone solved this problem?
You can execute this file. This creates the train_new folder.
python re_index.py
hi, can you help me about this question?
https://github.com/qiaoguan/Person-reid-GAN-pytorch/issues/26
Thank you very much!
You can execute this file. This creates the train_new folder.
python re_index.py
---------------------re_index.py------------------------
import os from shutil import copyfile original_path = './data/market/pytorch' def copyfolder(src, dst): files = os.listdir(src) if not os.path.isdir(dst): os.mkdir(dst) for tt in files: copyfile(src + '/' + tt, dst + '/' + tt) new_folders = ['train_new', 'val_new'] old_folders = ['train_all', 'val'] for train, data in zip(new_folders, old_folders): train_save_path = os.path.join(original_path, train) if not os.path.exists(train_save_path): os.mkdir(train_save_path) data_path = os.path.join(original_path, data) if not os.path.isdir(train_save_path): os.mkdir(train_save_path) reid_index = 0 folders = os.listdir(data_path) folders = sorted(folders) for foldernames in folders: copyfolder(data_path + '/' + foldernames, train_save_path + '/' + str(reid_index).zfill(4)) reid_index = reid_index + 1
hi, can you help me about this question?
https://github.com/qiaoguan/Person-reid-GAN-pytorch/issues/26
Thank you very much!
I run the train_baseline and met an error. In the train_baseline.py line176, a file 'train_new' is needed. However, after run 'python prepare.py', I only get 'train' and 'train_all' in file 'data/market/pytorch/'. Also in changeIndex.py line 17, the "train_save_path" is set to "val_new", is there something wrong?