-
Notifications
You must be signed in to change notification settings - Fork 2
/
main.py
30 lines (23 loc) · 937 Bytes
/
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
import os
import argparse
import yaml
if __name__ == '__main__':
parser = argparse.ArgumentParser()
parser.add_argument('--config', type=str, default='configs/SMPL.yaml', help='category_name')
args = parser.parse_args()
with open(args.config, 'r') as yaml_file:
config = yaml.safe_load(yaml_file)
print("Experiment: " + args.config)
cmd = "python optctrlpoints.py"
cmd += f" --source_data_path={config['source_data_path']}"
cmd += f" --target_data_path={config['target_data_path']}"
cmd += f" --log_dir={config['log_dir']}"
cmd += f" --dump_dir={config['dump_dir']}"
cmd += f" --num_keypoints={config['num_keypoints']}"
cmd += f" --calc_w_method={config['calc_w_method']}"
cmd += f" --eval_metric={config['eval_metric']}"
cmd += f" --seed={config['seed']}"
cmd += f" --gpu={config['gpu']}"
print("================")
print(cmd)
os.system(cmd)