Commit 99d13fb8 authored by 吴升宇's avatar 吴升宇

fix celery

parent f09724d7
...@@ -10,7 +10,7 @@ def img_to_three_color_map(source_path, target_path): ...@@ -10,7 +10,7 @@ def img_to_three_color_map(source_path, target_path):
parser = argparse.ArgumentParser(description="PyTorch Object Detection Webcam Demo") parser = argparse.ArgumentParser(description="PyTorch Object Detection Webcam Demo")
parser.add_argument( parser.add_argument(
"--config-file", "--config-file",
default="../configs/caffe2/e2e_mask_rcnn_R_50_FPN_1x_caffe2.yaml", default="configs/caffe2/e2e_mask_rcnn_R_50_FPN_1x_caffe2.yaml",
metavar="FILE", metavar="FILE",
help="path to config file", help="path to config file",
) )
...@@ -50,7 +50,7 @@ def img_to_three_color_map(source_path, target_path): ...@@ -50,7 +50,7 @@ def img_to_three_color_map(source_path, target_path):
# load config from file and command-line arguments # load config from file and command-line arguments
cfg.merge_from_file(args.config_file) cfg.merge_from_file(args.config_file)
cfg.merge_from_list(args.opts) # cfg.merge_from_list(args.opts)
cfg.freeze() cfg.freeze()
# prepare object that handles inference plus adds predictions on top of image # prepare object that handles inference plus adds predictions on top of image
......
...@@ -13,14 +13,18 @@ def write_redis(source_path, target_path): ...@@ -13,14 +13,18 @@ def write_redis(source_path, target_path):
def main(): def main():
rs = os.walk('../../fashionbase/images/dataset_0520/weiyi') rs = os.walk('../fashionbase/images/dataset_0520/weiyi')
for a, b, files in rs: for a, b, files in rs:
for file in files: for file in files:
source_path = '../../fashionbase/images/dataset_0520/weiyi/' + file dir = source_path.replace('dataset_0520', 'dataset_0520_10000')
fold = os.exit(dir)
if not fold:
os.mkdir(dir)
source_path = '../fashionbase/images/dataset_0520/weiyi/' + file
target_path = source_path.replace('dataset_0520', 'dataset_0520_10000') target_path = source_path.replace('dataset_0520', 'dataset_0520_10000')
print(source_path) print(source_path)
print(target_path) print(target_path)
# write_redis(source_path, target_path) #write_redis(source_path, target_path)
if __name__ == '__main__': if __name__ == '__main__':
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment