import os config_filename = "fastmri.yaml" default_config_content = """brain_path: brain path here knee_path: knee path here log_path: log path here checkpoint_path: checkpoint path here """ def check_and_create_config(): if not os.path.exists(config_filename): print(f"{config_filename} not found. Creating with default template...") with open(config_filename, "w") as config_file: config_file.write(default_config_content) print(f"Default configuration file created at {config_filename}.") else: print(f"{config_filename} already exists. No changes made.") check_and_create_config()