def main(): """ Entry point """ # parse CLI args parser = make_parser(description) setup_parser(parser) args = parser.parse_args() run_commands(args, logger)
default_vocab_tree_path): os.symlink(args.vocab_tree_path, default_vocab_tree_path) configuration_files = glob(os.path.join(args.input_path, "*.yaml")) for config_file in configuration_files: configuration_name = config_file.split("/")[-1].replace(".yaml", "") print("Running configuration called '{}' found at '{}'".format( configuration_name, config_file)) create_output_path(os.path.join(args.output_path, configuration_name), False, False) commands = read_config( config_file, args.image_path, os.path.join(args.output_path, configuration_name), args.colmap_path) try: run_commands(commands, os.path.join(args.output_path, configuration_name, "log.json"), verbose=False) except Exception as e: print( "Failed to run the configuration file {} because of exception {}" .format(configuration_name, e)) continue print("Completed configuration file {}".format(configuration_name))