fixed output_path bug