Browse Source

更新 gen_Pnet_train_data.py

fetches/Mortihoo/master
kkkim 7 years ago
parent
commit
f655b22a50
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      dface/prepare_data/gen_Pnet_train_data.py

+ 1
- 1
dface/prepare_data/gen_Pnet_train_data.py View File

@@ -43,7 +43,7 @@ def gen_pnet_data(data_dir,anno_file,prefix):
for annotation in annotations: for annotation in annotations:
annotation = annotation.strip().split(' ') annotation = annotation.strip().split(' ')
im_path = os.path.join(prefix,annotation[0]) im_path = os.path.join(prefix,annotation[0])
bbox = map(float, annotation[1:])
bbox = list(map(float, annotation[1:]))
boxes = np.array(bbox, dtype=np.int32).reshape(-1, 4) boxes = np.array(bbox, dtype=np.int32).reshape(-1, 4)
img = cv2.imread(im_path) img = cv2.imread(im_path)
idx += 1 idx += 1


Loading…
Cancel
Save